TLEPropagator.java

  1. /* Copyright 2002-2020 CS GROUP
  2.  * Licensed to CS GROUP (CS) under one or more
  3.  * contributor license agreements.  See the NOTICE file distributed with
  4.  * this work for additional information regarding copyright ownership.
  5.  * CS licenses this file to You under the Apache License, Version 2.0
  6.  * (the "License"); you may not use this file except in compliance with
  7.  * the License.  You may obtain a copy of the License at
  8.  *
  9.  *   http://www.apache.org/licenses/LICENSE-2.0
  10.  *
  11.  * Unless required by applicable law or agreed to in writing, software
  12.  * distributed under the License is distributed on an "AS IS" BASIS,
  13.  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14.  * See the License for the specific language governing permissions and
  15.  * limitations under the License.
  16.  */
  17. package org.orekit.propagation.analytical.tle;

  18. import org.hipparchus.geometry.euclidean.threed.Vector3D;
  19. import org.hipparchus.util.FastMath;
  20. import org.hipparchus.util.MathUtils;
  21. import org.hipparchus.util.SinCos;
  22. import org.orekit.annotation.DefaultDataContext;
  23. import org.orekit.attitudes.Attitude;
  24. import org.orekit.attitudes.AttitudeProvider;
  25. import org.orekit.data.DataContext;
  26. import org.orekit.errors.OrekitException;
  27. import org.orekit.errors.OrekitMessages;
  28. import org.orekit.frames.Frame;
  29. import org.orekit.frames.Frames;
  30. import org.orekit.orbits.CartesianOrbit;
  31. import org.orekit.orbits.Orbit;
  32. import org.orekit.propagation.Propagator;
  33. import org.orekit.propagation.SpacecraftState;
  34. import org.orekit.propagation.analytical.AbstractAnalyticalPropagator;
  35. import org.orekit.time.AbsoluteDate;
  36. import org.orekit.time.TimeScale;
  37. import org.orekit.utils.PVCoordinates;


  38. /** This class provides elements to propagate TLE's.
  39.  * <p>
  40.  * The models used are SGP4 and SDP4, initially proposed by NORAD as the unique convenient
  41.  * propagator for TLE's. Inputs and outputs of this propagator are only suited for
  42.  * NORAD two lines elements sets, since it uses estimations and mean values appropriate
  43.  * for TLE's only.
  44.  * </p>
  45.  * <p>
  46.  * Deep- or near- space propagator is selected internally according to NORAD recommendations
  47.  * so that the user has not to worry about the used computation methods. One instance is created
  48.  * for each TLE (this instance can only be get using {@link #selectExtrapolator(TLE)} method,
  49.  * and can compute {@link PVCoordinates position and velocity coordinates} at any
  50.  * time. Maximum accuracy is guaranteed in a 24h range period before and after the provided
  51.  * TLE epoch (of course this accuracy is not really measurable nor predictable: according to
  52.  * <a href="https://www.celestrak.com/">CelesTrak</a>, the precision is close to one kilometer
  53.  * and error won't probably rise above 2 km).
  54.  * </p>
  55.  * <p>This implementation is largely inspired from the paper and source code <a
  56.  * href="https://www.celestrak.com/publications/AIAA/2006-6753/">Revisiting Spacetrack
  57.  * Report #3</a> and is fully compliant with its results and tests cases.</p>
  58.  * @author Felix R. Hoots, Ronald L. Roehrich, December 1980 (original fortran)
  59.  * @author David A. Vallado, Paul Crawford, Richard Hujsak, T.S. Kelso (C++ translation and improvements)
  60.  * @author Fabien Maussion (java translation)
  61.  * @see TLE
  62.  */
  63. public abstract class TLEPropagator extends AbstractAnalyticalPropagator {

  64.     // CHECKSTYLE: stop VisibilityModifier check

  65.     /** Initial state. */
  66.     protected final TLE tle;

  67.     /** UTC time scale. */
  68.     protected final TimeScale utc;

  69.     /** final RAAN. */
  70.     protected double xnode;

  71.     /** final semi major axis. */
  72.     protected double a;

  73.     /** final eccentricity. */
  74.     protected double e;

  75.     /** final inclination. */
  76.     protected double i;

  77.     /** final perigee argument. */
  78.     protected double omega;

  79.     /** L from SPTRCK #3. */
  80.     protected double xl;

  81.     /** original recovered semi major axis. */
  82.     protected double a0dp;

  83.     /** original recovered mean motion. */
  84.     protected double xn0dp;

  85.     /** cosinus original inclination. */
  86.     protected double cosi0;

  87.     /** cos io squared. */
  88.     protected double theta2;

  89.     /** sinus original inclination. */
  90.     protected double sini0;

  91.     /** common parameter for mean anomaly (M) computation. */
  92.     protected double xmdot;

  93.     /** common parameter for perigee argument (omega) computation. */
  94.     protected double omgdot;

  95.     /** common parameter for raan (OMEGA) computation. */
  96.     protected double xnodot;

  97.     /** original eccentricity squared. */
  98.     protected double e0sq;
  99.     /** 1 - e2. */
  100.     protected double beta02;

  101.     /** sqrt (1 - e2). */
  102.     protected double beta0;

  103.     /** perigee, expressed in KM and ALTITUDE. */
  104.     protected double perige;

  105.     /** eta squared. */
  106.     protected double etasq;

  107.     /** original eccentricity * eta. */
  108.     protected double eeta;

  109.     /** s* new value for the contant s. */
  110.     protected double s4;

  111.     /** tsi from SPTRCK #3. */
  112.     protected double tsi;

  113.     /** eta from SPTRCK #3. */
  114.     protected double eta;

  115.     /** coef for SGP C3 computation. */
  116.     protected double coef;

  117.     /** coef for SGP C5 computation. */
  118.     protected double coef1;

  119.     /** C1 from SPTRCK #3. */
  120.     protected double c1;

  121.     /** C2 from SPTRCK #3. */
  122.     protected double c2;

  123.     /** C4 from SPTRCK #3. */
  124.     protected double c4;

  125.     /** common parameter for raan (OMEGA) computation. */
  126.     protected double xnodcf;

  127.     /** 3/2 * C1. */
  128.     protected double t2cof;

  129.     // CHECKSTYLE: resume VisibilityModifier check

  130.     /** TLE frame. */
  131.     private final Frame teme;

  132.     /** Spacecraft mass (kg). */
  133.     private final double mass;

  134.     /** Protected constructor for derived classes.
  135.      *
  136.      * <p>This constructor uses the {@link DataContext#getDefault() default data context}.
  137.      *
  138.      * @param initialTLE the unique TLE to propagate
  139.      * @param attitudeProvider provider for attitude computation
  140.      * @param mass spacecraft mass (kg)
  141.      * @see #TLEPropagator(TLE, AttitudeProvider, double, Frame)
  142.      */
  143.     @DefaultDataContext
  144.     protected TLEPropagator(final TLE initialTLE, final AttitudeProvider attitudeProvider,
  145.                             final double mass) {
  146.         this(initialTLE, attitudeProvider, mass,
  147.                 DataContext.getDefault().getFrames().getTEME());
  148.     }

  149.     /** Protected constructor for derived classes.
  150.      * @param initialTLE the unique TLE to propagate
  151.      * @param attitudeProvider provider for attitude computation
  152.      * @param mass spacecraft mass (kg)
  153.      * @param teme the TEME frame to use for propagation.
  154.      * @since 10.1
  155.      */
  156.     protected TLEPropagator(final TLE initialTLE,
  157.                             final AttitudeProvider attitudeProvider,
  158.                             final double mass,
  159.                             final Frame teme) {
  160.         super(attitudeProvider);
  161.         setStartDate(initialTLE.getDate());
  162.         this.tle  = initialTLE;
  163.         this.teme = teme;
  164.         this.mass = mass;
  165.         this.utc = initialTLE.getUtc();
  166.         initializeCommons();
  167.         sxpInitialize();
  168.         // set the initial state
  169.         final Orbit orbit = propagateOrbit(initialTLE.getDate());
  170.         final Attitude attitude = attitudeProvider.getAttitude(orbit, orbit.getDate(), orbit.getFrame());
  171.         super.resetInitialState(new SpacecraftState(orbit, attitude, mass));
  172.     }

  173.     /** Selects the extrapolator to use with the selected TLE.
  174.      *
  175.      * <p>This method uses the {@link DataContext#getDefault() default data context}.
  176.      *
  177.      * @param tle the TLE to propagate.
  178.      * @return the correct propagator.
  179.      * @see #selectExtrapolator(TLE, Frames)
  180.      */
  181.     @DefaultDataContext
  182.     public static TLEPropagator selectExtrapolator(final TLE tle) {
  183.         return selectExtrapolator(tle, DataContext.getDefault().getFrames());
  184.     }

  185.     /** Selects the extrapolator to use with the selected TLE.
  186.      * @param tle the TLE to propagate.
  187.      * @param frames set of Frames to use in the propagator.
  188.      * @return the correct propagator.
  189.      * @since 10.1
  190.      */
  191.     public static TLEPropagator selectExtrapolator(final TLE tle, final Frames frames) {
  192.         return selectExtrapolator(
  193.                 tle,
  194.                 Propagator.getDefaultLaw(frames),
  195.                 DEFAULT_MASS,
  196.                 frames.getTEME());
  197.     }

  198.     /** Selects the extrapolator to use with the selected TLE.
  199.      *
  200.      * <p>This method uses the {@link DataContext#getDefault() default data context}.
  201.      *
  202.      * @param tle the TLE to propagate.
  203.      * @param attitudeProvider provider for attitude computation
  204.      * @param mass spacecraft mass (kg)
  205.      * @return the correct propagator.
  206.      * @see #selectExtrapolator(TLE, AttitudeProvider, double, Frame)
  207.      */
  208.     @DefaultDataContext
  209.     public static TLEPropagator selectExtrapolator(final TLE tle, final AttitudeProvider attitudeProvider,
  210.                                                    final double mass) {
  211.         return selectExtrapolator(tle, attitudeProvider, mass,
  212.                 DataContext.getDefault().getFrames().getTEME());
  213.     }

  214.     /** Selects the extrapolator to use with the selected TLE.
  215.      * @param tle the TLE to propagate.
  216.      * @param attitudeProvider provider for attitude computation
  217.      * @param mass spacecraft mass (kg)
  218.      * @param teme the TEME frame to use for propagation.
  219.      * @return the correct propagator.
  220.      * @since 10.1
  221.      */
  222.     public static TLEPropagator selectExtrapolator(final TLE tle,
  223.                                                    final AttitudeProvider attitudeProvider,
  224.                                                    final double mass,
  225.                                                    final Frame teme) {

  226.         final double a1 = FastMath.pow( TLEConstants.XKE / (tle.getMeanMotion() * 60.0), TLEConstants.TWO_THIRD);
  227.         final double cosi0 = FastMath.cos(tle.getI());
  228.         final double temp = TLEConstants.CK2 * 1.5 * (3 * cosi0 * cosi0 - 1.0) *
  229.                             FastMath.pow(1.0 - tle.getE() * tle.getE(), -1.5);
  230.         final double delta1 = temp / (a1 * a1);
  231.         final double a0 = a1 * (1.0 - delta1 * (TLEConstants.ONE_THIRD + delta1 * (delta1 * 134.0 / 81.0 + 1.0)));
  232.         final double delta0 = temp / (a0 * a0);

  233.         // recover original mean motion :
  234.         final double xn0dp = tle.getMeanMotion() * 60.0 / (delta0 + 1.0);

  235.         // Period >= 225 minutes is deep space
  236.         if (MathUtils.TWO_PI / (xn0dp * TLEConstants.MINUTES_PER_DAY) >= (1.0 / 6.4)) {
  237.             return new DeepSDP4(tle, attitudeProvider, mass, teme);
  238.         } else {
  239.             return new SGP4(tle, attitudeProvider, mass, teme);
  240.         }
  241.     }

  242.     /** Get the Earth gravity coefficient used for TLE propagation.
  243.      * @return the Earth gravity coefficient.
  244.      */
  245.     public static double getMU() {
  246.         return TLEConstants.MU;
  247.     }

  248.     /** Get the extrapolated position and velocity from an initial TLE.
  249.      * @param date the final date
  250.      * @return the final PVCoordinates
  251.      */
  252.     public PVCoordinates getPVCoordinates(final AbsoluteDate date) {

  253.         sxpPropagate(date.durationFrom(tle.getDate()) / 60.0);

  254.         // Compute PV with previous calculated parameters
  255.         return computePVCoordinates();
  256.     }

  257.     /** Computation of the first commons parameters.
  258.      */
  259.     private void initializeCommons() {

  260.         // Sine and cosine of inclination
  261.         final SinCos scI0 = FastMath.sinCos(tle.getI());

  262.         final double a1 = FastMath.pow(TLEConstants.XKE / (tle.getMeanMotion() * 60.0), TLEConstants.TWO_THIRD);
  263.         cosi0 = scI0.cos();
  264.         theta2 = cosi0 * cosi0;
  265.         final double x3thm1 = 3.0 * theta2 - 1.0;
  266.         e0sq = tle.getE() * tle.getE();
  267.         beta02 = 1.0 - e0sq;
  268.         beta0 = FastMath.sqrt(beta02);
  269.         final double tval = TLEConstants.CK2 * 1.5 * x3thm1 / (beta0 * beta02);
  270.         final double delta1 = tval / (a1 * a1);
  271.         final double a0 = a1 * (1.0 - delta1 * (TLEConstants.ONE_THIRD + delta1 * (1.0 + 134.0 / 81.0 * delta1)));
  272.         final double delta0 = tval / (a0 * a0);

  273.         // recover original mean motion and semi-major axis :
  274.         xn0dp = tle.getMeanMotion() * 60.0 / (delta0 + 1.0);
  275.         a0dp = a0 / (1.0 - delta0);

  276.         // Values of s and qms2t :
  277.         s4 = TLEConstants.S;  // unmodified value for s
  278.         double q0ms24 = TLEConstants.QOMS2T; // unmodified value for q0ms2T

  279.         perige = (a0dp * (1 - tle.getE()) - TLEConstants.NORMALIZED_EQUATORIAL_RADIUS) * TLEConstants.EARTH_RADIUS; // perige

  280.         //  For perigee below 156 km, the values of s and qoms2t are changed :
  281.         if (perige < 156.0) {
  282.             if (perige <= 98.0) {
  283.                 s4 = 20.0;
  284.             } else {
  285.                 s4 = perige - 78.0;
  286.             }
  287.             final double temp_val = (120.0 - s4) * TLEConstants.NORMALIZED_EQUATORIAL_RADIUS / TLEConstants.EARTH_RADIUS;
  288.             final double temp_val_squared = temp_val * temp_val;
  289.             q0ms24 = temp_val_squared * temp_val_squared;
  290.             s4 = s4 / TLEConstants.EARTH_RADIUS + TLEConstants.NORMALIZED_EQUATORIAL_RADIUS; // new value for q0ms2T and s
  291.         }

  292.         final double pinv = 1.0 / (a0dp * beta02);
  293.         final double pinvsq = pinv * pinv;
  294.         tsi = 1.0 / (a0dp - s4);
  295.         eta = a0dp * tle.getE() * tsi;
  296.         etasq = eta * eta;
  297.         eeta = tle.getE() * eta;

  298.         final double psisq = FastMath.abs(1.0 - etasq); // abs because pow 3.5 needs positive value
  299.         final double tsi_squared = tsi * tsi;
  300.         coef = q0ms24 * tsi_squared * tsi_squared;
  301.         coef1 = coef / FastMath.pow(psisq, 3.5);

  302.         // C2 and C1 coefficients computation :
  303.         c2 = coef1 * xn0dp * (a0dp * (1.0 + 1.5 * etasq + eeta * (4.0 + etasq)) +
  304.              0.75 * TLEConstants.CK2 * tsi / psisq * x3thm1 * (8.0 + 3.0 * etasq * (8.0 + etasq)));
  305.         c1 = tle.getBStar() * c2;
  306.         sini0 = scI0.sin();

  307.         final double x1mth2 = 1.0 - theta2;

  308.         // C4 coefficient computation :
  309.         c4 = 2.0 * xn0dp * coef1 * a0dp * beta02 * (eta * (2.0 + 0.5 * etasq) +
  310.              tle.getE() * (0.5 + 2.0 * etasq) -
  311.              2 * TLEConstants.CK2 * tsi / (a0dp * psisq) *
  312.              (-3.0 * x3thm1 * (1.0 - 2.0 * eeta + etasq * (1.5 - 0.5 * eeta)) +
  313.               0.75 * x1mth2 * (2.0 * etasq - eeta * (1.0 + etasq)) * FastMath.cos(2.0 * tle.getPerigeeArgument())));

  314.         final double theta4 = theta2 * theta2;
  315.         final double temp1 = 3 * TLEConstants.CK2 * pinvsq * xn0dp;
  316.         final double temp2 = temp1 * TLEConstants.CK2 * pinvsq;
  317.         final double temp3 = 1.25 * TLEConstants.CK4 * pinvsq * pinvsq * xn0dp;

  318.         // atmospheric and gravitation coefs :(Mdf and OMEGAdf)
  319.         xmdot = xn0dp +
  320.                 0.5 * temp1 * beta0 * x3thm1 +
  321.                 0.0625 * temp2 * beta0 * (13.0 - 78.0 * theta2 + 137.0 * theta4);

  322.         final double x1m5th = 1.0 - 5.0 * theta2;

  323.         omgdot = -0.5 * temp1 * x1m5th +
  324.                  0.0625 * temp2 * (7.0 - 114.0 * theta2 + 395.0 * theta4) +
  325.                  temp3 * (3.0 - 36.0 * theta2 + 49.0 * theta4);

  326.         final double xhdot1 = -temp1 * cosi0;

  327.         xnodot = xhdot1 + (0.5 * temp2 * (4.0 - 19.0 * theta2) + 2.0 * temp3 * (3.0 - 7.0 * theta2)) * cosi0;
  328.         xnodcf = 3.5 * beta02 * xhdot1 * c1;
  329.         t2cof = 1.5 * c1;

  330.     }

  331.     /** Retrieves the position and velocity.
  332.      * @return the computed PVCoordinates.
  333.      */
  334.     private PVCoordinates computePVCoordinates() {

  335.         // Sine and cosine of final perigee argument
  336.         final SinCos scOmega = FastMath.sinCos(omega);

  337.         // Long period periodics
  338.         final double axn = e * scOmega.cos();
  339.         double temp = 1.0 / (a * (1.0 - e * e));
  340.         final double xlcof = 0.125 * TLEConstants.A3OVK2 * sini0 * (3.0 + 5.0 * cosi0) / (1.0 + cosi0);
  341.         final double aycof = 0.25 * TLEConstants.A3OVK2 * sini0;
  342.         final double xll = temp * xlcof * axn;
  343.         final double aynl = temp * aycof;
  344.         final double xlt = xl + xll;
  345.         final double ayn = e * scOmega.sin() + aynl;
  346.         final double elsq = axn * axn + ayn * ayn;
  347.         final double capu = MathUtils.normalizeAngle(xlt - xnode, FastMath.PI);
  348.         double epw = capu;
  349.         double ecosE = 0;
  350.         double esinE = 0;
  351.         double sinEPW = 0;
  352.         double cosEPW = 0;

  353.         // Dundee changes:  items dependent on cosio get recomputed:
  354.         final double cosi0Sq = cosi0 * cosi0;
  355.         final double x3thm1 = 3.0 * cosi0Sq - 1.0;
  356.         final double x1mth2 = 1.0 - cosi0Sq;
  357.         final double x7thm1 = 7.0 * cosi0Sq - 1.0;

  358.         if (e > (1 - 1e-6)) {
  359.             throw new OrekitException(OrekitMessages.TOO_LARGE_ECCENTRICITY_FOR_PROPAGATION_MODEL, e);
  360.         }

  361.         // Solve Kepler's' Equation.
  362.         final double newtonRaphsonEpsilon = 1e-12;
  363.         for (int j = 0; j < 10; j++) {

  364.             boolean doSecondOrderNewtonRaphson = true;

  365.             final SinCos scEPW = FastMath.sinCos(epw);
  366.             sinEPW = scEPW.sin();
  367.             cosEPW = scEPW.cos();
  368.             ecosE = axn * cosEPW + ayn * sinEPW;
  369.             esinE = axn * sinEPW - ayn * cosEPW;
  370.             final double f = capu - epw + esinE;
  371.             if (FastMath.abs(f) < newtonRaphsonEpsilon) {
  372.                 break;
  373.             }
  374.             final double fdot = 1.0 - ecosE;
  375.             double delta_epw = f / fdot;
  376.             if (j == 0) {
  377.                 final double maxNewtonRaphson = 1.25 * FastMath.abs(e);
  378.                 doSecondOrderNewtonRaphson = false;
  379.                 if (delta_epw > maxNewtonRaphson) {
  380.                     delta_epw = maxNewtonRaphson;
  381.                 } else if (delta_epw < -maxNewtonRaphson) {
  382.                     delta_epw = -maxNewtonRaphson;
  383.                 } else {
  384.                     doSecondOrderNewtonRaphson = true;
  385.                 }
  386.             }
  387.             if (doSecondOrderNewtonRaphson) {
  388.                 delta_epw = f / (fdot + 0.5 * esinE * delta_epw);
  389.             }
  390.             epw += delta_epw;
  391.         }

  392.         // Short period preliminary quantities
  393.         temp = 1.0 - elsq;
  394.         final double pl = a * temp;
  395.         final double r = a * (1.0 - ecosE);
  396.         double temp2 = a / r;
  397.         final double betal = FastMath.sqrt(temp);
  398.         temp = esinE / (1.0 + betal);
  399.         final double cosu = temp2 * (cosEPW - axn + ayn * temp);
  400.         final double sinu = temp2 * (sinEPW - ayn - axn * temp);
  401.         final double u = FastMath.atan2(sinu, cosu);
  402.         final double sin2u = 2.0 * sinu * cosu;
  403.         final double cos2u = 2.0 * cosu * cosu - 1.0;
  404.         final double temp1 = TLEConstants.CK2 / pl;
  405.         temp2 = temp1 / pl;

  406.         // Update for short periodics
  407.         final double rk = r * (1.0 - 1.5 * temp2 * betal * x3thm1) + 0.5 * temp1 * x1mth2 * cos2u;
  408.         final double uk = u - 0.25 * temp2 * x7thm1 * sin2u;
  409.         final double xnodek = xnode + 1.5 * temp2 * cosi0 * sin2u;
  410.         final double xinck = i + 1.5 * temp2 * cosi0 * sini0 * cos2u;

  411.         // Orientation vectors
  412.         final SinCos scuk   = FastMath.sinCos(uk);
  413.         final SinCos scik   = FastMath.sinCos(xinck);
  414.         final SinCos scnok  = FastMath.sinCos(xnodek);
  415.         final double sinuk  = scuk.sin();
  416.         final double cosuk  = scuk.cos();
  417.         final double sinik  = scik.sin();
  418.         final double cosik  = scik.cos();
  419.         final double sinnok = scnok.sin();
  420.         final double cosnok = scnok.cos();
  421.         final double xmx = -sinnok * cosik;
  422.         final double xmy = cosnok * cosik;
  423.         final double ux  = xmx * sinuk + cosnok * cosuk;
  424.         final double uy  = xmy * sinuk + sinnok * cosuk;
  425.         final double uz  = sinik * sinuk;

  426.         // Position and velocity
  427.         final double cr = 1000 * rk * TLEConstants.EARTH_RADIUS;
  428.         final Vector3D pos = new Vector3D(cr * ux, cr * uy, cr * uz);

  429.         final double rdot   = TLEConstants.XKE * FastMath.sqrt(a) * esinE / r;
  430.         final double rfdot  = TLEConstants.XKE * FastMath.sqrt(pl) / r;
  431.         final double xn     = TLEConstants.XKE / (a * FastMath.sqrt(a));
  432.         final double rdotk  = rdot - xn * temp1 * x1mth2 * sin2u;
  433.         final double rfdotk = rfdot + xn * temp1 * (x1mth2 * cos2u + 1.5 * x3thm1);
  434.         final double vx     = xmx * cosuk - cosnok * sinuk;
  435.         final double vy     = xmy * cosuk - sinnok * sinuk;
  436.         final double vz     = sinik * cosuk;

  437.         final double cv = 1000.0 * TLEConstants.EARTH_RADIUS / 60.0;
  438.         final Vector3D vel = new Vector3D(cv * (rdotk * ux + rfdotk * vx),
  439.                                           cv * (rdotk * uy + rfdotk * vy),
  440.                                           cv * (rdotk * uz + rfdotk * vz));

  441.         return new PVCoordinates(pos, vel);

  442.     }

  443.     /** Initialization proper to each propagator (SGP or SDP).
  444.      */
  445.     protected abstract void sxpInitialize();

  446.     /** Propagation proper to each propagator (SGP or SDP).
  447.      * @param t the offset from initial epoch (min)
  448.      */
  449.     protected abstract void sxpPropagate(double t);

  450.     /** {@inheritDoc} */
  451.     public void resetInitialState(final SpacecraftState state) {
  452.         throw new OrekitException(OrekitMessages.NON_RESETABLE_STATE);
  453.     }

  454.     /** {@inheritDoc} */
  455.     protected void resetIntermediateState(final SpacecraftState state, final boolean forward) {
  456.         throw new OrekitException(OrekitMessages.NON_RESETABLE_STATE);
  457.     }

  458.     /** {@inheritDoc} */
  459.     protected double getMass(final AbsoluteDate date) {
  460.         return mass;
  461.     }

  462.     /** {@inheritDoc} */
  463.     protected Orbit propagateOrbit(final AbsoluteDate date) {
  464.         return new CartesianOrbit(getPVCoordinates(date), teme, date, TLEConstants.MU);
  465.     }

  466.     /** Get the underlying TLE.
  467.      * @return underlying TLE
  468.      */
  469.     public TLE getTLE() {
  470.         return tle;
  471.     }

  472.     /** {@inheritDoc} */
  473.     public Frame getFrame() {
  474.         return teme;
  475.     }

  476. }