ImpulsiveManeuverSpecificFrame
Aller à la navigation
Aller à la recherche
public class ImpulsiveManeuverSpecificFrame {
public static void main(String[] args) throws PatriusException {
// Creating a mass model with a main part and with a tank
final AssemblyBuilder builder = new AssemblyBuilder();
// Main part (dry mass)
final double dryMass = 1000.;
builder.addMainPart("MAIN");
builder.addProperty(new MassProperty(dryMass), "MAIN");
// Tank part (ergols mass)
final double ergolsMass = 100.;
builder.addPart("TANK", "MAIN", Transform.IDENTITY);
builder.addProperty(new MassProperty(ergolsMass), "TANK");
final Assembly assembly = builder.returnAssembly();
final MassProvider mm = new MassModel(assembly);
// Event corresponding to the criteria to trigger the impulsive maneuver
// (when the S/C is at the apogee)
final EventDetector event = new AnomalyDetector(PositionAngle.TRUE, FastMath.PI);
// Creation of the impulsive maneuver (20 m/s int the x vehicle direction)
final Vector3D deltaV = new Vector3D(20., 0., 0.);
final double isp = 300.;
final Frame GCRF = FramesFactory.getGCRF();
// SPECIFIC
final ImpulseManeuver imp = new ImpulseManeuver(event, deltaV, GCRF, isp, mm, "TANK");
// SPECIFIC
System.out.println("DV components: "+imp.getDeltaVSat());
System.out.println("Maneuver frame: "+imp.getFrame());
}
}