[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Orekit Developers] Writing an OEM file after an ephemeris propagation



Hello Nicolas,

Yes we have a class and an example of doing what you are looking for.  The OrekitEphemerisFile and its corresponding classes are meant to be filled from internally propagated ephemeris which can then be piped out to the various external formats, like OEM.  The OrekitEphemerisFileTest shows an example of how to use it to generate an OEM file.  While Orekit currently supports reading in OEM file covariance it doesn't have the ability to write out covariance.  That is a feature worth looking into though, for sure.

Hank

On Wed, Mar 8, 2017 at 5:28 AM, <contact@nicolasrol.fr> wrote:

Hi all,

 

First of all, great job on OREKIT, it’s a really nice tool!

 

I’m trying to compare its orbit determination and propagation (so far it seems very accurate) with other softwares like STK or GMV but I have some trouble writing an OEM file after an orbit propagation.

 

I based my code on the tutorials « EphemerisMode » and « MasterMode » (found in Propagation) and modified it in order to obtain the « bounded propagator » containing the computed ephemeris data (that works well) :

 

<definition of the different useful data, initial orbit, integrator, etc.>

 

// Propagator

NumericalPropagator propagator = new NumericalPropagator(integrator);

propagator.setOrbitType(propagationType);

                  

// Set up initial state in the propagator

propagator.setInitialState(initialState);

 

// Set the propagator to ephemeris mode

propagator.setEphemerisMode();

 

// Extrapolate from the initial to the final date

SpacecraftState finalState = propagator.propagate(lastDate);

 

// Getting the integrated ephemeris

BoundedPropagator ephemeris = propagator.getGeneratedEphemeris();

 

 

Now what I would like to do is export that data in an OEM file.

Therefor, I looked into the OEMWriterTest file in order to see how you did it for the tests but it seems that you always use an EphemerisFile/OEMFile created by parsing an existing OEM file !

 

final OEMFile oemFile = parser.parse(inEntry, "OEMExample.txt");

final EphemerisFile ephemerisFile = (EphemerisFile) oemFile;

OEMWriter writer = new OEMWriter(interpolationMethod, originator, objectID, objectName);

writer.write(tempOEMFilePath, ephemerisFile);

 

Is there a way to create such OEMFile or EphemerisFile based on a BoundedPropagator ephemeris ? Or is it possible to write directly from the BoundedPropagator ?

I couldn’t find any constructor using such parameter…

 

 

Other quick question : is it possible to write the OEM file with the covariance matrix ? Is this covariance matrix even available after a propagation ?

 

Thanks in advance for your help

 

Nicolas