I am trying to understand how Orbit Determination should work, along with the covariance matrix generated. The test I had set up uses Beidou’s high precision ephemerides as inputs (position only) into the propagator. I also set the initial guess to be the very first state in the observation. My expectation was that the orbit generated would be almost identical to the initial guess since there aren’t any noise in the data itself. Therefore, the residual at the first guess should almost be 0. This was the case though, and now I am wondering if there are gaps in my understanding of Orbit determination itself. I have my code attached below, which is mostly taken from the tutorial.
Another point of issue is the STD that goes in the measurement. The value of the STD determines the covariance matrix which makes sense in theory, but when I input the actual STD of my observation, the covariance matrix generated feels too large in my opinion, but I don’t have a way to verify this.
public OrekitCovariancePropagation(List<SpacecraftState> observations) {
// Initial guess from first observation
TimeStampedPVCoordinates pv = observations.get(0).getPVCoordinates();
Orbit initialGuess = new CartesianOrbit(pv, frameTEME, pv.getDate(), mu);
DormandPrince853IntegratorBuilder integrator = new DormandPrince853IntegratorBuilder(0.001, 1000, 1e-6);
NumericalPropagatorBuilder builder = new NumericalPropagatorBuilder(initialGuess, integrator, PositionAngleType.TRUE, 1.0);
// Run BLS
Propagator[] props = BLS(observations, builder);
estimatedState = new SpacecraftState(props[0].getInitialState().getOrbit());
}
private Propagator[] BLS(List<SpacecraftState> observations, PropagatorBuilder builder) {
LeastSquaresOptimizer lso = new LevenbergMarquardtOptimizer();
BatchLSEstimator estimator = new BatchLSEstimator(lso, builder);
// Using scaled STD for measurements
double[] stdArr = getSTD(observations);
double[] posArr = { stdArr[0] / 100, stdArr[1] / 100, stdArr[2] / 100 };
for (SpacecraftState state : observations) {
Position pos = new Position(state.getDate(), state.getPosition(), posArr, 1.0, new ObservableSatellite(0));
estimator.addMeasurement(pos);
}
Propagator[] estimatedPropagators = estimator.estimate();
covarianceMatrix = estimator.getPhysicalCovariances(1e-15);
return estimatedPropagators;
}
I also added all the required force models to the propagator (sun and moon third body), gravity field, and Solar Radiation Pressure.
The result I get for the Estimated State is
Estimated State: {33,633,478.11606355; -14,827,612.255421402; 20,675,806.279446695}
True State: {33,624,630.958034806; -14,821,489.93243606; 20,693,313.03396951}
Any help would be greatly appreciated.