Slave vs Master vs Ephemeris propagators

Hello!

I am trying to understand the difference between the three different propagation modes available. I believe I understand the slave mode as it is the most simple of the three, but I am not sure I understand the other two, especially on what concerns their impact on the results obtained. Here are some of the questions I have:

  • If I for example was to run three times the same propagator with the same conditions using each one of the modes, would I obtain the exact same results?
  • Does it make any sense to use the master mode for an analytical propagator?
  • When I run the SGP4 propagator in the slave mode the performance is much slower than when I run it with the ephemeris mode and I do not understand why, in theory, it should be the second that takes longer, right?
  • How does the ephemeris generation mode work? It says that it calculates and stores all intermediate results, what is all? between any two points in time, there is an infinite number of points in between, which step-size is it using?

Thank you,

Iliass

Hi Iliass, here some elements to help understand the behaviour, which is often not intuitive.

For analytical propagators, yes, you should get the same results. For numerical propagators, not, you should see differences as you force steps to end at some times that may be different from the steps the underlying integrator would use.

Yes, mainly for the sake of maintainability. Letting the propagator handle time evolution, once user is accustomed to it, leads to simpler code as the code in the step handler concentrates on what to do at one point of time. This is the same reason that say events handling is separated from the main loop in events handlers: you have several independent small pieces of code instead of one big loop that manages everything at once. It will also allow switching from analytical to numerical propagators more easily if needed later.

No, because ephemeris generation is handled specially with all analytical propagators. In fact as these propagators don’t have a notion of “current” time, they only know the time of last reset (i.e. only initial time if you never reset the propagator, which is indeed the case for SGP4 that don’t support reset) and can propagate to any time using only this initial time. The ephemeris generation uses this property. It does not really store any intermediate state, it just keep a reference to the underlying analytical propagator. Basically, ephemeris generation in analytical propagator is no-op, but it is useful to have it for consistency with other (semi-analytical and numerical) propagators. The computation time time that is used in slave mode for SGP4 and seems to be saves in ephemeris generation is in fact only spent later on: when you will use the ephemeris.

For analytical propagators, as I wrote before the ephemeris just stores a reference to tha analytical propagator. For semi-analytical and numerical propagator, the ephemeris generation registers to the propagator a specific step handler. When the propagator will call this step handler during the run, this specific handler will then get a step interpolator valid throughout last step, but instead of using it for performing computation on the current step, it will store it in a list for later use. At the end of propagation, you then have available a collection of interpolators. When you ask for the state at a specific time, the ephemeris will look in its list to see which interpolator is valid for this time, then use this interpolator to interpolate the state at the specific time you asked for. This mean that if you use a propagator in master mode with a step handler or if you use it in ephemeris mode and then use the ephemeris with the same step interpolator, then you should get the same results, because in fact your step handler will see the exact same interpolator in both cases.