Python proof of concept for BCHOL.
Solves for x in Ax = b, using the Recursive Schur Linear Quadratic Regulator explained in the paper A Parallell Linear System Solver for Optimal Control by Brian E.Jackson. It requires A to be a positive semi-definite matrix to guarantee a good result.
This method is part of the Python implementation of trajectory optimization (trajopt) algorithms and model predictive control (MPC). Learn more about different TrajoptMPC here.
-
The following libraries (Numpy, Scipy) are included in the requirments.txt and can be downloaded with the following command
pip3 install -r requirements.txt
If you already have a defined LQR problem in a KKT form in a saved file .json/.csv you can look at solve_load.py
for an example. The program will return the solution in two forms:
- Flattened dxul vector
- Brian Jackson's format as mentioned in the paper [lambda_i ; x_i; u_i]
python solve_load.py
If you just have an A matrix and a b vector look at solve_build.py
for an example.
Both files will return an xyz solution vector in dxul.
Author: Yana Botvinnik Contact: ybotvinn@barnard.edu