Class OrbitHermiteInterpolator

All Implemented Interfaces:
TimeInterpolator<Orbit>

public class OrbitHermiteInterpolator extends AbstractOrbitInterpolator
Class using a Hermite interpolator to interpolate orbits. It is assumed that provided samples have the same gravitational parameter and frame. Otherwise, an error will be thrown

Depending on given sample orbit type, the interpolation may differ :

  • For Keplerian, Circular and Equinoctial orbits, the interpolated instance is created by polynomial Hermite interpolation, using derivatives when available.
  • For Cartesian orbits, the interpolated instance is created using the cartesian derivatives filter given at instance construction. Hence, it will fall back to Lagrange interpolation if this instance has been designed to not use derivatives.

In any case, it should be used only with small number of interpolation points (about 10-20 points) in order to avoid Runge's phenomenon and numerical problems (including NaN appearing).

Author:
Luc Maisonobe, Vincent Cucchietti
See Also:
  • Constructor Details

    • OrbitHermiteInterpolator

      public OrbitHermiteInterpolator(Frame outputInertialFrame)
      Constructor with :
      • Default number of interpolation points of DEFAULT_INTERPOLATION_POINTS
      • Default extrapolation threshold value (DEFAULT_EXTRAPOLATION_THRESHOLD_SEC s)
      • Use of position and two time derivatives during interpolation
      As this implementation of interpolation is polynomial, it should be used only with small number of interpolation points (about 10-20 points) in order to avoid Runge's phenomenon and numerical problems (including NaN appearing).
      Parameters:
      outputInertialFrame - output inertial frame
    • OrbitHermiteInterpolator

      public OrbitHermiteInterpolator(int interpolationPoints, Frame outputInertialFrame)
      Constructor with :
      • Default extrapolation threshold value (DEFAULT_EXTRAPOLATION_THRESHOLD_SEC s)
      • Use of position and two time derivatives during interpolation
      As this implementation of interpolation is polynomial, it should be used only with small number of interpolation points (about 10-20 points) in order to avoid Runge's phenomenon and numerical problems (including NaN appearing).
      Parameters:
      interpolationPoints - number of interpolation points
      outputInertialFrame - output inertial frame
    • OrbitHermiteInterpolator

      public OrbitHermiteInterpolator(int interpolationPoints, Frame outputInertialFrame, CartesianDerivativesFilter pvaFilter)
      Constructor with default extrapolation threshold value (DEFAULT_EXTRAPOLATION_THRESHOLD_SEC s).

      As this implementation of interpolation is polynomial, it should be used only with small number of interpolation points (about 10-20 points) in order to avoid Runge's phenomenon and numerical problems (including NaN appearing).

      Parameters:
      interpolationPoints - number of interpolation points
      outputInertialFrame - output inertial frame
      pvaFilter - filter for derivatives from the sample to use in position-velocity-acceleration interpolation. Used only when interpolating Cartesian orbits.
    • OrbitHermiteInterpolator

      public OrbitHermiteInterpolator(int interpolationPoints, double extrapolationThreshold, Frame outputInertialFrame, CartesianDerivativesFilter pvaFilter)
      Constructor.

      As this implementation of interpolation is polynomial, it should be used only with small number of interpolation points (about 10-20 points) in order to avoid Runge's phenomenon and numerical problems (including NaN appearing).

      Parameters:
      interpolationPoints - number of interpolation points
      extrapolationThreshold - extrapolation threshold beyond which the propagation will fail
      outputInertialFrame - output inertial frame
      pvaFilter - filter for derivatives from the sample to use in position-velocity-acceleration interpolation. Used only when interpolating Cartesian orbits.
  • Method Details

    • getPVAFilter

      public CartesianDerivativesFilter getPVAFilter()
      Get filter for derivatives from the sample to use in position-velocity-acceleration interpolation.
      Returns:
      filter for derivatives from the sample to use in position-velocity-acceleration interpolation
    • interpolate

      protected Orbit interpolate(AbstractTimeInterpolator<Orbit>.InterpolationData interpolationData)
      Interpolate instance from given interpolation data.

      Depending on given sample orbit type, the interpolation may differ :

      • For Keplerian, Circular and Equinoctial orbits, the interpolated instance is created by polynomial Hermite interpolation, using derivatives when available.
      • For Cartesian orbits, the interpolated instance is created using the cartesian derivatives filter given at instance construction. Hence, it will fall back to Lagrange interpolation if this instance has been designed to not use derivatives.
      If orbit interpolation on large samples is needed, using the Ephemeris class is a better way than using this low-level interpolation. The Ephemeris class automatically handles selection of a neighboring sub-sample with a predefined number of point from a large global sample in a thread-safe way.
      Specified by:
      interpolate in class AbstractTimeInterpolator<Orbit>
      Parameters:
      interpolationData - interpolation data
      Returns:
      interpolated instance at given date