From e6298d88b575f866f772dad3f71ed89d9baa2122 Mon Sep 17 00:00:00 2001 From: Maxime Journot Date: Wed, 14 Sep 2022 18:50:42 +0200 Subject: [PATCH] Removed commented note in ThrustPropulsionModel. Fixes #924. --- .../forces/maneuvers/propulsion/ThrustPropulsionModel.java | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) 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 983170e8f..9a5574df1 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)); } -- GitLab