Spacecraft state interpolation / integration

Good morning,

I have some doubts about the use of BoundedPropagator class. What I need is to perform an interpolation at certain epochs starting from a set of spacecraft states obtained through numerical propagation. I thought the use of a BoundedPropagator could make the job.

Peeking in the code, I reached the invocation of AbstractODEStateInterpolator.computeInterpolatedStateAndDerivatives() which is implemented differently depending on the adopted integrator. Here my question: it seems to me that what is performed here is a sort of integration at the wanted epoch starting from the state at the immediate previous / successive epoch. Am I missing something? From the name “StateInterpolator” I was indeed expecting something more similar to an actual interpolation (for example interpolate a certain number of close spacecraft states to get the wanted state) instead of an integration.

Thank you,

Hi @MarcoTosato

What is performed is really an interpolation, not an integration.
When using a numerical propagator, at each step the underlying integrator set up interpolators that were valid throughout the step. These interpolators are specific to the integrator (they corrrespond to the internal model it uses), but are mainly polynomials with degree related to the integrator order. When ephemeris generation is enabled, these interpolators are picked up on the fly and saved in the ephemeris. Then, when the ephemeris is retrieved and used later on, the only computation to be performed is to locate the proper interpolator from the list and evaluate it.

So there are no additional integration, we just reuse a polynomial model that was saved. Of course we save computation time when using the ephemeris but consume more memory.