Post · 4 min read· pp. 507–510

aerosandbox.dynamics.point_mass.point_3D.speed_gamma_track

Attributes

Classes

Module Contents

class aerosandbox.dynamics.point_mass.point_3D.speed_gamma_track.DynamicsPointMass3DSpeedGammaTrack(mass_props=None, x_e=0, y_e=0, z_e=0, speed=0, gamma=0, track=0, alpha=0, beta=0, bank=0) : Bases: aerosandbox.dynamics.point_mass.common_point_mass._DynamicsPointMassBaseClass

code
Dynamics instance:
\* simulating a point mass
\* in 3D
\* with velocity parameterized in speed-gamma-track space

State variables:
:   x\_e: x-position, in Earth axes. [meters]
    y\_e: y-position, in Earth axes. [meters]
    z\_e: z-position, in Earth axes. [meters]
    speed: Speed; equivalent to u\_w, the x-velocity in wind axes. [m/s]
    gamma: Flight path angle. [radians]
    track: Track angle. [radians]

    > - Track of 0 == North == aligned with x\_e axis
    > - Track of np.pi / 2 == East == aligned with y\_e axis

Indirect control variables:
:   alpha: Angle of attack. [degrees]
    beta: Sideslip angle. [degrees]
    bank: Bank angle. [radians]

Control variables:
:   Fx\_w: Force along the wind-x axis. [N]
    Fy\_w: Force along the wind-y axis. [N]
    Fz\_w: Force along the wind-z axis. [N]

Parameters:
:   - **mass\_props** ([*aerosandbox.weights.mass\_properties.MassProperties*](/u/921f7ad402625b18#aerosandbox-weights-mass-properties-massproperties)) –
    - **x\_e** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) –
    - **y\_e** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) –
    - **z\_e** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) –
    - **speed** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) –
    - **gamma** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) –
    - **track** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) –
    - **alpha** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) –
    - **beta** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) –
    - **bank** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) –

mass\_props
:   For each state variable, self.state\_var = state\_var

    For each indirect control variable, self.indirect\_control\_var = indirect\_control\_var

    For each control variable, self.control\_var = 0

x\_e *= 0*

y\_e *= 0*

z\_e *= 0*

speed *= 0*

gamma *= 0*

track *= 0*

alpha *= 0*

beta *= 0*

bank *= 0*

Fx\_w *= 0*

Fy\_w *= 0*

Fz\_w *= 0*

*property* state*: Dict[str, float | aerosandbox.numpy.ndarray]*
:   Returns the state variables of this Dynamics instance as a Dict.

    Keys are strings that give the name of the variables.
    Values are the variables themselves.

    This method should look something like:
    :   ```default

{ "x_e": self.x_e, "u_e": self.u_e, ... }

code

        Return type:
        :   Dict[str, Union[float, aerosandbox.numpy.ndarray]]

    *property* control\_variables*: Dict[str, float | aerosandbox.numpy.ndarray]*
    :   Return type:
        :   Dict[str, Union[float, aerosandbox.numpy.ndarray]]

    state\_derivatives()
    :   A function that returns the derivatives with respect to time of the state specified in the state property.

        Should return a Dict with the same keys as the state property.

        Return type:
        :   Dict[str, Union[float, aerosandbox.numpy.ndarray]]

    *property* u\_e

    *property* v\_e

    *property* w\_e

    convert\_axes(*x\_from*, *y\_from*, *z\_from*, *from\_axes*, *to\_axes*)
    :   Converts a vector [x\_from, y\_from, z\_from], as given in the from\_axes frame, to an equivalent vector [x\_to,
        y\_to, z\_to], as given in the to\_axes frame.

        Identical to OperatingPoint.convert\_axes(), but adds in “earth” as a valid axis frame. For more documentation,
        see the docstring of OperatingPoint.convert\_axes().

        Both from\_axes and to\_axes should be a string, one of:
        :   - “geometry”
            - “body”
            - “wind”
            - “stability”
            - “earth”

        Parameters:
        :   - **x\_from** (*float*) – x-component of the vector, in from\_axes frame.
            - **y\_from** (*float*) – y-component of the vector, in from\_axes frame.
            - **z\_from** (*float*) – z-component of the vector, in from\_axes frame.
            - **from\_axes** (*str*) – The axes to convert from. See above for options.
            - **to\_axes** (*str*) – The axes to convert to. See above for options.

        Return type:
        :   Tuple[float, float, float]

        Returns: The x-, y-, and z-components of the vector, in to\_axes frame. Given as a tuple.

    add\_force(*Fx=0*, *Fy=0*, *Fz=0*, *axes='wind'*)
    :   Adds a force (in whichever axis system you choose) to this Dynamics instance.

        Parameters:
        :   - **Fx** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) – Force in the x-direction in the axis system chosen. [N]
            - **Fy** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) – Force in the y-direction in the axis system chosen. [N]
            - **Fz** (*Union**[**float**,* *aerosandbox.numpy.ndarray**]*) – Force in the z-direction in the axis system chosen. [N]
            - **axes** – The axis system that the specified force is in. One of:
              \* “geometry”
              \* “body”
              \* “wind”
              \* “stability”
              \* “earth”

        Return type:
        :   None

        Returns: None (in-place)

<a id="aerosandbox.dynamics.point_mass.point_3D.speed_gamma_track.dyn"></a> aerosandbox.dynamics.point\_mass.point\_3D.speed\_gamma\_track.dyn