Built-in gravity model for an ideal planet.Use this with the dsim_rigid_body model to simulation an object in orbit about a planet. More...
Public Member Functions | |
dsim_ideal_gravity (dsim_model_setup *setup) | |
void | initialize_data () |
void | initialization_complete () |
void | rhs (double t, double jd) |
Built-in gravity model for an ideal planet.
Use this with the dsim_rigid_body model to simulation an object in orbit about a planet.
Point mass gravity model.
dsim_ideal_gravity::dsim_ideal_gravity | ( | dsim_model_setup * | setup ) |
Default constructor; no actions are necessary here.
setup | The dsim_model_setup object |
void dsim_ideal_gravity::initialization_complete | ( | ) | [virtual] |
Perform final initializations. In this case, request the parent mass and position and mark these variables as cointegrated.
Reimplemented from dsim_model.
void dsim_ideal_gravity::initialize_data | ( | ) | [virtual] |
Create the single parameter for the model, mu, and configure the timestep.
Reimplemented from dsim_model.
void dsim_ideal_gravity::rhs | ( | double | t, |
double | jd | ||
) | [virtual] |
The dynamics for a central body force, shown in the formula below. This model has no states itself, but it applies a force to the parent object using a "apply_force" message. The model will flag an error if the position magnitude is zero.
t | Elapsed time, unused |
jd | Julian date, unused |
Reimplemented from dsim_model.