Also beware that in the two cases (regular or irregular epochs), we used two close be slightly different features.
In the first case, regular steps, we called the method add(timeStep, fixedHandler)
from the step handler multiplexer. This method fixes the time step for calling the handler to the value specified by the first argument, and the fixed handler is called directly with a SpacecraftState
at the correct time.
In the second case, irregular steps, we called the method add(variableStepHandler)
from the step handler multiplexer. This method just follows the propagator decision about steps sizes and calls the handler giving it an interpolator that is valid throughout the step. The job to extract the SpacecraftState
from the interpolator at any desired intermediate time is the responsibility of the handler in this case. If the propagator is an analytical propagator, the step size will be the full propagation, so the handler will be called once with a long range interpolator (backed by the analytical model). If the propagator is a numerical or semi-analytical model, the step size will depend on the underlying ODE integrator, and in most cases people use variable step size integrators like Dormand-Prince 8(5, 3), so the step size will vary throughout propagation.