I am currently dealing with the covariance propagation coming from an ephemeris file.
The CCSDS OEM format might have only one covariance matrix sample in it, which then I would like to propagate during the whole arc of the ephemeris file.
I tried to use the new MatricesHarvester interface that was introduced in the last releases, however it triggers an unsupported exception when coupled with an ephemeris propagator.
So, to be able to propagate the covariance I thought of spawning a NumericalPropagatorBuilder, fitting the trajectory in the ephemeris propagator and then use the harvester to compute the covariance matrix at each step during the propagation with the newly created NumericalPropagator.
However I was wondering if there could be a simpler approach with the current release (v 11.2.1) or if you plan to provide a different solution in the future to deal with this particular case?
“It is normal” (or not )
With the current version of Orekit, the
Ephemeris propagator doesn’t have a matrix harvester. Therefore, it is not able to compute a state transition matrix and then it can’t propagate a covariance matrix. That’s why you have the unsupported exception.
Adding the harvester is a new feature we must add. It is straightforward to do since we already have a lot of matrix harvester implementations that can be used as example.
We implemented for the next version (i.e. 11.3) a new class able to propagate a state covariance matrix using the common used linear model. Its name is
StateCovarianceMatrixProvider. The class uses the concept of
AdditionalState, so it can be easy to configure and to add to an orbit propagator. It works for all propagators having a matrix harverster. So, it works for the numerical propagator.
Once the harvester added for the
Ephemeris, it will also work with it.
I don’t know if we will have time to implement the
Ephemeris harvester for the next release… However, because it is a very interesting new feature we will probably add it very soon.
Hi @bcazabonne ,
thank you really much for the prompt reply!
Good to know about the
StateCovarianceMatrixProvider and that you plan to add an harvester also for the
Well at this point I am looking forward for the next release/s
I worked on the implementation of the
EphemerisHarvester in order to use the
StateCovarianceMatrixProvider with an
Ephemeris. Unfortunately, I faced an issue that compromise the implementation…
It is not possible for the
Ephemeris propagator to compute the state transition matrix. Orekit computes partial derivatives using automatic differentiation. The automatic differentiation uses the “Field” elements implemented in Hipparchus library. More precisely, the
Gradient implementation of the “Field” elements.
The gradient converter used to convert the
FieldEphemeris cannot computes partial derivatives since it only knows the
List (i.e., without derivatives) of
SpacecraftState of the input
Ephemeris. The conversion of
List<FieldSpacecraftState> is done without derivatives information. Therefore, the computed STM is always equal to zero. I didn’t find any solution for this.
I’m sorry for the explanations which are complicated. The “Field” elements are difficult to understand in Orekit…even for the Orekit team
Your current approach with the
NumericalPropagator is the correct one. It will be simplified with the
StateCovarianceMatrixProvider. But it will not be possible to use the
thanks for the update and the explanation
Now that I am thinking a bit more, it makes sense that we cannot use it. We can’t get the partial without a propagation done in the background
Ok, so we will rely on the
I’m dropping by this thread to inform you that, although we can’t propagate covariance with the
Ephemeris class as @bcazabonne said, we will soon be able to interpolate covariance (see Issue #970 for more information).
In your case and when this will be ready, you’ll be able to propagate the covariance using the
NumericalPropagator as previously explained and then save some tabulated states and their associated covariances using an
Ephemeris. Later on you will be able to interpolate the covariance very precisely between your tabulated values !
Hi @Vincent ,
thanks a lot for the update