Skip to content
Snippets Groups Projects
Commit 10bb9c32 authored by Maxime Journot's avatar Maxime Journot
Browse files

Merge branch 'issue-403' into develop

parents 2359c3e6 df7c50b4
No related branches found
No related tags found
No related merge requests found
......@@ -21,6 +21,10 @@
</properties>
<body>
<release version="10.0" date="TBD" description="TBD">
<action dev="maxime" type="add" issue="403">
Added tests for class UnivariateProcessNoise.
Working tests for non-Cartesian orbit propagation are still needed.
</action>
<action dev="maxime" type="fix" issue="514">
Deprecated unused DerivativeStructure acceleration computation methods.
In interfaces radiationPressureAcceleration and dragAcceleration, and all their implementations and their tests.
......
......@@ -24,6 +24,7 @@ import org.orekit.errors.OrekitException;
import org.orekit.frames.LOFType;
import org.orekit.orbits.PositionAngle;
import org.orekit.propagation.SpacecraftState;
import org.orekit.utils.CartesianDerivativesFilter;
/** Provider for a temporal evolution of the process noise matrix.
* All parameters (orbital or propagation) are time dependent and provided as {@link UnivariateFunction}.
......@@ -184,40 +185,25 @@ public class UnivariateProcessNoise extends AbstractCovarianceMatrixProvider {
// Form the diagonal matrix in LOF frame and Cartesian formalism
final RealMatrix lofCartesianProcessNoiseMatrix = MatrixUtils.createRealDiagonalMatrix(lofOrbitalProcessNoiseValues);
// Get the rotation matrix from LOF to inertial frame
final double[][] lofToInertialRotation = lofType.rotationFromInertial(current.getPVCoordinates()).
revert().getMatrix();
// Jacobian from LOF to inertial frame
final RealMatrix jacLofToInertial = MatrixUtils.createRealMatrix(6, 6);
jacLofToInertial.setSubMatrix(lofToInertialRotation, 0, 0);
jacLofToInertial.setSubMatrix(lofToInertialRotation, 3, 3);
// FIXME: Trying to fix the transform from LOF to inertial
//final Transform lofToInertial = lofType.transformFromInertial(current.getDate(), current.getPVCoordinates()).getInverse();
//final Vector3D OM = lofToInertial.getRotationRate().negate();
//final double[][] MOM = new double[3][3];
//MOM[0][1] = -OM.getZ();
//MOM[0][2] = OM.getY();
//MOM[1][0] = OM.getZ();
//MOM[1][2] = -OM.getX();
//MOM[2][0] = -OM.getY();
//MOM[2][1] = OM.getX();
//jacLofToInertial.setSubMatrix(MOM, 3, 0);
//debug
// Get the Jacobian from LOF to Inertial
final double[][] dLofdInertial = new double[6][6];
lofType.transformFromInertial(current.getDate(),
current.getPVCoordinates()).getInverse().getJacobian(CartesianDerivativesFilter.USE_PV,
dLofdInertial);
final RealMatrix jacLofToInertial = MatrixUtils.createRealMatrix(dLofdInertial);
// Jacobian of orbit parameters with respect to Cartesian parameters
final double[][] dYdC = new double[6][6];
current.getOrbit().getJacobianWrtCartesian(positionAngle, dYdC);
final RealMatrix jacParametersWrtCartesian = MatrixUtils.createRealMatrix(dYdC);
final RealMatrix jacOrbitWrtCartesian = MatrixUtils.createRealMatrix(dYdC);
// Complete Jacobian of the transformation
final RealMatrix jacobian = jacParametersWrtCartesian.multiply(jacLofToInertial);
final RealMatrix jacobian = jacOrbitWrtCartesian.multiply(jacLofToInertial);
// Return the orbital process noise matrix in inertial frame and proper orbit type
final RealMatrix inertialOrbitalProcessNoiseMatrix = jacobian.
multiply(lofCartesianProcessNoiseMatrix).
multiply(jacobian.transpose());
multiplyTransposed(jacobian);
return inertialOrbitalProcessNoiseMatrix;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment