Boolean-Based Control Barrier Functions
- Boolean-based CBFs are techniques that encode complex safety specifications by composing primitive state constraints using Boolean operations like min, max, and negation.
- They tackle challenges such as nonsmoothness, feasibility, and scalability by employing methods including smoothing approximations, dual-number arithmetic, and mixed-integer formulations.
- These methods are applied in diverse areas such as autonomous vehicle lane keeping, multi-agent collision avoidance, and stochastic model-predictive control to ensure robust safety.
Boolean-based control barrier functions are control barrier function (CBF) constructions in which complex safety specifications are encoded as Boolean compositions of primitive state constraints. In this setting, each primitive safe set is typically written as , conjunctions are represented by intersections or pointwise minima, disjunctions by unions or pointwise maxima, and negation by sign reversal. The resulting composite safe set may be enforced through a single scalar barrier, a collection of simultaneous barrier inequalities, a piecewise-defined nonsmooth barrier, a mixed-integer formulation, or a matrix inequality. Across the literature, the principal technical issue is that exact Boolean composition is natural at the level of sets but often introduces nonsmoothness, feasibility problems, switching, or combinatorial growth in the online safety filter (Molnar et al., 2023, Vahs et al., 2023, Ong et al., 15 Aug 2025, Ong et al., 12 Sep 2025).
1. Logical encoding of safety sets
In the standard continuous-time control-affine setting,
a safe set is represented as
For multiple primitive sets , Boolean set operations are encoded directly at the barrier level. Identity can be represented by for any class- ; negation is represented by ; union is represented by ; and intersection is represented by . Arbitrary Boolean safety specifications can therefore be built from repeated applications of negation, 0, 1, and optional scaling by class-2 functions (Molnar et al., 2023).
The same semantic correspondence appears in discrete-time and logic-driven formulations. In discrete time, the safe set is again written as 3, but Boolean operators are encoded in mixed-integer form: negation by 4, conjunction by requiring 5 for all 6, disjunction by binary variables, slack variables, and SOS-1 constraints, and implication or if-then-else rules by reducing them to disjunctions. This framework was used to represent piecewise barrier functions and switched-mode safety conditions (Cavorsi et al., 2020).
The logic-to-barrier correspondence also underlies temporal-logic control. In a barrier-based treatment of a restricted fragment 7, each atomic proposition 8 is assigned a barrier function 9 with
0
while negation is represented by 1. Conjunction and disjunction of propositions then become intersections and unions of barrier-defined sets, and the temporal operators 2 are reduced to invariance, finite-time reachability, recurrence, and persistence subproblems solved through barrier-constrained quadratic programs (Srinivasan et al., 2019).
This logical encoding is the conceptual core of Boolean-based CBFs: safety specifications are written as formulas over primitive predicates, then realized as barrier superlevel sets that can be inserted into optimization-based controllers.
2. Exact Boolean composition and nonsmooth barriers
Exact Boolean composition is set-theoretically natural, but it produces nonsmooth composite barriers. For example,
3
is locally Lipschitz but not differentiable at points where multiple constraints tie for the minimum. At such points, the classical Lie derivative 4 is undefined, so the standard smooth CBF condition cannot be applied directly. A deterministic nonsmooth formulation addresses this by using the Clarke generalized gradient
5
and the nonsmooth CBF condition
6
For a minimum of smooth functions, Clarke’s result yields
7
where 8 is the active set. The same work emphasizes that selecting one Clarke vertex gives a valid nonsmooth directional derivative but is not by itself enough to guarantee forward invariance at corners; the counterexample 9 at 0 shows that enforcing only one active constraint can leave another boundary unconstrained (Kamaldar, 24 Jun 2026).
A stochastic formulation reaches the same nonsmoothness issue from a different direction. There the safe set is written as
1
but 2 may be a nested composition of 3 and 4. Conjunctions correspond to intersections and minima; disjunctions correspond to unions and maxima. A representative example is
5
To handle the nonsmooth switching surfaces, the state space is partitioned into finitely many regions 6, with 7 on each region and 8 on shared boundaries. Under non-degenerate diffusion, the process almost surely does not remain on a partition boundary over a finite interval, so the analysis can proceed regionwise without generalized gradients. This yields partition-wise stochastic barrier conditions and an almost-sure forward invariance result for the full nonsmooth Boolean safe set (Vahs et al., 2023).
These exact nonsmooth formulations preserve the intended logical safe set. The technical cost is the need for Clarke-subgradient arguments, partition-wise reasoning, or simultaneous enforcement of multiple active branches.
3. Smooth Boolean composition
A different design choice is to smooth the Boolean composition itself and recover a continuously differentiable barrier that can be used in standard single-constraint CBF-QPs. For unions, one smooth approximation is
9
which over-approximates 0 and satisfies
1
For intersections, the corresponding approximation is
2
which under-approximates 3 and satisfies
4
These constructions extend recursively to nested Boolean formulas through exponentiated quantities 5, and the resulting composed 6 can be shifted by a buffer 7 so that the smooth safe set lies inside or contains the exact Boolean set. As 8, the approximation converges to the exact 9 composition (Molnar et al., 2023).
The same paper derives closed-form recursive derivatives for the composed function and uses the resulting single smooth 0 in a standard safety filter,
1
This converts a nested Boolean safety specification into one continuously differentiable barrier and one CBF inequality, rather than a set of potentially incompatible pointwise constraints (Molnar et al., 2023).
Under noisy inputs, smoothing has also been used in stochastic multi-agent control. There, a Boolean-composed ensemble barrier 2 is replaced by a piecewise polynomial smoothing 3 obtained from a polynomial approximation 4 of the discontinuous switching function 5. The resulting controller is synthesized through a stochastic quadratic program or stochastic model-predictive control problem with a chance-constrained CBF inequality. The same study contrasts the polynomial approximation with log-sum-exp smoothing, stating that the polynomial smoothing is “more conservative but safer,” “less sensitive” to the smoothing parameter, and gives “more conservative control actions.” For the chosen polynomial smoothing with 6, it reports
7
and the proposed method maintained safety in all 100 simulation runs (Enwerem et al., 2023).
Smooth Boolean composition therefore trades exactness at the barrier level for differentiability and conventional optimization. The literature treats that trade-off explicitly: smoothing can enable continuous control laws, but it can also enlarge, shrink, or otherwise distort the exact logical safe set.
4. Feasibility, compatibility, and safety-filter design
Boolean composition is not only a representational issue; it is also a feasibility issue. If multiple barrier inequalities are enforced directly,
8
the quadratic program may be infeasible even if each individual barrier condition is feasible. A necessary and sufficient feasibility condition is
9
and this condition motivates the construction of a single composed CBF rather than a direct multi-constraint formulation (Molnar et al., 2023).
A separate line of work studies this issue as compatibility. For input-constrained systems
0
with safe set
1
the feasible input set is
2
The CBFs are compatible if 3 for all 4 in the region of interest, and robustly compatible with robustness level 5 if the inequalities hold with a uniform margin 6. An offline algorithm based on grid sampling and refinement checks compatibility by solving a local margin problem,
7
then expanding certified neighborhoods through Lipschitz bounds and refining uncertain cubes. If the algorithm terminates, it gives the correct answer; under robust compatibility and bounded 8, it terminates in finite steps (Tan et al., 2022).
Feasibility can also be improved by altering how multiple logical requirements are enforced. In the temporal-logic framework, multiple reachability requirements are not always imposed as separate finite-time barrier constraints. Instead, a composed finite-time barrier inequality on a weighted sum enlarges the feasible control set relative to the separate-constraint formulation, while zeroing CBFs can be relaxed by weighted slack variables to prioritize safety clauses. The same work is explicit that exact temporal-logic satisfaction is guaranteed only when the QP controller remains feasible; if slack variables become nonzero, the formal satisfaction theorem no longer strictly applies (Srinivasan et al., 2019).
Taken together, these results make a recurrent point: Boolean structure can be encoded cleanly at the level of sets, but the online safety filter must still confront actuator bounds, simultaneous barrier satisfaction, and the geometry of the admissible control set.
5. Deterministic, matrix-valued, and combinatorial formulations
A deterministic nonsmooth approach based on dual numbers addresses real-time execution directly. For
9
the system state and vector field are embedded in the dual-number ring
0
For a multivariable barrier 1 and direction 2,
3
One forward pass through the original arithmetic program computing 4 then returns both the barrier value and its exact directional derivative. In a composite minimum, floating-point comparison deterministically selects the first minimizer in a fixed left-to-right order,
5
and the selected gradient is a valid Clarke subgradient. To guarantee forward invariance, however, the controller still enforces all 6-active constraints in a QP. The paper states that if evaluating 7 costs 8 elementary operations, then evaluating 9 costs at most 0 real operations, independent of state dimension 1, number of constraints 2, active-set size, and local geometry of the boundary (Kamaldar, 24 Jun 2026).
Matrix control barrier functions replace scalar barriers by symmetric matrix functions 3. In the semidefinite case,
4
which reduces to conjunction when 5 is diagonal. In the indefinite case,
6
which naturally encodes disjunctions. With diagonal entries 7, the safe set becomes
8
so Boolean OR is represented directly by a single matrix inequality rather than a soft-max approximation or an active-constraint switch. The associated safety filter is posed as an SDP minimizing deviation from a nominal controller subject to a matrix inequality, and the paper proves continuity of the resulting CBF-SDP on a neighborhood of the safe set (Ong et al., 15 Aug 2025).
A further generalization treats Boolean and combinatorial specifications through order statistics. Given primitive barriers 9, the 0-choose-1 safe set is encoded by the pivot
2
so that 3 recovers AND and 4 recovers OR. The combinatorial CBF condition is imposed on every primitive barrier,
5
The corresponding CBF-QP uses exactly 6 barrier inequalities rather than enumerating all valid Boolean combinations. In a multi-agent patrolling example, the paper reports that the exact logical condition was enforced using 7 primitive constraints, whereas naive Boolean enumeration would require 5448 combinations (Ong et al., 12 Sep 2025).
These formulations all preserve exact logical safe sets, but they do so in different ways: deterministic arithmetic over dual numbers, matrix inequalities over eigenvalues, or order-statistic pivots over primitive barriers.
6. Applications, adjacent methods, and recurring limitations
Boolean-based CBFs have been used in a wide range of applications. In discrete time, mixed-integer formulations were applied to lane keeping and obstacle avoidance. Lane-keeping uses a partially control-affine vehicle model and a piecewise discrete-time barrier, while obstacle avoidance is written as an OR between left and right lane-following modes,
8
yielding an MIQP that effectively decides whether the car passes the obstacle on the left or the right (Cavorsi et al., 2020).
In stochastic continuous time, a single agent has been studied under the Boolean specification
9
and a multi-agent example enforces
00
through a global minimum-distance barrier. The reported simulations show that the non-smooth stochastic CBF controller keeps all trajectories safe almost surely and that an almost-active set with 01 significantly reduces chattering in the control signals (Vahs et al., 2023).
Under noisy inputs, Boolean-composed barriers have been embedded into stochastic MPC for collective control of single-integrator agents with inter-agent collision avoidance and obstacle avoidance. The reported comparison is against an LSE-smoothed controller and a naive state-feedback controller without safety filtering; the proposed polynomial-smoothed Boolean-CBF plus stochastic QP controller successfully drives agents to goals while avoiding obstacles and collisions (Enwerem et al., 2023).
Two adjacent areas broaden the scope of Boolean-based CBF analysis. One concerns systems with multiple control inputs and higher relative degree. Although not formulated as Boolean-based CBFs directly, the introduction of a “relative degree set,” the integral HOCBF construction, and the constraint-transformation method are explicitly described as useful building blocks for Boolean-Based Control Barrier Function formulations, especially when different logical clauses correspond to different geometry or actuation pathways (Xiao et al., 2022). The other concerns formal verification and synthesis for polynomial systems. There, CBF validity is reduced to the non-existence of solutions to polynomial equations and then certified by Positivstellensatz and sum-of-squares constraints; the framework also treats multiple CBF constraints through intersections and notes a natural connection to Boolean-style safety reasoning via unions and intersections of certified invariant sets (Clark, 2021).
Several recurring limitations are explicit in the literature. Exact 02 composition creates nonsmooth boundaries where standard Lie derivatives fail (Kamaldar, 24 Jun 2026). Smoothing restores differentiability but can conservatively alter the safe set (Molnar et al., 2023, Enwerem et al., 2023). Direct multi-CBF QPs may be infeasible even when individual barrier conditions are feasible (Molnar et al., 2023, Tan et al., 2022). Temporal-logic guarantees depend on QP feasibility, and slack-based prioritization can improve feasibility only by allowing safety propositions to be violated when the slack is nonzero (Srinivasan et al., 2019). A plausible implication is that Boolean-based CBF design is governed less by a single preferred formalism than by a choice among exactness, continuity, scalability, and certifiability, each emphasized by a different branch of the literature.