Module: dynamicObject

Object that is to be used by an integrator. This holds the equations of motion, integrate state, energy and momentum calculations. Module: dynamicObject is what puts all of the pieces together for your system


class DynamicObject : public SysModel
#include <dynamicObject.h>

A DynamicObject is a Basilisk model with states that must be integrated

Public Functions

DynamicObject() = default
DynamicObject(const DynamicObject&) = delete
DynamicObject &operator=(const DynamicObject&) = delete
DynamicObject(DynamicObject&&) = delete
DynamicObject &operator=(DynamicObject&&) = delete
virtual ~DynamicObject() = default
virtual void UpdateState(uint64_t callTime) = 0

Hooks the dyn-object into Basilisk architecture

virtual void equationsOfMotion(double t, double timeStep) = 0

Computes F = Xdot(X,t)

virtual void preIntegration(uint64_t callTimeNanos) = 0

Performs pre-integration steps

virtual void postIntegration(uint64_t callTimeNanos) = 0

Performs post-integration steps

inline virtual void initializeDynamics()

Initializes the dynamics and variables

inline virtual void computeEnergyMomentum(double t)

Computes energy and momentum of the system

void integrateState(uint64_t t)

Prepares the dynamic object to be integrated, integrates the states forward in time, and finally performs the post-integration steps.

This is only done if the DynamicObject integration is not sync’d to another DynamicObject

void setIntegrator(StateVecIntegrator *newIntegrator)

Sets a new integrator in use

void syncDynamicsIntegration(DynamicObject *dynPtr)

Connects the integration of a DynamicObject to the integration of this DynamicObject.

Public Members

DynParamManager dynManager

Dynamics parameter manager for all effectors

StateVecIntegrator *integrator

Integrator used to propagate state forward

BSKLogger bskLogger

BSK Logging

bool isDynamicsSynced = false

flag indicating that another spacecraft object is controlling the integration

double timeStep = 0.0

[s] integration time step

double timeBefore = 0.0

[s] prior time value

uint64_t timeBeforeNanos = 0

[ns] prior time value