MPC-Based Safety Filter
- MPC-based safety filters are defined as receding-horizon intervention mechanisms that modify arbitrary inputs to ensure hard state and input constraints while maintaining system stability.
- The framework utilizes an online constrained MPC optimization to minimally adjust proposed control signals, enforcing a stability bound through a Lyapunov-based cost function.
- Practical applications, such as automotive driver assistance, demonstrate the filter’s ability to integrate backup control laws and guarantee bounded convergence under dynamic conditions.
A Model Predictive Control (MPC)-based safety filter is a receding-horizon intervention mechanism that wraps an arbitrary (and potentially unsafe) input signal—typically from a learning-based controller, human operator, or trajectory planner—with a formal guarantee of safety and, when possible, stability. The core principle is to solve a constrained MPC problem at each time-step, "filtering" the proposed input so that the actual control administered is certifiably safe (i.e., satisfying state and input constraints), and, in advanced treatments, ensures desirable stability properties such as bounded convergence or uniform asymptotic stability. This framework extends and systematizes classical MPC safety and stability results, allowing seamless integration with practical system designs, robust backup control, and adaptation to dynamic trajectory tracking.
1. System Architecture and Notation
Consider the discrete-time, nonlinear plant model: where is the state (in a compact set ), is the control input (in a compact set ), and is continuous with . The filter operates online: at each time , it receives a proposed input , which may not satisfy constraints or deliver stability. The safety filter dynamically checks the feasibility of . If infeasible, it substitutes the minimally invasive safe action through the receding-horizon MPC framework.
Key aspects:
- Hard state and input constraint enforcement,
- Optional stabilization/tracking to a target (origin or reference),
- Online backup controller for recursive feasibility.
2. MPC-Based Safety Filter Formulation
At each time , after measuring the current state and receiving the candidate input , the filter solves the following finite-horizon nonlinear MPC optimization: subject to
where the cost function is typically
to ensure minimal perturbation from the nominal command. The terminal set is chosen so it is forward-invariant under a nominal local controller, ensuring recursive feasibility.
The safe output assigned to the plant is always: where the superscript * denotes the optimizer's solution.
3. Stability Augmentation Mechanism
To guarantee stability beyond mere constraint satisfaction, the filter augments the optimization with a classical MPC Lyapunov-style cost: where is a positive-definite stage cost (often quadratic), and is a terminal cost (typically via Riccati or LQR design). At each step, a one-step upper bound constraint is enforced: where is a time-varying stability bound, initialized by and updated recursively: with , trading off convergence speed and nominal matching.
Terminal ingredients:
- A local backup controller and invariant terminal set so that
This guarantees recursive feasibility as well as bounded, Lyapunov-style stability.
Formal guarantees:
- Bounded convergence: The state sequence remains bounded and converges to zero, i.e., as .
- Uniform asymptotic stability: The same bound/convergence applies uniformly in any time-shifted window.
Proof relies on standard MPC Lyapunov decrease, shift-append backup policy, and recursive feasibility.
4. Online Filter Algorithm and Implementation
Algorithm 1 (Model Predictive Stability Filter)
- Initialize with horizon , stage cost , terminal cost , terminal set , and bound .
- For each time-step :
- Measure current state .
- Receive input .
- Solve MPC safety filter:
subject to dynamics, constraints , and stability bound . - Apply . - Update the stability bound:
- Increment .
Backup logic: If is safe and does not violate the stability bound, the filter passes it through. Otherwise, it "projects" into the largest subset admitting a feasible backup trajectory.
5. Design Guidelines and Tuning Parameters
Critical parameters and their tuning:
- Prediction horizon : Larger expands the filter’s feasible domain and reduces conservatism, but incurs higher computation. Typical values are .
- Stage cost : Quadratic form ; penalizes state error, penalizes input deviation.
- Terminal cost : Quadratic , where is obtained from the Riccati equation for an LQR design.
- Terminal set : Defined as , with small .
- Stability trade-off : Lower reduces intervention, higher values yield faster convergence.
6. Demonstrative Automotive Application
The framework is validated using an advanced driver assistance system scenario for a single-track car model linearized about 10 m/s cruising:
- States:
- Inputs: , with constraints such as , , box constraints on other variables.
- Reference: Generated from a lane-change planner: sequence .
- Filter parameters: , , , from LQR, .
Key findings:
- For nominal demanded (u_des) inputs, the filter is minimally invasive: average .
- When u_des would induce instability or violate constraints, e.g., sharp steering reversals, the filter actively projects the steering into the largest safe admissible set, ensuring convergence to the reference trajectory.
- The performance bound
is numerically verified for monotonic decrease.
- Full constraint satisfaction and uniform convergence to the reference are attained.
7. Context and Significance
MPC-based safety filters with formal stability mechanisms, as constructed in this framework (Milios et al., 8 Apr 2024), represent a systematic methodology to shield safety-critical systems from the risks of arbitrary learning-based or human inputs. These filters guarantee hard constraint satisfaction and, by embedding Lyapunov-style stability costs and bounds, admit rigorous guarantees of bounded, even uniform, convergence under minimal intervention. The modular architecture enables plug-and-play augmentation of existing control stacks (including learning-based policies), supports computationally tractable online filtering, and is readily tuned for application-specific requirements. The framework's utility is exemplified in contextually demanding domains such as automotive lane-keeping and trajectory stabilization, delivering both empirical safety and mathematical guarantees without imposing excessive conservatism. The approach admits straightforward extensions to trajectory tracking and other domains, subject to the expressiveness of the terminal ingredients and stability bounds.