Hello Orekit community,
I’ve been trying to do the following. Retrieve manually the state vector from a CDM at TCA and propagate it back for two days assuming a low-thrust maneuver. Then retrieve the state vector at TCA-2days and propagate it forwards with the same maneuver but this time introducing a perturbation in the thrust.
The code is the following:
position = Vector3D([initialX,initialY,initialZ])
velocity = Vector3D([initialXdot,initialYdot,initialZdot])
initialCoordinates = PVCoordinates(position, velocity)
initialOrbit = CartesianOrbit(initialCoordinates, inertialFrame, initialDate,
Constants.EGM96_EARTH_MU)
minStep = 0.001
maxStep = 1.0
initStep = 0.001
positionTolerance = 1.0
tolerances = NumericalPropagator.tolerances(positionTolerance,
initialOrbit,
initialOrbit.getType())
integrator = DormandPrince853Integrator(minStep, maxStep,
JArray_double.cast_(tolerances[0]),
JArray_double.cast_(tolerances[1]))
integrator.setInitialStepSize(initStep)
satelliteMass =5000.0
initialState = SpacecraftState(initialOrbit, satelliteMass)
num_propagator_maneuver = NumericalPropagator(integrator)
num_propagator_maneuver.setOrbitType(initialOrbit.getType())
isp = 2000.0
thrust = 0.0028
direction = Vector3D(0.0, 1.0, 0.0)
thruster_axis = Vector3D(0.0, 1.0, 0.0)
thrust_direction_provider = ConstantThrustDirectionProvider(direction)
thrust_direction_and_attitude_provider = ThrustDirectionAndAttitudeProvider.buildFromDirectionInLOF(
LOFType.QSW,
thrust_direction_provider,
thruster_axis)
num_propagator_maneuver.setAttitudeProvider(thrust_direction_and_attitude_provider)
num_propagator_maneuver.setInitialState(initialState)
MCsamples = 100
mean, sigma = 0, 0.005
perturbation = np.random.normal(mean,sigma,MCsamples)
for i in range(MCsamples):
perturbed_thrust = float(thrust + perturbation[i]*thrust)
duration_low_thrust_maneuver = finalDate.durationFrom(initialDate)
low_thrust_maneuver = ConstantThrustManeuver(initialDate, duration_low_thrust_maneuver, perturbed_thrust, isp, direction)
num_propagator_maneuver.addForceModel(low_thrust_maneuver)
end_state = num_propagator_maneuver.propagate(initialDate, finalDate)
The issue that I encounter is that when propagating with thrust perturbation, the X coordinate of the end state is off by a lot. It should be somewhere around -2035 km but I get values from 1600 to 2400 km. Also the Y and Z coordinates are changing but not that much. I need to correct these coordinates because I’m interested in computing the probability of collision afterwards to get some statistical data. But unfortunately only one out of 100 generates a collision with a very small PoC. Do you know what could I improve in the code or what could I do to get more or less the same position at TCA in more samples (assuming of course that the time of closest approach doesn’t change)? Thank you very much for your help.
All the best,
Razvan