Use Cases#
The use cases of c4dynamics span different systems: a quadcopter, a missile, a ballistic object, a car, and a laboratory helicopter. They run different algorithms: PID and model predictive control, Kalman filters, proportional navigation, and neural network control. Yet they are all built the same way.
One representation
Every system is described in state space. A state vector \(X\) holds the variables that define the system at a given moment, the equations of motion describe how it evolves, \(\dot{X} = f(X, u)\), and the sensors measure a function of it, \(z = h(X)\).
In c4dynamics, the state vector is an object.
A state object, or one of its library forms
(datapoint,
rigidbody,
pixelpoint),
has the same interface for any system:
X to get and set the state vector,
store and
data to record and retrieve its history,
and plot to view it.
One loop
Each use case follows the same loop:
State: define the state object of the system.
Dynamics: propagate the state by the equations of motion.
Algorithm: estimate the state from the measurements, and compute the control command.
Action: apply the command, store the state, and repeat.
The structure repeats. Only the physics changes.
The switch
Because the interface stays the same, moving from one system to another means replacing the physics: the state variables and the equations of motion. The algorithm, the simulation loop, the storage, and the plots stay intact.
The use cases show this in both directions.
The same quadcopter model is flown by a cascade PID, estimated by an extended Kalman filter,
and controlled by the ArduPilot flight controller.
The same ekf object estimates the full state of a quadcopter
and the ballistic coefficient of a falling object,
and its linear sibling, kalman,
tracks a car in a video.
Pick a use case below, and look for what stays the same.
Cascade PID
Quadcopter figure-8 trajectory tracking
EKF State Estimation
Quadcopter GPS/IMU/MAG sensor fusion
ArduPilot Simulation
Quadcopter figure-8 under ArduCopter control
6-DOF
Proportional navigation guidance
Extended Kalman Filter
Ballistic coefficient estimation
Model Predictive Control
Vehicle steering
YOLO3 Detector & Kalman Filter
Car tracker
YOLO11 Detector & Kalman Filter
Car tracker, modern detector refresh
Neural Network Based Controller
Helicopter learning control