DragSensitive.java

  1. /* Copyright 2002-2025 CS GROUP
  2.  * Licensed to CS GROUP (CS) under one or more
  3.  * contributor license agreements.  See the NOTICE file distributed with
  4.  * this work for additional information regarding copyright ownership.
  5.  * CS licenses this file to You under the Apache License, Version 2.0
  6.  * (the "License"); you may not use this file except in compliance with
  7.  * the License.  You may obtain a copy of the License at
  8.  *
  9.  *   http://www.apache.org/licenses/LICENSE-2.0
  10.  *
  11.  * Unless required by applicable law or agreed to in writing, software
  12.  * distributed under the License is distributed on an "AS IS" BASIS,
  13.  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14.  * See the License for the specific language governing permissions and
  15.  * limitations under the License.
  16.  */
  17. package org.orekit.forces.drag;

  18. import java.util.List;

  19. import org.hipparchus.CalculusFieldElement;
  20. import org.hipparchus.geometry.euclidean.threed.FieldVector3D;
  21. import org.hipparchus.geometry.euclidean.threed.Vector3D;
  22. import org.orekit.propagation.FieldSpacecraftState;
  23. import org.orekit.propagation.SpacecraftState;
  24. import org.orekit.utils.ParameterDriver;

  25. /** Interface for spacecraft that are sensitive to atmospheric drag forces.
  26.  *
  27.  * @see DragForce
  28.  * @author Luc Maisonobe
  29.  * @author Pascal Parraud
  30.  */
  31. public interface DragSensitive {

  32.     /** Parameter name for global multiplicative factor.
  33.      * @since 12.0
  34.      */
  35.     String GLOBAL_DRAG_FACTOR = "global drag factor";

  36.     /** Parameter name for drag coefficient. */
  37.     String DRAG_COEFFICIENT = "drag coefficient";

  38.     /** Parameter name for lift ration enabling Jacobian processing.
  39.      * <p>
  40.      * The lift ratio is the proportion of atmosphere modecules that will
  41.      * experience specular reflection when hitting spacecraft instead
  42.      * of experiencing diffuse reflection. The ratio is between 0 and 1,
  43.      * 0 meaning there are no specular reflection, only diffuse reflection,
  44.      * and hence no lift effect.
  45.      * </p>
  46.      * @since 9.0
  47.      */
  48.     String LIFT_RATIO = "lift ratio";

  49.     /** Check if model depends on attitude's rotation rate or acceleration at a given, fixed date.
  50.      * If false, it essentially means that at most the attitude's rotation is used when computing the acceleration vector.
  51.      * The default implementation returns false as common models for orbital mechanics do not.
  52.      * @return true if force model depends on attitude derivatives
  53.      * @since 12.1
  54.      */
  55.     default boolean dependsOnAttitudeRate() {
  56.         return false;
  57.     }

  58.     /** Get the drivers for supported parameters.
  59.      * @return parameters drivers
  60.      * @since 8.0
  61.      */
  62.     List<ParameterDriver> getDragParametersDrivers();

  63.     /** Compute the acceleration due to drag.
  64.      * <p>
  65.      * The computation includes all spacecraft specific characteristics
  66.      * like shape, area and coefficients.
  67.      * </p>
  68.      * @param state current state
  69.      * @param density atmospheric density at spacecraft position
  70.      * @param relativeVelocity relative velocity of atmosphere with respect to spacecraft,
  71.      * in the same inertial frame as spacecraft orbit (m/s)
  72.      * @param parameters values of the force model parameters
  73.      * @return spacecraft acceleration in the same inertial frame as spacecraft orbit (m/s²)
  74.      * @since 12.0
  75.      */
  76.     Vector3D dragAcceleration(SpacecraftState state,
  77.                               double density, Vector3D relativeVelocity,
  78.                               double[] parameters);

  79.     /** Compute the acceleration due to drag.
  80.      * <p>
  81.      * The computation includes all spacecraft specific characteristics
  82.      * like shape, area and coefficients.
  83.      * </p>
  84.      * @param state current state
  85.      * @param density atmospheric density at spacecraft position
  86.      * @param relativeVelocity relative velocity of atmosphere with respect to spacecraft,
  87.      * in the same inertial frame as spacecraft orbit (m/s)
  88.      * @param parameters values of the force model parameters
  89.      * @param <T> instance of a CalculusFieldElement
  90.      * @return spacecraft acceleration in the same inertial frame as spacecraft orbit (m/s²)
  91.      * @since 12.0
  92.      */
  93.     <T extends CalculusFieldElement<T>> FieldVector3D<T> dragAcceleration(FieldSpacecraftState<T> state,
  94.                                                                           T density, FieldVector3D<T> relativeVelocity,
  95.                                                                           T[] parameters);
  96. }