{'fraction_non_alphanumeric': 0.038892333126679064, 'fraction_numerical': 0.008596817524281876, 'mean_word_length': 4.514129443938013, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 8, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Unmatched Control Barrier Functions: Certainty Equivalence Adaptive Safety

This work applies universal adaptive control to control barrier functions to achieve forward invariance of a safe set despite the presence of unmatched parametric uncertainties. The approach combines two ideas. The first is to construct a family of control barrier functions that ensures the system is safe for all possible models. The second is to use online parameter adaptation to methodically select a control barrier function and corresponding safety controller from the allowable set. While such a combination does not necessarily yield forward invariance without additional requirements on the barrier function, we show that such invariance can be established by simply adjusting the adaptation gain online. It is also shown that the developed method is applicable to systems with safety constraints that have a relative degree greater than one. This work thus represents the first adaptive safety approach that successfully employs the certainty equivalence principle for general state constraints without sacrificing safety guarantees.


Introduction
Safety-critical controllers rely on precise model knowledge to ensure forward invariance of a safe set. Although these controllers often possess some inherent robustness [1], techniques that guarantee safety while effectively compensating for model uncertainties with minimal conservatism have only recently been proposed. One such framework is based on the notion of adaptive safety; a paradigm that achieves forward invariance of a safe set using results from adaptive control and model estimation theory. The work by [2] introduced the adaptive control barrier function (aCBF)analogous to an adaptive control Lyapunov function in adaptive control [3] -and showed that subsets of a safe set were forward invariant when an aCBF was used to construct controllers. The conservatism of an aCBF was addressed by [4] through the so-called robust adaptive control barrier function (RaCBF). There are two key differences between an aCBF and RaCBF. Firstly, an RaCBF yields less conservative controllers as the system is allowed to approach the boundary of the safe set. Secondly, an RaCBF can be combined with model estimation to further reduce conservatism if monotonic reduction in the model uncertainty can be established. Due to its effectiveness and strong theoretical guarantees, the adaptive safety paradigm has seen several extensions by others in the controls and robotics communities (see, e.g., [5][6][7][8]).
A fundamental limitation of current adaptive safety approaches is the inability to employ the certainty equivalence principle when the barrier function depends on unknown model parameters. Model parameter dependency usually arises when either 1) the system possess unmatched model uncertainties, i.e., unknown dynamics outside the span of the arXiv:2207.13873v2 [eess.SY] 16 Aug 2022 control input matrix, or 2) the uncertainty enters through the control input matrix for systems with control constraints. The certainty equivalency principle is a design philosophy that entails constructing barrier functions as if the model were known. Then, the uncertain parameters can simply be replaced with their online estimates. This philosophy works seamlessly when the barrier function does not depend on unknown parameters. Conversely, it is very difficult to establish forward invariance of a parameter-dependent barrier function as sign-indefinite terms arise in the forward invariance proof. To cancel out the sign-indefinite terms, [2,4] construct a barrier function for a modified system that depends on its own (unknown) barrier function. Generating such a barrier function is generally no easier than dealing with the problematic terms directly.
The main contribution of this work is a stable adaptive safety algorithm which employs the certainty equivalence principle to achieve set invariance through online parameter adaptation. Unlike previous works, one just needs to construct a family of control barrier functions for all possible models -a much simpler procedure than that originally proposed by [2,4]. It is shown that a safe set can be made forward invariant with a novel direct adaptation law that systematically adjusts the adaptation gain online; a novel technique recently developed for adaptive control with unmatched uncertainties [9] that has also found uses in other areas of control, e.g., direct adaptive optimal control [10]. Furthermore, the direct adaptation law can be combined with model learning to improve parameter adaptation transients and reduce conservatism. The derived adaptation laws can also be used with safety constraints more than one derivative away from the input. As a result, this is the first work to successfully utilize the certainty equivalence principle in adaptive safety, and represents an important step towards safety-critical control of uncertain systems.
Notation: The set of positive and strictly-positive scalars will be denoted as R + and R >0 , respectively. The shorthand notation for a function T parameterized by a vector a with vector argument s will be T a (s) T (s; a). The partial differentiation with respect to variable x ∈ R n of function N (x, y) will be ∇ x N (x, y) = ∂N/∂x ∈ R n . The subscript for ∇ will be omitted when it is clear which variable the differentiation is with respect to. The Lie derivative of a scalar function h : R n → R with respect to a vector field f : R n → R n is L f h ∇h f .

Problem Formulation
Consider the uncertain nonlinear systemẋ with state x ∈ R n , control input u ∈ U ⊆ R m , known dynamics f : R n → R n , unknown parameters θ ∈ Θ ⊂ R p with known regressor ∆ : R n → R p×n , and known control input matrix g : R n → R n×m . In this work we derive an adaptive safety controller that ensures x(t) ∈ C for all time where C is a set of safe states. The following assumption is made on the unknown parameters θ.
Assumption 1. The unknown parameters θ belong to a known closed and bounded set Θ ⊂ R p .
An immediate consequence of Assumption 1 is that the parameter estimation errorθ θ − θ must also belong to a known closed and bounded set, i.e.,θ ∈Θ. Moreover, each element must then have a finite supremum wherẽ ϑ i sup θi∈Θθ i for i = 1, . . . , p. Note thatθ is equivalent to the maximum possible parameter estimation error.

Background: Adaptive Safety
The following definitions are stated for completeness, a more thorough treatment can be found in [11,12] and references therein. See [2,4] for the first works on adaptive safety.
Let the set C ⊂ R n be a 0-superlevel set of a continuously differentiable function h : R n → R where The following definitions assume the dynamics (1) are Lipschitz (at least locally) so that there exists a unique solution x(t) for t ≥ t 0 with initial condition x 0 x(t 0 ).
Definition 2. A system is safe with respect to set C if the set C is forward invariant.
Definition 3. A continuous function α : R → R is an extended class K ∞ function if it is strictly increasing, α(0) = 0, and is defined on the entire real line.
When model uncertainty is present, as is the case in (1), it is challenging or infeasible to derive a controller that renders a safe set forward invariant. Conceptually, adaptive safety is a framework that uses tools from adaptive control theory to systematically compute a safe controller via online parameter adaptation. Central to adaptive safety is the notion of model-parameterized safe sets C θ which are shown to be forward invariant with an aCBF [2] or RaCBF [4]. Due to the similarities between [4] and this work, only the core results from [4] are summarized below.
Definition 4 (Robust Adaptive Control Barrier Function [4]). Let C θ be a family of 0-superlevel sets parameterized by θ for a continuously differentiable function h r θ : R n × R p → R. The function h r θ (x) is a robust adaptive control barrier function (RaCBF) if there exists a controller u ∈ U and extended class K ∞ function α(·) such that for every where Λ θ (x) θ − γ∇ θ h r θ (x) and γ is an admissible adaptation gain.
Observe that an RaCBF is designed for a modified system that depends upon its own RaCBF via Λ θ (x). This is the main drawback of using an RaCBF (and an aCBF as the same modification is employed). Fundamentally, the modified dynamics are a byproduct of attempting to use the certainty equivalence principle with model-parameterized safe sets. It can be shown that the extra term is actually related to the adaptation law derived for an RaCBF [4]. Therefore, an RaCBF is constructed to account for parameter adaptation transients and hence represents a departure from the certainty equivalence principle design philosophy. In this work we will show that a true certainty equivalence adaptive safety framework is possible when the adaptation gain is adjusted online [9].
The main theorem from [4] is stated below and will serve as a useful comparison for results derived in Section 4.
θ } ⊆ Cθ then any locally Lipschitz continuous controller satisfying sup renders Cθ safe with the adaptation lawθ where γ is an admissible adaptation gain.

Overview
This section contains the main results of this work. First, it is shown that set invariance is achieved by combining the so-called unmatched control barrier function and direct adaptive control with online adaptation gain adjustment. Then, several modifications to the direct adaptive control algorithm that can improve transients and reduce conservatism are discussed. Finally, a unified adaptive safety tracking min-norm controller is presented.
The subsequent results will make use of a special class functions called scaling functions.

Definition 5 (Scaling Function).
A scaling function v : R → R satisfies the following conditions for ζ > 1 and

Direct Adaptive Safety
We will consider two safe sets defined by a continuously differentiable function h θ : Definition 6 (Unmatched Control Barrier Function). Let C θ be a family of 0-superlevel sets parameterized by θ for a continuously differentiable function h θ : R n × R p → R. The function h θ (x) is an unmatched control barrier function (uCBF) if there exists a controller u ∈ U and extended class K ∞ function α(·) such that for every θ ∈ Θ Remark 2. In addition to α(·) ∈ K ∞ , we require that cα(r) ≤ α(cr) for c ≥ 1. This property is not restrictive as it satisfied by many common choices for α(·) found in the literature.
Fundamentally, condition (5) states that there exists a controller that renders C θ invariant for every θ ∈ Θ. Or, put another way, the uncertain system (1) can be made safe for every θ ∈ Θ. This is analogous to an uncertain system being stabilizable for every θ ∈ Θ in the context of adaptive control, as discussed in [9]. Note that (5) is an invariance condition for C θ with the actual dynamics as opposed to the modified dynamics used in [2,4]. This distinction has both theoretical and practical implications. In particular, safety is now formulated as an inherent property of the system since the actual dynamics are being evaluated for safety. Moreover, in terms of constructing an uCBF, the safety condition (5) is much easier to verify as it preservers bilinearity of h θ (x) and u [12]. Conversely, the condition for an aCBF or RaCBF is nonconvex so systematically constructing either barrier function is more difficult.
The following theorem establishes forward invariance of a parameter-dependent safe set C θ when Definition 6 is combined with direct parameter adaption and online adjustment of the adaptation gain.
Theorem 2. Let Cθ be a 0-superlevel set of a continuously differentiable function hθ : θ } ⊆ Cθ then any locally Lipschitz continuous controller satisfying renders Cθ safe with the direct adaptation laẇ where γ is an admissible adaptation gain, v(ρ) is a scaling function, and η ∈ R >0 is a design parameter.
Proof. Consider the barrier-like function where η > 0. We will show that the adaptation law (7) yields hθ(t) ≥ 0 for all t which is equivalent to Cθ being forward invariant. Differentiating h(t) and applying (7) yieldṡ where the inequality arises from (6) and the property cα(r) ≤ α(cr) for c ≥ 1. Since |θ| ≤θ and v(ρ) ≥ 1 then ≥ 0 for all t. Therefore, the controller (6) and direct adaptation law (7) render the set Cθ forward invariant.
Remark 3. One notable modification to the adaptation law in (7) is the use of Bregman divergence to impose physical consistency [13,14] or sparsity [15,16] on the parameter estimates. See Definition 9 in the Appendix.
It is instructive to analyze the online gain adjustment mechanism to develop an intuition about how the technique achieves forward invariance. In the case of no gain adjustment, i.e.,ρ = 0, thenḣ(t) becomeṡ If ∇θhθ(x) θ ≥ 0 then safety is preserved as the same inequality used to prove Theorem 2 is obtained. However, if ∇θhθ(x) θ < 0 then safety might be compromised since this could lead to h(t) < 0 and subsequently hθ(x) < 0.
From (7), we see thatρ will be of opposite sign of ∇θhθ(x) θ . Hence, if the parameter adaptation transients is negative (unsafe), then ρ increases resulting in a larger effective adaptation gain γv(ρ). Conversely, if the transients is positive (safe) then ρ decreases yielding a smaller effective adaptation gain. In this scenario, one could also setρ = 0 without sacrificing safety. To summarize, the effective adaptation gain γv(ρ) will increase if the parameter adaptation transients compromises forward invariance of Cθ while γv(ρ) will decrease or remain constant if the parameter adaptation transients preserves safety. Note that the above analysis of adaptation gain adjustment is analogous to that in universal adaptive control [9] where the effective adaptation gain changes to achieve a stable closed-loop system.
Theorem 2 requires the adaptation gain γ be admissible in order to prove forward invariance of Cθ. The following corollary establishes a lower bound on γ thereby making it admissible.
The lower bound for the adaptation gain is identical to that obtained in [4] and similar to that in [2] (in the latter case the initial parameter estimation error had to be known). Essentially, (8) states that the closer hθ(x 0 ) is to ∂Cθ the faster the adaptation has to be in order to render Cθ invariant [2,4].
An interesting consequence of Theorem 2 is that the set C r θ = {x ∈ R n ,θ ∈ Θ : hθ(x) ≥ 1 2γθ θ } is input-to-state safe [17] with the proposed adaptive safety controller.
θ } is input-to-state safe (ISSf) with the controller and adaptation law in Theorem 2.
Proof. Follows immediately from the definition of ISSf which states that a set is ISSf if it is a subset of a forward invariant set. Since the controller and adaptation law render Cθ invariant, and C r θ ⊆ Cθ, then C r θ is ISSf. Remark 4. Future work will investigate strengthening Corollary 2 to show that the set C r θ is asymptotically stable, as is the case with a RaCBF (see Proposition 1 in Appendix).
Depending on the choice of v(ρ), one may need to modify (7) in order for ρ and v(ρ) to remain bounded. One possibility is to reset ρ once it exceeds a certain threshold. Even though u,θ, and hθ(x) remain continuous after a reset, a thorough analysis is required to ensure the closed-loop system remains safe despite the barrier-like function h(t) decreasing after the reset. Alternatively, one could add damping toρ, thereby bounding ρ but at the expense of rendering Cθ ISSf, as shown in the following corollary.
Corollary 3. Let Cθ be a 0-superlevel set of a continuously differentiable function hθ : R n × R p → R. If hθ(x) is an uCBF on C r θ {x ∈ R n ,θ ∈ Θ : hθ(x) ≥ 1 2γθ θ } ⊆ Cθ then any locally Lipschitz continuous controller satisfying renders Cθ input-to-state safe with the adaptation laẇ where and γ is an admissible adaptation gain, v(ρ) is a scaling function, and η, σ ∈ R >0 are design parameters.
Proof. We must first establish that ρ is bounded from above and non-negative before showing Cθ is ISSf. Let dθ(x, ρ) σ v(ρ)
Remark 5. A convenient byproduct of adding damping toρ is that it naturally restores ρ to zero when the adaptation transients does not negatively impact safety. If one designs v(ρ) so that v(0) = 1 then the effective gain γv(ρ) also returns to its nominal value γ without compromising safety.
Remark 6. The proposed modification to the ρ dynamics is similar to the σ−modification [18,19] and e-modification [20] used in adaptive control to improve robustness and transients. Despite their similarities, this type of modification for online adjustment of the adaptation gain is quite novel. Moreover, as discussed in Remark 5, it is beneficial for ρ → 0 which is considered a detrimental behavior for the parameter estimates as they unlearn the values that yielded small tracking error [20].

Composite Adaptive Safety
The direct adaptive safety controller in Theorem 2 guarantees the safe set defined by C θ is forward invariant for all possible models. Better parameter adaptation transients can be obtained by combining (7) with a model estimator.
There are a plethora of suitable model estimators that can be used with (7). One example of an effective and simple estimator is the state predictor.
An important property of the state predictor is that it εθ can be written as εθ = ∆(x) θ . If the state velocities are not directly available, one can use a filtered velocity generated by a first order filter; see [10] for details. The following theorem shows that set invariance is still maintained with the state predictor and direct adaptation law (7). Theorem 3. Let Cθ be a 0-superlevel set of a continuously differentiable function hθ : R n × R p → R. If hθ(x) is an uCBF on C r θ {x ∈ R n ,θ ∈ Θ : hθ(x) ≥ 1 2γθ θ } ⊆ Cθ then any locally Lipschitz continuous controller satisfying renders Cθ safe with the composite adaptation laẇ where γ is an admissible adaptation gain, v(ρ) is scaling function, β ∈ R >0 is the model estimation gain, εθ is the state predictor, and η ∈ R >0 is a design parameter.

Data-Driven Safety
One of the key ideas discussed in [4] is the benefit of using a history of data, i.e., life-long model estimation, to reduce the conservatism of adaptive safety controllers. Conceptually, the controller in (5) is trying to render the tightened set C r θ -not the actual safe set Cθ -invariant leading to conservatism. Reducing the parameter estimation error boundsθ via least squares, set membership identification, concurrent learning, Bayesian estimation, etc. can significantly improve the performance of the closed-loop system since C r θ → Cθ asθ → 0. We will show the benefits of life-long model estimation is also applicable to the uCBF adaptive safety framework. First, we establish a useful lemma. Lemma 1. Let C σ θ be a σ-superlevel set for a continuously differentiable function h θ : is an uCBF on C σ θ then it is also an uCBF on C θ ⊇ C σ θ where C θ is the 0-superlevel set of h θ (x).

Safe Tracking Control
An unmatched CBF can be immediately combined with an unmatched CLF [9] for safe stabilizing controller κ : R n × R p × R p → U that depends on parameter estimatesφ andθ computed for tracking and safety, respectively. The pointwise min-norm controller can be compute by solving the well-known quadratic program κ x,φ,θ = arg min Note any of the modifications stated previously can be applied to both the tracking and safety adaptation laws. One could also formulate a quadratic program for a system that already has a well-designed tracking controller [12].

Extension: Adaptive Safety with High Relative Degree Constraints
The unmatched control barrier function presented in Definition 6 can be extended to safety constraints that are more than one derivative away from the input, i.e., those with a relative degree greater than one. Several works have addressed high relative degree constraints via input-output linearization with known system dynamics [21][22][23]. Recently, [8] extended [2,4] to high relative degree control barrier functions to uncertain systems, but only for those with uncertainties that satisfy the so-called matching condition. This section will show that the results in Section 4 also apply to model-dependent safety constraints with an arbitrary relative degree. Now let C θ be a family of 0-superlevel sets parameterized by θ for a continuously differentiable function h θ : R n ×R p → R which has a well-defined relative degree of r b . Using the shorthand notation The input-output dynamics were obtained by treating θ as if it were known in accordance to the certainty equivalence design philosophy. Conversely, if θ were treated as unknown and replaced byθ then higher order derivatives ofθ would appear in h θ (x) making the design of an adaptive safety controller substantially more difficult.
Existing works [21][22][23] use pole placement to stabilize the input-output dynamics yielding forward invariance for known systems. The work by [8] uses the pole placement approach developed in [22] for systems with matched uncertainties. We instead employ a sliding variable s θ (x) h , which can be viewed as an input into contracting [24] dynamics φ : R × · · · × R → R. The sliding variable approach can be viewed as a generalization of the pole placement technique as the contracting dynamics can be designed to have eigenvalues that are a function of h θ (x), i.e., λ = λ(h θ (x)), which can improve time response characteristics. Examples of suitable sliding variables for r b = 2 are s θ =ḣ θ (x) + λ 1 h θ (x) and s θ =ḣ θ (x) where the latter has a state-dependent eigenvalue λ 1 + λ 2 |h θ (x)| q .
Definition 8 (High-Order Unmatched Control Barrier Function). Let C θ be a family of 0-superlevel sets parameterized by θ for a continuously differentiable function h θ : R n × R p → R which has a relative degree of r b . Additionally, let s θ (x) = h ) be the input to contracting dynamics given by φ : R × · · · × R → R.
The function h θ (x) is a high-order unmatched control barrier function (HOuCBF) if there exists a controller u ∈ U and extended class K ∞ function α(·) such that for every θ ∈ Θ Fundamentally, Definition 8 states there exists a controller u and extended class K ∞ function α(·) such that s θ (x(t)) ≥ 0 uniformly. The implication s θ (x(t)) ≥ 0 =⇒ h θ (x(t)) ≥ 0 for all t ≥ 0 can be established by requiring h θ (x 0 ) ∈ C i θ for i = 0, . . . , r b − 1 where C i θ depends on the choice of contracting dynamics φ(·). For example, if φ(·) has the repeated (constant) eigenvalue λ then C î The following theorem shows a safe set with a high relative degree can be rendered forward invariant using an HOuCBF and direct adaptive control.

Concluding Remarks
A new adaptive safety framework was presented that permits the use of the certainty equivalence principle for systematic online selection of a controller that renders a safe set forward invariant despite the presence of unmatched parametric uncertainties. The safe combination of policy selection and direct parameter adaptation was achieved by online adjustment of the adaptation gain (inspired by [9]). The ability to employ the certainty equivalence principle significantly reduces the complexities associated with existing adaptive safety approaches without sacrificing strong theoretical guarantees. Several modifications that build upon the developed direct adaptation law were shown to also guarantee forward invariance. Numerous avenues for future work are of interest, many of which center around experimental verification and practical modifications for real-world deployment. Investigating the viability of datadriven or learning-based techniques to systematically synthesize a family of barrier functions is also of interest. While the certainty equivalence principle allows for parallelization of this process, there are several fundamental questions on scalability, certifiability, and generalizability when generating barrier (and Lyapunov) functions for uncertain high-dimensional systems.

Appendix
Definition 9 (Bregman Divergence). Let ψ(·) be a strictly convex, continuously differentiable function on a closed convex set. The Bregman divergence associated with ψ(·) is given by