Incorrect usage of DSST Forces?

I am having a few issues with my DSST Propagator, specifically around atmospheric drag and third bodies. When I add the Moon as a third body my spacecraft will orbit for ~8.78 years before giving me the following error

JavaError                                 Traceback (most recent call last)
Cell In [9], line 1
----> 1 proptagate_orbit(
      2         ra=None,
      3         cd=1.5,
      4         satellite_mass=14.0,
      5         area=0.103,
      6         epochDate=AbsoluteDate(2026, 1, 1, TimeScalesFactory.getUTC()),
      7         inclination=None,
      8         time_steps_per_day=5,
      9     )

Cell In [8], line 93, in proptagate_orbit(ra, cd, satellite_mass, area, inclination, epochDate, max_days, time_steps_per_day)
     91 while (time*u.s).to(u.day).value <= max_days:
     92     new_date = extrapDate.shiftedBy(float(dt))
---> 93     sma = dsstProp.propagate(
     94         extrapDate, new_date
     95     ).getA()
     96     smas.append(sma)
     97     time += dt

JavaError: <super: <class 'JavaError'>, <JavaError object>>
    Java stacktrace:
org.orekit.errors.OrekitIllegalArgumentException: hyperbolic orbits cannot be handled as org.orekit.orbits.EquinoctialOrbit instances
	at org.orekit.orbits.EquinoctialOrbit.<init>(EquinoctialOrbit.java:179)
	at org.orekit.orbits.EquinoctialOrbit.<init>(EquinoctialOrbit.java:143)
	at org.orekit.orbits.OrbitType$3.mapArrayToOrbit(OrbitType.java:449)
	at org.orekit.orbits.OrbitType$3.mapArrayToOrbit(OrbitType.java:405)
	at org.orekit.propagation.semianalytical.dsst.DSSTPropagator$MeanPlusShortPeriodicMapper.mapArrayToState(DSSTPropagator.java:1032)
	at org.orekit.propagation.integration.StateMapper.mapArrayToState(StateMapper.java:169)
	at org.orekit.propagation.integration.AbstractIntegratedPropagator$ConvertedMainStateEquations.computeDerivatives(AbstractIntegratedPropagator.java:754)
	at org.hipparchus.ode.ExpandableODE.computeDerivatives(ExpandableODE.java:134)
	at org.hipparchus.ode.AbstractIntegrator.computeDerivatives(AbstractIntegrator.java:265)
	at org.hipparchus.ode.nonstiff.EmbeddedRungeKuttaIntegrator.integrate(EmbeddedRungeKuttaIntegrator.java:252)
	at org.orekit.propagation.integration.AbstractIntegratedPropagator.integrateDynamics(AbstractIntegratedPropagator.java:477)
	at org.orekit.propagation.integration.AbstractIntegratedPropagator.propagate(AbstractIntegratedPropagator.java:425)

However, when I remove the Moon third body, it only propagates for ~1.74yrs and gives me the following error

JavaError                                 Traceback (most recent call last)
Cell In [11], line 1
----> 1 proptagate_orbit(
      2         ra=None,
      3         cd=1.5,
      4         satellite_mass=14.0,
      5         area=0.103,
      6         epochDate=AbsoluteDate(2026, 1, 1, TimeScalesFactory.getUTC()),
      7         inclination=None,
      8         time_steps_per_day=5,
      9     )

Cell In [10], line 93, in proptagate_orbit(ra, cd, satellite_mass, area, inclination, epochDate, max_days, time_steps_per_day)
     91 while (time*u.s).to(u.day).value <= max_days:
     92     new_date = extrapDate.shiftedBy(float(dt))
---> 93     sma = dsstProp.propagate(
     94         extrapDate, new_date
     95     ).getA()
     96     smas.append(sma)
     97     time += dt

JavaError: <super: <class 'JavaError'>, <JavaError object>>
    Java stacktrace:
org.orekit.errors.OrekitException: no solar activity available at 2042-02-15T20:49:09.94163531064987Z, data available only in range [1998-09-01T00:00:00.000Z, 2041-10-01T00:00:00.000Z]
	at org.orekit.models.earth.atmosphere.NRLMSISE00.getDensity(NRLMSISE00.java:1158)
	at org.orekit.forces.drag.DragForce.acceleration(DragForce.java:80)
	at org.orekit.propagation.semianalytical.dsst.forces.AbstractGaussianContribution$IntegrableFunction.value(AbstractGaussianContribution.java:1003)
	at org.orekit.propagation.semianalytical.dsst.forces.AbstractGaussianContribution$GaussQuadrature.basicIntegrate(AbstractGaussianContribution.java:1472)
	at org.orekit.propagation.semianalytical.dsst.forces.AbstractGaussianContribution$GaussQuadrature.integrate(AbstractGaussianContribution.java:1383)
	at org.orekit.propagation.semianalytical.dsst.forces.AbstractGaussianContribution.getMeanElementRate(AbstractGaussianContribution.java:388)
	at org.orekit.propagation.semianalytical.dsst.forces.AbstractGaussianContribution.getMeanElementRate(AbstractGaussianContribution.java:300)
	at org.orekit.propagation.semianalytical.dsst.DSSTPropagator$Main.elementRates(DSSTPropagator.java:1173)
	at org.orekit.propagation.semianalytical.dsst.DSSTPropagator$Main.computeDerivatives(DSSTPropagator.java:1152)
	at org.orekit.propagation.integration.AbstractIntegratedPropagator$ConvertedMainStateEquations.computeDerivatives(AbstractIntegratedPropagator.java:758)
	at org.hipparchus.ode.ExpandableODE.computeDerivatives(ExpandableODE.java:134)
	at org.hipparchus.ode.AbstractIntegrator.computeDerivatives(AbstractIntegrator.java:265)
	at org.hipparchus.ode.nonstiff.AdaptiveStepsizeIntegrator.initializeStep(AdaptiveStepsizeIntegrator.java:226)
	at org.hipparchus.ode.nonstiff.EmbeddedRungeKuttaIntegrator.integrate(EmbeddedRungeKuttaIntegrator.java:226)
	at org.orekit.propagation.integration.AbstractIntegratedPropagator.integrateDynamics(AbstractIntegratedPropagator.java:477)
	at org.orekit.propagation.integration.AbstractIntegratedPropagator.propagate(AbstractIntegratedPropagator.java:425)

I am confused as to why the Third body has such a large impact, and why it matters that there isn’t data for 2042, when I am trying to propagate in 2027. I have also noticed that if I change the minStep, maxStep, and positionTolerance to be much smaller this problem does not persist.

deorbits_notebook.ipynb (7.1 KB)

I have attached the notebook that I am using to run this. Can anyone provide any clarification to why this is happening, or if I am doing something incorrectly.

Hi there,

I must start by apologizing for not looking at your Jupiter NB as I am on my phone. What’s the initial orbit like?

I understand that you are using DSST with an adaptive stepzise integrator? I don’t think this is necessary as the point of semi analytical models is to smooth the dynamics. Have you tried any fixed stepsize scheme like RK4?

Your first error arises because the orbit somehow becomes hyperbolic, which might be due to integration noise, resonance or a bug. Have you looked on gitlab if any known issue ressembles this? I recently posted about propagation errors seemingly linked to the lunar perturbation, but the exception was different.

The second one is indeed weird if the propagation does stop in 2029. Have you tried removing the force that requires solar activity data?

Best,
Romain.

Hi,

Thanks for your reply. I think the issue is that my orbit is degrading to the point of re-entry, when I switch to the Harris-Priester drag model it says that my semi-major axis is -8,000m. Also, my plots of sma and eccentricity, when using NRLMSISE00, suggest this is the case.

Additionally, I switched to ClassicalRungeKutta and wasn’t able to reproduce the second issue.

Thanks for your help.

Hi there,

I’m glad that you made progress. If ultimately you’re interested in time of reentry, you could set up an altitude detector.

About the second issue, maybe the adaptive step was trying a gigantic leap leading to a big jump of date. That would explain why lowering the maximum stepsize or switching to RK4 removed the problem.

Best,
Romain.