Skip to main content

Koopman-based Linear MPC for Quadrotor Control

Project description

🚁 kq_lmpc_quadrotor: Koopman MPC for Quadrotors Derived From Analytically Derived Koopman Embeddings

A complete Python package for real-time Koopman-based Linear Model Predictive Control (LMPC) of quadrotors.

PyPI Version License Python Paper Stars

First hardware-deployed real-time Linear MPC for quadrotors derived using Koopman operator theory, no data required.
Fast QP ⚡ Comparable Performance like NMPC 🎯 Runs on embedded hardware 💻✅

KQ-LMPC = Koopman Lift + Convex MPC + Real-Time Control

A unified Python framework:

  • Koopman lifting without machine learning
  • Convex linear MPC that runs in real time
  • Provable stability + hardware deployability


🌟 Key Features

Analytical Koopman lifting with generalizable observables
    → No neural networks, no training, no data fitting required

Data-free Koopman-lifted LTI + LPV models
    → Derived directly from SE(3) quadrotor dynamics using Lie algebra structure

Real-time Linear MPC (LMPC)
    → Solved as a single convex QP termed KQ-LMPC
    → < 10 ms solve time on Jetson NX / embedded hardware

Trajectory tracking on SE(3)
    → Provable controllability in lifted Koopman space

Closed-loop robustness guarantees
    → Input-to-state practical stability (I-ISpS)

Hardware-ready integration
    → Works with PX4 Offboard Mode, ROS2, MAVSDK, MAVROS

Drop-in MPC module
    → for both KQ-LMPC, NMPC with acados on Python.


🧠 Paper

This work is based on:

"Real-Time Linear MPC for Quadrotors on SE(3): An Analytical Koopman-based Realization"
IEEE Robotics and Automation Letters (RA-L), 2025
Santosh Rajkumar, Chengyu Yang, Yuliang Gu, Sheng Cheng, Naira Hovakimyan, Debdipta Goswami
[Paper PDF][ArXiv][Video Demos]

If you use this repository, please cite us 🙏

@article{rajkumar2025kqlmpc,
  title={Real-Time Linear MPC for Quadrotors on SE(3): An Analytical Koopman-based Realization},
  author={Rajkumar, Santosh and Yang, Chengyu and Gu, Yuliang and Cheng, Sheng and Hovakimyan, Naira and Goswami, Debdipta},
  journal={IEEE Robotics and Automation Letters},
  year={2025}
}

🔧 Installation

*Virtual environment recommended

Install from PyPI (recommended):

pip install kq-lmpc-quadrotor

Install from source

git clone https://github.com/santoshrajkumar/kq-lmpc-quadrotor.git
cd kq-lmpc-quadrotor
pip install -e .

⚡ Quick Demo

lqr_demo
kqlmpc_demo

⚙️ Note: This package uses the acados toolchain for fast MPC.
Please ensure that acados is installed and its Python interface is configured before running the demo/examples with MPC.
Installation guide: https://docs.acados.org/installation/index.html

Python interface: https://docs.acados.org/python_interface/index.html

OS requirement: Linux/Mac (Not tested on Windows).

Ensure that LD_LIBRARY_PATH is set correctly (DYLD_LIBRARY_PATHon MacOS).

Ensure that ACADOS_SOURCE_DIR is set correctly.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kq_lmpc_quadrotor-1.0.5.tar.gz (33.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kq_lmpc_quadrotor-1.0.5-py3-none-any.whl (35.8 kB view details)

Uploaded Python 3

File details

Details for the file kq_lmpc_quadrotor-1.0.5.tar.gz.

File metadata

  • Download URL: kq_lmpc_quadrotor-1.0.5.tar.gz
  • Upload date:
  • Size: 33.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.10.12

File hashes

Hashes for kq_lmpc_quadrotor-1.0.5.tar.gz
Algorithm Hash digest
SHA256 3a8d7c8ff56ae07c61c5f41f4ae57c623353d5e106080ecd32395d679eed3fa0
MD5 7e70e391f74e6ebcd65e0e3b28bf7f41
BLAKE2b-256 cac11756cba0bd3c5c495ae4cc9cf528f5b696d71d30b8f7b790034f8524c900

See more details on using hashes here.

File details

Details for the file kq_lmpc_quadrotor-1.0.5-py3-none-any.whl.

File metadata

File hashes

Hashes for kq_lmpc_quadrotor-1.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 2bbed9be3522dc58fd2e9f720b788c4b30bf051d937c8fb7f499070d7d71ec27
MD5 0536b58a9b7037285689d13fe576670f
BLAKE2b-256 53fa877a2d640845a0580df2e600c241c1d1ed0452090374a2034b77bc46f321

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page