This repository contains a naive implementation of Model Predictive Control (MPC) that uses linearized dynamic models for path prediction and control.
This is a simplified MPC approach that:
- Linearizes the dynamic model around the current state
- Uses this linearized model to predict the system's behavior over the next N time steps
- Optimizes control inputs without a reference trajectory, instead using a target point in the loss function
Key characteristics:
- No reference trajectory is used - optimization targets a single point
- The linearized dynamics are computed once at each time step based on the drone's current (real) state and are then used to simulate the entire predicted (future) trajectory.
- Simple quadratic cost function penalizing distance to target and control effort
pip install -r requirements.txtpython vis.py