« API TLE options » : différence entre les versions

De Gentleman
Aller à la navigation Aller à la recherche
Aucun résumé des modifications
 
(9 versions intermédiaires par le même utilisateur non affichées)
Ligne 3 : Ligne 3 :


=== Single TLE ===
=== Single TLE ===
Data corresponds to the ones described [[TLE_options#Single_TLE|here]] here when using the <font color=#FF8C00 title="Graphical User Interface">GUI</font>.


We have to instantiate a [{{PathCurrentJavaDoc}}/fr/cnes/dynvol/gentleman/calc/data/tle/GtmSingleTle.html GtmSingleTle] object. Two constructors are then available :
We have to instantiate a [{{PathCurrentJavaDoc}}/fr/cnes/dynvol/gentleman/calc/data/tle/GtmSingleTle.html GtmSingleTle] object. Two constructors are then available :
Ligne 23 : Ligne 21 :
final GtmSingleTle data = new GtmSingleTle(date, geo.getAmountOfPoints(), 1.0, false, false, GtmBuildingMethods.DIFFERENTIAL, 30);
final GtmSingleTle data = new GtmSingleTle(date, geo.getAmountOfPoints(), 1.0, false, false, GtmBuildingMethods.DIFFERENTIAL, 30);
</syntaxhighlight>
</syntaxhighlight>
These data corresponds to the ones described [[TLE_options#Single_TLE|here]] when using the <font color=#FF8C00 title="Graphical User Interface">GUI</font>.


=== Best single TLE ===
=== Best single TLE ===
In that case, we will use a [{{PathCurrentJavaDoc}}/fr/cnes/dynvol/gentleman/calc/data/tle/GtmBestTle.html GtmBestTle] object.
* one with the minimum data to give (the other ones will be set to default values) :
<syntaxhighlight lang="java">
// GtmBestTle data
final GtmBestTle data = new GtmBestTle(date, geo.getAmountOfPoints(), geo.getAmountOfPoints());
</syntaxhighlight>
* one with all the needed data. The example below is fully equivalent to the one above.
<syntaxhighlight lang="java">
final GtmBestTle data = new GtmBestTle(date, geo.getAmountOfPoints(), geo.getAmountOfPoints(), 1.0, false, false, GtmBuildingMethods.DIFFERENTIAL, 30);
</syntaxhighlight>
These data corresponds to the ones described [[TLE_options#Best_single_TLE|here]] when using the <font color=#FF8C00 title="Graphical User Interface">GUI</font>.


=== Best dated TLEs ===
=== Best dated TLEs ===
Fist of all, we will have to initialize a list of dates for which <font color=#FF8C00 title="Two Lines Elements">TLEs</font> will be computed. In the example below, we will add the initial date as the first one then two other dates corresponding to one and two orbital periods later.
<syntaxhighlight lang="java">
// GtmBestTlesDates data
final ArrayList<AbsoluteDate> listOfDates = new ArrayList<AbsoluteDate>();
// First TLE at the initial date
listOfDates.add(date);
// next TLEs 1 and 2 period after
// Warning : dates do not correspond exactly with output steps !
final double period = geo.getIniOrbit().getKeplerianPeriod();
listOfDates.add(date.shiftedBy(period));
listOfDates.add(date.shiftedBy(2.*period));
</syntaxhighlight>
At last, we will use a [{{PathCurrentJavaDoc}}/fr/cnes/dynvol/gentleman/calc/data/tle/GtmBestTlesDates.html GtmBestTlesDates] object.
* one with the minimum data to give (the other ones will be set to default values) :
<syntaxhighlight lang="java">
final double minDuration = 0.5*period;
final int nbMax = 99;
final GtmBestTlesDates data = new GtmBestTlesDates(listOfDates, minDuration, nbMax);
</syntaxhighlight>
* one with all the needed data. The example below is fully equivalent to the one above.
<syntaxhighlight lang="java">
final GtmBestTlesDates data = new GtmBestTlesDates(listOfDates, minDuration, nbMax, 1.0, false, false, GtmBuildingMethods.DIFFERENTIAL, 30);
</syntaxhighlight>
These data corresponds to the ones described [[TLE_options#Best_dated_TLEs|here]] when using the <font color=#FF8C00 title="Graphical User Interface">GUI</font>.


=== Best periodic TLEs ===
=== Best periodic TLEs ===
At last, we will use a [{{PathCurrentJavaDoc}}/fr/cnes/dynvol/gentleman/calc/data/tle/GtmBestTlesPeriod.html GtmBestTlesPeriod] object.
* one with the minimum data to give (the other ones will be set to default values) :
<syntaxhighlight lang="java">
// GtmBestTlesDates data
final double period = Constants.JULIAN_DAY; // dates will correspond exactly with output steps !
final double minDuration = 0.5*period;
final int nbMax = 99;
final GtmBestTlesPeriod data = new GtmBestTlesPeriod(date, Constants.JULIAN_DAY, false, minDuration, nbMax);
</syntaxhighlight>
* one with all the needed data. The example below is fully equivalent to the one above.
<syntaxhighlight lang="java">
final GtmBestTlesPeriod data = new GtmBestTlesPeriod(date, Constants.JULIAN_DAY, false, minDuration, nbMax,
    1.0, false, false, GtmBuildingMethods.DIFFERENTIAL, 30);
</syntaxhighlight>
These data corresponds to the ones described [[TLE_options#Best_periodic_TLEs|here]] when using the <font color=#FF8C00 title="Graphical User Interface">GUI</font>.

Dernière version du 13 septembre 2021 à 07:19

The way to set how TLE(s) will be generated will depend of the chosen option as described here.


Single TLE

We have to instantiate a GtmSingleTle object. Two constructors are then available :

  • one with the minimum data to give (the other ones will be set to default values) :
final AbsoluteDate date = new AbsoluteDate("2020-01-01T00:00:00.000", GtmConstants.UTC);
final GtmGeoPropagator geo = new GtmGeoPropagator();
...
// GtmSingleTle data
final GtmSingleTle data = new GtmSingleTle(date, geo.getAmountOfPoints());
  • one with all the needed data. The example below is fully equivalent to the one above.
final GtmSingleTle data = new GtmSingleTle(date, geo.getAmountOfPoints(), 1.0, false, false, GtmBuildingMethods.DIFFERENTIAL, 30);

These data corresponds to the ones described here when using the GUI.

Best single TLE

In that case, we will use a GtmBestTle object.

  • one with the minimum data to give (the other ones will be set to default values) :
// GtmBestTle data
final GtmBestTle data = new GtmBestTle(date, geo.getAmountOfPoints(), geo.getAmountOfPoints());
  • one with all the needed data. The example below is fully equivalent to the one above.
final GtmBestTle data = new GtmBestTle(date, geo.getAmountOfPoints(), geo.getAmountOfPoints(), 1.0, false, false, GtmBuildingMethods.DIFFERENTIAL, 30);

These data corresponds to the ones described here when using the GUI.

Best dated TLEs

Fist of all, we will have to initialize a list of dates for which TLEs will be computed. In the example below, we will add the initial date as the first one then two other dates corresponding to one and two orbital periods later.

// GtmBestTlesDates data
final ArrayList<AbsoluteDate> listOfDates = new ArrayList<AbsoluteDate>();
// First TLE at the initial date
listOfDates.add(date);
// next TLEs 1 and 2 period after
// Warning : dates do not correspond exactly with output steps !
final double period = geo.getIniOrbit().getKeplerianPeriod();
listOfDates.add(date.shiftedBy(period));
listOfDates.add(date.shiftedBy(2.*period));

At last, we will use a GtmBestTlesDates object.

  • one with the minimum data to give (the other ones will be set to default values) :
final double minDuration = 0.5*period;
final int nbMax = 99;
final GtmBestTlesDates data = new GtmBestTlesDates(listOfDates, minDuration, nbMax);
  • one with all the needed data. The example below is fully equivalent to the one above.
final GtmBestTlesDates data = new GtmBestTlesDates(listOfDates, minDuration, nbMax, 1.0, false, false, GtmBuildingMethods.DIFFERENTIAL, 30);

These data corresponds to the ones described here when using the GUI.

Best periodic TLEs

At last, we will use a GtmBestTlesPeriod object.

  • one with the minimum data to give (the other ones will be set to default values) :
// GtmBestTlesDates data
final double period = Constants.JULIAN_DAY; // dates will correspond exactly with output steps !
final double minDuration = 0.5*period;
final int nbMax = 99;
final GtmBestTlesPeriod data = new GtmBestTlesPeriod(date, Constants.JULIAN_DAY, false, minDuration, nbMax);
  • one with all the needed data. The example below is fully equivalent to the one above.
final GtmBestTlesPeriod data = new GtmBestTlesPeriod(date, Constants.JULIAN_DAY, false, minDuration, nbMax,
    1.0, false, false, GtmBuildingMethods.DIFFERENTIAL, 30);

These data corresponds to the ones described here when using the GUI.