rotation_model
#
This module contains a set of factory functions for setting up the rotation models of celestial bodies in an environment.
Functions#
|
Factory function for creating simple rotation model settings. |
|
Factory function for creating simple rotation model settings using initial orientation and rotation rates from Spice. |
|
Factory function for creating synchronous rotational ephemeris settings. |
|
Factory function for creating rotation model settings from the Spice interface. |
|
Factory function for creating high-accuracy Earth rotation model settings. |
|
Factory function for creating simple rotation model settings for target-frames with constant orientation. |
- simple(base_frame: str, target_frame: str, initial_orientation: numpy.ndarray[numpy.float64[3, 3]], initial_time: float, rotation_rate: float) tudatpy.kernel.numerical_simulation.environment_setup.rotation_model.RotationModelSettings #
Factory function for creating simple rotation model settings.
Factory function for settings object, defining a basic rotation model with constant orientation of the rotation axis and constant rotation rate about this axis. Rotation from original (inertial) to target (body-fixed) frame at some reference time
initial_time
(\(t_{0}\)) is defined by theinitial_orientation
(\(\mathbf{R}^{(B/I)}(t_{0})\)) rotation matrix. Rotation about the body-fixed z-axis is defined by therotation_rate
(\(\omega\)) float variable (in rad/s). The rotation matrix is computed from:\[\mathbf{R}^{(B/I)}(t)=\mathbf{R}_{z}(\omega(t-t_{0}))(t_{0})\mathbf{R}^{(B/I)}(t_{0})\]where \(\mathbf{R}^{(B/I)}\) denotes the rotation matrix from inertial to body-fixed frame, and \(\mathbf{R}_{z}\) denotes a rotaion matrix about the z-axis.
The matrix \(\mathbf{R}^{(B/I)}(t_{0})\) is sometimes parameterized by pole right ascension and declination (\(\alpha\) and \(\delta\)), as well as the meridian of date \(W_{0}\) with
\[\mathbf{R}^{(B/I)}(t_{0})=\mathbf{R}_{z}(W_{0})\mathbf{R}_{x}(\pi/2-\delta)\mathbf{R}_{z}(\pi/2+\alpha)\]- Parameters
base_frame (str) – Base frame of rotation model.
target_frame (str) – Target frame of rotation model.
initial_orientation (numpy.ndarray[numpy.float64[3, 3]]) – Orientation of target frame in base frame at initial time.
initial_time (float) – Initial time (reference epoch for rotation matrices).
rotation_rate (float) – Constant rotation rate [rad/s] about rotational axis.
- Returns
Instance of the
RotationModelSettings
derivedSimpleRotationModelSettings
class- Return type
SimpleRotationModelSettings
Examples
In this example, we create
RotationModelSettings
for Earth, using a simple rotation model with constant orientation of the rotation axis (body-fixed z-axis), and constant rotation rate about this axis:# Set parameters describing the rotation between the two frames initial_orientation = np.array([[1, 0, 0], [0, -1, 0], [0, 0, 1]]) initial_time = 12345 # [sec since J2000] rotation_rate = 2e-5 # [rad/s] original_frame = "J2000" target_frame = "Earth_Fixed_Simplified" # Create the rotation model settings and assign to body settings of "Earth" body_settings.get( "Earth" ).rotation_model_settings = environment_setup.rotation_model.simple( original_frame, target_frame, initial_orientation, initial_time, rotation_rate)
- simple_from_spice(base_frame: str, target_frame: str, target_frame_spice: str, initial_time: float) tudatpy.kernel.numerical_simulation.environment_setup.rotation_model.RotationModelSettings #
Factory function for creating simple rotation model settings using initial orientation and rotation rates from Spice.
Factory function for settings object, defining a
simple()
rotation model with the added functionality that the initial orientation and rotation rate are extracted from Spice, as opposed to provided manually. Note that only the initial orientation and rotation rate ( at the time defined byinitial_time
) are extracted from Spice - for the full Spice rotation model seespice()
. Also note the distinction between thetarget_frame
andtarget_frame_spice
parameters.- Parameters
base_frame (str) – Base frame of rotation model.
target_frame (str) – Target frame of rotation model - name of frame that Tudat assigns to the body-fixed frame
target_frame_spice (str) – Spice reference of target frame - name of the frame in Spice for which the initial orientation and rotation rate are extracted.
initial_time (float) – Initial time (reference epoch for rotation matrices).
- Returns
Instance of the
RotationModelSettings
derivedSimpleRotationModelSettings
class- Return type
SimpleRotationModelSettings
Notes
In order to create a
SimpleRotationModelSettings
object which describes a synchronous rotation w.r.t. somecentral_body
, we require anephemeris_settings
attribute to theBodySettings
object of thecentral_body
.Examples
In this example, we create
RotationModelSettings
for Earth, using a simple rotation model with constant orientation of the rotation axis (body-fixed z-axis), and constant rotation rate about this axis. The initial orientation and rotation rate are extracted from Spice at the time defined byinitial_time
:# set parameters for time at which initial data is extracted from spice initial_time = 12345 # set parameters for defining the rotation between frames original_frame = "J2000" target_frame = "IAU_Earth_Simplified" target_frame_spice = "IAU_Earth" # create rotation model settings and assign to body settings of "Earth" body_settings.get( "Earth" ).rotation_model_settings = environment_setup.rotation_model.simple_from_spice( original_frame, target_frame, target_frame_spice, initial_time)
- synchronous(central_body_name: str, base_frame: str, target_frame: str) tudatpy.kernel.numerical_simulation.environment_setup.rotation_model.RotationModelSettings #
Factory function for creating synchronous rotational ephemeris settings.
Factory function for settings object, defining a synchronous rotation model where rotation of a body is defined from its relative orbit w.r.t. some central body. Specifically - the body-fixed x-axis is always pointing towards the central body - the body-fixed z-axis is always perpendicular to the orbital plane (along the direction of \(\mathbf{x}\times\mathbf{v}\) ) - the body-fixed y-axis completes the right-handed reference frame
Such a model can be useful for, for instance, approximate rotation of tidally locked natural satellites or nadir-pointing spacecraft.
- Parameters
- Returns
Instance of the
RotationModelSettings
derivedSynchronousRotationModelSettings
class- Return type
SynchronousRotationModelSettings
Examples
In this example, we create
RotationModelSettings
for the martian moon Phobos, We do so by assigning a synchronous rotation model to the rotation model settings of Phobos, using in this case"ECLIPJ2000"
as the base frame, and"Phobos_Fixed"
as the target frame.# define parameters describing the synchronous rotation model central_body_name = "Mars" original_frame = "ECLIPJ2000" target_frame = "Phobos_Fixed" # create rotation model settings for target frame and assign to body settings of "Phobos" body_settings.get( "Phobos" ).rotation_model_settings = environment_setup.rotation_model.synchronous( central_body_name, original_frame, target_frame)
- spice(base_frame: str, target_frame: str) tudatpy.kernel.numerical_simulation.environment_setup.rotation_model.RotationModelSettings #
Factory function for creating rotation model settings from the Spice interface.
Factory function for settings object, defining a rotation model directly (and entirely) from Spice interface.
- Parameters
- Returns
Instance of
RotationModelSettings
class.- Return type
Examples
In this example, we create
RotationModelSettings
for Earth, using full rotation model data from Spice:# define parameters describing the rotation between frames original_frame = "J2000" target_frame = "IAU_Earth" # create rotation model settings and assign to body settings of "Earth" body_settings.get( "Earth" ).rotation_model_settings = environment_setup.rotation_model.spice( original_frame, target_frame)
- gcrs_to_itrs(precession_nutation_theory: tudatpy.kernel.numerical_simulation.environment_setup.rotation_model.IAUConventions = <IAUConventions.iau_2006: 2>, base_frame: str = 'GCRS') tudatpy.kernel.numerical_simulation.environment_setup.rotation_model.RotationModelSettings #
Factory function for creating high-accuracy Earth rotation model settings.
Factory function for settings object, defining high-accuracy Earth rotation model according to the IERS 2010 Conventions. This settings class has various options to deviate from the default settings, typical applications will use default. Note that for this model the original frame must be J2000 or GCRS (in the case of the former, the frame bias between GCRS and J2000 is automatically corrected for). The target frame (e.g. body-fixed frame) name is ITRS. The precession-nutation theory may be any member of
IAUConventions
(iau_2000a
/iau_2000b
oriau_2006
). Alternative options to modify the input (not shown here) include the EOP correction file, input time scale, short period UT1 and polar motion variations. The target frame (e.g. body-fixed frame) name is ITRS.- Parameters
precession_nutation_theory (IAUConventions, default=tba::iau_2006) – Setting theory for modelling Earth nutation.
base_frame (str, default='GCRS') – Base frame of rotation model
- Returns
Instance of the
RotationModelSettings
derivedGcrsToItrsRotationModelSettings
class- Return type
GcrsToItrsRotationModelSettings
Examples
In this example, we create
RotationModelSettings
for Earth, using a high-accuracy Earth rotation model as defined by IERS 2010 conventions:# define parameters describing the rotation between frames precession_nutation_theory = environment_setup.rotation_model.IAUConventions.iau_2006 original_frame = "J2000" # create rotation model settings and assign to body settings of "Earth" body_settings.get( "Earth" ).rotation_model_settings = environment_setup.rotation_model.gcrs_to_itrs( precession_nutation_theory, original_frame)
- constant(base_frame: str, target_frame: str, initial_orientation: numpy.ndarray[numpy.float64[3, 3]]) tudatpy.kernel.numerical_simulation.environment_setup.rotation_model.RotationModelSettings #
Factory function for creating simple rotation model settings for target-frames with constant orientation.
Factory function for settings object, defining simple rotation model setting objects with constant rotation matrix. These model settings are for target frames which do not have a rotational rate in the base frame and are fully defined by their initial orientation.
- Parameters
base_frame (str) – Base frame of rotation model.
target_frame (str) – Target frame of rotation model.
initial_orientation (numpy.ndarray[numpy.float64[3, 3]]) – Rotation matrix from inertial to body-fixed (base to target) frame at initial time (constant throughout).
- Returns
Instance of the
RotationModelSettings
derivedSimpleRotationModelSettings
class.- Return type
SimpleRotationModelSettings
Examples
In this example, we create
RotationModelSettings
for Earth, using a constant rotation matrix between Earth-fixed and inertial frame:# define parameters describing the constant orientation between frames original_frame = "ECLIPJ2000" target_frame = "Earth_fixed" constant_orientation = np.array([[1, 0, 0], [0, -1, 0], [0, 0, 1]]) # create rotation model settings and assign to body settings of "Earth" body_settings.get( "Earth" ).rotation_model_settings = environment_setup.rotation_model.constant( original_frame, target_frame, constant_orientation )
Enumerations#
Enumeration of rotation model types. |
|
Enumeration of IAU conventions for Earth rotation. |
- class RotationModelType#
Enumeration of rotation model types.
Enumeration of rotation model types supported by tudat.
Members:
simple_rotational_model : No documentation found.
spice_rotation_model :
gcrs_to_itrs_rotation_model :
synchronous_rotation_model :
planetary_rotation_model :
- property name#
Classes#
Base class for providing settings for automatic rotation model creation. |
- class RotationModelSettings#
Base class for providing settings for automatic rotation model creation.
This class is a functional base class for settings of rotation models that require no information in addition to their type. Basic rotation model has constant orientation of the rotation axis (body-fixed z-axis) and constant rotation rate about this axis. Rotation models requiring additional information must be created using the factory functions which create the specific object derived from this base class.
- property rotation_type#
read-only
Type of rotation model that is to be created.
- Type