Papers
Topics
Authors
Recent
Search
2000 character limit reached

MPC-Based Safety Filter

Updated 13 November 2025
  • 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: xk+1=f(xk,uk)x_{k+1} = f(x_k,u_k) where xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n is the state (in a compact set XX), uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m is the control input (in a compact set UU), and ff is continuous with f(0,0)=0f(0,0)=0. The filter operates online: at each time kk, it receives a proposed input udes(k)u_{\mathrm{des}}(k), which may not satisfy constraints or deliver stability. The safety filter dynamically checks the feasibility of udes(k)u_{\mathrm{des}}(k). If infeasible, it substitutes the minimally invasive safe action xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n0 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 xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n1, after measuring the current state xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n2 and receiving the candidate input xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n3, the filter solves the following finite-horizon nonlinear MPC optimization: xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n4 subject to

xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n5

where the cost function xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n6 is typically

xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n7

to ensure minimal perturbation from the nominal command. The terminal set xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n8 is chosen so it is forward-invariant under a nominal local controller, ensuring recursive feasibility.

The safe output assigned to the plant is always: xk∈X⊆Rnx_k \in X \subseteq \mathbb{R}^n9 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: XX0 where XX1 is a positive-definite stage cost (often quadratic), and XX2 is a terminal cost (typically via Riccati or LQR design). At each step, a one-step upper bound constraint is enforced: XX3 where XX4 is a time-varying stability bound, initialized by XX5 and updated recursively: XX6 with XX7, trading off convergence speed and nominal matching.

Terminal ingredients:

  • A local backup controller XX8 and invariant terminal set XX9 so that

uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m0

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., uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m1 as uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m2.
  • 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)

  1. Initialize with horizon uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m3, stage cost uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m4, terminal cost uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m5, terminal set uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m6, and bound uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m7.
  2. For each time-step uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m8:

    • Measure current state uk∈U⊆Rmu_k \in U \subseteq \mathbb{R}^m9.
    • Receive input UU0.
    • Solve MPC safety filter:

    UU1

    subject to dynamics, constraints UU2, and stability bound UU3. - Apply UU4. - Update the stability bound:

    UU5

- Increment UU6.

Backup logic: If UU7 is safe and does not violate the stability bound, the filter passes it through. Otherwise, it "projects" UU8 into the largest subset admitting a feasible backup trajectory.

5. Design Guidelines and Tuning Parameters

Critical parameters and their tuning:

  • Prediction horizon UU9: Larger ff0 expands the filter’s feasible domain and reduces conservatism, but incurs higher computation. Typical values are ff1.
  • Stage cost ff2: Quadratic form ff3; ff4 penalizes state error, ff5 penalizes input deviation.
  • Terminal cost ff6: Quadratic ff7, where ff8 is obtained from the Riccati equation for an LQR design.
  • Terminal set ff9: Defined as f(0,0)=0f(0,0)=00, with small f(0,0)=0f(0,0)=01.
  • Stability trade-off f(0,0)=0f(0,0)=02: Lower f(0,0)=0f(0,0)=03 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: f(0,0)=0f(0,0)=04
  • Inputs: f(0,0)=0f(0,0)=05, with constraints such as f(0,0)=0f(0,0)=06, f(0,0)=0f(0,0)=07, box constraints on other variables.
  • Reference: Generated from a lane-change planner: sequence f(0,0)=0f(0,0)=08.
  • Filter parameters: f(0,0)=0f(0,0)=09, kk0, kk1, kk2 from LQR, kk3.

Key findings:

  • For nominal demanded (u_des) inputs, the filter is minimally invasive: average kk4.
  • 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

kk5

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., 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.

Definition Search Book Streamline Icon: https://streamlinehq.com
References (1)

Topic to Video (Beta)

No one has generated a video about this topic yet.

Whiteboard

No one has generated a whiteboard explanation for this topic yet.

Follow Topic

Get notified by email when new papers are published related to Model Predictive Control (MPC)-Based Safety Filter.