betaFeedback

WorksMathematics

Construction of Universal Safe Stabilizing Formulas with Weighted Centroid Methodology

Abstract

Control Lyapunov and control barrier functions ensure stability and safety, respectively, by imposing state-dependent affine constraints on the control input. Controller design can therefore be viewed as the problem of selecting an admissible input from the set defined by these constraints. This paper adopts this perspective and develops a weighted-centroid methodology for constructing explicit feedback formulas that are provably smooth. The selection method relies on the fact that weighted centroids of a convex set lie within the set. We establish conditions on the weight functions that guarantee smoothness and continuity for several classes of constraints, including single constraints, mirrored constraints, linearly independent multiple constraints, and two-constraint Gaussian constructions. The framework recovers Sontag's universal formula and generates other new explicit formulas. When specialized to control-theoretic settings, the resulting formulas yield smooth safety filters, stabilizing controllers, and safe-stabilizing controllers. Simulation and hardware experiments on a small quadrotor illustrate the practical benefits of the proposed construction.

This work was supported by AFOSR Award FA9550-23-1-0740.

Introduction

Certificate-based methods provide powerful tools for enforcing and certifying desirable closed-loop dynamical properties, such as stability and safety. Control Lyapunov functions (CLFs) [1, 2] certify the existence of stabilizing inputs, while control barrier functions (CBFs) [3, 4] certify the existence of inputs that render a prescribed safe set forward invariant. In both cases, these certificates translate the desired closed-loop properties into state-dependent constraints on the control inputs. As a result, controller design can be viewed as a selection problem consisting of selecting at each state an admissible control input from the set defined by the constraints.

These selection problems can be approached using optimization, formulating the control design as a state-wise optimization subject to the control-theoretic constraints. Such ideas have long been employed in nonlinear control [2], but have become especially prominent over the past decade in the safety-critical control literature via CLF-CBF-based quadratic programs [3]. This optimization framework is appealing due to its modularity, computational tractability, and its ability to accommodate multiple constraints, making it well suited for real-time safety-critical applications. Despite its advantages, optimization-based controllers often fail to be differentiable [5, 6, 7]. This nonsmoothness is already evident from the closed-form expressions in the single-constraint case [8], and persists in more general explicit CBF-based safety filters [9].

In many settings, it is desirable for the feedback controller to be smooth. In particular, smoothness enables recursive and compositional control constructions in which the controller itself is an intermediate design step within a broader control design framework or hierarchy. Examples include backstepping [10], which has recently been extended to safety-critical control [11, 12]. Other examples include the backup CBF framework [13] — in which a safe backup policy is used to dynamically generate an implicit control invariant set — where the backup controller must be continuously differentiable to reliably compute gradients of the resulting implicit CBF.

Smooth feedback design has long appeared in the literature of nonlinear stabilization. In particular, Artstein’s theorem [14] establishes the existence of a continuous stabilizing controller from a CLF. Although not stated explicitly, the same selection method can be extended more generally to obtain smooth feedback [15]. Unfortunately, these existence results are nonconstructive. Sontag’s universal formula [16] addresses this limitation by providing an explicit feedback construction from a CLF. The formula, however, is tailored to a single CLF constraint. Subsequent works [17] and [18] extend the universal formula to handle additional constraints such as u∈[0,∞)u \in[0,\infty) and u∈[0,1]u \in[0,1], respectively. However, these methods do not handle additional constraints that are state-dependent, such as those induced by CBFs.

Motivated in part by the introduction of CBFs, more recent works have revisited universal-formula constructions. Earlier work applies the Sontag’s formula in settings where both stability and safety objectives can be encoded together with control Lyapunov barrier functions [19, 20]. The implicit-function-theorem viewpoint underlying Sontag’s formula has been used to characterize and construct smooth safety filters for single affine constraints [21]. Other works [22, 23] study how the Sontag’s formula can be tuned toward minimum-norm controllers while retaining smoothness or inverse optimality [24]. Extensions to safe stabilization with both CLF and CBF constraints have also been developed. For instance, [25] proposes a Sontag-type formula that handles both constraints, albeit for single-input systems. Alternatively, multiple constraints with multiple inputs can be handled by reformulating the selection problem as an unconstrained optimization problem whose optimizer varies smoothly with the state [26]. While this provides a smooth selection mechanism, it does not yield an explicit closed-form formula.

Statement of Contributions: The present paper develops a general weighted-centroid methodology for constructing explicit smooth feedback formulas that select admissible control inputs from state-dependent affine constraints. The work builds on our earlier conference version of the paper [27], which introduced a Gaussian-weighted centroid formula for smooth safe stabilization with one CLF and one CBF. Here, we generalize the core idea into a broader framework in which the choice of weight function becomes a mechanism for generating explicit feedback formulas.

The first contribution is the introduction of the weighted-centroid perspective as a constructive methodology for control design. In contrast to [27], where smoothness followed from known closed-form expressions for truncated Gaussian means, the present smoothness results apply to general classes of weight functions. In particular, we identify sufficient conditions for smoothness of the admissible control maps and weight functions, covering the following cases: single affine constraints, mirrored constraints (two affine constraints with anti-parallel normals), multiple constraints with linearly independent constraint normals, structured linearly dependent constraints arising from mirrored pairs, and the general two affine constraints using Gaussian weights. For linearly independent cases, we provide continuity guarantees at states where constraint normals vanish, provided the remaining nonzero constraint normals remain linearly independent.

The second contribution is the use of the proposed methodology to derive explicit feedback formulas, beyond Gaussian-weighted constructions in [27]. Notably, we show that Sontag’s universal formula can be recovered as a weighted centroid of the admissible control set induced by a single affine constraint. This interpretation allows us to extend Sontag’s formula to handle mirrored constraints while retaining an explicit closed-form expression, rather than an optimization-based formulation. Beyond Sontag-type constructions, we derive additional explicit formulas using Gaussian weights and various polynomial weights. We also develop a compactly supported formula that respects state-independent input bounds.

The third contribution is the specialization of the framework to control-theoretic settings with CLFs and CBFs. The resulting constructions yield explicit smooth formulas for safety filtering, stabilization, and safe stabilization by satisfying the corresponding CLF and/or CBF constraints under suitable compatibility assumptions. For the CLF stabilization setting, we characterize classes of weight functions for which the resulting formula is continuous at the origin under the small control property, and propose a state-dependent scaling method for modifying existing weight functions to fit this class.

Finally, we demonstrate the practical implications of the proposed methodology through both simulation and hardware experiments on a quadrotor. The simulation study uses higher-order tracking dynamics to illustrate how nonsmooth safety-filter commands can repeatedly excite tracking transients, whereas the proposed smooth formula avoids this effect. Complementary hardware experiments on a small quadrotor show that our approach provides an inherent robustness margin against residual tracking and implementation errors.

Admissible Control Map Selection

This section introduces the problem of designing a controller to satisfy state-dependent control constraints. Consider a nonlinear control-affine system1:

x˙=f(x)+g(x)u,(1)\dot{\mathbf{x}}=\mathbf{f}(\mathbf{x})+\mathbf{g}(\mathbf{x})\mathbf{u}, \tag*{(1)}

where x∈Rn\mathbf{x} \in\mathbb{R}^{n} is the state and u∈Rm\mathbf{u} \in\mathbb{R}^{m} is the control input. The drift vector field f:Rn→Rn\mathbf{f}:\mathbb{R}^{n} \to\mathbb{R}^{n} and the control matrix-valued function g:Rn→Rn×m\mathbf{g}:\mathbb{R}^{n} \to\mathbb{R}^{n \times m} are assumed to be smooth. Given a locally Lipschitz feedback controller k:Rn→Rm\mathbf{k}:\mathbb{R}^{n} \to\mathbb{R}^{m}, the closed-loop system is: x˙=f(x)+g(x)k(x)\dot{\mathbf{x}}=\mathbf{f}(\mathbf{x})+\mathbf{g}(\mathbf{x})\mathbf{k}(\mathbf{x}).

In many situations, the choice of u\mathbf{u} is limited to a specific set U⊂Rm\mathcal{U} \subset\mathbb{R}^{m}. In the simplest case, the set U\mathcal{U} is fixed, e.g., when the input has hard actuation limits. In general, however, the constraint set is described by a set-valued map U:Rn⇉Rm\mathcal{U}:\mathbb{R}^{n} \rightrightarrows\mathbb{R}^{m} that captures dependency on the state. This naturally arises in control design problems that enforce performance or safety specifications. For example, control Lyapunov functions (CLFs) [1] and control barrier functions (CBFs) [3] impose inequality constraints on u\mathbf{u} that depend explicitly on the state. Although the results in this paper apply to general state-dependent affine constraints, we focus on those induced by CLFs and CBFs, given their relevance in control theory.

Control Lyapunov and Control Barrier Functions

The concept of a CLF builds on Lyapunov theory by incorporating the control input u\mathbf{u} to certify the existence of stabilizing controllers. Throughout this section, we assume that the system (1) admits an equilibrium under zero input. Without loss of generality, we shift coordinates so that the equilibrium of interest is located at the origin x=0\mathbf{x}=0, i.e., f(0)=0\mathbf{f}(0)=0.

Definition 1. ([2 Section 3.3.1]): A continuously differentiable function V:Rn→RV:\mathbb{R}^{n} \to\mathbb{R} is a control Lyapunov function for the control-affine system (1) if there exists class-K∞\mathcal{K}_{\infty} functions α\alpha and α‾\overline{\alpha} such that for all x∈Rn\mathbf{x} \in\mathbb{R}^{n}:

α(∥x∥)≤V(x)≤α‾(∥x∥),\alpha(\lVert\mathbf{x}\rVert) \leq V(\mathbf{x}) \leq\overline{\alpha}(\lVert\mathbf{x}\rVert),

and, there exists a class-K\mathcal{K} function α\alpha such that, for each x∈Rn∖{0}\mathbf{x} \in\mathbb{R}^{n} \setminus\{0\}, there exists u∈Rm\mathbf{u} \in\mathbb{R}^{m} satisfying CLF constraint:

LfV(x)+LgV(x)u<−α(V(x))(2)\mathcal{L}_{\mathbf{f}}V(\mathbf{x})+\mathcal{L}_{\mathbf{g}}V(\mathbf{x})\mathbf{u} < -\alpha(V(\mathbf{x})) \tag*{(2)}

At each x∈Rn\mathbf{x} \in\mathbb{R}^{n}, the CLF constraint (2) ensures the existence of a control u\mathbf{u} that makes the time derivative of the function VV negative, as required to make VV a Lyapunov function. Importantly, CLFs facilitate the selection of control inputs to enforce stability of the closed-loop system.

Lemma II.1. (Stabilizing Controller): Consider the control-affine system (1) and a CLF V:Rn→RV : \mathbb{R}^{n} \to\mathbb{R}. Define a state-dependent admissible control map ΩCLF:Rn⇉Rm\Omega_{\mathrm{CLF}} : \mathbb{R}^{n} \rightrightarrows\mathbb{R}^{m} such that for all x≠0\mathbf{x} \ne0:

ΩCLF(x)={u∈Rm∣LfV(x)+LgV(x)u≤−α(V(x))}.\Omega_{\mathrm{CLF}}(\mathbf{x}) = \left\{ \mathbf{u} \in\mathbb{R}^{m} \mid L_f V(\mathbf{x}) + L_g V(\mathbf{x})\mathbf{u} \le-\alpha(V(\mathbf{x})) \right\}.

Given a function k:Rn→Rm\mathbf{k} : \mathbb{R}^{n} \to\mathbb{R}^{m} such that k(0)=0\mathbf{k}(0) = 0, k\mathbf{k} is locally Lipschitz on Rn∖{0}\mathbb{R}^{n} \setminus\{0\}, and k(x)∈ΩCLF(x)\mathbf{k}(\mathbf{x}) \in\Omega_{\mathrm{CLF}}(\mathbf{x}) for each x∈Rn∖{0}\mathbf{x} \in\mathbb{R}^{n} \setminus\{0\}, the feedback law u=k(x)\mathbf{u} = \mathbf{k}(\mathbf{x}) renders the origin asymptotically stable.

The set-valued map ΩCLF\Omega_{\mathrm{CLF}} specifies, at each x\mathbf{x}, the set of all admissible inputs u\mathbf{u} that lead to the decrease of VV. Note that although the constraint (2) is stated with a strict inequality, the admissible control set ΩCLF\Omega_{\mathrm{CLF}} is defined using the non-strict condition (≤\le). The strict inequality in the definition not only guarantees that the set ΩCLF(x)\Omega_{\mathrm{CLF}}(\mathbf{x}) is nonempty but also ensures the existence of a smooth feedback controller satisfying the constraint, see also Lemma II.3 discussed shortly.

We next review the concepts of safety and CBFs. For (1), suppose S⊂RnS \subset\mathbb{R}^{n} is a safe set and the control objective is to design a feedback controller such that the safe set SS is forward invariant for the closed-loop system. In other words, the set SS is safe if the solution to the closed-loop system is such that x(t)∈S\mathbf{x}(t) \in S at all time in its interval of existence for any given initial condition x0∈S\mathbf{x}_0 \in S. The concept of a CBF facilitates the construction of controllers enforcing safety.

Definition 2. (Control Barrier Function [3]): A continuously differentiable function h:Rn→Rh : \mathbb{R}^{n} \to\mathbb{R} is a control barrier function for the set SS under the control-affine system (1) if its 0-superlevel set defines SS:

S={x∈Rn∣h(x)≥0};(3)S = \left\{ \mathbf{x} \in\mathbb{R}^{n} \mid h(\mathbf{x}) \ge0 \right\}; \tag*{(3)}

and, there exists a class-Ke\mathcal{K}^{e} function αh\alpha_h such that, for each x∈S\mathbf{x} \in S, there exists u∈Rm\mathbf{u} \in\mathbb{R}^{m} satisfying the CBF constraint:

Lfh(x)+Lgh(x)u>−αh(h(x)),(4)L_f h(\mathbf{x}) + L_g h(\mathbf{x})\mathbf{u} > -\alpha_h(h(\mathbf{x})), \tag*{(4)}

The concept of a CBF builds on that of a barrier certificate [28], which has traditionally been used for safety verification of autonomous systems, by extending such a certificate function to incorporate control inputs. The CBF constraint (4) guarantees that there exists a control u\mathbf{u} that does just that. Furthermore, the function αh\alpha_h on the right-hand side of (4) allows the value of hh to decrease at points where h(x)>0h(\mathbf{x}) > 0, i.e., in the interior of SS. Consequently, there are more possible choices of control input u\mathbf{u} that help render the set SS safe. We formally state the safety result using CBFs below.

Lemma II.2. (Safeguarding Controller): Consider the control-affine system (1) and a CBF h:Rn→Rh : \mathbb{R}^{n} \to\mathbb{R}. Define a state-dependent admissible control map ΩCBF:S⇉Rm\Omega_{\mathrm{CBF}} : S \rightrightarrows\mathbb{R}^{m} as:

ΩCBF(x)={u∈Rm∣Lfh(x)+Lgh(x)u≥−αh(h(x))}.\Omega_{\mathrm{CBF}}(\mathbf{x}) = \left\{ \mathbf{u} \in\mathbb{R}^{m} \mid L_f h(\mathbf{x}) + L_g h(\mathbf{x})\mathbf{u} \ge-\alpha_h(h(\mathbf{x})) \right\}.

Given a function k:Rn→Rm\mathbf{k} : \mathbb{R}^{n} \to\mathbb{R}^{m} such that k\mathbf{k} is locally Lipschitz on SS and k(x)∈ΩCBF(x)\mathbf{k}(\mathbf{x}) \in\Omega_{\mathrm{CBF}}(\mathbf{x}) for each x∈S\mathbf{x} \in S, the feedback u=k(x)\mathbf{u} = \mathbf{k}(\mathbf{x}) renders the set SS safe.

Lemma II.2 uses a CBF to guarantee safety by limiting the admissible inputs at each state. Similar to CLFs, CBFs induce a set-valued map ΩCBF\Omega_{\mathrm{CBF}} that specifies admissible control inputs. The use of a strict inequality in the CBF constraint (4), while the safety result only requires the non-strict condition defining ΩCBF\Omega_{\mathrm{CBF}}, parallels the discussion following Lemma II.1.

Problem Statement

Motivated by the CLF and CBF constructions above, we consider a general class of affine inequality constraints. Abstracting this structure, we define admissible control maps Ωi:Si⇉Rm\Omega_i : S_i \rightrightarrows\mathbb{R}^{m} on domains Si⊆RnS_i \subseteq\mathbb{R}^{n} as:

Ωi(x)={u∈Rm∣ai(x)+bi(x)u≤0 (or < 0)}.(5)\Omega_i(\mathbf{x}) = \left\{ \mathbf{u} \in\mathbb{R}^{m} \mid a_i(\mathbf{x}) + b_i(\mathbf{x})\mathbf{u} \le0\ \text{(or < 0)} \right\}. \tag*{(5)}

References

  1. [1]E. D. Sontag, “A Lyapunov-like characterization of asymptotic controllability,” SIAM Journal on Control and Optimization, vol. 21, pp. 462–471, 1983.DOI
  2. [2]R. A. Freeman and P. V. Kokotovic, Robust Nonlinear Control Design: State-Space and Lyapunov Techniques. Boston, MA: Birkhäuser, 1996.
  3. [3]A. D. Ames, X. Xu, J. W. Grizzle, and P. Tabuada, “Control barrier function based quadratic programs for safety critical systems,” IEEE Transactions on Automatic Control, vol. 62, no. 8, pp. 3861–3876, 2017.DOI
  4. [4]A. D. Ames, S. Coogan, M. Egerstedt, G. Notomista, K. Sreenath, and P. Tabuada, “Control barrier functions: Theory and applications,” in European Control Conference, (Naples, Italy), pp. 3420–3431, June 2019.arxiv.org/abs/1903.11199
  5. [5]P. Mestres, A. Allibhoy, and J. Cortés, “Regularity properties of optimization-based controllers,” European Journal of Control, vol. 81, p. 101098, 2025.arxiv.org/abs/2311.13167
  6. [6]B. J. Morris, M. J. Powell, and A. D. Ames, “Continuity and smoothness properties of nonlinear optimization-based feedback controllers,” in IEEE Conf. on Decision and Control, (Osaka, Japan), pp. 151–158, Dec. 2018.
  7. [7]D. R. Agrawal, H. Lee, and D. Panagou, “Reformulations of quadratic programs for Lipschitz continuity,” IEEE Control Systems Letters, vol. 9, pp. 2603–2608, 2025.
  8. [8]M. Jankovic, “Robust control barrier functions for constrained stabilization of nonlinear systems,” Automatica, vol. 96, pp. 359–367, 2018.DOI
  9. [9]P. Mestres, S. S. Mousavi, P. Ong, L. Yang, E. Das, J. W. Burdick, and A. D. Ames, “Explicit control barrier function-based safety filters and their resource-aware computation,” in IFAC World Congress, (Busan, South Korea), Aug. 2026. To appear.arxiv.org/abs/2512.10118
  10. [10]M. Krstić, I. Kanellakopoulos, and P. Kokotović, Nonlinear and Adaptive Control Design. New York: Wiley, 1995.
  11. [11]A. J. Taylor, P. Ong, T. G. Molnar, and A. D. Ames, “Safe backstepping with control barrier functions,” in IEEE Conf. on Decision and Control, (Cancún, Mexico), pp. 5775–5782, Dec. 2022.arxiv.org/abs/2204.00653
  12. [12]M. H. Cohen, P. Ong, and A. D. Ames, “Input-to-state safe backstepping: Robust safety-critical control with unmatched uncertainties,” in American Control Conference, (New Orleans, LA), pp. 551–558, May 2026.arxiv.org/abs/2602.03691
  13. [13]T. Gurriet, M. Mote, A. Singletary, P. Nilsson, E. Feron, and A. D. Ames, “A scalable safety critical control framework for nonlinear systems,” IEEE Access, vol. 8, pp. 187249–187275, 2020.
  14. [14]Z. Artstein, “Stabilization with relaxed controls,” Nonlinear Analysis, vol. 7, no. 11, pp. 1163–1173, 1983.DOI
  15. [15]P. Ong, B. Capelli, L. Sabattini, and J. Cortés, “Nonsmooth control barrier function design of continuous constraints for network connectivity maintenance,” Automatica, vol. 156, p. 111209, 2023.arxiv.org/abs/2112.05935
  16. [16]E. D. Sontag, “A universal construction of Artstein’s theorem on nonlinear stabilization,” Systems & Control Letters, vol. 13, no. 2, pp. 117–123, 1989.
  17. [17]Y. Lin and E. D. Sontag, “A universal formula for stabilization with bounded controls,” Systems & Control Letters, vol. 16, no. 6, pp. 393–397, 1991.DOI
  18. [18]Y. Lin and E. D. Sontag, “Control-Lyapunov universal formulas for restricted inputs,” Control-Theory and Advanced Technology, vol. 10, pp. 1981–2004, 1995.
  19. [19]M. Z. Romdlony and B. Jayawardhana, “Stabilization with guaranteed safety using control Lyapunov–barrier function,” Automatica, vol. 66, pp. 39–47, 2016.DOI
  20. [20]P. Braun and C. M. Kellett, “Comment on “Stabilization with guaranteed safety using control Lyapunov–barrier function”,” Automatica, vol. 122, p. 109225, 2020.
  21. [21]M. H. Cohen, P. Ong, G. Bahati, and A. D. Ames, “Characterizing smooth safety filters via the implicit function theorem,” IEEE Control Systems Letters, vol. 7, pp. 3890–3895, 2024.arxiv.org/abs/2309.12614
  22. [22]M. Li and Z. Sun, “A graphical interpretation and universal formula for safe stabilization,” in American Control Conference, pp. 3012–3017, 2023.DOI
  23. [23]M. Li, Z. Sun, P. J. W. Koelewijn, and S. Weiland, “A tunable universal formula for safety-critical control,” arXiv preprint arXiv:2403.06285, 2024.arxiv.org/abs/2403.06285
  24. [24]M. Krstic, “Inverse optimal safety filters,” IEEE Transactions on Automatic Control, vol. 69, no. 1, pp. 16–31, 2024.arxiv.org/abs/2112.08225
  25. [25]B. Wang and M. Krstic, “Universal formula families for safe stabilization of single-input nonlinear systems,” arXiv preprint arXiv:2603.22654, 2026.arxiv.org/abs/2603.22654
  26. [26]P. Mestres, J. Cortés, and E. D. Sontag, “Universal formulas for safe control and their neural network approximations,” Systems & Control Letters, vol. 215, p. 106480, 2026.
  27. [27]P. Ong and J. Cortés, “Universal formula for smooth safe stabilization,” in IEEE Conf. on Decision and Control, (Nice, France), pp. 2373–2378, Dec. 2024.
  28. [28]S. Prajna and A. Jadbabaie, “Safety verification of hybrid systems using barrier certificates,” in Hybrid Systems: Computation and Control, (Philadelphia, PA), pp. 477–492, Mar. 2004.DOI
  29. [29]S. Boyd and L. Vandenberghe, Convex Optimization. Cambridge, UK: Cambridge University Press, 2009.
  30. [30]H. Flanders, “Differentiation under the integral sign,” The American Mathematical Monthly, vol. 80, no. 6, pp. 615–627, 1973.DOI
  31. [31]J. Nocedal and S. Wright, Numerical optimization. Berlin, Heidelberg: Springer, 2006.
  32. [32]W. Rudin, Real and Complex Analysis. McGraw-Hill, 3 ed., 1987.
  33. [33]G. M. Tallis, “Plane truncation in normal populations,” Journal of the Royal Statistical Society. Series B (Methodological), vol. 27, no. 2, pp. 301–307, 1965.DOI
  34. [34]J. Zeng, B. Zhang, Z. Li, and K. Sreenath, “Safety-critical control using optimal-decay control barrier function with guaranteed point-wise feasibility,” in American Control Conference, pp. 3856–3863, 2021.arxiv.org/abs/2103.12375
  35. [35]P. Ong, M. H. Cohen, T. G. Molnar, and A. D. Ames, “On the properties of optimal-decay control barrier functions,” in IEEE Conf. on Decision and Control, (Rio De Janeiro, Brazil), pp. 7375–7382, Dec. 2025.arxiv.org/abs/2507.12717

Paper details

vlnc:W_mzd2wq6s
Version
v1 · latest
Published
Fresh — added to the Hub within the last 30 days
Added
License
CC BY 4.0
Usage

views · 3

downloads · 0

A view counts once per browser per day, a download each time the PDF is requested.

  • Mathematics

Not recorded for this paper

View statement
Looking for related papers…
Contents