## I Introduction

Deploying autonomous and versatile robots into the real world comes with the challenge of ever increasing complexity in sensing, decision making, and actuation. One difficulty in designing controllers for such complex systems lies in the need to simultaneously meet a large set of design requirements. Achieving stable and safe behavior is often in conflict with performance objectives, and finding the right balance between these requirements can be a challenging task.

A disjoint, hierarchical approach is typically taken in this context. High-level trajectories are planned to satisfy performance objectives via computationally intensive nonlinear optimization, and local feedback controllers are separately designed to ensure stability. The goal of this paper is to directly integrate these two components by constructing controllers that simultaneously optimize performance along a horizon and satisfy local stability constraints in a computationally efficient manner. In particular, we seek to unify guarantee-based methods of nonlinear control with the optimization-based view in model predictive control. To this end, we combine the guarantees endowed by Control Lyapunov Functions (CLFs) [4, 43] with the optimal performance of Nonlinear Model Predictive Control (NMPC) [6, 29, 40].

Lyapunov methods are a powerful tool for certifying stability properties of nonlinear systems [21]. The use of Control Lyapunov Functions to synthesize stabilizing controllers for robotic platforms has become increasingly popular [11, 26, 36], often via quadratic programs (QPs) [1, 2]. Despite the optimization-based formulation of these controllers, they often fail to achieve long-term optimal behavior. This deficiency arises due to the fact that the cost of these optimization problems fails to incorporate the future behavior of the system, but is instead point-wise optimal [10].

In contrast, Nonlinear Model Predictive Control (NMPC) emphasizes performance by solving a finite horizon optimal control problem online and applying the first element of the computed open-loop input trajectory to the system [40]. This optimization is repeatedly solved with each newly measured state to obtain the next control input trajectory. While this class of control laws can achieve strong performance in practice [12, 39, 14], and allows intuitive specification of the desired behaviour, additional assumptions must be met to certify closed-loop stability. In classical discrete-time NMPC, stability is guaranteed by an appropriately designed terminal penalty and terminal constraint [29, 7, 14].

The integration of Lyapunov methods with NMPC is not a new idea. Lyapunov methods have been used to construct stabilizing terminal conditions [19], or to analyze stability in the absence thereof [18]. Another approach incorporates the stability condition required by a CLF along the prediction horizon found with NMPC [38, 48]. As noted in [38], this approach has several desirable properties such as the absence of a terminal cost, stability for any horizon length, and recovery of the CLF-QP [1] or infinite horizon optimal controllers when considering the limiting behavior of the finite horizon. The idea of imposing stability constraints along the horizon has appeared in other forms such as contractive state constraints [8], and has been applied within the context of chemical process control [27, 47], economic cost functions [16], and switched nonlinear systems [30].

While this existing work has analyzed the stability and optimality properties obtained through the unification of CLFs and NMPC, there has been little attention to the practical and computational aspects of the resulting nonlinear optimization problem. Limited computational resources and fast system dynamics present a challenge to the deployment of these unified methods to modern robotic systems. Indeed, to the best of our knowledge, such a control scheme has not yet been applied to robotic systems experimentally.

To achieve the goal of experimental realizability, we develop a new methodology for combining CLFs with NMPC. We describe practical methods to efficiently solve the resulting nonlinear optimization problems and ultimately realize the proposed controllers in simulation and, for the first time, experimentally on a robotic platform; in this case, a Segway hardware platform seen in Fig. 1. While each proposed method provides theoretical stability guarantees, significant differences in computational efficiency and performance are observed. Furthermore, we find that the pairing of these control methodologies leads to improved performance over CLF methods and significantly reduced tuning of prediction horizon length and terminal conditions for NMPC methods.

Our paper is organized as follows. Section II provides a review of CLFs and the stability guarantees they yield, and reviews the NMPC problem and how it is solved in practice. In Section III we propose a set of methods for incorporating CLF stability constraints into the NMPC problem, and provide additional details on implementation. Lastly, in Section IV we provide results from both simulation and hardware that demonstrate the ability of this unified control approach to achieve stability and improve performance.

## Ii Background

In this section we provide background information on Control Lyapunov Functions (CLFs) and Nonlinear Model Predictive Control (NMPC). This information supports the specific framework unifying CLFs and NMPC in Section III.

### Ii-a Control Lyapunov Functions

Consider a state space and a control input space , where it is assumed is path-connected and . Consider the control-affine dynamic system given by:

(1) |

where , , and and are Lipschitz continuous on . Further assume that , or that the origin is an equilibrium point of the system. As in [21], we define a class function as a continuous function , with , and strictly monotonically increasing (denoted ). If and , then is said to be a class function (). This type of function can be interpreted as a type of nonlinear gain function, noting the linear gain function with satisfies this definition. Given this definition, we define Control Lyapunov Functions (CLFs) as in [4, 25].

###### Definition 1 (Control Lyapunov Functions).

A continuously differentiable function is a Control Lyapunov Function (CLF) for (1) on if there exists such that for all :

(2) | ||||

(3) |

This definition can be restated with with resulting stability guarantees holding locally. The existence of a CLF for (1) implies the existence of a continuous (except possibly at ) state-feedback controller that renders the origin globally asymptotically stable [4, 44]. It is possible to make continuous at if satisfies the small-control property [43]. If the functions take the form , , the resulting stability is global exponential stability, with the magnitude of the state upper bounded by a function exponentially decaying in time:

(4) |

with . Similarly, the CLF can be upper bounded:

(5) |

This preceding bound will be useful for enforcing Lyapunov stability guarantees within the discrete time NMPC problem.

The CLF definition implies the existence of a point-wise set of stabilizing control inputs:

(6) |

Thus a CLF characterizes a stabilizing feedback controller as a controller such that for all . Furthermore, upon selection of such a controller, the CLF is a certificate of stability for the closed loop system:

(7) |

Establishing that a given function serves as a CLF for (1) is often done for robotic systems constructively by specifying a controller taking values in for all [46, 22]. Note that for any the set is described by an affine inequality in due to the affine nature of the dynamics:

(8) |

Due to this, the CLF itself may then be used to synthesize a optimization-based controller with more desirable properties using quadratic programs [1, 2, 11]. Specifically, we obtain a feedback control law that satisfies the inequality (3):

(9) | ||||

where is positive definite and assumed to be a polytope. Feasibility of this optimization problem is guaranteed by the satisfaction of the constraint (3) and Lipschitz continuity of this controller has been studied in [32, 20].

This controller is point-wise optimal [10], and takes a greedy approach to specifying control inputs. This often leads to poor performance compared to even non-optimization based controllers as there is no consideration of the future behavior of the system when the input is chosen. In addition to challenges in achieving longer horizon optimality, these controllers face difficulty in implementation on robotic platforms. The stability guarantees endowed by these controllers assume a continuous-time implementation, which is not possible on many modern digital control systems. Instead, control inputs are chosen and held for a small interval of time in a zero-order-hold manner. Lyapunov stability of zero-order-hold systems has been studied utilizing an approximate discretization of the nonlinear dynamics [35, 34], or in the context of model predictive control [15, 33, 31, 13].

### Ii-B Nonlinear Model Predictive Control

Nonlinear Model Predictive Control (NMPC) offers an alternative to CLF-based methods for controlling nonlinear systems, and is inherently designed to resolve the challenges of longer horizon optimality at the expensive of higher online computational cost.

We consider a direct NMPC approach to transform the continuous optimal control problem into a finite dimensional nonlinear program (NLP) [6]. The continuous control signal is parameterized over subintervals of the prediction horizon to obtain a finite dimensional decision problem. This creates a fixed grid of nodes defining control times separated by intervals of duration . In this work, we consider a piecewise constant, or zero-order-hold, parameterization of the input. Denoting and integrating the continuous dynamics in (1) over an interval leads to a discrete time representation of the dynamics:

(10) |

The integral in (10) is numerically approximated with an integration method of choice to achieve a desired approximation accuracy of the evolution of the continuous time system under the zero-order-hold commands.

The general NMPC problem presented below can be formulated by defining and evaluating a cost function and constraints on the grid of nodes. Here, we write the problem in parametric form, depending on the current measured state and additional parameters contained in , and with a subset of the constraints implemented as soft-constraints with slack terms:

(11a) | ||||||

(11b) | ||||||

(11c) | ||||||

(11d) | ||||||

(11e) | ||||||

(11f) |

where , , and are the sequences of state, input, and slack variables respectively. The nonlinear cost and constraint functions , , , and , are allowed to vary depending on the node index and are dependent on problem specific parameters and the current measured state . The slack variables are penalized with , an exact penalty [42]

. Collecting all decision variables into a vector,

, problem (11) can be framed as a general nonlinear program (NLP):(12) |

### Ii-C Sequential Quadratic Programming (SQP)

Interior-Point Methods (IP) and Sequential Quadratic Programming (SQP) are two popular families of algorithms for solving general NLPs [37]. Additionally, the sparsity of (12) induced by the underlying structure of (11) can be exploited to obtain solutions in real-time and at a high sampling rate, which is necessary in many dynamic robotic applications. An overview of recent advances in sparsity exploiting algorithms and software tools is provided in [23].

SQP approaches offer a distinct advantage in that successive problem instances may be warm-started with solutions from preceding instances. This serves to further decrease computation time as it is often only feasible to take a single SQP step per control iteration [24]. As NMPC computes optimal control inputs over a horizon, successive instances of (11) are similar and portions of the preceding optimal control sequence can be use to warm-start the following iteration, enabling convergence across multiple iterations of the problem, rather than iterating until convergence on one instance of the problem [9].

SQP based methods apply Newton-type iterations to KKT optimality conditions for (12), assuming some regularity conditions on the constraints [28]. The Lagrangian of the NLP in (12) is defined as:

(13) |

with Lagrange multipliers , and corresponding to equality and inequality constraints, respectively. The Newton iterations can be equivalently computed by solving the following potentially non-convex QP [37]:

(14a) | ||||

(14b) | ||||

(14c) |

where the decision variables, , define the update step relative to the current iteration , and the Hessian . Computing the solution to (14) provides a decision variable update, , and updated Lagrange multipliers and . These iterations are ran until the variables , , and converge. This iterative approach is summarized in Algorithm 1.

Convergence of the SQP algorithm leads to a state and input sequence, and , respectively. The first element of , denoted as , can be applied to the system, after which the SQP algorithm is run again to determine a new control input sequence. The application of SQP as a subroutine within a NMPC feedback controller is provided in Algorithm 2.

## Iii Unifying CLFs with NMPC

In this section we explore different ways of integrating the stability based CLF-QP and performance driven NMPC controllers discussed in Section II. These different methods will be evaluated experimentally in Section IV.

The NMPC framework presented in Algorithm 2 can be interpreted as a closed-loop feedback controller, . As described in Section II-A, for each state , a CLF defines a point-wise set of stabilizing control inputs given in (6). To inherit the stability guarantees provided by the CLF, we need to restrict the NMPC controller to these stabilizing inputs, such that for all .

As noted in [38], if only the first input in the input sequence is applied before the input sequence is recomputed, the restriction of the NMPC controller to stabilizing inputs can be achieved by directly imposing the CLF condition only on the first input, subject to the current measured state :

(15) |

As in the case of the controller (9), for a given state, this constraint is affine in the decision variable . Due to this, the SQP subroutine (14) contains the CLF constraint without approximation, and will therefore, in the same way as the CLF-QP, compute a stabilizing control input after solving just one QP. In the context of dynamic robotic platforms, this provides an advantage over general NMPC in that it does not require the computational cost of multiple Newton iterations to converge to a potentially stabilizing control input.

Beyond the constraint on the first input, any further modifications to the NMPC problem are done explicitly to increase performance or accommodate the discrete time implementation of control inputs. In the following, we will discuss additional constraints that serve to increase performance beyond that of the controller given by (9) while achieving stability.

### Iii-a Extended Horizon Constraints

While the preceding CLF constraint (15) enforces the selection of a stabilizing control input, the resulting theoretical stability properties rely on the controller being applied continuously in time, as noted in Section II-A. As this is not possible in practice, it desirable to incorporate additional stability constraints that enforce stable behavior when control is implemented in a zero-order-hold fashion. NMPC is an advantageous framework for these types of constraints as future states to reflect desired stability properties.

In particular, consider the bound in time on the Lyapunov function established with exponential stability in (5). While this bound is continuous in time, comparison principles [21] may be used to formulate an analogous discrete time bound at the th node:

(16) |

The constraints given by and can be combined in varying ways along the length of the prediction horizon. The basic approach, denoted CLF-0 and presented in (17a) to (17f), implements the constraint only at the initial node. This is extended in the CLF-All approach, where the constraint is enforced at each node in the horizon in (17g). These constraints are no longer affine since at nodes both state and input are decision variables, and are non-linearly coupled in (15).

In the approach denoted LLS-N, we enforce the constraint at the first node and enforce the constraint at only the final node in the prediction horizon in (17h). A similar bound, which relies on evaluating at the final node after the system has been simulated under a control law given by Sontag’s universal formula [44], is enforced in [38]. Our bound differs in that it is controller independent and only relies on the bound from exponential stability. Lastly, in the approach denoted LLS-All, the level set constraint is applied at each node in (17h), forming an exponentially contracting funnel along the horizon. Additionally, for all formulations, the inputs are bounded , enforcing .

CLF-NMPC:

(17a) | ||||||

(17b) | ||||||

(17c) | ||||||

(17d) | ||||||

(17e) | ||||||

(17f) | ||||||

(17g) | ||||||

(17h) | ||||||

(17i) |

### Iii-B Quadratic Approximation Strategy

When applying the SQP algorithm presented in Section II-B to the nonlinear formulations presented in (17), the quadratic subproblem (14) is repeatedly solved. As we seek to deploy NMPC on dynamic robotic platforms, it is critical that these optimization problems are well conditioned and do not provide difficulty to numerical solvers. In particular, when in (14a) is positive semi-definite (p.s.d), the resulting QP is convex and can be efficiently solved [23, 45].

To ensure this, an approximate (p.s.d) Hessian can be used instead of the full Hessian of the Lagrangian. For (17), the objective function has a least-squares form, i.e. , in which case the Gauss-Newton approximation,

(18) |

proves effective in practice [5, 17]. This neglects the curvature of , as well as the contribution by the curvature of the constraints. We use this strategy for the CLF-0 and CLF-All formulations.

For the LLS-N and LLS-All formulations, we retain the contribution of the LLS constraints in the Hessian approximation. The second term in (16) is independent of the decision variables, and the properties of this constraint are thus directly determined by the structure of the CLF . In particular, if the CLF used is convex (as is the case for many constructive techniques for producing CLFs [46, 22]), then the approximation

(19) |

remains positive definite, and, as we will show in Section IV-C, improves convergence compared to a Gauss-Newton approximation.

### Iii-C Baseline Comparisons

To understand how unifying these two control methodologies impacts performance and stability, it is necessary to compare against baseline controllers given by both (9) and (11). In particular, elements should be shared between controllers to limit the impact of tuning on performance. To this end, we begin by synthesizing a CLF using feedback-linearization based constructive techniques discussed in [46], which enables the consideration of underactuated systems.

Consider an output with relative degree 2 [41] and , a time-varying reference trajectory , and define the tracking error :

(20) |

A feedback-linearizing controller exists, that yields linear closed-loop error dynamics given by:

(21) |

where the eigenvalues of

have negative real part. For any positive definite , the Continuous Time Lyapunov Equation (CTLE):(22) |

has a positive definite solution . This enables the synthesis of a quadratic (and convex) Lyapunov function given by with time derivative , which is negative definite. Furthermore, the existence of the feedback linearizing controller implies that is a CLF, as:

(23) |

This CLF can be used in the following CLF-QP controller that achieves exponential stability with . The constraint is slacked for numerical conditioning with .

CLF-QP:

(24) | ||||

To synthesize a baseline NMPC- controller, elements from the construction of the CLF can be utilized. In particular, can be used as a running cost on the state, and the terminal value of the CLF can penalized as in [19]:

NMPC-:

(25a) | ||||||

(25b) | ||||||

(25c) | ||||||

(25d) |

That is, the CLF is used as a terminal cost and scaled up with the parameter . As noted in [40] if is selected large enough, stability can be achieved without the need to specify a terminal state constraint. The baseline NMPC problem has constraints on the initial condition and dynamic evolution given by (11b) and (11c), but does not include any CLF-based constraints. The inputs are also constrained such that .

## Iv Simulation & Experimental Results

In this section we provide details on the implementation of the methods established in Section III on a Segway platform, and discuss simulation and experimental results.

### Iv-a Segway System & Implementation

Dynamics simulations provide an environment for assessing attainable levels of performance of the various approaches. The simulated dynamics model reflects a modified Ninebot E+ Segway platform, seen in Fig. 1. We consider a planar representation of the Segway, with state where is the horizontal position and is the pitch angle. The input to the Segway, , is current to the Segway motors. The equations of motion are derived via the Newton-Euler equations for an asymmetric, two-wheeled inverted pendulum with torque input. The asymmetry of the system leads to an unforced equilibrium at with . In the NMPC controllers, a forward Euler time discretization is used with .

State estimation on the physical Segway is done with wheel encoders and IMU data from a VectorNav VN-100. All computations are performed on board on an ARM Cortex-A57 (quad-core) @ 2GHz CPU running the ERIKA3 RTOS. For each NMPC formulation, all functions, gradients, and Hessians in (

14) are found using the CasADi auto-differentiation framework [3]. This leads to a QP with a fixed sparsity pattern, which we solve with the sparsity-exploiting solver OSQP [45]. We solve a single QP per control iteration, unless otherwise stated.### Iv-B Simulation Results

To compare the behavior of the different control approaches, we considered a stabilization task. In particular, we simulated the system under each controller with a fixed initial condition and an objective of stabilizing to the unforced equilibrium point . The performance of each controller was quantified by the average input norm over a 2 second time horizon, which provides an assessment of the total input used. These averages appear in Table I.

N | 1 | 10 | 20 | 30 | 40 | 50 |
---|---|---|---|---|---|---|

CLF-QP | 1.085 | 1.085 | 1.085 | 1.085 | 1.085 | 1.085 |

CLF-0 | 1.085 | 1.085 | 1.085 | 1.085 | 1.085 | 1.085 |

CLF-All | 1.085 | 1.072 | 0.952 | 0.849 | 0.794 | 0.769 |

LLS-N | 1.083 | 0.957 | 0.889 | 0.842 | 0.808 | 0.784 |

LLS-All | 1.083 | 0.956 | 0.887 | 0.839 | 0.805 | 0.782 |

NMPC-0.1 | - | - | 3.232 | 2.435 | 2.036 | 1.783 |

NMPC-1 | - | 3.026 | 2.019 | 1.732 | 1.574 | 1.471 |

NMPC-10 | 0.828 | 0.607 | 0.704 | 0.823 | 0.926 | 1.006 |

We see that the CLF-QP and CLF-0 controllers select identical inputs over the entire trajectory and have the largest average input of any CLF-based controllers. This indicates that the addition of a prediction horizon to the baseline CLF-QP controller only improves its performance if the stability constraint is applied further along the horizon. We also see that with no horizon (), all of the CLF-based controllers recover similar performance to the baseline CLF-QP. If we consider the controllers that impose constraints further along the horizon we see that their average input consistently decreases with horizon length, with the CLF-All controller marginally outperforming the LLS controllers at the longest horizon lengths.

The performance of the baseline NMPC- controllers heavily depended on the weighting of the terminal cost. At shorter horizons the NMPC-0.1 and NMPC-1 controllers failed to stabilize the system, and saw improved performance as the horizon grew longer. In contrast, the NMPC-10 controller demonstrated the best performance of all controllers at shorter horizons, but saw worsening performance as the horizon grew longer. This illustrates the issues that arise when both stability and performance are achieved through the cost, rather than decoupled through constraints as in the CLF-based formulations.

To more clearly understand the possible behaviors of the various CLF-NMPC controllers, we visualize the solutions to each controller obtained at the initial condition, i.e. in Fig. 2. As the CLF-0 controller is only required to satisfy the stability constraint at the initial node, its input quickly drops to zero and the constraint is violated in the next step in the horizon. In contrast, the CLF-All controller meets the constraint along the entirety of the horizon as required. Despite meeting this constraint on at each node, the CLF-All controller slightly fails to meet the implied level-set bounds along the horizon. This is due to the fact that the constraint is checked only at the beginning of each interval and is not required to hold over the interval which the control input is held over.

The LLS controllers both satisfy the level constraints at the required points, with the LLS-N controller violating the level set bounds earlier in the horizon. Despite meeting these level set bounds and the required points, both controllers violate the associated bound on , with the LLS-All controller satisfying the constraint loosely early in the trajectory before satisfying it tightly at the end of the trajectory.

The evolution of the system under these controllers with a horizon length is captured in Fig. 3. We see that all CLF-based controllers satisfy the stability constraint (15) during the entire simulation. The most significant difference in the behavior of these controllers arises in the magnitude of the input taken early in the trajectory. The best performing controllers applying higher inputs earlier in the trajectory to stabilize the system quickly and avoid accruing input over more of the trajectory.

We additionally perform a simulation in the opposite direction, driving the Segway from its unforced equilibrium to a desired state, . The resulting trajectories are seen in Fig. 4. In this scenario we see that the CLF-QP controller demonstrates significantly different behavior from the CLF-NMPC controllers. In particular, the CLF-QP controller takes an initial input to drive the system towards the desired state, and then allows gravity to carry it to this point. This results in a large overshoot past the desired state, where as the CLF-NMPC controllers approach the equilibrium point more slowly.

The NMPC- controllers fail to converge to the desired state. This arises due to the fact that the cost on the input is not centered about the input that makes the desired state an equilibrium point, i.e. . Because both the input and the state error appear in the cost, larger error is accepted in the state to minimize the input. This highlights the flexibility in choosing the cost function in the CLF-NMPC formulations. General cost functions that do not necessarily obtain their minimum at the goal can be used, which opens up the possibility of using economic cost functions [16].

### Iv-C Numerical Results

To understand the feasibility of deploying these control approaches on the computationally limited Segway platform, we investigated the convergence rate of each formulation on a single instance of the NMPC problem. We also considered variants of the LLS formulations using the Gauss-Newton approximation in (18) (denoted and ) and compare them to using the modified Hessian in (19).

We execute Algorithm 1 for each formulation until the constraints are sufficiently satisfied, , and no further progress is made in cost, . The optimization is fully cold-started such that all decision variables and Lagrange multipliers are initialized to zero. The problem is set up with and a horizon length of . The step size, constraint satisfaction, and first order optimality are plotted in Fig. 5.

The CLF-0 and NMPC- formulations converge rapidly as they have a quadratic cost function and affine constraints. The only nonlinearity in these problems therefore arises from the system dynamics, making the QP subproblem a good model for the full problem. The CLF-All, LLS-N, and LLS-All have nonlinear constraints along the horizon, and therefore take significantly longer to converge. Nonetheless, the convergence rate accelerates over the last few iterations, indicating that these formulations can still perform well when starting close to the solution. Finally, the LLS-N, and LLS-All formulations initially decrease the constraint violation, but fail to make further progress after a certain point.

### Iv-D Experimental Results

In addition to simulation, we also demonstrate the ability of this unified control approach on the physical Segway in Fig. 1. In particular, we define a desired angular trajectory in time:

(26) |

where is a commanded velocity and is a velocity feedback gain, leading to error dynamics given by . These dynamics are used to synthesize a quadratic CLF as per Section III. This CLF was used to formulate a CLF-QP controller given by (24), a NMPC-1 and NMPC-10 controller with cost given by (25a), and CLF-All, LLS-N, and LLS-All controllers. Each controller was used to track the desired trajectory and then stabilize the system. The results of these experiments can be seen in Fig. 6. We see that all controllers except the NMPC-1 controller are able to stabilize the system. The CLF-QP displays aggressive behavior compared to the NMPC controllers as it does not incorporate a prediction horizon.

The average input and control frequency along the experimental horizon is seen in Table II. We see that at a horizon of the NMPC-10 controller has the best performance, with the NMPC-1 controller omitted due to failure to stabilize. Of the CLF-NMPC controllers the CLF-All controller has the best performance. We note that although the baseline NMPC-10 controller outperforms the proposed methods, this required tuning of the cost function and matches the behavior seen in simulation at this horizon length. We see that the CLF-NMPC methods have a higher computational cost than the NMPC-10 controller. This follows as the NLP has additional constraints related to stability that must be met. In that sense, LLS-N is an appealing approach among the CLF-NMPC methods, as it imposes only two stability constraints.

CLF-QP | CLF-All | LLS-N | LLS-All | NMPC-10 | |
---|---|---|---|---|---|

2.081 | 1.594 | 1.666 | 1.898 | 1.152 | |

1.25 | 5.56 | 4.17 | 6.13 | 3.11 |

## V Conclusion

In conclusion, we have presented a novel set of approaches for unifying CLFs and NMPC on robotic platforms with limited computational resources. The use of a SQP algorithm with modified Hessian was proposed to efficiently solve the resulting nonlinear optimization problem. The different unified formulations were analyzed in simulation, for the first time demonstrated on hardware, and were shown to improve performance beyond baseline CLF and NMPC methods. In particular for forced equilibria, the CLF-NMPC method converges without modifications while the cost-driven baseline NMPC does not. Furthermore, the unified methods all achieved stability where as the stability baseline NMPC methods was sensitive to cost function parameters. As system complexity increases, such manual tuning becomes increasingly difficult. In this space, we see an opportunity for the presented CLF-NMPC methods, where stability is explicitly embedded and requires no further tuning.

## Acknowledgments

R.Grandia and M. Hutter are supported via the European Union’s Horizon 2020 research and innovation programme under grant agreement No 780883. A. Taylor, A. Singletary, and A. Ames are supported via DARPA awards HR00111890035 and NNN12AA01C, and NSF awards 1923239 and 1924526.

## References

- [1] (2014) Rapidly exponentially stabilizing control lyapunov functions and hybrid zero dynamics. IEEE Transactions on Automatic Control 59 (4), pp. 876–891. Cited by: §I, §I, §II-A.
- [2] (2013) Towards the unification of locomotion and manipulation through control lyapunov functions and quadratic programs. In Control of Cyber-Physical Systems, pp. 219–240. Cited by: §I, §II-A.
- [3] (2019) CasADi – A software framework for nonlinear optimization and optimal control. Mathematical Programming Computation 11 (1), pp. 1–36. Cited by: §IV-A.
- [4] (1983) Stabilization with relaxed controls. Nonlinear Analysis: Theory, Methods & Applications 7 (11), pp. 1163–1173. Cited by: §I, §II-A, §II-A.
- [5] (1983) Recent advances in parameteridentification techniques for ode. In Numerical treatment of inverse problems in differential and integral equations, pp. 95–121. Cited by: §III-B.
- [6] (1984) A Multiple Shooting Algorithm for Direct Solution of Optimal Control Problems. IFAC Proceedings Volumes 17 (2), pp. 1603 – 1608. Cited by: §I, §II-B.
- [7] (1998) A Quasi-Infinite Horizon Nonlinear Model Predictive Control Scheme with Guaranteed Stability.. Automatica 34 (10), pp. 1205 – 1217. Cited by: §I.
- [8] (2000-06) Contractive model predictive control for constrained nonlinear systems. IEEE Transactions on Automatic Control 45 (6), pp. 1053–1071. Cited by: §I.
- [9] (2002) Real-time optimization and nonlinear model predictive control of processes governed by differential-algebraic equations. Journal of Process Control 12 (4), pp. 577 – 585. Cited by: §II-C.
- [10] (1996) Inverse optimality in robust stabilization. SIAM journal on control and optimization 34 (4), pp. 1365–1391. Cited by: §I, §II-A.
- [11] (2015) Torque saturation in bipedal robotic walking through control Lyapunov function-based quadratic programs. IEEE Access 3, pp. 323–332. Cited by: §I, §II-A.
- [12] (1989) Model predictive control: theory and practice—a survey. Automatica 25 (3), pp. 335–348. Cited by: §I.
- [13] (2007) Model Predictive Control for Nonlinear Sampled-Data Systems. In Assessment and Future Directions of Nonlinear Model Predictive Control, pp. 105–113. Cited by: §II-A.
- [14] (2017) Nonlinear model predictive control. In Nonlinear Model Predictive Control, pp. 45–69. Cited by: §I.
- [15] (2004) Stabilization of sampled-data nonlinear systems by receding horizon control via discrete-time approximations. Automatica 40 (12), pp. 2017 – 2028. Cited by: §II-A.
- [16] (2012) Economic model predictive control of nonlinear process systems using Lyapunov techniques. AIChE Journal 58 (3), pp. 855–870. Cited by: §I, §IV-B.
- [17] (2011) An auto-generated real-time iteration algorithm for nonlinear MPC in the microsecond range. Automatica 47 (10), pp. 2279–2285. Cited by: §III-B.
- [18] (2005-05) On the stability of receding horizon control with a general terminal cost. IEEE Transactions on Automatic Control 50 (5), pp. 674–678. Cited by: §I.
- [19] (2001-05) Unconstrained receding-horizon control of nonlinear systems. IEEE Transactions on Automatic Control 46 (5), pp. 776–783. Cited by: §I, §III-C.
- [20] (2018) Robust control barrier functions for constrained stabilization of nonlinear systems. Automatica 96, pp. 359–367. Cited by: §II-A.
- [21] (2002) Nonlinear Systems - 3rd Edition. PH, Upper Saddle River, NJ. Cited by: §I, §II-A, §III-A.
- [22] (2019) PD based Robust Quadratic Programs for Robotic Systems. In 2019 IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), pp. 6834–6841. Cited by: §II-A, §III-B.
- [23] (2018-12-01) Recent Advances in Quadratic Programming Algorithms for Nonlinear Model Predictive Control. Vietnam Journal of Mathematics 46 (4), pp. 863–882. Cited by: §II-C, §III-B.
- [24] (1989) A Multistep, Newton-Type Control Strategy for Constrained, Nonlinear Processes. In 1989 ACC, Vol. , pp. 1526–1527. Cited by: §II-C.
- [25] (1991) A universal formula for stabilization with bounded controls. Sys. & Control Letters 16 (6), pp. 393–397. Cited by: §II-A.
- [26] (2017) Bipedal robotic running with DURUS-2D: Bridging the gap between theory and experiment. In Proceedings of the 20th International Conference on Hybrid Systems: Computation and Control, pp. 265–274. Cited by: §I.
- [27] (2014) Constrained control Lyapunov function based model predictive control design. International Journal of Robust and Nonlinear Control 24 (2), pp. 374–388. Cited by: §I.
- [28] (1967) The Fritz John necessary optimality conditions in the presence of equality and inequality constraints. Journal of Mathematical Analysis and Applications 17 (1), pp. 37 – 47. Cited by: §II-C.
- [29] (2000) Constrained model predictive control: Stability and optimality. Automatica 36 (6), pp. 789 – 814. Cited by: §I, §I.
- [30] (2005) Predictive control of switched nonlinear systems with scheduled mode transitions. IEEE Transactions on Automatic Control 50 (11), pp. 1670–1680. Cited by: §I.
- [31] (2006) Stabilization of nonlinear systems with state and control constraints using Lyapunov-based predictive control. Systems & Control Letters 55 (8), pp. 650 – 659. Cited by: §II-A.
- [32] (2015) Continuity and smoothness properties of nonlinear optimization-based feedback controllers. In 2015 54th IEEE Conference on Decision and Control (CDC), pp. 151–158. Cited by: §II-A.
- [33] (2006) A receding horizon control approach to sampled-data implementation of continuous-time controllers. Systems & Control Letters 55 (8), pp. 660–672. Cited by: §II-A.
- [34] (2004) A framework for stabilization of nonlinear sampled-data systems based on their approximate discrete-time models. IEEE Transactions on Automatic Control 49 (7), pp. 1103–1122. Cited by: §II-A.
- [35] (1999) Formulas relating KL stability estimates of discrete-time and sampled-data nonlinear systems. Systems & Control Letters 38 (1), pp. 49 – 60. Cited by: §II-A.
- [36] (2015) Optimal Robust Control for Bipedal Robots through Control Lyapunov Function based Quadratic Programs.. In Robotics: Science and Systems, Cited by: §I.
- [37] (2006) Numerical Optimization. second edition, Springer, New York, NY, USA. Cited by: §II-C, §II-C.
- [38] (2000) A receding horizon generalization of pointwise min-norm controllers. IEEE Transactions on Automatic Control 45 (5), pp. 898–909. Cited by: §I, §III-A, §III.
- [39] (2003) A survey of industrial model predictive control technology. Control engineering practice 11 (7), pp. 733–764. Cited by: §I.
- [40] (2017) Model Predictive Control: Theory, Computation, and Design. 2nd Edition edition, Nob Hill. Cited by: §I, §I, §III-C.
- [41] (1999) Nonlinear Systems: Analysis, Stability and Control. Springer, NY. Cited by: §III-C.
- [42] (1999) Feasibility issues in linear model predictive control. AIChE Journal 45 (8), pp. 1649–1659. Cited by: §II-B.
- [43] (1989) A ‘universal’ construction of Artstein’s theorem on nonlinear stabilization. Systems & control letters 13 (2), pp. 117–123. Cited by: §I, §II-A.
- [44] (1989) Smooth stabilization implies coprime factorization. IEEE transactions on automatic control 34 (4), pp. 435–443. Cited by: §II-A, §III-A.
- [45] (2018) OSQP: An operator splitting solver for quadratic programs. In 2018 UKACC 12th International Conference on Control (CONTROL), pp. 339–339. Cited by: §III-B, §IV-A.
- [46] (2019) Episodic Learning with Control Lyapunov Functions for Uncertain Robotic Systems. arXiv preprint arXiv:1903.01577. Cited by: §II-A, §III-B, §III-C.
- [47] (2018) Control Lyapunov-Barrier Function-Based Model Predictive Control of Nonlinear Systems. In 2018 Annual American Control Conference (ACC), Vol. , pp. 5920–5926. Cited by: §I.
- [48] (2001) Comparison of nonlinear control design techniques on a model of the Caltech ducted fan. Automatica 37 (12), pp. 1971 – 1978. Cited by: §I.