environment

Functionalities of environment objects.

This module provides functionalities for environment objects. Specifically, it contains classes and functions that perform computations related to environment models of natural and artificial bodies. Much of the functionality in this module concerns classes stored inside Body objects, a list of which is in turn stored in a SystemOfBodies object. Note that the classes in this module are rarely created manually, but are instead created by the functionality in the environment_setup module.

Functions

transform_to_inertial_orientation(...)

Function to convert a Cartesian state vector from a body-fixed to an inertial frame

save_vehicle_mesh_to_file(...[, ...])

Function to save the mesh used for a hypersonic local inclination analysis to a file.

fit_tle_to_cartesian_state_history(*args, ...)

Overloaded function.

save_vehicle_mesh_to_file(local_inclination_analysis_object: tudatpy.kernel.dynamics.environment.HypersonicLocalInclinationAnalysis, output_directory: str, output_file_prefix: str = '') → None

Function to save the mesh used for a hypersonic local inclination analysis to a file.

Function to save the mesh used for a hypersonic local inclination analysis to a file. This function saves two files to the specified directory, with filenames: “ShapeFile.dat” and “SurfaceNormalFile.dat”, where these files names may be prefixed by an optional string (see below). The first of these files contains four columns defining the surface points that define mesh, with Column 0: point index; Column 1: x-position of point; Column 1: y-position of point; Column 2: z-position of point. The second file contains four columns with Column 0: point index; Column 1: x-component of surface normal; Column 1: y-position of surface normal; Column 2: z-position of surface normal.

Parameters:
  • local_inclination_analysis_object (HypersonicLocalInclinationAnalysis) – Object used to calculate the aerodynamics of the vehicle

  • output_directory (str) – Directory to which the files are to be saved

  • output_file_prefix (str, default='') – Optional prefix of output file names

transform_to_inertial_orientation(state_in_body_fixed_frame: numpy.ndarray[numpy.float64[6, 1]], current_time: float, rotational_ephemeris: tudatpy.kernel.dynamics.environment.RotationalEphemeris) → numpy.ndarray[numpy.float64[6, 1]]

Function to convert a Cartesian state vector from a body-fixed to an inertial frame

Function to convert a Cartesian state vector from a body-fixed to an inertial frame, using a RotationalEphemeris object as a model for the rotation. The body-fixed frame from which the conversion takes place is the body_fixed_frame_name frame, the (assumedly) inertial frame to which the conversion is done is inertial_frame_name.

This function calls rotate_state_to_frame() (with frame \(A\) the inertial frame, and frame \(B\) the body-fixed frame). The present function computes the required rotation matrix and its time derivative from the rotational_ephemeris input given here.

Parameters:
  • state_in_body_fixed_frame (numpy.ndarray[numpy.float64[6, 1]]) – Cartesian state (position and velocity) in the body-fixed frame

  • current_time (float) – Epoch in seconds since J2000 (TDB) at which the transformation is to be computed.

  • rotational_ephemeris (RotationalEphemeris) – Boy rotation model that is to be used to convert the body-fixed state to inertial state

Returns:

Cartesian state transformed to inertial frame, using rotational_ephemeris model, from body-fixed state_in_body_fixed_frame

Return type:

numpy.ndarray[numpy.float64[6, 1]]

fit_tle_to_cartesian_state_history(*args, **kwargs)

Overloaded function.

Overload 1: fit_tle_to_cartesian_state_history(cartesian_state_history: dict[float, numpy.ndarray[numpy.float64[6, 1]]], frame_orientation: str) -> tudatpy.kernel.dynamics.environment.TleFitResult

Fit a full-precision numerical TLE to an Earth-centred Cartesian state history using the default fit settings.

The fit minimizes Cartesian position residuals with a damped Levenberg-Marquardt solve. It evaluates a full-precision SGP4 model using nonsingular equinoctial solve-for parameters and a central-difference Jacobian.

Parameters:
  • cartesian_state_history (dict) – Mapping from epoch to Cartesian state.

  • frame_orientation (str) – Either “J2000” or “ECLIPJ2000”.

Returns:

The fitted TLE and residual diagnostics.

Return type:

TleFitResult

Overload 2: fit_tle_to_cartesian_state_history(cartesian_state_history: dict[float, numpy.ndarray[numpy.float64[6, 1]]], frame_orientation: str, settings: tudatpy.kernel.dynamics.environment.TleFitSettings) -> tudatpy.kernel.dynamics.environment.TleFitResult

Fit a full-precision numerical TLE to an Earth-centred Cartesian state history.

The fit minimizes Cartesian position residuals with a damped Levenberg-Marquardt solve. It evaluates a full-precision SGP4 model using nonsingular equinoctial solve-for parameters and a central-difference Jacobian.

Parameters:
  • cartesian_state_history (dict) – Mapping from epoch to Cartesian state.

  • frame_orientation (str) – Either “J2000” or “ECLIPJ2000”.

  • settings (TleFitSettings) – Configuration settings for the nonlinear fit.

Returns:

The fitted TLE and residual diagnostics.

Return type:

TleFitResult

Enums

FrequencyGapHandling

Enumeration of methods for handling gaps in transmitted frequency data.

class FrequencyGapHandling

Bases: pybind11_object

Enumeration of methods for handling gaps in transmitted frequency data.

Members:

extrapolate_at_gaps : Extrapolate the transmitted frequency when the requested epoch lies in a ramp gap.

throw_exception_at_gaps : Raise an exception when the requested epoch lies in a frequency ramp gap.

print_error_at_gaps : Report each request in a frequency ramp gap while continuing frequency evaluation.

print_error_once_at_gaps : Report a frequency ramp gap once while continuing frequency evaluation.

FrequencyGapHandling.name -> str

read-only

Classes

Ephemeris

Object that computes the state of a body as a function of time

TimeEphemeris

Relativistic time-scale converter for a body (and optional reference points on bodies, such as ground stations).

Tle

Tle object containing the SGP/SDP model parameters as derived from the element set.

TleFitResult

Result and convergence diagnostics of a Cartesian-state-history-to-TLE fit.

RotationalEphemeris

Object that stores the rotational state of the bodies.

GcrsToItrsRotationModel

Object for high-accuracy GCRS<->ITRS rotation.

EarthOrientationAnglesCalculator

Object for computing high-accuracy Earth orientation angles

GravityFieldModel

Object that provides the gravity field of a body

GravityFieldVariationModel

Object that computes a single type of gravity field variation.

SphericalHarmonicsGravityField

Object that provides a spherical harmonic gravity field of a body.

TimeDependentSphericalHarmonicsGravityField

Derived class of SphericalHarmonicsGravityField that is created when any gravity field variations are detected.

BodyShapeModel

Object that provides a shape model for a natural body.

RigidBodyProperties

Object that defines the mass, center of mass, and inertia tensor as a function of time.

AtmosphereModel

Object that provides the atmospheric properties of the body.

NRLMSISE00Atmosphere

AtmosphereModel derived class created from settings returned by nrlmsise00().

RadiationSourceModel

Model created from settings returned by isotropic_radiation_source(), panelled_extended_radiation_source().

AerodynamicCoefficientInterface

Base class for computing the current aerodynamic coefficients of the body

HypersonicLocalInclinationAnalysis

Model created by __init__().

TransmittingFrequencyCalculator

Object that computes the current transmitting frequency of a ground station.

ConstantTransmittingFrequencyCalculator

Object defining a constant transmitted frequency.

PiecewiseLinearFrequencyInterpolator

Object that computes the current transmitting frequency of a ground station, using a piecewise linear interpolation of the frequency over defined intervals.

PointingAnglesCalculator

Calculator for ground station elevation and azimuth in a local East-North-Up frame.

GroundStation

Object used to define and store properties of a ground station.

GroundStationState

Object that performs computations of the current (body-fixed) position and frame conversions of the ground station.

FlightConditions

Object that calculates various state-derived quantities typically relevant for flight dynamics.

AtmosphericFlightConditions

Object that calculates various state-derived quantities typically relevant for flight dynamics, for flight in an atmosphere.

AerodynamicAngleCalculator

Object to calculate (aerodynamic) orientation angles, and frame transformations, from current vehicle state.

VehicleSystems

Object used to store physical (hardware) properties of a vehicle.

EngineModel

Object defining the thrust produced by an engine.

Body

Object that stores the environment properties and current state of a single body.

SystemOfBodies

Object that contains a set of Body objects and associated frame information.

class Ephemeris

Bases: pybind11_object

Object that computes the state of a body as a function of time

Object (typically stored inside a Body object) that computes the state of a body as a function of time, both outside of a propagation, and during a propagation if the given body’s translational state is not propagated. Note that this object computes the state w.r.t. its own origin (defined by frame_origin), which need not be the same as the global frame origin of the environment.

cartesian_position(self: tudatpy.kernel.dynamics.environment.Ephemeris, current_time: float) → numpy.ndarray[numpy.float64[3, 1]]

As cartesian_state, but only the three position components

Parameters:

current_time (float) – Time (in seconds since J2000 in TDB time scale) at which the state is to be computed.

Returns:

Requested Cartesian position

Return type:

numpy.ndarray

cartesian_state(self: tudatpy.kernel.dynamics.environment.Ephemeris, current_time: float) → numpy.ndarray[numpy.float64[6, 1]]

This function returns the Cartesian state (position and velocity) at the given time, w.r.t. the frame_origin.

Parameters:

current_time (float) – Time (in seconds since J2000 in TDB time scale) at which the state is to be computed.

Returns:

Requested Cartesian state

Return type:

numpy.ndarray

cartesian_velocity(self: tudatpy.kernel.dynamics.environment.Ephemeris, current_time: float) → numpy.ndarray[numpy.float64[3, 1]]

As cartesian_state, but only the three velocity components

Parameters:

current_time (float) – Time (in seconds since J2000 in TDB time scale) at which the state is to be computed.

Returns:

Requested Cartesian velocity

Return type:

numpy.ndarray

property frame_orientation

read-only

Name of the frame orientation w.r.t which this object provides its states

Type:

str

property frame_origin

read-only

Name of the reference body/point w.r.t. which this object provides its states

Type:

str

class TimeEphemeris

Bases: pybind11_object

Relativistic time-scale converter for a body (and optional reference points on bodies, such as ground stations).

This object is created/populated from relativistic time propagator settings after propagation of the associated proper-time differential equations. Depending on the selected model, it provides either direct barycentric↔proper-time conversion, or chained barycentric↔planet-centered↔proper-time conversion for configured reference points.

Time-ephemeris data are generated from settings created with: first_order_bodycentric_relativistic_time_settings(), bodycentered_to_topocentric_time_settings(), and direct_relativistic_time_settings(). These settings are then attached through set_relativistic_time_converters().

Two conversion structures are used in Tudat:

  1. Direct-from-metric (no planet-centered coordinate time available):

\[\Delta_{B\tau}^{\mathrm{direct}}(t_B)=\tau-t_B,\qquad \Delta_{\tau B}^{\mathrm{direct}}(\tau)=t_B-\tau.\]
  1. Post-Newtonian chained conversion (with planet-centered coordinate time \(t_P\)):

\[\Delta_{B\tau}(t_B)=\Delta_{BC}(t_B)+\Delta_{PT}(t_P)+\Delta_{\mathrm{direct}}(t_P), \qquad t_P=t_B+\Delta_{BC}(t_B),\]

where \(\Delta_{BC}=t_P-t_B\), \(\Delta_{PT}=\tau-t_P\), and for first-order direct conversion \(\Delta_{\mathrm{direct}}=-\mathbf{v}_C\cdot\mathbf{r}/c^2\). For \(\tau\rightarrow t_B\), the inverse conversion applies the inverse/interpolated \(\Delta_{PT}\) and \(\Delta_{BC}\) terms with the opposite-sign direct correction.

The object is typically set up via set_relativistic_time_converters() using settings created from the propagator module.

get_time_difference(self: tudatpy.kernel.dynamics.environment.TimeEphemeris, input_scale: tudatpy.kernel.astro.time_representation.TimeScales, output_scale: tudatpy.kernel.astro.time_representation.TimeScales, input_time: float, point_identifier: str = '') → float

Get time difference \(t_{output} - t_{input}\) at a given input epoch.

Parameters:
  • input_scale (TimeScales) – Input time scale.

  • output_scale (TimeScales) – Output time scale.

  • input_time (float) – Input time value in seconds since J2000.

  • point_identifier (str, default = "") – Optional reference point identifier (for topocentric/local proper time).

Returns:

Time difference in seconds.

Return type:

float

get_time_difference_from_time(self: tudatpy.kernel.dynamics.environment.TimeEphemeris, input_scale: tudatpy.kernel.astro.time_representation.TimeScales, output_scale: tudatpy.kernel.astro.time_representation.TimeScales, input_time: tudatpy.kernel.astro.time_representation.Time, point_identifier: str = '') → tudatpy.kernel.astro.time_representation.Time

Get time difference \(t_{output} - t_{input}\) at a given input epoch.

This overload takes and returns a Time object.

Parameters:
  • input_scale (TimeScales) – Input time scale.

  • output_scale (TimeScales) – Output time scale.

  • input_time (Time) – Input time value as a Time object.

  • point_identifier (str, default = "") – Optional reference point identifier (for topocentric/local proper time).

Returns:

Time difference as a Time object.

Return type:

Time

class Tle

Bases: pybind11_object

Tle object containing the SGP/SDP model parameters as derived from the element set.

Note

This class is typically used together with the TleEphemeris class, which uses the TLE data to compute the state of a satellite at a given epoch.

__init__(*args, **kwargs)

Overloaded function.

Overload 1: __init__(self: tudatpy.kernel.dynamics.environment.Tle, lines: str) -> None

Initialize TLE object from a single string containing the TLE data, delimited by a newline character.

type:

str

Overload 2: __init__(self: tudatpy.kernel.dynamics.environment.Tle, line_1: str, line_2: str) -> None

Initialize TLE object from separate strings for the first and second lines of the TLE.

type:

str

epoch(self: tudatpy.kernel.dynamics.environment.Tle) → float

Retrieve the epoch of the two-line element set.

Returns:

Epoch in seconds since J2000 (TDB).

Return type:

float

get_arg_of_perigee(self: tudatpy.kernel.dynamics.environment.Tle) → float

Retrieve the argument of perigee of the two-line element set.

Returns:

Argument of perigee, in rad.

Return type:

float

get_b_star(self: tudatpy.kernel.dynamics.environment.Tle) → float

Retrieve the B-star drag term of the two-line element set.

Returns:

B-star drag term used by SGP4, in inverse Earth radii.

Return type:

float

get_eccentricity(self: tudatpy.kernel.dynamics.environment.Tle) → float

Retrieve the eccentricity of the two-line element set.

Returns:

Orbital eccentricity.

Return type:

float

get_epoch(self: tudatpy.kernel.dynamics.environment.Tle) → float

Retrieve the epoch of the two-line element set.

Returns:

Epoch in seconds since J2000 (TDB).

Return type:

float

get_inclination(self: tudatpy.kernel.dynamics.environment.Tle) → float

Retrieve the orbital inclination of the two-line element set.

Returns:

Inclination, in rad.

Return type:

float

get_mean_anomaly(self: tudatpy.kernel.dynamics.environment.Tle) → float

Retrieve the mean anomaly at the epoch of the two-line element set.

Returns:

Mean anomaly, in rad.

Return type:

float

get_mean_motion(self: tudatpy.kernel.dynamics.environment.Tle) → float

Retrieve the mean motion of the two-line element set.

Returns:

Mean motion, in rad/min, as used by SGP4.

Return type:

float

get_right_ascension(self: tudatpy.kernel.dynamics.environment.Tle) → float

Retrieve the right ascension of the ascending node of the two-line element set.

Returns:

Right ascension of the ascending node, in rad.

Return type:

float

property argument_of_perigee

read-only

Argument of perigee of the orbit as provided by the TLE, in radians.

Type:

float

property b_star

read-only

B* coefficient used by the SGP4 propagator, as provided by the TLE.

Type:

float

property classification

read-only

Security classification of the TLE (e.g. 'U' for unclassified).

Type:

str

property eccentricity

read-only

Orbital eccentricity as provided by the TLE.

Type:

float

property element_set_number

read-only

Element set number of the TLE, indicating successive updates.

Type:

int

property ephemeris_type

read-only

Ephemeris type indicator used by the TLE (typically zero for SGP4).

Type:

int

property inclination

read-only

Orbital inclination as provided by the TLE, in radians.

Type:

float

property international_designator_launch_number

read-only

International designator (COSPAR ID) launch number of the space object, as provided by the TLE.

Type:

int

property international_designator_launch_year

read-only

International designator (COSPAR ID) launch year of the space object, as provided by the TLE.

Type:

int

property international_designator_piece

read-only

International designator (COSPAR ID) launch piece of the space object, as provided by the TLE.

Type:

str

property mean_anomaly

read-only

Mean anomaly of the orbit at the TLE epoch as provided by the TLE, in radians.

Type:

float

property mean_motion

read-only

Mean motion of the orbit in radians per minute, in radians per minute.

Type:

float

property mean_motion_first_derivative

read-only

First time derivative of the mean motion as given in the TLE, in radians per minute^2.

Type:

float

property mean_motion_second_derivative

read-only

Second time derivative of the mean motion as given in the TLE, in radians per minute^3.

Type:

float

property norad_catalog_number

read-only

NORAD catalog number identifying the space object.

Type:

int

property raw_line_1

read-only

Raw first line of the two-line element set.

Type:

str

property raw_line_2

read-only

Raw second line of the two-line element set.

Type:

str

property reference_epoch

read-only

Reference epoch of the TLE element set in TDB seconds since J2000.

Type:

float

property revolution_number_at_epoch

read-only

Revolution number of the orbit at the TLE epoch.

Type:

int

property right_ascension

read-only

Right ascension of the ascending node of the orbit as provided by the TLE, in radians.

Type:

float

class TleFitResult

Bases: pybind11_object

Result and convergence diagnostics of a Cartesian-state-history-to-TLE fit.

Instances of this class are returned by fit_tle_to_cartesian_state_history().

property converged

read-only

Whether the final parameter update met the configured convergence tolerance.

Type:

bool

property fitted_tle

read-only

Full-precision fitted TLE, including serialized raw TLE lines.

Type:

Tle

property initial_position_rms

read-only

Root-mean-square position residual of the supplied or generated initial TLE, in metres.

Type:

float

property number_of_iterations

read-only

Number of Levenberg-Marquardt iterations performed.

Type:

int

property position_residuals

read-only

Position residual vectors, defined as input position minus fitted SGP4 position, in metres and ordered by input epoch.

Type:

list[numpy.ndarray]

property position_rms

read-only

Root-mean-square norm of the final position residuals, in metres.

Type:

float

class RotationalEphemeris

Bases: pybind11_object

Object that stores the rotational state of the bodies.

Object that stores the rotational state of the bodies. This object can be used to calculate rotation matrices, which are used to transform coordinates between reference frames.

angular_velocity_in_body_fixed_frame(self: tudatpy.kernel.dynamics.environment.RotationalEphemeris, time: float) → numpy.ndarray[numpy.float64[3, 1]]

Function to get the body’s angular velocity vector, expressed in the body-fixed frame.

Function to get the body’s angular velocity vector \(\boldsymbol{\omega}^{(B)}\), expressed in the body-fixed frame \(B\). The calculation of the angular velocity depends on the specific rotation model that has been defined, either from an a priori definition (see rotation_model submodule) or from processing the results of propagation of the rotational equations of motion. Note that when numerically propagating rotational dynamics, this angular velocity vector is typically directly defined in the last three entries of the state vector.

Parameters:

time (float) – Epoch in seconds since J2000 (TDB) at which the angular velocity vector is evaluated.

Returns:

Angular velocity vector of the body \(\boldsymbol{\omega}^{(B)}\) expressed in the body-fixed frame \(B\)

Return type:

numpy.ndarray

angular_velocity_in_inertial_frame(self: tudatpy.kernel.dynamics.environment.RotationalEphemeris, time: float) → numpy.ndarray[numpy.float64[3, 1]]

Function to get the body’s angular velocity vector, expressed in the inertial frame.

Function to get the body’s angular velocity vector \(\boldsymbol{\omega}^{(I)}\), expressed in the body-fixed frame \(I\). This quantity is computed from \(\mathbf{R}^{I/B}\boldsymbol{\omega}^{(B)}\), see the angular_velocity_in_body_fixed_frame and body_fixed_to_inertial_rotation functions.

Parameters:

time (float) – Epoch in seconds since J2000 (TDB) at which the angular velocity vector is evaluated.

Returns:

Angular velocity vector of the body \(\boldsymbol{\omega}^{(B)}\) expressed in the body-fixed frame \(B\)

Return type:

numpy.ndarray

body_fixed_to_inertial_rotation(self: tudatpy.kernel.dynamics.environment.RotationalEphemeris, time: float) → numpy.ndarray[numpy.float64[3, 3]]

Function to get rotation matrix from body-fixed frame to inertial frame over time.

Function to get rotation matrix from body-fixed (target) frame to inertial (base) frame over time. The calculation of this rotation matrix depends on the specific rotation model that has been defined, either from an a priori definition (see rotation_model submodule) or from processing the results of propagation of the rotational equations of motion.

Parameters:

time (float) – Epoch in seconds since J2000 (TDB) at which the rotation matrix is evaluated.

Returns:

Rotation matrix \(\mathbf{R}^{I/B}\) from body-fixed frame \(B\) to inertial frame I

Return type:

numpy.ndarray

inertial_to_body_fixed_rotation(self: tudatpy.kernel.dynamics.environment.RotationalEphemeris, time: float) → numpy.ndarray[numpy.float64[3, 3]]

Function to get rotation matrix from inertial frame to body-fixed frame over time.

Function computes the inverse (equal to transpose) rotation of the body_fixed_to_inertial_rotation function.

Parameters:

time (float) – Epoch in seconds since J2000 (TDB) at which the rotation matrix is evaluated.

time_derivative_body_fixed_to_inertial_rotation(self: tudatpy.kernel.dynamics.environment.RotationalEphemeris, time: float) → numpy.ndarray[numpy.float64[3, 3]]

Function to get time derivative of rotation matrix from body-fixed frame to inertial frame over time.

Function to get time derivative of rotation matrix from body-fixed frame to inertial frame over time (see body_fixed_to_inertial_rotation), denoted \(\dot{\mathbf{R}}^{(I/B)}\),

Parameters:

time (float) – Epoch in seconds since J2000 (TDB) at which the rotation matrix derivative is evaluated.

Returns:

Rotation matrix \(\dot{\mathbf{R}}^{I/B}\) from body-fixed frame \(B\) to inertial frame I

Return type:

numpy.ndarray

time_derivative_inertial_to_body_fixed_rotation(self: tudatpy.kernel.dynamics.environment.RotationalEphemeris, time: float) → numpy.ndarray[numpy.float64[3, 3]]

Function to get time derivative of rotation matrix from inertial frame to body-fixed frame over time.

Function to get time derivative of rotation matrix from inertial frame to body-fixed frame over time (see inertial_to_body_fixed_rotation), denoted \(\dot{\mathbf{R}}^{(B/I)}\),

Parameters:

time (float) – Epoch in seconds since J2000 (TDB) at which the rotation matrix derivative is evaluated.

Returns:

Rotation matrix \(\dot{\mathbf{R}}^{B/I}\) from inertial frame I to body-fixed frame \(B\)

Return type:

numpy.ndarray

property body_fixed_frame_name

read-only

The identifier of the body-fixed frame, used in other parts of the simulation to identify it.

Type:

str

property inertial_frame_name

read-only

The identifier of the inertial frame, used in other parts of the simulation to identify it.

Type:

str

class GcrsToItrsRotationModel

Bases: RotationalEphemeris

Object for high-accuracy GCRS<->ITRS rotation.

Object derived from RotationalEphemeris that implements the high-accuracy GCRS<->ITRS rotation as per the IERS 2010 Conventions. The details of the model are described in gcrs_to_itrs() With the exception of \(s'\), the list of angles used to compute the full rotation are computed by an object of type EarthOrientationAnglesCalculator (which can be retrieved from this rotation model through angles_calculator.

get_rotation_between_intermediate_frames(self: tudatpy.kernel.dynamics.environment.GcrsToItrsRotationModel, original_frame: tudatpy.kernel.dynamics.environment.EarthOrientationIntermediateFrame, target_frame: tudatpy.kernel.dynamics.environment.EarthOrientationIntermediateFrame, epoch: float) → numpy.ndarray[numpy.float64[3, 3]]

Function to compute a rotation matrix between two IERS Earth-orientation intermediate frames.

Parameters:
  • original_frame (EarthOrientationIntermediateFrame) – Frame from which the rotation is computed.

  • target_frame (EarthOrientationIntermediateFrame) – Frame to which the rotation is computed.

  • epoch (float) – Seconds since J2000 at which the rotation matrix is evaluated.

Returns:

Rotation matrix from original_frame to target_frame.

Return type:

numpy.ndarray

property angles_calculator

read-only

Object that computes the Earth rotation angles \(X,Y,s,\theta_{E},x_{p},y_{p}\)

Type:

EarthOrientationAnglesCalculator

class EarthOrientationAnglesCalculator

Bases: pybind11_object

Object for computing high-accuracy Earth orientation angles

get_gcrs_to_itrs_rotation_angles(self: tudatpy.kernel.dynamics.environment.EarthOrientationAnglesCalculator, epoch: tudatpy.kernel.astro.time_representation.Time, time_scale: tudatpy.kernel.astro.time_representation.TimeScales = <TimeScales.tdb_scale: 2>) → tuple[numpy.ndarray[numpy.float64[5, 1]], tudatpy.kernel.astro.time_representation.Time]

Function to compute high-accuracy Earth orientation angles

Function to compute high-accuracy Earth orientation angle quantities \(X,Y,s,x_{p},y_{p}\) and UT1 (from which \(\theta_{E}\) is computed) as described in gcrs_to_itrs()

Parameters:
  • epoch (astro.time_representation.Time) – Time object representing seconds since J2000 at which the Earth orientation angles are to be compute

  • time_scale (TimeScales) – Time scale in which the input epoch is given

Returns:

Pair (tuple of size two) with the first entry a list of orientation angles \(X,Y,s,x_{p},y_{p}\) (in that order) and the second entry the current UT1.

Return type:

tuple[numpy.ndarray[numpy.float64[5, 1]], astro.time_representation.Time]

class GravityFieldModel

Bases: pybind11_object

Object that provides the gravity field of a body

Object (typically stored inside a Body object) that provides the gravity field of a body, typically (but not exclusively) for use in gravitational acceleration and torque models. This base class allows access to the gravitational parameter of the body. Specific derived classes are implemented to provide models for more detailed gravity field models (e.g. spherical harmonics, polyhedron).

get_gravitational_parameter(self: tudatpy.kernel.dynamics.environment.GravityFieldModel) → float

Retrieve the gravitational parameter of the body.

Returns:

Gravitational parameter, in m^3/s^2.

Return type:

float

property gravitational_parameter

Value of the gravity field’s gravitational parameters \(\mu\)

Type:

float

class GravityFieldVariationModel

Bases: pybind11_object

Object that computes a single type of gravity field variation.

Object that computes a single type of gravity field variation. This object is typically not used directly, but internally by the TimeDependentSphericalHarmonicsGravityField class.

class SphericalHarmonicsGravityField

Bases: GravityFieldModel

Object that provides a spherical harmonic gravity field of a body.

Object (typically stored inside a Body object) that provides a spherical harmonic gravity field of a body, typically (but not exclusively) for use in gravitational acceleration and torque models. This class is derived from GravityFieldModel. This object is typically created using the spherical_harmonic() settings function. If any time variations of the gravity field are provided, an object of the derived class TimeVariableSphericalHarmonicsGravityField is created.

property cosine_coefficients

Matrix with cosine spherical harmonic coefficients \(\bar{C}_{lm}\) (geodesy normalized). Entry \((i,j)\) denotes coefficient at degree \(i\) and order \(j\).

Type:

numpy.ndarray[numpy.float64[l, m]]

property maximum_degree

read-only

Maximum spherical harmonic degree \(l_{max}\) for which coefficients are defined

Type:

int

property maximum_order

read-only

Maximum spherical harmonic order \(m_{max}\) for which coefficients are defined

Type:

int

property reference_radius

read-only

Reference radius \(R\) of the gravity field

Type:

float

property sine_coefficients

Matrix with sine spherical harmonic coefficients \(\bar{S}_{lm}\) (geodesy normalized). Entry \((i,j)\) denotes coefficient at degree \(i\) and order \(j\).

Type:

numpy.ndarray[numpy.float64[l, m]]

class TimeDependentSphericalHarmonicsGravityField

Bases: SphericalHarmonicsGravityField

Derived class of SphericalHarmonicsGravityField that is created when any gravity field variations are detected.

Derived class of SphericalHarmonicsGravityField that is created instead when any gravity field variations are detected during object creation (typically during a call of create_system_of_bodies()) This object computes the time-variability of spherical harmonic coefficients from a list of GravityFieldVariationModel objects. The cosine_coefficients and sine_coefficients attributes provide the instantaneous coefficients (including the time-variability) The nominal_cosine_coefficients and nominal_sine_coefficients provide the static (e.g. without time-variations) coefficients.

property gravity_field_variation_models

read-only

List of gravity field variation models that the object uses to update the spherical harmonic coefficients at every time step

Type:

list[GravityFieldVariationModel]

property nominal_cosine_coefficients

Matrix with cosine spherical harmonic coefficients \(\bar{C}_{lm}\) (geodesy normalized) excluding time-variations. Entry \((i,j)\) denotes coefficient at degree \(i\) and order \(j\).

Type:

numpy.ndarray[numpy.float64[l, m]]

property nominal_sine_coefficients

Matrix with sine spherical harmonic coefficients \(\bar{S}_{lm}\) (geodesy normalized) excluding time-variations. Entry \((i,j)\) denotes coefficient at degree \(i\) and order \(j\).

Type:

numpy.ndarray[numpy.float64[l, m]]

class BodyShapeModel

Bases: pybind11_object

Object that provides a shape model for a natural body.

Object (typically stored inside a Body object) that provides a shape model for a body, for instance to compute the altitude from a body-centered state, or w.r.t. which to place ground stations. This shape model is typically only associated with natural bodies. Shape models for spacecraft (for non-conservative force models) use properties stored inside the VehicleSystems object.

property average_radius

read-only

Average radius of the body, for use in computations that assume a spherical body shape.

Type:

float

class RigidBodyProperties

Bases: pybind11_object

Object that defines the mass, center of mass, and inertia tensor as a function of time.

Object that defines the mass, center of mass, and inertia tensor as a function of time, typically used for evaluation of torques and non-conservative forces in numerical state propagation. Note that this object does not define properties of a gravity field (it defines the inertial mass rather than the gravitational mass)

update(self: tudatpy.kernel.dynamics.environment.RigidBodyProperties, time: float) → None

Function to update the body properties to the current time. This function is called automatically during a propagation loop. In case these properties are not time-dependent (e.g. when using the constant_rigid_body_properties() settings) this function does nothing (since no update is needed).

Parameters:

time (float) – Epoch in seconds since J2000 (TDB) to which this object is to be updated.

property current_center_of_mass

read-only

Position of the center of mass of the object (in the body-centered, body-fixed frame), as set by the latest call to the update function of this object.

property current_inertia_tensor

read-only

Inertia tensor of the object (with axes along those of the body-fixed frame), as set by the latest call to the update function of this object.

property current_mass

read-only

Mass of the object, as set by the latest call to the update function of this object.

class AtmosphereModel

Bases: pybind11_object

Object that provides the atmospheric properties of the body.

Object that provides the atmospheric properties of the body, as a function of altitude, latitude, longitude and time. Depending on the implementation, the this dependence may be limited to altitude-only (e.g. standard atmosphere models). This object can be accessed directly by the user to compute atmospheric properties outside the loop of the propagation by calling one of its member functions. During the propagation, each body undergoing aerodynamic forces has a AtmosphericFlightConditions object associated with it (accessed from a boyd through flight_condition) that links the atmosphere model to the aerodynamic model.

get_density(self: tudatpy.kernel.dynamics.environment.AtmosphereModel, altitude: float, longitude: float, latitude: float, time: float) → float

Function to compute the atmospheric freestream density at a given location.

Parameters:
  • altitude (float) – Local altitude above the body surface at which the property is to be computed

  • latitude (float) – Geographic latitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • longitude (float) – Geographic longitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • time (float) – Epoch in seconds since J2000 (TDB) at which the property is to be computed.

Returns:

Freestream density at the given time and location

Return type:

float

get_number_density(self: tudatpy.kernel.dynamics.environment.AtmosphereModel, species: tudatpy.kernel.dynamics.environment_setup.aerodynamic_coefficients.AtmosphericCompositionSpecies, altitude: float, longitude: float, latitude: float, time: float) → float

Function to compute the atmospheric freestream number density of a given specie at a given location.

Parameters:
  • species (AtmosphericCompositionSpecies) – Atmospheric species for which the number density is to be computed

  • altitude (float) – Local altitude above the body surface at which the property is to be computed

  • latitude (float) – Geographic latitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • longitude (float) – Geographic longitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • time (float) – Epoch in seconds since J2000 (TDB) at which the property is to be computed.

Returns:

Freestream number density of the requested specie at the given time and location

Return type:

float

get_pressure(self: tudatpy.kernel.dynamics.environment.AtmosphereModel, altitude: float, longitude: float, latitude: float, time: float) → float

Function to compute the atmospheric freestream static pressure at a given location.

Parameters:
  • altitude (float) – Local altitude above the body surface at which the property is to be computed

  • latitude (float) – Geographic latitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • longitude (float) – Geographic longitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • time (float) – Epoch in seconds since J2000 (TDB) at which the property is to be computed.

Returns:

Freestream static pressure at the given time and location

Return type:

float

get_speed_of_sound(self: tudatpy.kernel.dynamics.environment.AtmosphereModel, altitude: float, longitude: float, latitude: float, time: float) → float

Function to compute the atmospheric freestream speed of sound at a given location.

Parameters:
  • altitude (float) – Local altitude above the body surface at which the property is to be computed

  • latitude (float) – Geographic latitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • longitude (float) – Geographic longitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • time (float) – Epoch in seconds since J2000 (TDB) at which the property is to be computed.

Returns:

Freestream speed of sound at the given time and location

Return type:

float

get_temperature(self: tudatpy.kernel.dynamics.environment.AtmosphereModel, altitude: float, longitude: float, latitude: float, time: float) → float

Function to compute the atmospheric freestream temperature at a given location.

Parameters:
  • altitude (float) – Local altitude above the body surface at which the property is to be computed

  • latitude (float) – Geographic latitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • longitude (float) – Geographic longitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • time (float) – Epoch in seconds since J2000 (TDB) at which the property is to be computed.

Returns:

Freestream temperature at the given time and location

Return type:

float

get_total_number_density(self: tudatpy.kernel.dynamics.environment.AtmosphereModel, altitude: float, longitude: float, latitude: float, time: float) → float

Function to compute the atmospheric freestream total number density at a given location.

Parameters:
  • altitude (float) – Local altitude above the body surface at which the property is to be computed

  • latitude (float) – Geographic latitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • longitude (float) – Geographic longitude (in the body-fixed frame of the body with the atmosphere) at which the property is to be computed

  • time (float) – Epoch in seconds since J2000 (TDB) at which the property is to be computed.

Returns:

Freestream total number density at the given time and location

Return type:

float

class NRLMSISE00Atmosphere

Bases: AtmosphereModel

AtmosphereModel derived class created from settings returned by nrlmsise00().

The model is created during environment setup and can be accessed through atmosphere_model. Atmospheric properties can be queried using the inherited AtmosphereModel methods.

__init__(self: tudatpy.kernel.dynamics.environment.NRLMSISE00Atmosphere, solar_activity_data: dict[float, tudat::input_output::solar_activity::SolarActivityData], use_ideal_gas_law: bool = True, use_storm_conditions: bool = False, use_anomalous_oxygen: bool = True) → None

Create an NRLMSISE-00 atmosphere model directly from solar activity data.

The GTD7 function of NRLMSISE-00 is used to compute the atmospheric density and temperature, from the surface to the lower exosphere. The specific heat ratio is assumed constant and equal to 1.4.

Parameters:
  • solar_activity_data (dict[float, SolarActivityData]) – Solar activity data for a range of epochs, as produced by read_solar_activity_data().

  • use_ideal_gas_law (bool, default = True) – Whether to use the ideal gas law to compute the pressure and speed of sound.

  • use_storm_conditions (bool, default = False) – Whether to include the geomagnetic storm-time contribution in the model inputs.

  • use_anomalous_oxygen (bool, default = True) – Whether to include anomalous oxygen in the computed total mass density.

get_use_geodetic_latitude(self: tudatpy.kernel.dynamics.environment.NRLMSISE00Atmosphere) → bool

Retrieve the latitude convention used by the atmosphere model.

Returns:

True if geodetic latitude is used, or False if geocentric latitude is used.

Return type:

bool

get_use_utc(self: tudatpy.kernel.dynamics.environment.NRLMSISE00Atmosphere) → bool

Retrieve whether the atmosphere model uses UTC epochs.

Returns:

True if UTC is used for the time input to the atmosphere model.

Return type:

bool

set_use_geodetic_latitude(self: tudatpy.kernel.dynamics.environment.NRLMSISE00Atmosphere, arg0: bool) → None

Set whether the atmosphere model uses geodetic latitude.

When True, geodetic latitude is used when obtaining the coordinates for atmosphere model evaluation; when False, geocentric latitude is used.

Parameters:

use_geodetic_latitude (bool) – Whether to use geodetic latitude (True) or geocentric latitude (False).

set_use_utc(self: tudatpy.kernel.dynamics.environment.NRLMSISE00Atmosphere, arg0: bool) → None

Set whether UTC epochs are used for atmosphere model evaluation.

When True, the epoch is converted to UTC when preparing the time input for the atmosphere model; when False, TDB is used.

Parameters:

use_utc (bool) – Whether to use UTC (True) or TDB (False) when evaluating the atmosphere inputs.

class RadiationSourceModel

Bases: pybind11_object

Model created from settings returned by isotropic_radiation_source(), panelled_extended_radiation_source().

class AerodynamicCoefficientInterface

Bases: pybind11_object

Base class for computing the current aerodynamic coefficients of the body

Base class for computing the current aerodynamic coefficients of the body. The implementation of the computation depends on the choice of aerodynamic coefficient model (see aerodynamic_coefficients for available options). During the propagation, this object is automatically updated to the current state by the AtmosphericFlightConditions object. The user may override the current aerodynamic coefficients when using, for instance, a custom aerodynamic guidance model (see here for an example). using the member functions of this class.

current_control_surface_force_coefficient_increment(self: tudatpy.kernel.dynamics.environment.AerodynamicCoefficientInterface, control_surface_name: str) → numpy.ndarray[numpy.float64[3, 1]]

Function to get the contribution from a single control surface to the aerodynamic force coefficient, as compute by last call to update_full_coefficients()

Parameters:

control_surface_name (str) – The name of the control surface for which the contribution is to be retrieved

Returns:

Contribution from the requested control surface to the aerodynamic force coefficient

Return type:

numpy.ndarray

current_control_surface_moment_coefficient_increment(self: tudatpy.kernel.dynamics.environment.AerodynamicCoefficientInterface, control_surface_name: str) → numpy.ndarray[numpy.float64[3, 1]]

Function to get the contribution from a single control surface to the aerodynamic moment coefficients, as compute by last call to update_full_coefficients()

Parameters:

control_surface_name (str) – The name of the control surface for which the contribution is to be retrieved

Returns:

Contribution from the requested control surface to the aerodynamic moment coefficients.

Return type:

numpy.ndarray

set_control_surface_increments(self: tudatpy.kernel.dynamics.environment.AerodynamicCoefficientInterface, control_surface_list: dict[str, tudatpy.kernel.dynamics.environment.ControlSurfaceIncrementAerodynamicInterface]) → None

Set the aerodynamic coefficient increment models for the control surfaces.

This function replaces the existing collection of control surface increment models.

Parameters:

control_surface_list (dict[str, ControlSurfaceIncrementAerodynamicInterface]) – Dictionary mapping each control surface name to its aerodynamic coefficient increment model.

update_coefficients(self: tudatpy.kernel.dynamics.environment.AerodynamicCoefficientInterface, independent_variables: list[float], time: float) → None

Function to update the aerodynamic coefficients of the body only

Function to update the aerodynamic coefficients of the body only (without the control surface contribution), based on the current state. This function may be called by the user, but will set only the current_force_coefficients and current_moment_coefficients (while leaving the current_control_surface_free_force_coefficients and current_control_surface_free_moment_coefficients unchanged)

Parameters:
  • independent_variables (list[float]) – List of inputs from which the aerodynamic coefficients are to be computed, with each entry corresponding to the value of the physical variable defined by the independent_variable_names attribute.

  • time (float) – Epoch in seconds since J2000 (TDB).

Returns:

This method updates the stored aerodynamic coefficients in place.

Return type:

None

update_full_coefficients(self: tudatpy.kernel.dynamics.environment.AerodynamicCoefficientInterface, independent_variables: list[float], control_surface_independent_variables: dict[str, list[float]], time: float, check_force_contribution: bool = True) → None

Function to update the aerodynamic coefficients, from both the body and its control surfaces

Function to update the aerodynamic coefficients of both the body and its control surfaces, based on the current state. This function will call the update_coefficients() function to update the body coefficients. This function may be called by the user, and will set the following attributes: current_force_coefficients, current_moment_coefficients , current_control_surface_free_force_coefficients and current_control_surface_free_moment_coefficients. In addition, it will modify the coefficients returned by the current_control_surface_force_coefficient_increment() and current_control_surface_moment_coefficient_increment() functions

Parameters:
  • independent_variables (list[float]) – List of inputs from which the aerodynamic coefficients of the body are to be computed, with each entry corresponding to the value of the physical variable defined by the independent_variable_names attribute.

  • control_surface_independent_variables (dict[str,list[float]]) – Dictionary of input lists from which the control surface aerodynamic coefficients are to be computed, keyed by control surface name, with each entry corresponding to the value of the physical variable defined by the control_surface_independent_variable_names attribute.

  • time (float) – Epoch in seconds since J2000 (TDB).

  • check_force_contribution (bool, default = True) – Boolean that determines if the force contribution to the aerodynamic moments should be added. Note that this input is only used if the add_force_contribution_to_moments attribute is set to True.

property control_surface_independent_variable_names

read-only

List of independent variables from which the aerodynamic coefficients of each control surface are computed, with dictionary key being the control surface name (e.g. required input to update_full_coefficients() function).

Type:

dict[str,list[AerodynamicCoefficientsIndependentVariables]]

property current_coefficients

read-only

Concatenation of current_force_coefficients and current_moment_coefficients

Type:

numpy.ndarray

property current_control_surface_free_force_coefficients

read-only

Same as current_force_coefficients, but without contribution (if any) from control surfaces

Type:

numpy.ndarray

property current_control_surface_free_moment_coefficients

read-only

Same as current_moment_coefficients, but without contribution (if any) from control surfaces

Type:

numpy.ndarray

property current_force_coefficients

read-only

The current aerodynamic force coefficients, in the frame defined by the force_coefficient_frame attribute, as computed by the last call to the update_coefficients() function.

Type:

numpy.ndarray

property current_moment_coefficients

read-only

The current aerodynamic moment coefficients, in the frame defined by the moment_coefficient_frame attribute, as computed by the last call to the update_coefficients() function.

Type:

numpy.ndarray

property force_coefficient_frame

read-only

Reference frame in which the current_force_coefficients are defined

Type:

AerodynamicCoefficientFrames

property independent_variable_names

read-only

List of independent variables from which the aerodynamic coefficients are computed (e.g. required input to update_coefficients() function).

Type:

list[AerodynamicCoefficientsIndependentVariables]

property moment_coefficient_frame

read-only

Reference frame in which the current_moment_coefficients are defined

Type:

AerodynamicCoefficientFrames

property reference_area

read-only

The aerodynamic reference area \(A\) of the coefficients

Type:

float

class HypersonicLocalInclinationAnalysis

Bases: AerodynamicCoefficientGenerator36

Model created by __init__().

See the constructor documentation for the vehicle geometry, discretization and local inclination methods.

__init__(self: tudatpy.kernel.dynamics.environment.HypersonicLocalInclinationAnalysis, independent_variable_points: list[list[float]], body_shape: tudatpy.kernel.math.geometry.SurfaceGeometry, number_of_lines: list[int], number_of_points: list[int], invert_orders: list[bool], selected_methods: list[list[int]], reference_area: float, reference_length: float, moment_reference_point: numpy.ndarray[numpy.float64[3, 1]], save_pressure_coefficients: bool = False) → None

Class constructor, taking the shape of the vehicle, and various analysis options as input.

Parameters:
  • independent_variable_points (list[list[float]]) – List containing three lists, with each sublist containing the data points of each of the independent variables for the coefficient generation. The physical meaning of each of the three independent variables is: 0 = mach number, 1 = angle of attack, 2 = angle of sideslip. Each of the subvectors must be sorted in ascending order.

  • body_shape (SurfaceGeometry) – Class that defines the shape of the vehicle as a continuous surface. The local inclination analysis discretizes the surface of the vehicle into quadrilateral panels, defined by the other inputs to this constructor. In case the tudat.geometry.SurfaceGeometry object is made up of multiple sub-shapes, different settings may be used for each

  • number_of_lines (list[int]) – Number of discretization points in the first independent surface variable of each of the subparts of body_shape. The size of this list should match the number of parts of which the body_shape is composed. The first independent variable of a subpart typically runs along the longitudinal vehicle direction

  • number_of_points (list[int]) – Number of discretization points in the second independent surface variable of each of the subparts of body_shape. The size of this list should match the number of parts of which the body_shape is composed. The first independent variable of a subpart typically runs along the lateral vehicle direction

  • invert_orders (List[ bool ]) – Booleans to denote whether the surface normals of the panels of each discretized body_shape subpart are to be inverted (i.e. inward-facing->outward facing or vice versa). The size of this list should match the number of parts of which the body_shape is composed.

  • selected_methods (List[ List[ int ] ]) – Double list of selected local inclination methods, the first index (outer list) represents compression or expansion (0 and 1), the second index (inner list) denotes the vehicle part index. The size of this inner list should match the number of parts of which the body_shape is composed. The int defining the method type is interpreted as follows. For the compression methods, the following are available: * 0: Newtonian Method. * 1: Modified Newtonian. * 2 and 3: not available at this moment. * 4: Tangent-wedge method. * 5: Tangent-cone method. * 6: Modified Dahlem-Buck method. * 7: VanDyke unified pressure method. * 8: Smyth Delta Wing method. * 9: Hankey flat surface method The expansion method has the following options: * 0: Vacuum Pressure coefficient method. * 1: Zero Pressure function. * 4: High Mach base pressure method. * 3 or 5: Prandtl-Meyer method. * 6: ACM empirical pressure coefficient.

  • reference_area (float) – Reference area used to non-dimensionalize aerodynamic forces and moments.

  • moment_reference_point (numpy.ndarray) – Reference point wrt which aerodynamic moments are calculated.

  • save_pressure_coefficients (bool) – Boolean denoting whether to save the pressure coefficients that are computed to files

clear_data(self: tudatpy.kernel.dynamics.environment.HypersonicLocalInclinationAnalysis) → None

Clear the stored local inclination analysis data.

Clears the coefficient-generation data, cached panel inclinations and pressure coefficients. This function is used to release analysis data that are no longer required.

class TransmittingFrequencyCalculator

Bases: pybind11_object

Object that computes the current transmitting frequency of a ground station.

class ConstantTransmittingFrequencyCalculator

Bases: TransmittingFrequencyCalculator

Object defining a constant transmitted frequency.

TransmittingFrequencyCalculator derived class returning the same transmitted frequency at every epoch.

Parameters:

constant_frequency (float) – Transmitted frequency, in Hz.

class PiecewiseLinearFrequencyInterpolator

Bases: TransmittingFrequencyCalculator

Object that computes the current transmitting frequency of a ground station, using a piecewise linear interpolation of the frequency over defined intervals.

If multiple intervals are defined at the same time, the frequency of the interval with the latest start time is used. If no interval is defined at the current time, the frequency is computed using the strategy defined by gap_handling.

add_frequency_interpolator(self: tudatpy.kernel.dynamics.environment.PiecewiseLinearFrequencyInterpolator, frequency_interpolator_to_add: tudatpy.kernel.dynamics.environment.PiecewiseLinearFrequencyInterpolator) → None

Function to add a frequency interpolator to the current interpolator. This will add the start times, end times, ramp rates and start frequencies of the provided interpolator to those of the current interpolator.

Parameters:

frequency_interpolator_to_add (PiecewiseLinearFrequencyInterpolator) – The frequency interpolator to add to the current interpolator.

compute_current_frequency(self: tudatpy.kernel.dynamics.environment.PiecewiseLinearFrequencyInterpolator, lookup_time_original: tudatpy.kernel.astro.time_representation.Time) → float

Compute the transmitted frequency at the requested epoch.

The frequency is evaluated using the constant term and frequency rate of the applicable ramp interval. Requests in gaps are handled according to the interpolator’s FrequencyGapHandling setting.

Parameters:

lookup_time_original (tudatpy.astro.time_representation.Time) – Epoch at which the frequency is evaluated, in the time scale used to define the ramp intervals.

Returns:

Transmitted frequency, in Hz.

Return type:

float

property end_times

read-only

End times of the piecewise linear frequency intervals.

Type:

numpy.ndarray

property ramp_rates

read-only

Ramp rates of the piecewise linear frequency intervals, used to interpolate the frequency between the start and end times.

Type:

numpy.ndarray

property start_frequencies

read-only

Frequencies of the piecewise linear frequency interval at the start epoch.

Type:

numpy.ndarray

property start_times

read-only

Start times of the piecewise linear frequency intervals.

Type:

numpy.ndarray

class PointingAnglesCalculator

Bases: pybind11_object

Calculator for ground station elevation and azimuth in a local East-North-Up frame.

The topocentric x, y and z axes point East, North and Up, respectively, as defined by rotation_matrix_body_fixed_to_topocentric. The input inertial orientation is the base frame of the host body’s rotation model (inertial_frame_name), typically J2000 or ECLIPJ2000. The host body’s rotation maps that orientation to its body-fixed frame before the topocentric transformation.

calculate_azimuth_angle(self: tudatpy.kernel.dynamics.environment.PointingAnglesCalculator, inertial_vector_to_target: numpy.ndarray[numpy.float64[3, 1]], time: float) → float

Calculate the azimuth angle of a target object.

Parameters:
  • inertial_vector_to_target (numpy.ndarray) – Vector from ground station to target in inertial frame

  • time (float) – Epoch in seconds since J2000 (TDB) at which to calculate the angle.

Returns:

Azimuth angle in radians

Return type:

float

calculate_elevation_angle(self: tudatpy.kernel.dynamics.environment.PointingAnglesCalculator, inertial_vector_to_target: numpy.ndarray[numpy.float64[3, 1]], time: float) → float

Calculate the elevation angle of a target object.

Parameters:
  • inertial_vector_to_target (numpy.ndarray) – Vector from ground station to target in inertial frame

  • time (float) – Epoch in seconds since J2000 (TDB) at which to calculate the angle.

Returns:

Elevation angle in radians

Return type:

float

convert_inertial_vector_to_topocentric(self: tudatpy.kernel.dynamics.environment.PointingAnglesCalculator, inertial_vector: numpy.ndarray[numpy.float64[3, 1]], time: float) → numpy.ndarray[numpy.float64[3, 1]]

Convert a vector from the host body’s inertial orientation to the station East-North-Up frame.

See PointingAnglesCalculator for both frame definitions and rotation_matrix_body_fixed_to_topocentric for the station axes.

Parameters:
  • inertial_vector (numpy.ndarray[numpy.float64[3, 1]]) – Vector in the base orientation of the host body’s rotation model.

  • time (float) – Transformation epoch, in seconds since J2000 (TDB).

Returns:

Vector in the station East-North-Up frame, with its magnitude unchanged.

Return type:

numpy.ndarray[numpy.float64[3, 1]]

class GroundStation

Bases: pybind11_object

Object used to define and store properties of a ground station.

Object (typically stored inside a Body object) used to define and store properties of a ground station, typically used in modelling tracking observations to/from a ground station.

has_frequency_calculator(self: tudatpy.kernel.dynamics.environment.GroundStation) → bool

Check if the ground station has a frequency calculator.

Returns:

True if the ground station has a frequency calculator, False otherwise.

Return type:

bool

set_station_meteo_data(self: tudatpy.kernel.dynamics.environment.GroundStation, meteo_data: tudatpy.kernel.dynamics.environment.StationMeteoData) → None

Assign a meteorological data model to the ground station.

Parameters:

meteo_data (StationMeteoData) – Model supplying the meteorological quantities used for atmospheric tracking observation corrections.

set_timing_system(self: tudatpy.kernel.dynamics.environment.GroundStation, timing_system: tudatpy.kernel.dynamics.environment.TimingSystem) → None

Assign a timing system to the ground station.

Parameters:

timing_system (TimingSystem) – Timing system defining the station clock errors.

set_transmitting_frequency_calculator(self: tudatpy.kernel.dynamics.environment.GroundStation, transmitting_frequency_calculator: tudatpy.kernel.dynamics.environment.TransmittingFrequencyCalculator) → None

Set the transmitting frequency calculator for the ground station.

Note

This will override any previously set transmitting frequency calculator. To check if a frequency calculator is set, use the has_frequency_calculator() method. To merge multiple piecewise linear frequency interpolators, use the add_frequency_interpolator() function.

Parameters:

transmitting_frequency_calculator (TransmittingFrequencyCalculator) – The transmitting frequency calculator to set.

property pointing_angles_calculator

read-only

Object that performs computations of the azimuth and elevation of an arbitrary target as observed by the ground station

Type:

PointingAnglesCalculator

property pressure_function

read-only

Function that provides the local pressure at the ground station (typically use for media corrections) as a function of time

Type:
type:

callable[[float], float]

property relative_humidity_function

read-only

Function that provides the local relative humidity at the ground station (typically use for media corrections) as a function of time

Type:
type:

callable[[float], float]

property station_state

read-only

Object that performs computations of the current (body-fixed) position and frame conversions of the ground station.

Type:

GroundStationState

property temperature_function

read-only

Function that provides the local temperature at the ground station (typically use for media corrections) as a function of time

Type:
type:

callable[[float], float]

property transmitting_frequency_calculator

Object that provides the transmission frequency as a function of time for (radio) tracking stations. This attribute is typically set automatically when loading tracking data files (e.g. ODF, IFMS, TNF, etc.)

Type:

TransmittingFrequencyCalculator

class GroundStationState

Bases: pybind11_object

Object that performs computations of the current (body-fixed) position and frame conversions of the ground station.

Object that performs computations of the current (body-fixed) position and frame conversions of the ground station. In the simplest situation, only a Cartesian position is provided, which is then assumed constant. If time variations (for instance due to tides or plate motion) are present, their impact on station position is computed in this object.

get_cartesian_position(self: tudatpy.kernel.dynamics.environment.GroundStationState, current_time: float, target_frame_origin: str = '') → numpy.ndarray[numpy.float64[3, 1]]

This function computes the position of the station as a function of time.

This function computes the position of the station as a function of time, in a frame with body-fixed orientation. Some time-variations of the station position depend on the origin of the frame in which the computation is to be used. For instance, relativistic correction to the Earth-fixed position is different in a geocentric or barycentric frame. However, the output of this function is always given in the body-fixed, body-centered frame.

Parameters:
  • current_time (float) – Epoch in seconds since J2000 (TDB) at which the position is to be computed.

  • target_frame_origin (str, default = "") – Identifier for the frame origin w.r.t. which the computed position is to be used.

Returns:

Cartesian position of the station at the current epoch, in a body-centered, body-fixed frame

Return type:

numpy.ndarray

get_cartesian_state(self: tudatpy.kernel.dynamics.environment.GroundStationState, current_time: float, target_frame_origin: str = '') → numpy.ndarray[numpy.float64[6, 1]]
property cartesian_position_at_reference_epoch

read-only

Cartesian position of the ground station, at the reference epoch, in a body-fixed, body-centered frame.

Type:

numpy.ndarray[numpy.float64[3, 1]]

property geodetic_position_at_reference_epoch

read-only

Geodetic position of the ground station (altitude w.r.t. body shape model, geodetic latitude, longitude), at the reference epoch, in a body-fixed, body-centered frame.

Type:

numpy.ndarray[numpy.float64[3, 1]]

property rotation_matrix_body_fixed_to_topocentric

read-only

Rotation matrix from the body-fixed frame (of the station’s central body) to the topocentric frame of the ground station. The body-fixed frame is defined by the rotation model of the body object (rotation_model). The axes of the topocentric frame are defined such that the x-axis is in East direction, the z-direction is upwards, perpendicular to the body’s surface sphere (with properties defined by the central body’s shape model shape_model). The y-axis completes the frame, and is in northern direction. For time-varying ground station positions, this function uses the station position at reference epoch for the computation of the axes.

Type:

numpy.ndarray[numpy.float64[3, 3]]

property spherical_position_at_reference_epoch

read-only

Spherical position of the ground station (distance w.r.t. body center, latitude, longitude), at the reference epoch, in a body-fixed, body-centered frame.

Type:

numpy.ndarray[numpy.float64[3, 1]]

class FlightConditions

Bases: pybind11_object

Object that calculates various state-derived quantities typically relevant for flight dynamics.

Object that calculates various state-derived quantities typically relevant for flight dynamics, such as latitude, longitude, altitude, etc. It also contains an AerodynamicAngleCalculator that computes derived angles (flight path, heading angle, etc.). This object is limited to non-atmospheric flight. For flight through Body objects endowed with an atmosphere model, the derived class AtmosphericFlightConditions is used. This object is stored inside a Body object, and represents the flight conditions of a single body w.r.t. a single central body.

update_conditions(self: tudatpy.kernel.dynamics.environment.FlightConditions, current_time: float) → None

Update the flight conditions at the requested time.

The flight conditions are evaluated from the current body states and environment models. This function updates the stored quantities exposed by the flight conditions object; it does not propagate the body states.

Parameters:

current_time (float) – Epoch at which the flight conditions are evaluated, in seconds since J2000.

property aerodynamic_angle_calculator

read-only

The object that is responsible for computing various relevant flight dynamics angles and frame rotations.

Type:

AerodynamicAngleCalculator

property altitude

read-only

The current time, at which this object was last updated

Type:

float

property body_centered_body_fixed_state

read-only

Cartesian translational state, expressed in a frame centered at, and fixed to, the central body. Note that, due to the rotation of the central body, the norm of the body-fixed, body-centered, velocity differs from the norm of the inertial body-centered velocity.

Type:

numpy.ndarray

property geodetic_latitude

read-only

The body-fixed geographic latitude of the body w.r.t. its central body.

Type:

float

property latitude

read-only

The body-fixed geographic latitude of the body w.r.t. its central body.

Type:

float

property longitude

read-only

The body-fixed longitude of the body w.r.t. its central body.

Type:

float

property time

read-only

The current time, at which this object was last updated

Type:

float

class AtmosphericFlightConditions

Bases: FlightConditions

Object that calculates various state-derived quantities typically relevant for flight dynamics, for flight in an atmosphere.

Object that calculates various state-derived quantities typically relevant for flight dynamics, for flight in an atmosphere, such as latitude, longitude, altitude, density, Mach number etc. It also contains an AerodynamicAngleCalculator that computes derived angles (flight path, heading angle, etc.). This object is derived from FlightConditions, which performs computations for non-atmospheric flight only. This object is stored inside a Body object, and represents the flight conditions of a single body w.r.t. a single central body.

property aero_coefficient_independent_variables

read-only

List of current values of independent variables of aerodynamic coefficients. This list is only defined if the body has an AerodynamicCoefficientInterface that has dependencies on environmental variables (e.g. Mach number, angle of attack, etc.).

Type:

numpy.ndarray

property aerodynamic_coefficient_interface

read-only

Object extracted from the same Body object as this AtmosphericFlightConditions object, which defines the aerodynamic coefficients.

Type:

AerodynamicCoefficientInterface

property airspeed

read-only

The airspeed of the body w.r.t. the atmosphere.

Type:

float

property airspeed_velocity

read-only

The velocity vector of the body w.r.t. the freestream atmosphere (e.g. vectorial counterpart of airspeed).

Type:

numpy.ndarray

property control_surface_aero_coefficient_independent_variables

read-only

List of lists current values of independent variables of aerodynamic coefficients for control surfaces. The outer list defines the control surface, the inner list the values of the independent variables. This list is only defined if the body has an AerodynamicCoefficientInterface with control surfaces that have dependencies on environmental variables (e.g. Mach number, angle of attack, etc.).

Type:

numpy.ndarray

property density

read-only

The freestream atmospheric density at the body’s current location.

Type:

float

property dynamic_pressure

read-only

The freestream atmospheric dynamic pressure at the body’s current location.

Type:

float

property mach_number

read-only

The freestream Mach number of the body.

Type:

float

property pressure

read-only

The freestream atmospheric static pressure at the body’s current location.

Type:

float

property speed_of_sound

read-only

The freestream atmospheric speed of sound at the body’s current location.

Type:

float

property temperature

read-only

The freestream atmospheric temperature at the body’s current location.

Type:

float

class AerodynamicAngleCalculator

Bases: pybind11_object

Object to calculate (aerodynamic) orientation angles, and frame transformations, from current vehicle state.

Object to calculate (aerodynamic) orientation angles (list given by the AerodynamicsReferenceFrameAngles enum) and transformations between frames (list given by the AerodynamicsReferenceFrames enum) from current vehicle state.

get_angle(self: tudatpy.kernel.dynamics.environment.AerodynamicAngleCalculator, angle_type: tudatpy.kernel.dynamics.environment_setup.aerodynamic_coefficients.AerodynamicsReferenceFrameAngles) → float

Function to get a single orientation angle

Function to get a single orientation angle. This function is meant to be used only during a numerical propagation, in particular for the definition of a custom (e.g. guidance) model.

Parameters:

original_frame (AerodynamicsReferenceFrameAngles) – The identifier for the angle that is to be returned

Returns:

Value of requested angle

Return type:

double

get_rotation_matrix_between_frames(self: tudatpy.kernel.dynamics.environment.AerodynamicAngleCalculator, original_frame: tudatpy.kernel.dynamics.environment_setup.aerodynamic_coefficients.AerodynamicsReferenceFrames, target_frame: tudatpy.kernel.dynamics.environment_setup.aerodynamic_coefficients.AerodynamicsReferenceFrames) → numpy.ndarray[numpy.float64[3, 3]]

Function to get the rotation matrix between two frames.

Function to get the rotation matrix between two frames. This function is meant to be used only during a numerical propagation, in particular for the definition of a custom (e.g. guidance) model.

Parameters:
Returns:

Rotation matrix \(\mathbf{R}^{B/A}\) from frame \(A\) to frame B

Return type:

numpy.ndarray

class VehicleSystems

Bases: pybind11_object

Object used to store physical (hardware) properties of a vehicle.

get_camera(self: tudatpy.kernel.dynamics.environment.VehicleSystems, camera_name: str) → tudatpy.kernel.dynamics.environment.Camera

This function extracts a camera object from the body.

This function extracts a camera object, for a camera of a given name, from the body. If no camera of this name exists, an exception is thrown.

Parameters:

camera_name (str) – Name of the camera that is to be retrieved.

Returns:

Camera object of the camera of requested name

Return type:

Camera

get_control_surface_deflection(self: tudatpy.kernel.dynamics.environment.VehicleSystems, control_surface_id: str) → float

Function to retrieve the current deflection of an aerodynamic control surface.

Function to retrieve the current deflection of an aerodynamic control surface, identified by its name. To extract the control surface deflection, the control surface has to exist. A control surface is created whenever control surfaces are defined in a body’s aerodynamic coefficient interface.

Parameters:

control_surface_id (str) – The identified (name) of the given control surface

Returns:

Current deflection (in radians) that the control surface

Return type:

float

get_engine_model(self: tudatpy.kernel.dynamics.environment.VehicleSystems, engine_name: str) → tudatpy.kernel.dynamics.environment.EngineModel

Function to retrieve an engine model from the vehicle

Parameters:

engine_name (str) – The identifier for the engine model that is to be retrieved

Returns:

Model for the engine that is requested

Return type:

EngineModel

is_transponder_delay_defined(self: tudatpy.kernel.dynamics.environment.VehicleSystems) → bool

Check whether a transponder retransmission delay has been defined for the vehicle.

Returns:

True if a transponder delay is defined.

Return type:

bool

set_control_surface_deflection(self: tudatpy.kernel.dynamics.environment.VehicleSystems, control_surface_id: str, deflection_angle: float) → None

Function to set the current deflection of an aerodynamic control surface.

Function to set the current deflection of an aerodynamic control surface, identified by its name. To set the control surface deflection, the control surface has to exist. A control surface is created whenever control surfaces are defined in a body’s aerodynamic coefficient interface.

Parameters:
  • control_surface_id (str) – The identified (name) of the given control surface

  • deflection_angle (float) – The deflection (in radians) that the control surface is to be set to. This will typically influence the aerodynamic coefficients of the vehicle

set_default_transponder_turnaround_ratio_function(self: tudatpy.kernel.dynamics.environment.VehicleSystems) → None

Retrieve standard, DSN turnaround ratios based on the frequency bands of the link

set_reference_point(*args, **kwargs)

Overloaded function.

Overload 1: set_reference_point(self: tudatpy.kernel.dynamics.environment.VehicleSystems, reference_point: str, location: numpy.ndarray[numpy.float64[3, 1]], frame_origin: str = '', frame_orientation: str = '') -> None

Set a fixed body-frame location for an antenna or instrument on the vehicle.

The location is stored as a constant ephemeris with zero body-fixed velocity. An existing entry with the same name is replaced.

Parameters:
  • reference_point (str) – Identifier of the antenna or instrument location.

  • location (numpy.ndarray[numpy.float64[3, 1]]) – Cartesian location in the body-fixed frame, in m.

  • frame_origin (str, default="") – Frame origin label stored in the constant ephemeris.

  • frame_orientation (str, default="") – Frame orientation label stored in the constant ephemeris.

Overload 2: set_reference_point(self: tudatpy.kernel.dynamics.environment.VehicleSystems, reference_point: str, ephemeris: tudatpy.kernel.dynamics.environment.Ephemeris) -> None

Set a body-fixed ephemeris for an antenna or instrument on the vehicle.

The ephemeris defines the position and velocity of the named location relative to the vehicle. An existing entry with the same name is replaced.

Parameters:
  • reference_point (str) – Identifier of the antenna or instrument location.

  • ephemeris (Ephemeris) – Ephemeris returning the body-fixed position in m and velocity in m/s of the specified location.

set_timing_system(self: tudatpy.kernel.dynamics.environment.VehicleSystems, timing_system: tudatpy.kernel.dynamics.environment.TimingSystem) → None

Assign a timing system to the vehicle.

Parameters:

timing_system (TimingSystem) – Timing system defining the vehicle clock errors.

set_transmitted_frequency_calculator(self: tudatpy.kernel.dynamics.environment.VehicleSystems, transmitted_frequency_calculator: tudatpy.kernel.dynamics.environment.TransmittingFrequencyCalculator) → None

Set the transmitted frequency calculator for the vehicle. This function assigns a frequency calculator to the vehicle, which can be used to determine the frequency transmitted by an onboard station or system. :param transmitted_frequency_calculator: The frequency calculator object to be associated with the vehicle. :type transmitted_frequency_calculator: StationFrequencyInterpolator

set_transponder_turnaround_ratio(self: tudatpy.kernel.dynamics.environment.VehicleSystems, transponder_ratio_per_uplink_and_downlink_frequency_band: dict[tuple[tudatpy.kernel.estimation.observations_setup.ancillary_settings.FrequencyBands, tudatpy.kernel.estimation.observations_setup.ancillary_settings.FrequencyBands], float]) → None

Set the transponder turnaround ratios for the supported frequency band combinations.

The turnaround ratio is the transmitted downlink frequency divided by the received uplink frequency.

Parameters:

transponder_ratio_per_uplink_and_downlink_frequency_band (dict[tuple[tudatpy.estimation.observations_setup.ancillary_settings.FrequencyBands, tudatpy.estimation.observations_setup.ancillary_settings.FrequencyBands], float]) – Dictionary mapping an uplink and downlink frequency band pair to its turnaround ratio.

property camera_dict

read-only

Dictionary of all cameras that exist in the body, with dictionary key being the name of the camera, and the camera object the value of the dictionary.

Type:

dict[str, Camera]

property transponder_delay

Transponder retransmission delay for the vehicle, in seconds.

Type:

float

class EngineModel

Bases: pybind11_object

Object defining the thrust produced by an engine.

Object containing the thrust magnitude calculator and the thrust direction associated with a single engine. Engines are stored in the body’s VehicleSystems and can be used to define thrust accelerations.

property thrust_magnitude_calculator

read-only

Thrust magnitude calculator associated with this engine. This object supplies the engine thrust magnitude and mass flow rate.

Type:

tudatpy.dynamics.propagation.ThrustMagnitudeWrapper

class Body

Bases: pybind11_object

Object that stores the environment properties and current state of a single body.

Object that stores the environment properties and current state of a single celestial body (natural or artificial). Each separate environment model (gravity field, ephemeris, etc.) is stored as a member object in this class. During each time step, the Body gets updated to the current time/propagated state, and the current properties, in as much as they are time-dependent, can be extracted from this object

get_ground_station(self: tudatpy.kernel.dynamics.environment.Body, station_name: str) → tudatpy.kernel.dynamics.environment.GroundStation

This function extracts a ground station object from the body.

This function extracts a ground station object, for a station of a given name, from the body. If no station of this name exists, an exception is thrown

Parameters:

station_name (str) – Name of the ground station that is to be retrieved.

Returns:

Ground station object of the station of requested name

Return type:

GroundStation

get_ionosphere_model(self: tudatpy.kernel.dynamics.environment.Body) → tudatpy.kernel.dynamics.environment.IonosphereModel

Retrieve the ionosphere model assigned to this body.

Returns:

Ionosphere model associated with the body, or None if no model has been assigned.

Return type:

IonosphereModel or None

state_in_base_frame_from_ephemeris(self: tudatpy.kernel.dynamics.environment.Body, time: tudatpy.kernel.astro.time_representation.Time) → numpy.ndarray[numpy.float64[6, 1]]

This function returns the body’s state, as computed from its ephemeris model (extracted from ephemeris) at the current time, and (if needed) translates this state to the global frame origin. For the case where the origin of the body’s ephemeris (extracted from frame_origin) is equal to the global frame origin of the system of bodies it is in (extracted from SystemOfBodies.global_frame_origin), this function is equal to Body.ephemeris.cartesian_state( time ). Where the global frame origin and ephemeris origin is not equal, other bodies’ ephemerides are queried as needed to provide this body’s state w.r.t. the global frame origin

Parameters:

time (astro.time_representation.Time) – Time object representing seconds since J2000 (TDB) at which the state is to be computed

Returns:

Cartesian state (position and velocity) of the body w.r.t. the global frame origin at the requested time.

Return type:

numpy.ndarray

property aerodynamic_coefficient_interface

Object defining the aerodynamic coefficients of the body (force-only, or force and moment) as a function of any number of independent variables. Depending on the selected type of model, the type of this attribute is of type AerodynamicCoefficientInterface, or a derived class thereof.

Type:

AerodynamicCoefficientInterface

property atmosphere_model

Object defining the atmosphere model of this body, used to calculate density, temperature, etc. at a given state/time. Depending on the selected type of model, the type of this attribute is of type AtmosphereModel, or a derived class thereof.

Type:

AtmosphereModel

property body_fixed_angular_velocity

read-only

Angular velocity vector of the body, expressed in body-fixed frame (see inertial_to_body_fixed_frame).

Type:

numpy.ndarray

property body_fixed_to_inertial_frame

read-only

The rotation from this Body’s body-fixed frame to inertial frame (see inertial_to_body_fixed_frame).

Type:

numpy.ndarray

property body_fixed_to_inertial_frame_derivative

read-only

Time derivative of rotation matrix from this Body’s body-fixed frame to inertial frame (see inertial_to_body_fixed_frame).

Type:

numpy.ndarray

property custom_state

read-only

The custom state of the Body, as set during the current step of the numerical propagation. This property is only valid during propagation, and only when exactly one custom state is propagated for this body.

Type:

numpy.ndarray

property ephemeris

Object defining the ephemeris model of this body, used to calculate its current state as a function of time. Depending on the selected type of model, the type of this attribute is of type Ephemeris, or a derived class thereof.

Type:

Ephemeris

property flight_conditions

Object used to calculated and store the current flight conditions of a vehicle (altitude, latitude, longitude, flight-path angle, etc.) w.r.t. a central body. In case the central body contains an atmosphere, this object also stores current local density, Mach number, etc. This object is typically used for aerodynamic accelerations, guidance models or other central-body-related custom models.

Type:

FlightConditions

property gravitational_parameter

read-only

Attribute of convenience, equivalent to .gravity_field_model.gravitational_parameter

Type:

float

property gravity_field_model

Object defining the a gravity field model of this body, used to define the exterior gravitational potential, and its gradient(s). Depending on the selected type of model, the type of this attribute is of type GravityFieldModel, or a derived class thereof.

Type:

GravityFieldModel

property ground_station_list

read-only

Dictionary of all ground stations that exist in the body, with dictionary key being the name of the station, and the ground station object the key of the dictionary.

Type:

dict[str,GroundStation]

property inertia_tensor

The current inertia tensor \(\mathbf{I}\) of the vehicle, as used in the calculation of (for instance) the response to torques. This attribute is a shorthand for accessing the inertia tensor as computed/stored in the rigid_body_properties attribute. For certain types of rigid-body properties, this attribute cannot be used to (re)set the current mass.

Unlike the attributes containing the state, orientation, angular velocity of the Body, this attribute may be used to retrieve the state during the propagation and to define the mass of a vehicle.

Type:

numpy.ndarray

property inertial_angular_velocity

read-only

Angular velocity vector of the body, expressed in inertial frame (see inertial_to_body_fixed_frame).

Type:

numpy.ndarray

property inertial_to_body_fixed_frame

read-only

The rotation from inertial frame (with global frame orientation) to this Body’s body-fixed frame. The rotation is always returned here as a rotation matrix. If the body’s rotational state is numerically propagated, this property gets extracted from the propagated state vector. If it is not propagated, the state is extracted from this body’s rotational ephemeris.

Note

This function is only valid during the numerical propagation if any aspects of the dynamics or dependent variables require the body’s rotational state.

Type:

numpy.ndarray

property inertial_to_body_fixed_frame_derivative

read-only

Time derivative of rotation matrix from inertial frame to this Body’s body-fixed frame (see inertial_to_body_fixed_frame).

Type:

numpy.ndarray

property mass

The current mass \(m\) of the vehicle, as used in the calculation of non-conservative acceleration. This attribute is a shorthand for accessing the mass as computed/stored in the Body.rigid_body_properties attribute. For certain types of rigid-body properties, this attribute cannot be used to (re)set the current mass. If the body has no Body.rigid_body_properties, and this function is used to set a mass, a new object is automatically created, with settings analogous to the the constant_rigid_body_properties() setting.

Unlike the attributes containing the state, orientation, angular velocity of the Body, this attribute may be used to retrieve the state during the propagation and to define the mass of a vehicle.

Type:

float

property position

read-only

The translational position of the Body, as set during the current step of the numerical propagation (see state).

Type:

numpy.ndarray

property radiation_pressure_source_model

Object that defines the radiation that a body emits, primarily for the calculation of radiation pressure acceleration. It computes the irradiance at a given target location.

This attribute is a list of RadiationSourceModel, or a derived class thereof.

Type:

RadiationSourceModel

property radiation_pressure_target_models

List of radiation pressure target models that exist in the body. These objects define how incoming radiation interacts with the body to produce a force/torque. A single body may be endowed with multiple target models, which may be selected for an acceleration depending on the application. For instance, a body may have a cannonball target model and a panelled target model available, and use one for solar radiation pressure acceleration, and the other for planetary radiation pressure acceleration (see radiation_pressure()). This attribute is a list of RadiationPressureTargetModel, or a derived class thereof.

Type:

list[RadiationPressureTargetModel]

property rigid_body_properties

Object defining the mass, center of mass and inertia tensor of the body. This object is distinct from the gravity field of a body (defined by the Body.gravity_field object). A body endowed with this property does not automatically have a gravity field created for it. However, the whenever a body is endowed with a gravity field, a rigid body properties attribute is created to be consistent with this gravity field (e.g. for a spherical harmonic gravity field the mass, center of mass and inertia tensor are created from the gravitational parameter, degree-1 coefficients, and degree-2 coefficients plus mean moment of inertia, respectively).

Type:

RigidBodyProperties

property rotation_model

Object defining the orientation of the body, used to calculate the rotation to/from a body-fixed frame (and its derivate). Depending on the selected type of model, the type of this attribute is of type RotationalEphemeris, or a derived class thereof.

Type:

RotationalEphemeris

property shape_model

Object defining the a shape model of this body, used to define the exterior shape of the body, for instance for the calculation of vehicle’s altitude. Depending on the selected type of model, the type of this attribute is of type BodyShapeModel, or a derived class thereof.

Type:

BodyShapeModel

property state

read-only

The translational state of the Body, as set during the current step of the numerical propagation. The translational state stored here is always in Cartesian elements, w.r.t. the global frame origin, with axes along the global frame orientation. If the body’s translational state is numerically propagated, this property gets extracted from the propagated state vector. If it is not propagated, the state is extracted from this body’s ephemeris. In both cases, any required state transformations are automatically applied. Note that this function is only valid during the numerical propagation if any aspects of the dynamics or dependent variables require the body’s state.

type:

numpy.ndarray

property system_models

Object used to store physical (hardware) properties of a vehicle, such as engines, control surfaces, etc. This object is typically created automatically whenever such a hardware model needs to be assigned to a vehicle.

Type:

VehicleSystems

property time_ephemeris

read-only

Object defining the relativistic time conversion model of this body, used to convert between barycentric coordinate time, body-centered coordinate time and proper time. Depending on the selected model, the type of this attribute is TimeEphemeris, or a derived class thereof. If no converter has been defined for this body, this attribute is None.

Type:

TimeEphemeris

property velocity

read-only

The translational velocity of the Body, as set during the current step of the numerical propagation (see state).

Type:

numpy.ndarray

class SystemOfBodies

Bases: pybind11_object

Object that contains a set of Body objects and associated frame information.

Object that contains a set of Body objects and associated frame information. This object stored the entire environment for a typical Tudat numerical simulation, and is fundamental for the overall Tudat architecture.

add_body(self: tudatpy.kernel.dynamics.environment.SystemOfBodies, body_to_add: tudatpy.kernel.dynamics.environment.Body, body_name: str, process_body: bool = 1) → None

This function adds an existing body, which the user has separately created, to the SystemOfBodies.

Parameters:
  • body_to_add (Body) – Body object that is to be added.

  • body_name (str) – Name of the Body that is to be added.

  • process_body (bool, default=True) –

    Variable that defines whether this new Body will have its global frame origin/orientation set to conform to rest of the environment.

    Warning

    Only in very rare cases should this variable be anything other than True. Users are recommended to keep this default value intact.

create_empty_body(self: tudatpy.kernel.dynamics.environment.SystemOfBodies, body_name: str, process_body: bool = 1) → None

This function creates a new empty body.

This function creates a new empty body, and adds it to the SystemOfBodies. Since the body is empty, it will not have any environment models defined. These must all be added manually by a user.

Parameters:
  • body_name (string) – Name of the Body that is to be added

  • process_body (bool, default=True) –

    Variable that defines whether this new Body will have its global frame origin/orientation set to conform to rest of the environment.

    Warning

    Only in very rare cases should this variable be anything other than True. Users are recommended to keep this default value intact.

Examples

This function is often used early on in the environment creation segment of a simulation, following the creation of a SystemOfBodies from the default settings for celestial bodies.

# Define string names for bodies to be created from default.
bodies_to_create = ["Sun", "Earth", "Moon", "Mars", "Venus"]

# Use "Earth"/"J2000" as global frame origin and orientation.
global_frame_origin = "Earth"
global_frame_orientation = "J2000"

# Create default body settings, usually from `spice`.
body_settings = environment_setup.get_default_body_settings(
    bodies_to_create,
    global_frame_origin,
    global_frame_orientation)

# Create system of selected celestial bodies
bodies = environment_setup.create_system_of_bodies(body_settings)

# Create vehicle objects.
bodies.create_empty_body("Delfi-C3")
does_body_exist(self: tudatpy.kernel.dynamics.environment.SystemOfBodies, body_name: str) → bool

Function to check if a body with a given name exists in the SystemOfBodies

Parameters:

body_name (string) – Name of the Body whose existence is to be checked

Returns:

True if the body exists in this object, false if not

Return type:

bool

get(self: tudatpy.kernel.dynamics.environment.SystemOfBodies, body_name: str) → tudatpy.kernel.dynamics.environment.Body

This function extracts a single Body object from the SystemOfBodies.

Parameters:

body_name (str) – Name of the Body that is to be retrieved.

Returns:

Body object of the requested name

Return type:

Body

global_frame_orientation(self: tudatpy.kernel.dynamics.environment.SystemOfBodies) → str

Common global frame orientation for all bodies in this SystemOfBodies, described in more detail here.

global_frame_origin(self: tudatpy.kernel.dynamics.environment.SystemOfBodies) → str

Common global frame origin for all bodies in this SystemOfBodies, described in more detail here.

list_of_bodies(self: tudatpy.kernel.dynamics.environment.SystemOfBodies) → list[str]

List of names of bodies that are stored in this SystemOfBodies

remove_body(self: tudatpy.kernel.dynamics.environment.SystemOfBodies, body_name: str) → None

This function removes an existing body from the SystemOfBodies.

Warning

This function does not necessarily delete the Body object, it only removes it from this object. If any existing models in the simulation refer to this Body, it will persist in memory.

Parameters:

body_name (str) – Name of the Body that is to be removed.

property space_time_properties

read-only

Space-time properties container used by models created from this system of bodies. This is the canonical access point for PPN parameters and the equivalence-principle LPI-violation parameter.

Type:

SpaceTimeProperties