Features by Example#

This page showcases how specific acados features can be used by pointing to the relevant examples. If you are new to acados, we highly recommend you to start with the getting_started examples:

Getting started with Model Predictive Control#

In particular, the closed-loop examples are a great starting point to develop model predictive control (MPC) in a simulation. Here, an OCP solver (AcadosOcpSolver) is used to compute the control inputs and an integrator (AcadosSimSolver) is used to simulate the real system.

Simulation and Sensitivity propagation#

Optimal Control Problem Formulation#

Parameter updates#

Cost formulations#

acados supports general nonlinear cost, but can also exploit particular cost structures such as (non)linear least-squares costs and convex-over-nonlinear costs.

Soft constraints#

Convex-over-nonlinear constraints#

  • Python

  • currently not supported for MATLAB

Multi-phase OCP#

Constraints and cost on control rate#

Moving horizon estimation (MHE)#

Discretization with a nonuniform grid#

Time-varying reference tracking#

One-sided constraints#

Algorithmic features and solver options#

Real-time iterations (RTI)#

Advanced-step real-time iterations (AS-RTI)#

Relevant publications: Frey2024a, Nurkanovic2019a

Solver timeout#

Cost integration#

Globalization#

Differential dynamic programming (DDP)#

Partial condensing#

Use a qp_solver starting with PARTIAL_CONDENSING, use qp_solver_cond_N to set the horizon of the partially condensed QP. Additionally, one can use qp_solver_cond_block_size to specify how many blocks are condensed into one block in partial condensing.

Zero-order robust optimization (zoRO)#

Relevant publications: Frey2024, Zanelli2021

Solution sensitivities#

  • Python

  • currently not supported for MATLAB/Octave

Adjoint solution sensitivities#

  • Python

  • currently not supported for MATLAB/Octave