Funnel MPC for nonlinear systems with arbitrary relative degree

The Model Predictive Control (MPC) scheme Funnel MPC enables output tracking of smooth reference signals with prescribed error bounds for nonlinear multi-input multi-output systems with stable internal dynamics. Earlier works achieved the control objective for system with relative degree restricted to one or incorporated additional feasibility constraints in the optimal control problem. Here we resolve these limitations by introducing a modified stage cost function relying on a weighted sum of the tracking error derivatives. The weights need to be sufficiently large and we state explicit lower bounds. Under these assumptions we are able to prove initial and recursive feasibility of the novel Funnel MPC scheme for systems with arbitrary relative degree - without requiring any terminal conditions, a sufficiently long prediction horizon or additional output constraints.


Introduction
Model predictive control (MPC) is a nowadays widely used control technique which has seen various applications, see e.g.[27] and also [31].It is applicable to nonlinear multi-input multi-output system and able to take state and control constraints directly into account.MPC relies on the iterative solution of finite horizon optimal control problems (OCP), see e.g.[29,15].
Solvability of the OCP at any particular time instance is essential for the successful application of MPC.Incorporating suitably designed terminal conditions (costs and constraints) in the optimization problem is an often used method to guarantee initial and recursive feasibility, meaning guaranteeing that the solvability of the OCP at a particular instance in time automatically implies that the OCP can be solved at the successor time instance.However, the computational effort for solving the OCP and finding initially feasible control signals becomes significantly more complicated by the introduction of such (artificial) terminal conditions.Thus, the domain of admissible controls for MPC might shrink substantially, see e.g.[10,14].Alternative methods relying on controllability conditions, e.g.cost controllability [11], require a sufficiently long prediction horizon, see e.g.[8,12].Especially in the presence of time-varying state and output constraints these techniques are considerably more involved, see e.g.[25].
Funnel MPC was proposed in [5] to overcome these restrictions.It allows for output reference tracking such that the tracking error evolves within predefined (timevarying) performance bounds.This is different from the output tracking or output regulation problem on which other MPC approaches usually focus, see e.g.[18,23].Instead of prescribing a transient behavior for the system output, the control objective in these works is to achieve asymptotic tracking, i.e., ensuring the convergence of the tracking error to zero.In [19], the output regulation problem is considered in the presence of time-invariant constraints.The constraint satisfaction is ensured by assuming suitable stabilizability and detectability conditions and a sufficiently long prediction horizon.A similar control objective is pursued by tube-based MPC schemes, see e.g.[26] for linear systems and [13,28,20] for nonlinear systems.Similar to funnel MPC, the tracking error is confined to a controllable and known range which might change over time.The intention is to compensate for model uncertainties and disturbances acting on the system.These methods ensure safe operation by introducing tightening tubes around the input and output constraints in order to ensure robust satisfaction of the given constraints.However, these tubes are usually calculated offline and cannot be arbitrarily chosen by the user since they have to encompass the system uncertainties -see e.g.[24], where the tubes and the reference trajectory are simultaneously optimized depending on the proximity to the tube boundary.
While the first proposed funnel MPC algorithm in [5] incorporated output constraints in the OCP, it was shown in the successor work [2] that for a class of systems with relative degree one and, in a certain sense, input-to-state stable internal dynamics, these constraints are superfluous.Utilizing a "funnel-like" stage cost, which penalizes the tracking error and becomes infinite when approaching predefined boundaries, guarantees initial and recursive feasibility -without the necessity to impose additional terminal conditions or requirements on the length of the prediction horizon.
Funnel MPC is inspired by funnel control which is an adaptive feedback control technique of high-gain type first proposed in [17], see also the recent work [4] for a comprehensive literature overview.The funnel controller is inherently robust and allows for output tracking with prescribed performance guarantees for a fairly large class of systems solely invoking structural assumptions.In contrast to MPC, funnel control does not use a model of the system.The control input signal is solely determined by the instantaneous values of the system output.The controller therefore cannot "plan ahead".This often results in unnecessary high control values and a rapidly changing control signal with peaks.Compared to this, by utilizing a system model, funnel MPC exhibits a significantly better controller performance in numerical simulations, see [2,5].A direct combination of both control techniques which allows for the application of funnel MPC in the presence of disturbances and even a structural plant-model mismatch was recently proposed in [3].This approach was further extended in [21] by a learning component which realizes online learning of the model to allow for a steady improvement of the controller performance over time.
Nevertheless, the results of [2,3,21] are still restricted to the case of systems with relative degree one.Utilizing so-called feasibility constraints in the optimization problem and restricting the class of admissible funnel functions, the case of arbitrary relative degree was considered in [1].Like in previous results no terminal conditions nor requirements on the length of the prediction horizon are imposed.But then again these feasibility constraints lead to an increased computational effort and they depend on a number of design parameters which are not easy to determine.Furthermore, the cost functional used in [1] is rather complex (using several auxiliary error variables).In the present paper, we resolve these problems and propose a novel cost functional to extend funnel MPC to systems with arbitrary relative degree.We further enlarge the considered system class considered in previous works to encompass systems with nonlinear time delays and potentially infinite-dimensional internal dynamics.Similar to funnel MPC for relative degree one systems, only the distance of one error variable to the funnel boundary is penalized and no feasibility constraints are required.

Nomenclature
N and R denote natural and real numbers, respectively.N 0 := N ∪ {0} and R ≥0 := [0, ∞).∥x∥ := ⟨x, x⟩ denotes the Euclidean norm of x ∈ R n .∥A∥ denotes the induced operator norm ∥A∥ := sup ∥x∥=1 ∥Ax∥ for the space of measurable and essentially bounded functions f : I → R n with norm ∥f ∥ ∞ := ess sup t∈I ∥f (t)∥, L ∞ loc (I, R n ) the set of measurable and locally essentially bounded functions, and L p (I, R n ) the space of measurable and p-integrable functions with norm ∥•∥ L p and with p ≥ 1.Furthermore, W k,∞ (I, R n ) is the Sobolev space of all k-times weakly differentiable functions f : I → R n such that f, . . ., f (k) ∈ L ∞ (I, R n ); and f | J denotes the restriction of a function f : I → R n to the interval J ⊆ I.

System class
We consider nonlinear control affine multi-input multioutput systems of order r ∈ N of the form y (r) (t) = f T(y, . . ., y (r−1) )(t) + g T(y, . . ., y (r−1) )(t) u(t), with initial "memory" σ ≥ 0, functions f ∈ C(R q , R m ), g ∈ C(R q , R m×m ), and an operator T. The operator T is causal, locally Lipschitz, and satisfies a bounded-input bounded-output and a limited memory property.It is characterised in detail in the following Definition 1.1.
Definition 1.1.For n, q ∈ N and σ ≥ 0, the set T n,q σ denotes the class of operators T : for which the following properties hold: ∥T(y)(t)∥ ≤ c 1 .
• Limited memory: The number τ in the above property is called memory limit of the operator T.
Note that many physical phenomena such as backlash and relay hysteresis, and nonlinear time delays can be modelled by means of the operator T, where σ corresponds to the initial delay, cf.[4,Sec. 1.2].Moreover, systems with infinite-dimensional internal dynamics can be represented by (1), see [6].For a practically relevant example of infinite-dimensional internal dynamics (modelled by an operator T) we refer to the moving water tank system considered in [7].Compared to previous works, the limited memory property is new here and required in the context of MPC, in order to ensure that in each MPC step only the history of the state up to the memory limit τ ≥ 0 is utilized, instead of requiring the full history, which would be infeasible in practice.In Section 4, we illustrate how the limited memory property can be checked by means of a specific example.
For given t ≥ 0, τ, σ ≥ 0, we use the notation and x| [ t,ω) is absolutely continuous such that ẋi (t) = x i+1 (t) for i = 1, . . ., r − 1, and ẋr (t) = f (T(x)(t)) + g(T(x)(t))u(t) for almost all t ∈ [ t, ω).A solution x is said to be maximal, if it has no right extension that is also a solution.This maximal solution is called the response associated with u and denoted by x(•; t, ŷ, T, u).Its first component x 1 is denoted by y(•; t, ŷ, T, u).Note that in the above definition we did not distinguish between the cases σ > 0 and σ = 0 as in (1), since a larger variety of cases is possible here.Essentially, the cases I t,τ σ ̸ = { t} and I t,τ σ = { t} mus be distinguished; in the latter case, we will implicitly assume a representation of the initial condition ŷ as in (1) throughout the article.
Let us provide an additional explanation of the above definition.At first glance it might seem that T is completely determined by (ŷ, ŷ(1) , . . ., ŷ(r−1) ).However, the latter is not an element of the domain of T in general.In fact, the second condition in (2) entwines the full history of x (by causality, T (x)(t) is defined in terms of x| [−σ,t] for any t ≥ 0) with the initial datum T. In contrast to this, the first condition in (2) only fixes the history of x on the interval I t,τ σ .We summarize our assumptions and define the general system class under consideration.Definition 1.2 (System class).We say that the system (1) belongs to the system class N m,r for m, r ∈ N, written (f, g, T) ∈ N m,r , if, for some q ∈ N and σ ≥ 0, the following holds:

Control objective
The objective is to design a control strategy that allows tracking of a given reference trajectory y ref ∈ W r,∞ (R ≥0 , R m ) within pre-specified error bounds.To be more precise, the tracking error e(t) := y(t) − y ref (t) shall evolve within the prescribed performance funnel This funnel is determined by the choice of the function ψ belonging to see also Figure 1.Note that the evolution in F ψ does not force the tracking error to converge to zero asymptotically.Furthermore, the funnel boundary is not necessarily monotonically decreasing and there are situations, like in the presence of periodic disturbances, where widening the funnel over some later time interval might be beneficial.The specific application usually dictates the constraints on the tracking error and thus indicates suitable choices for ψ.

Given:
System (1), reference signal ) and stage cost function ℓ θ as in (5).Set the time shift δ > 0, the prediction horizon T ≥ δ, and initialize the current time t := 0. Steps: (a) Obtain a measurement of the output y of (1) and of T(y) on the interval where to system (1).Increase t by δ and go to Step (a).
Remark 2.2.For a nonlinear system of the form with nonlinear functions f : R n → R n , g : R n → R n×m and h : R n → R m , there exists, under assumptions provided in [9, Cor.5.6], a coordinate transformation induced by a diffeomorphism Φ : R n → R n which puts the system in the form (1) with σ = 0, appropriate functions f and g and an operator T, which is the solution operator of the internal dynamics of the transformed system.Assuming the existence of the diffeomorphism Φ, the funnel MPC Algorithm 2.1 can be directly applied to the system (8) without computing Φ.In this case, the output derivatives ẏ, . . ., y (r−1) required in the OCP (6) can be determined as functions of the state; e.g., All results presented in this paper can also be expressed for the system (8) using Φ.Concrete knowledge about the coordinate transformation however is not required for the design and application of the controller -it is merely used as a tool for the proofs.
In the following main result we show that for a funnel function ψ ∈ G, a reference signal y ref and sufficiently large k 1 , . . ., k r−1 (depending on the choice of ψ, y ref and the initial data y 0 ) there exists a sufficiently large saturation level M > 0 such that the funnel MPC Algorithm 2.1 (with a suitable function θ ∈ G) is initially and recursively feasible for every prediction horizon T > 0 and that it guarantees the evolution of the tracking error within the performance funnel F ψ .
Theorem 2.3.Consider system (1) with (f, g, T) ∈ N m,r , initial data y 0 ∈ C r−1 ([−σ, 0], R m ) and let τ ≥ 0 be the memory limit of the operator T. Let y ref ∈ W r,∞ (R ≥0 , R m ) and choose ψ ∈ G with associated constants α, β > 0. In addition, let γ ∈ (0, 1) such that Furthermore, choose parameters k 1 , . . ., k r−1 such that for all i = 2, . . ., r − 1 we have (9) Then, there exists M > 0 such that the funnel MPC Algorithm 2.1 with prediction horizon T > 0, time shift δ > 0, and stage cost function ℓ θ with (10) for r > 1 and θ(t) := ψ(t) for r = 1, is initially and recursively feasible, i.e., at time t = 0 and at each successor time t ∈ δN the OCP (6) has a solution.In particular, the closed-loop system consisting of (1) and the funnel MPC feedback (7) has a (not necessarily unique) global solution x : [−σ, ∞) → R rm with corresponding output y = x 1 and the corresponding input is given by . Furthermore, each global solution x with corresponding output y and input u FMPC satisfies: Note that for r = 1 the above result essentially coincides with [2, Thm.2.10], except for the different system classes considered.In particular, the stage cost function in (5) is the same as in [2] in this case.In this sense, the findings of the present paper represent an extension of the results of [2].
Therefore, χ(y 0 − y ref )(0) ∈ D r 0 .We define the set of all functions ζ ∈ C r−1 ([−σ, ∞), R m ) which coincide with y 0 on the interval [−σ, 0] and for which χ(ζ − y ref )(t) ∈ D r t on the interval J s := [0, s) for some s ∈ (0, ∞] as follows: Lemma 3.1.Consider the system (1) with (f, g, T) ∈ N m,r .Let ψ i ∈ G, for i = 1, . . ., r with parameters k i > 0 for i = 1, . . ., r − 1.Further, let Then, there exist constants f max , g max > 0 such that for all s ∈ (0, ∞], ζ ∈ Y r s , and t ∈ [0, s) Proof.We prove the Lemma by adapting the proof of [22, Lem.2.2] to the given setting.By definition of Y r ∞ and D r t , we have for all i = 1, . . ., r Due to the definition of the error variables e i there exists an invertible matrix S ∈ R rm×rm such that Hence, by boundedness of ψ i and y ref for all i = 1, . . ., r, there exists a compact set K ⊂ R rm with Invoking the BIBO property of the operator T, there exists a compact set and g(•) −1 are continuous, the constants f max = max x∈Kq ∥f (x)∥ and g max = max x∈Kq g(x) −1 are well-defined.For all s ∈ (0, ∞] and ζ ∈ Y r s we have which proves the assertion. Lemma 3.2.Under the assumptions of Theorem 2.3, consider the functions ψ 2 , . . ., ψ r ∈ G defined in (11).
For i = 1 we find that ψ 1 = ψ and by properties of G it follows − ψ(t) Furthermore, we have that ψ(t) ≥ ψ(0)e −αt + β α for all t ≥ 0. Therefore, for all t ≥ 0, where we have use that ∥e(0)∥ ≤ γ r ψ(0).Hence we obtain that where the last inequality follows from (9).Now consider the case i > 1.Then we have − ψi(t) ψi(t) ≤ α for all t ≥ 0 and, invoking that by (4) we find that for all t ≥ 0. Hence we obtain that where the last inequality follows from (9).Summarizing, in each case the contradiction arises, which completes the proof., where This is the set of all L ∞ -controls u bounded by M which, if applied to the system (1), guarantee that the error signals e i (x(t; t, ŷ, T, u)−χ(y ref )(t)) evolve within their respective funnels defined by ψ i on the interval [ t, t + T ].We note that the conditions in (13)  .Then, there exists M > 0 such that for all T > 0 we have where ζ is an arbitrary element in Y r t with ζ| I t,τ σ = y(•; t, ŷ, T, u)| I t,τ σ .Proof.Step 1 : We define M > 0. To that end, define, for i = 1, . . ., r − 1 and j = 0, . . ., r − i − 1 Using the constants f max and g max from Lemma 3.1, define Step 2 : Let T > 0 be arbitrary.We construct a control function u and show that u ∈ U T (M, t, ŷ, T).
Step 3 : We show implication (14).If, for any T 1 > 0 an arbitrary but fixed control û ∈ U T1 (M, t, ŷ, T) is applied to the system (1), then x(t; t, ŷ, T, u) − χ(y ref )(t) ∈ D r t for all t ∈ [ t, t + T 1 ].If for any t ∈ [ t, t + T ], the system is considered on the interval [ t, t + T 2 ] with T 2 > 0 and initial data ỹ := y(•; t, ŷ, T, u)| I t,τ , then one can show by a repetition of the arguments in Step 2 that the application of the control ũ ∈ L ∞ ([ t, t + T 2 ], R m ) as in (16), mutatis mutandis, guarantees x(t; t, ỹ, T, ũ) − χ(y ref )(t) ∈ D r t for all t ∈ [ t, t + T 2 ].Note that, on the interval [ t, t + T ], the function T(x)( t) is solely determined by ỹ, T, and the differential equation (1).It does not depend on the choice of ζ due to the limited memory property of the operator T. Since the prerequisites for Lemmata 3.1 and 3.2 are still satisfied, the control ũ is bounded by M as constructed in Step 1.Thus, ũ ∈ U T2 (M, t, ỹ, T) ̸ = ∅.Lemma 3.4.Under the assumptions of Theorem 2.3, consider the functions ψ 2 , . . ., ψ r ∈ G defined in (11).
Proof.As a consequence of Lemma 3.4, solving the OCP ( 6) is equivalent to minimizing the function  [2,Thm. 4.6] yields that (x k ) has a subsequence (which we do not relabel) that converges uniformly to x ⋆ = x(•; t, ŷ, T, u ⋆ ) and that ∥u ⋆ ∥ ∞ ≤ M .Along the lines of Steps 5-7 of the proof of [2,Thm. 4.6] it follows that u ⋆ ∈ U T (M, t, ŷ, T) and J(u ⋆ ) = J ⋆ .This completes the proof.

Proof of Theorem 2.3
Choosing the bound M > 0 from Lemma 3.3 and utilizing Lemma 3.5 this can be shown by a straightforward adaption of the proof of [2,Thm. 2.10].□

Simulations
To demonstrate the application of the funnel MPC Algorithm 2.1 we consider the example of a mass-spring system mounted on a car from [32].Consider a car with mass m 1 , on which a ramp is mounted and inclined by the angle θ ∈ [0, π 2 ).On this ramp a mass m 2 , which is coupled to the car by spring-damper component with spring constant k > 0 and damping coefficient d > 0, moves frictionless, see Figure 2. A control force F = u can be applied to the car.The dynamics of the system can be described by the equations where z(t) is the horizontal position of the car and s(t) the relative position of the mass on the ramp at time t.
We compare the funnel MPC Algorithm Algorithm 2.1 with the original funnel MPC scheme from [2], for which only feasibility for systems with relative degree one has been shown so far, and the funnel MPC scheme from [1], which uses feasibility constraints to ensure recursive feasibility for systems with higher relative degree.Since, in comparison to the set G, the set of admissible funnel functions for control scheme from [1] is quite restrictive, the same funnel function ψ(t) = 1/10 + 11e −27x/20 − 7e −3x/2 as in [1] was chosen.Straightforward calculations show that α = 1.5, β = 3 20 , γ = 0.5, and k 1 = 14 satisfy the requirements of Theorem 2.3.With these parameters, the funnel function θ in ( 10) is given by θ(t) = 28e −3t/2 + 1 5 .
For the stage cost function ℓ θ as in (5) the parameter λ u = 1 100 has been chosen.Further, the maximal input was limited to ∥u∥ ∞ ≤ 20, i.e., M = 20 was chosen.
Inserting the definition of the function e 2 from (3) with parameter k 1 , the stage cost thus reads ℓ θ (t, ξ 1 , ξ As in [1] and [2] only step functions with constant step length 0.04 are considered in the OCP (6) due to discretisation.The prediction horizon and the time shift are chosen as T = 0.6 and δ = 0.04.All simulations are performed with Matlab and the toolkit CasADi on the interval [0, 10] and are depicted in Figure 3.The tracking from the cation of the different MPC schemes from [1], [2] and Algorithm 2.1 to system (19) are shown in Figure 3a.The corresponding control signals are displayed in Figure 3b.It is evident that all three control schemes achieve the control objective, the evolution of the tracking error with in the performance boundaries given by ψ.
Overall, the performance of all three funnel MPC schemes is comparable.After t = 4 the computed control signals and the corresponding tracking errors of all three control schemes are almost identical.However, funnel MPC from [1] requires feasibility constraints in the OCP to achieve initial and recursive feasibility; together with the more complex stage cost, this severely increases the computational effort.Furthermore, the parameters involved in the feasibility constraints are very hard to determine and usually (as in the simulations performed here) conservative estimates must be used.But then again, initial and recursive cannot be guaranteed.Concerning the funnel MPC scheme from [2], it is still an open problem to show that it is initially and recursively feasible for systems with relative degree larger than one.

Conclusion
In the present paper we proposed a new model predictive control algorithm for a class of nonlinear systems with arbitrary relative degree, which achieves tracking of a reference signal with prescribed performance.The new funnel MPC scheme resolves the drawbacks of earlier approaches in [2] (no proof of initial and recursive feasibility for relative degree larger than one) and [1] (requirement of feasibility constraints, design parameters difficult to determine, high computational effort).All advantages of these approaches (no terminal costs or conditions, no requirements on the prediction horizon) are retained.Essentially, this solves the open problems formulated in the conclusions of [1,2].Compared to previous works on funnel MPC, the class of nonlinear systems considered here includes systems with nonlinear delays and infinite-dimensional internal dynamics.An interesting question which remains for future research is, whether the weighted sum of the tracking error derivatives e, ė, . . ., e (r−1) used in the cost functional in (6) can be replaced by a sole error signal e, when instead the prediction horizon T is chosen sufficiently long.

Figure 1 :
Figure 1: Error evolution in a funnel F ψ with boundary ψ(t).