Custom land vehicle trajectory with linear position interpolation between points

Hello,

Rellated topics:

I would like to create a propagator that allows me to define the trajectory of a land vehicle given a list of position coordinates. But I want the returned position to be a linear propagation between points. (Exemple: I have A [t=0, x=0, y=0, z=0] and B [t = 52, x=1, y=1, z=0], I want MyPropagator.propagate(t=13) to yield [t = 13, x=0.25, y=0.25, z=0] and 0 velocity, 0 acceleration).

Like [2], I used PVCoordinates and Ephemeris. But Ephemeris seems to try to propagate a velocity and acceleration as well to find which trajectory could fit between to points. Therefore the position is not propagated “linearly”, if that makes sense.

Is there an easy way to create our own propagator to solve this?

Hello @OrekitBigestNoob and welcome to the Orekit community :partying_face:.

No class in Orekit exactly fits your need currently. However the core of your need can be done by implementing your own TimeInterpolator in order to interpolate a TimeStampedPVCoordinates.

Then you will be able to specify your custom TimeStampedPVCoordinatesLinearInterpolator to interpolate AbsolutePVCoordinates for your SpacecraftStateInterpolator when creating an Ephemeris

You can look at TimeStampedPVCoordinatesHermiteInterpolator to have an example.

Hope this helps !

Cheers,
Vincent

@OrekitBigestNoob

Another class that might be handy to you is the hipparchus LinearInterpolator. Store 3 of these in your custom class (one each for x, y, z) and that will allow you to pull “position” values as a function of time.