Basic Principle

De Wiki
Aller à : navigation, rechercher

OPERA proposed a Java interface. To use this Java interface, the developer will have to:

To obtain the results, some "getter" methods will be available depending on the type of computation.

Do not forget to initialize PATRIUS dataset ...

As every computation using [PATRIUS], it is mandatory to well intialize a data set including main information to propagate trajectories (atmospheric models, third bodies ephemeris, UTC/TAI shifts, ...). Thanks to the additional jar available [here] and directly included in the opera-NN.n-jar-with-dependencies.jar file, it is really easy to do it by calling the OperaReadUtils.iniPatriusDataset() method.

// Patrius Dataset initialization (needed for example to get the UTC time)
OperaReadUtils.iniPatriusDataset(null);

Rather than to put null as input parameter of the OperaReadUtils.iniPatriusDataset() method, it is possible to give the name of a directory where additional data could be read.

How to initialize Opera Properties

A properties file is mandatory to initialize all the parameters needed to tune an OPERA computation. For more explanation about this kind of file, see here.

Thanks to the static method getConfigurationProperties() from OperaReadUtils class, we have just to precise the file path:

// Opera properties configuration
final OperaConfigurationProperties conf = OperaReadUtils.getConfigurationProperties("data/opera-configuration.properties");

How to initialize solar activity

Similarly, we can use another static method from the OperaSolarActivity class. This method (getSolarActivityFromFile()) needs as input parameters:

  • the path for the file where actual activity is stored
  • the path for the file where predicted activity is stored
  • the CNES Julian date corresponding to the switch between actual and predicted activity
// Solar activity initialization
final String realPath = "data/solar/ACSOL_REAL.act";
final String predPath = "data/solar/ACSOL_PREDICTED.act";
final double switchCJD = 22700.0;                
final List<OperaSolarActivityRow> solarActivity = OperaSolarActivity.getSolarActivityFromFile(realPath, predPath, switchCJD);

Reentry simulation object

To create such an object only consists in calling the dedicated constructor with both previous OperaConfigurationProperties and List<OperaSolarActivityRow> objects:

// Reentry simulation creation
final OperaReentrySimulation simulation = new OperaReentrySimulation(conf, solarActivity);

Getting list of TLE

Getting the list of TLE is done in two steps:

  1. Getting all the available TLE for a given Norad Id calling the static OperaTleManager.readTLEs() method
  2. Extract from this previous list the needed sublist corresponding to a given duration and an "End Of History" date calling the static OperaTleManager.selectTLEs() method
// TLEs initialization
final int noradId = 10479;
final SortedSet<TLE> tlesSet = OperaTleManager.readTLEs("data/tles", noradId, true, "txt");
 
// TLEs selection
final double historyDuration = 80.;
final double endOfHistoryCJD = 22605.0;                
final List<OperaTLE> tles = OperaTleManager.selectTLEs(tlesSet, endOfHistoryCJD, historyDuration);