Spacecraft Models Package 2.0
Spacecraft Models for DSim
|
Rigid body dynamical model applying both force and torque to the spacecraft. More...
#include <rigid_body.h>
Inherits dsim_model.
Public Member Functions | |
void | initialize_data () |
Initialize outlets and output variables. | |
void | initialization_complete () |
Finish initialization. | |
void | initialize_timestep () |
Computation done prior to numerical integration. | |
void | complete_timestep () |
Computation done after numerical integration. | |
void | rhs (double t, double jd) |
Computation done during numerical integration. More... | |
dsim_value | handle_message (const std::string &sender_path, const std::string &message_name, const dsim_value &argument) |
Handle force and torque messages. More... | |
Rigid body dynamical model applying both force and torque to the spacecraft.
Integrates the position, velocity, quaternion, and body rates. Allows the mass of the spacecraft to change. Children can use the apply_torque, apply_force, or mass_changed messages. Ignores any effect of or changes in center of mass. Does not add up or compute changes in inertia. Assumes all torques are about the center of mass.
void rigid_body::rhs | ( | double | t, |
double | jd | ||
) |
Computation done during numerical integration.
Dynamics and kinematics.
References acceleration_dsim, angular_acceleration_dsim, bodyRate_dsim, force, inertia, invInertia, m_to_km, mass, mass_dsim, position_dsim, quaternion_dsim, torque, and velocity_dsim.
dsim_value rigid_body::handle_message | ( | const std::string & | sender_path, |
const std::string & | message_name, | ||
const dsim_value & | argument | ||
) |