NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

Learning Stability Certificates from Data

Nicholas M. Boffi, Stephen Tu, Nikolai Matni, Jean-Jacques E. Slotine, Vikas Sindhwani

Abstract

Many existing tools in nonlinear control theory for establishing stability or safety of a dynamical system can be distilled to the construction of a certificate function which guarantees a desired property. Traditionally, these certificates are derived from analytical physics models. This paper introduces a framework for learning formal stability and safety certificates directly from robot trajectory data. By leveraging statistical learning theory, we demonstrate that these learned certificates generalize to unseen trajectories with high probability and can provide global stability guarantees even in high-dimensional systems where analytical models are unavailable.

Introduction: The Trust Gap in Modern Robotics

In traditional control theory, ensuring a robot's stability—guaranteeing it won't crash or deviate uncontrollably—relies on constructing a certificate function, such as a Lyapunov function. This function acts as an "energy" map: if we can prove the system's energy consistently decreases toward a goal state, stability is formally guaranteed.

However, traditional synthesis methods like Sum-of-Squares (SOS) optimization require a perfect analytical model of the system's physics. In modern robotics, we increasingly rely on complex simulators or deep neural networks where such equations are either unknown or too complex to derive. This creates a "trust gap": while Reinforcement Learning can produce impressive behaviors, we often lack the formal proofs needed for safety-critical real-world deployment.

Learning Certificates from Data

We propose treating certificate synthesis as a statistical learning problem. Instead of deriving a function from physics, we learn it from observed trajectories.

Optimization and Generalization

The framework involves collecting sequences of states and velocities from a dynamical system. We then search for a certificate function $V$ within a specific function class (e.g., neural networks or polynomials) that satisfies the required stability conditions across all training samples, incorporating a small safety margin.

Using Rademacher complexity, we provide a theoretical analysis of the generalization error. We prove that if a certificate satisfies the conditions on a sufficient number of training trajectories ($n$), the probability of failure on unseen trajectories scales at a fast rate of roughly $\tilde{O}(k/n)$, where $k$ represents the complexity of the function class. This ensures that as we collect more data, the "violation regions" where the certificate might fail progressively vanish.

Violation regions of a learned Lyapunov function for a Van der Pol oscillator shrink as the number of training samples $n$ increases.

From Local to Global Guarantees

A key contribution is a mathematical bridge that elevates these probabilistic statements to non-probabilistic, global guarantees. By assuming the system possesses a basic level of inherent local stability, we can prove that the learned certificate holds globally, except perhaps within a small, quantifiable region around the equilibrium.

Experimental Evaluation

The approach was validated across several simulated environments:

  • Damped Van der Pol Oscillator: Used to visualize the shrinking of violation regions.
  • Damped Pendulum: 1,000 trajectories were used to learn a Lyapunov function for adaptive control tasks.
  • Minitaur Quadruped: A high-dimensional PyBullet simulation where 50,000 trajectories were used to learn a discrete-time Lyapunov function for recovery from random impulses.
  • 6D Gradient Flow: A synthetic system used to test the learning of contraction metrics.

Key Results and Insights

The experiments yielded several significant findings:

  • High Accuracy and Sample Efficiency: For the complex Minitaur robot, the learned certificate achieved a median generalization error of just 1.11% on 10,000 test trajectories. In the 6D system, error probability dropped to 5-8% with only 4,000 samples, showing that high-dimensional verification does not necessarily require millions of data points.
  • Certificates as Controllers: Learned certificates are functional. In the pendulum experiment, the learned Lyapunov function was used to design an adaptive controller capable of handling disturbances 10x stronger than standard baseline controllers.
  • Flexibility: The framework is versatile, supporting Lyapunov functions (stability), barrier functions (safety), and contraction metrics (convergence).
Top: Adaptive control of a pendulum using a learned certificate handles disturbances up to 10x baseline. Bottom: Generalization error vs. sample size for a 6D system demonstrates fast convergence.

Conclusion and Future Directions

This work demonstrates that perfect physics models are not a prerequisite for formal stability verification. If a system's behavior is sufficiently observed, we can learn functions that capture its underlying stability structure.

Future work will address the challenges of noisy sensor data, which can degrade certificate quality in real-world settings. Additionally, we aim to explore joint learning, where the dynamics model and the certificate function are learned simultaneously to achieve tighter performance bounds and more robust safety guarantees.

Summary updated

BibTeX
@inproceedings{boffi2020learning,
  author = {Nicholas M. Boffi and Stephen Tu and Nikolai Matni and Jean-Jacques E. Slotine and Vikas Sindhwani},
  title = {{Learning Stability Certificates from Data}},
  booktitle = {Conference on Robot Learning},
  year = {2020},
  url = {https://openreview.net/forum?id=BddBcW7qDe5},
}
Figure