diff --git a/src/main/java/org/orekit/forces/maneuvers/propulsion/ThrustPropulsionModel.java b/src/main/java/org/orekit/forces/maneuvers/propulsion/ThrustPropulsionModel.java index 983170e8f2790196f6435e5249b4cb7e3a61423e..9a5574df16d27b14922a597ff18b4fdd4f0149e3 100644 --- a/src/main/java/org/orekit/forces/maneuvers/propulsion/ThrustPropulsionModel.java +++ b/src/main/java/org/orekit/forces/maneuvers/propulsion/ThrustPropulsionModel.java @@ -108,14 +108,12 @@ public interface ThrustPropulsionModel extends PropulsionModel { final Attitude maneuverAttitude, double[] parameters) { + // Extract thrust & direction from thrust vector final Vector3D thrustVector = getThrustVector(s, parameters); final double thrust = thrustVector.getNorm(); final Vector3D direction = thrustVector.normalize(); // Compute thrust acceleration in inertial frame - // It seems under-efficient to rotate direction and apply thrust - // instead of just rotating the whole thrust vector itself. - // However it has to be done that way to avoid numerical discrepancies with legacy tests. return new Vector3D(thrust / s.getMass(), maneuverAttitude.getRotation().applyInverseTo(direction)); } @@ -133,9 +131,6 @@ public interface ThrustPropulsionModel extends PropulsionModel { final FieldVector3D direction = thrustVector.normalize(); // Compute thrust acceleration in inertial frame - // It seems under-efficient to rotate direction and apply thrust - // instead of just rotating the whole thrust vector itself. - // However it has to be done that way to avoid numerical discrepancies with legacy tests. return new FieldVector3D<>(s.getMass().reciprocal().multiply(thrust), maneuverAttitude.getRotation().applyInverseTo(direction)); }