On the exact linearisation and control of flat discrete-time systems

The paper addresses the exact linearisation of flat nonlinear discrete-time systems by generalised static or dynamic feedbacks which may also depend on forward-shifts of the new input. We first investigate the question which forward-shifts of a given flat output can be chosen in principle as a new input, and subsequently how to actually introduce the new input by a suitable feedback. With respect to the choice of a feasible input, easily verifiable conditions are derived. Introducing such a new input requires a feedback which may in general depend not only on this new input itself but also on its forward-shifts. This is similar to the continuous-time case, where feedbacks which depend on time derivatives of the closed-loop input – and in particular quasi-static ones – have already been used successfully for the exact linearisation of flat systems since the nineties of the last century. For systems with a flat output that does not depend on forward-shifts of the input, it is shown how to systematically construct a new input such that the total number of the corresponding forward-shifts of the flat output is minimal. Furthermore, it is shown that in this case the calculation of a linearising feedback is particularly simple, and the subsequent design of a discrete-time flatness-based tracking control is discussed. The presented theory is illustrated by the discretised models of a wheeled mobile robot and a 3DOF helicopter.


Introduction
The concept of flatness has been introduced in the 1990s by Fliess, Lévine, Martin and Rouchon for nonlinear continuous-time systems (see e.g. Fliess, Lévine, Martin, and Rouchon (1995) and Fliess, Lévine, Martin, and Rouchon (1999)). Roughly speaking, a continuous-time system is flat if all system variables can be parameterized by a flat output and its time derivatives, which in turn depends on the system variables and their time derivatives. In other words, there exists a one-to-one correspondence between the trajectories of a flat system and the trajectories of a trivial system. Since these properties allow an elegant solution to motion planning problems and a systematic design of tracking controllers, flatness belongs doubtlessly to the most popular nonlinear control concepts.
For the practical implementation of a flatness-based control, it is important to evaluate the continuous-time control law at a sufficiently high sampling rate. If this is not possible, it can be advantageous to design the controller directly for a suitable discretization of the continuous-time system, see e.g. Diwold, Kolar, and Schöberl (2022a). Thus, transferring the flatness concept to discrete-time systems is both interesting from a theoretical and an application point of view. In fact, there are two equally obvious possibilities: The first one is to re-place the time derivatives of the continuous-time definition by forward-shifts. This point of view has been adopted e.g. in Kaldmäe and Kotta (2013), Sira-Ramirez and Agrawal (2004), or Kolar, Kaldmäe, Schöberl, Kotta, and Schlacher (2016), and is consistent with the linearizability by a discrete-time endogenous dynamic feedback as it is defined in Aranda-Bricaire and Moog (2008). The second approach is based on the one-to-one correspondence of the system trajectories to the trajectories of a trivial system. In contrast to the first approach, in this case the flat output may also depend on backward-shifts of the system variables, see Diwold, Kolar, and Schöberl (2022b) or Guillot and Millérioux (2020). Since it is more general, within the present paper we consider the second approach, and refer to the first one, which is included as a special case, as forward-flatness.
In Diwold et al. (2022b), it has been shown that flat discrete-time systems can be exactly linearized by a dynamic feedback in such a way that the new input of the closed-loop system corresponds to the highest forward-shifts of the flat output that appear in the parameterization of the system variables. Similarly, in the continuous-time case it is always possible to perform an exact linearization such that the new input corresponds to the highest time derivatives of the flat output that appear in the parameterization of the system variables, see e.g. Fliess et al. (1999). However, it is well-known that it can be beneficial to choose appropriate lower-order time derivatives of the flat output as a new input. If the sum of the orders of the chosen time derivatives is equal to the order of the system, this approach is known as linearization by a quasi-static state feedback, see Delaleau and Rudolph (1998), Rudolph (2021), or Gstöttner, Kolar, and Schöberl (2021a). An important advantage of such an exact linearization is that it allows e.g. to achieve a lower-order error dynamics for a subsequently designed tracking control. For discrete-time systems, quasi-static feedbacks have already been used e.g. in Aranda-Bricaire and Kotta (2001), but not in the context of exact linearization and flatness. The practical applicability of a discrete-time quasi-static exact linearization has been demonstrated in Diwold et al. (2022a) with a flatness-based tracking control for a gantry crane. However, according to the authors' best knowledge, a thorough theoretical analysis of this topic for flat discrete-time systems in general does not yet exist in the literature. Thus, the aim of the present paper is to close this gap: We investigate under which conditions it is possible to choose lower-order forward-shifts of a flat output as a new input, and how to actually introduce such a new input by a suitable feedback. After discussing the general case, we consider systems with a flat output that does not depend on future values of the control input. We show how to systematically construct a new input such that the sum of the orders of the corresponding forward-shifts of the components of the flat output is minimal, and that deriving a linearizing feedback is particularly simple in this case. Furthermore, we show how such an exact linearization can be used as a basis for the design of a flatness-based tracking control, and demonstrate our results by two examples.
The employed mathematical methods are similar as in Gstöttner et al. (2021a), where we have proven that every flat continuous-time system with a flat output that is independent of time derivatives of the input can be exactly linearized by a quasi-static feedback of its classical state. Hence, it is particularly important to emphasize that like in Gstöttner et al. (2021a) we restrict ourselves to feedbacks of the classical system state, and do not consider feedbacks of generalized states as e.g. in Delaleau and Rudolph (1998) or Rudolph (2021).
The paper is organized as follows: In Section 2 and Section 3 we introduce some notation and recapitulate the concept of flatness for discrete-time systems. In Section 4 we investigate the exact linearization of flat discrete-time systems in general, and derive further results for systems with a flat output that does not depend on future values of the control input. The design of a flatnessbased tracking control is discussed in Section 5, and in Section 6 the developed theory is finally applied to the discretized models of a wheeled mobile robot and a 3DOF helicopter.

Notation
Throughout the paper we make use of some basic differential-geometric concepts. Let X be an n-dimensional smooth manifold equipped with local coordinates x i , i = 1, . . . , n, and h : X → R m some smooth function. Then we denote by ∂ x h the m × n Jacobian matrix of h = (h 1 , . . . , h m ) with respect to x = (x 1 , . . . , x n ). The partial derivative of a single component h j with respect to a coordinate x i is denoted by ∂ x i h j . Furthermore, dh j = ∂ x 1 h j dx 1 +. . .+∂ x n h j dx n denotes the differential (exterior derivative) of the function h j , where dx i , i = 1, . . . , n are the differentials corresponding to the local coordinates. We frequently use dh as an abbreviation for the set {dh 1 , . . . , dh m }, and with e.g. span{dh 1 , . . . , dh m } we mean the span over the ring C ∞ (X ) of smooth functions. The symbols ⊂ and ⊃ are used in the sense that they also include equality.
To denote forward-and backward-shifts of the system variables, we use subscripts in brackets. For instance, the α-th forward-or backward-shift of a component y j of a flat output y with α ∈ Z is denoted by y j [α] , and y [α] = (y 1 [α] , . . . , y m [α] ). To keep expressions which depend on different numbers of shifts of different components of a flat output readable, we use multi-indices. If A = (a 1 , . . . , a m ) and B = (b 1 , . . . , b m ) are two multi-indices with A ≤ B, i.e., a j ≤ b j for j = 1, . . . , m, then and In the case a j > b j we define y j [a j ,b j ] as empty. The addition and subtraction of multi-indices is performed componentwise, and for an integer c we define A ± c = (a 1 ± c, . . . , a m ± c). Furthermore, #A = m j=1 a j denotes the sum over all components of a multiindex. As an example consider the tuple y = (y 1 , y 2 ), an integer c = 2, and multi-indices A = (0, 2), B = (1, 2). We then have y [c]  ) as well as #A = 2 and #B = 3. Frequently, it is also convenient to decompose the components of a flat output y or the input u into several blocks like e.g. y = (y 1 , . . . , y m1 y1 , y m1+1 , . . . , y m y2 ) .
Since such blocks are also denoted by a subscript, in this case the first subscript always refers to the block, and shifts are denoted by a second subscript in brackets. For instance, ) with some multi-index A 1 = (a 1 1 , . . . , a m1 1 ).

Discrete-time systems and flatness
In this contribution, we consider time-invariant discrete-time nonlinear systems with dim(x) = n, dim(u) = m and smooth functions f i (x, u). In addition, we assume that the system (1) meets the submersivity condition which is common in the discrete-time literature and necessary for accessibility. Like in Diwold et al. (2022b), we call a discrete-time system (1) flat if there exists a oneto-one correspondence between its solutions (x(k), u(k)) and solutions y(k) of a trivial system (arbitrary trajectories that need not satisfy any difference equation) with the same number of inputs. Before we state a more rigorous definition of discrete-time flatness, let us consider the coupling of the trajectories x(k) and u(k) by the system equations (1). By a repeated application of (1), all forward-shifts x(k + α), α ≥ 1 of the state variables are obviously determined by x(k) and the input trajectory u(k + α) for α ≥ 0. A similar argument holds for the backward-direction: Because of the submersivity condition (2), there always exist m functions g(x, u) such that the (n + m) × (n + m) Jacobian matrix is regular and the map hence locally invertible. By a repeated application of its inverse all backward-shifts x(k − β), u(k − β) of the state-and input variables for β ≥ 1 are determined by x(k) and backward-shifts ζ(k − β), β ≥ 1 of the system variables ζ defined by (3). Hence, if only a finite time-interval is considered, the system trajectories (x(k), u(k)) can be identified with points . . . , u [lu] ) and suitably chosen integers lu] ) is a function defined on this manifold, then its future values can be determined by a repeated application δ β of the forward-shift operator Likewise, its past values can be determined by a repeated application δ −β of the backward-shift operator where ψ x and ψ u are the corresponding components of (4). Since we work in a finite-dimensional framework, it is important to emphasize that δ only yields the correct forward-shift if the integer l u is chosen large enough such that the considered function h does not already depend on u [lu] . Likewise, δ −1 only yields the correct backward-shift if l ζ is chosen large enough such that the function h does not already depend on ζ [−lζ] . Thus, throughout this contribution we assume that l u and l ζ are chosen large enough such that (5) and (6) act as correct forward-and backward-shifts on all considered functions. Like the discrete-time static feedback linearization problem, discrete-time flatness is considered in a suitable neighborhood of an equilibrium (x 0 , u 0 ) of the system (1). On the manifold ζ [−lζ,−1] × X × U [0,lu] , an equilibrium corresponds to a point with coordinates (ζ 0 , . . . , ζ 0 , x 0 , u 0 , u 0 , . . . , u 0 ) with ζ 0 = g(x 0 , u 0 ) according to (3). Hence, evaluated at an equilibrium point (or, in other words, at an equilibrium trajectory), the functions δ(h) and δ −1 (h) have the same value as the function h itself.
Definition 3.1. (Diwold et al. (2022b)) The system (1) is said to be flat around an equilibrium (x 0 , u 0 ), if the n + m coordinate functions x and u can be expressed locally by an m-tuple of functions u, . . . , u [q2] ) , j = 1, . . . , m and their forward-shifts up to some finite order. The m-tuple (7) is called a flat output.
The multi-index R = (r 1 , . . . , r m ) consists of the number of forward-shifts of each component of the flat output (7) that are needed to express x and u. After substituting (8) into (9), the equations are satisfied identically. Because of Lemma A.1 (see the appendix), this is equivalent to the condition dx ∈ span{dϕ, . . . , dδ R−1 (ϕ)} du ∈ span{dϕ, . . . , dδ R (ϕ)} which we shall use later. The uniqueness of the map (9) is a consequence of the fact that all forwardand backward-shifts of a flat output are functionally independent, see Diwold et al. (2022b). Furthermore, the rows of the Jacobian matrix of the right-hand side of (9) with respect to y [0,R] are linearly independent, i.e., the map (9) is a submersion. With a restriction to flat outputs that are independent of backward-shifts of the system variables, Definition 3.1 leads to the concept of forward-flatness considered e.g. in Sira-Ramirez and Agrawal (2004), Kaldmäe and Kotta (2013), or Kolar et al. (2016).
Definition 3.2. (Diwold et al. (2022b)) The system (1) is said to be forward-flat, if it meets the conditions of Definition 3.1 with a flat output of the form y j = ϕ j (x, u, . . . , u [q2] ).
For continuous-time systems, the computation of flat outputs is known to be a challeng-ing problem. Recent research in this field can be found e.g. in Nicolau and Respondek (2017), Nicolau and Respondek (2019), or Gstöttner, Kolar, and Schöberl (2021b). For discrete-time systems, in contrast, we have shown in Kolar, Schöberl, and Diwold (2021) that every forward-flat system can be decomposed by coordinate transformations into a smaller-dimensional forward-flat subsystem and an endogenous dynamic feedback. Because of this property, it is possible to check the forward-flatness of a system (1) similar to the well-known static feedback linearization test by computing a certain sequence of distributions, see Kolar, Diwold, and Schöberl (2019). However, even though ideas for an extension of this approach to the general case of Definition 3.1 can be found in Kaldmäe (2021), a computationally efficient test does not yet exist. Hence, within the present paper, we assume that a flat output is given and do not address its computation.

Exact linearization
In Diwold et al. (2022b), it has been shown that every flat discrete-time system (1) can be exactly linearized by a dynamic feedback which leads to an input-output behaviour of the form y j [r j ] = v j , j = 1, . . . , m between the new input v = δ R (ϕ) and the considered flat output (7). In the following, we address the question whether also lower-order forward-shifts v = δ A (ϕ) of the flat output with a suitable multi-index A ≤ R can be chosen as new input. This is particularly interesting for the subsequent design of a tracking control, since with an input-output behaviour the order of the tracking error dynamics is given by #A instead of #R. The criterion for the feasibility of an m-tuple of forward-shifts δ A (ϕ) of a flat output (7) as a new input v is the possibility to realize arbitrary trajectories v(k + α), α ≥ 0 independently of the previous trajectory of the system. More precisely, like for the original input u, at every time step k the system (1) must permit arbitrary trajectories v(k + α), α ≥ 0 independently of its current state x(k) and past values ζ(k − β), β ≥ 1. That is, for every possible state x(k) and past values ζ(k − β), β ≥ 1 there must exist a trajectory u(k + α), α ≥ 0 of the original control input such that the desired trajectory v(k + α), α ≥ 0 can be realized. The practical importance of this criterion is obvious, since otherwise there would be no guarantee that a trajectory v(k + α), α ≥ 0 requested e.g. by a controller for the exactly linearized system can actually be achieved. Similar considerations for flat continuous-time systems can be found in Gstöttner et al. (2021a), where it has to be ensured that arbitrary trajectories v(t) can be realized.
Theorem 4.1. The system (1) permits arbitrary trajectories v(k + α), α ≥ 0 for the forward-shifts v = δ A (ϕ) of a flat output (7) regardless of its current state x(k) and past values ζ(k − β), β ≥ 1 if and only if the differentials are linearly independent.
Proof. The system permits arbitrary trajectories v(k + α), α ≥ 0 if and only if there does not exist any nontrivial relation of the form Otherwise, (11) could be solved by the implicit function theorem for at least one component of some v(k +α), α ≥ 0, which would thus be uniquely determined by the other quantities appearing in (11). In our differential-geometric framework with the manifold ζ [−lζ,−1] × X × U [0,lu] , this corresponds to the non-existence of any nontrivial relation Because of Lemma A.1, this condition is equivalent to the linear independence of the differentials However, it is not necessary to check the linear independence of all these differentials. Since the flat output (7) is independent of the variables . . . , . Thus, we do not need to consider the corresponding differentials. Furthermore, since the differentials of a flat output and all its forward-and backward-shifts are linearly independent and the fact that there is also no need to consider the differentials dδ R (ϕ), dδ R+1 (ϕ), . . .. Consequently, the linear independence of the differentials (10) implies the linear independence of the differentials (12), which completes the proof.
An immediate consequence of Theorem 4.1 is that the choice of an input v = δ A (ϕ) with A ≥ R is always possible.

Construction of the linearizing feedback in the general case
Theorem 4.1 ensures that every trajectory v(k + α), α ≥ 0 of the new input v = δ A (ϕ) can be realized independently of the previous trajectory of the system up to the time instant k by applying a suitable trajectory of the control input u(k+α), α ≥ 0. In the following, we show how the required trajectory u(k + α) can be determined by a suitable state feedback. In other words, we derive a feedback which actually introduces v = δ A (ϕ) as new input. For simplicity we assume A ≤ R, since the choice A = R is possible anyway. The basic idea for the construction of the linearizing feedback is similar as in the continuous-time case in Gstöttner et al. (2021a). However, due to the different transformation laws of continuous-time and discrete-time systems, the proof is adapted accordingly.
Because of the linear independence of the differentials (10) and dx ∈ span{dϕ [0,R−1] }, there exists a selection dϕ c of #A − n differentials from the set dϕ [0,A−1] such that As a consequence of Lemma A.1, there exists a diffeomorphism Ψ : R #R+m → R #R+m such that locally holds identically. Its inverse is given by where F x is the parameterization of the state variables according to (9). Based on the diffeomorphism (13), the quantities v = δ A (ϕ) can be introduced as new input of the system (1) by a dynamic feedback with the controller state z = ϕ c . Since the functions ϕ c belong to the set and can hence be expressed as functions of x, ϕ c , and ϕ [A,R] . The corresponding components of (13) are denoted in the following as Theorem 4.2. Consider a system (1) with a flat output (7) and a multi-index A ≤ R which satisfies the condition of Theorem 4.1. With a feedback with dim(z) = #A − n, the closed-loop system has the input-output behaviour y Proof. First, let us extend the feedback (14) by the trivial equations , such that the extended closed-loop system has the form of a classical state representation with the input v [R−A] . In the following, we show that with the transformation derived from (13) the system is equivalent to the discrete-time Brunovsky normal form . . . . . .
From the inverse of (17) and , it is clear that the transformation is actually a state transformation for the extended closed-loop system (16). The input is only renamed according Because of the transformation law for discrete-time systems, applying the transformation (19) to the Brunovsky normal form (18) yields .
, the system representation (16) follows. Thus, the extended closed-loop system (16) is equivalent to the Brunovsky normal form (18) via a state transformation and a renaming of the input. Consequently, it has the linear input-output behaviour y Remark 1. For #A = n, the controller state z is empty and the feedback (14) degenerates to a feedback of the form u Since there is no controller state but the feedback depends on forward-shifts of the closed-loop input v, such a feedback is a discrete-time quasistatic feedback as it is defined in Aranda-Bricaire and Kotta (2001). For continuous-time systems, a quasi-static feedback depends on time derivatives instead of forward-shifts of the closed-loop input.

Flat outputs that are independent of future values of the input
In the remainder of the paper, we consider flat outputs of the form that are independent of future values of the input u. With this restriction, it is possible to derive further results in a similar way as in Gstöttner et al. (2021a) for flat outputs of continuous-time systems which are independent of time derivatives of u. In the following, we show how to systematically construct a "minimal" multi-index κ = (κ 1 , . . . , κ m ) such that with A = κ the condition of Theorem 4.1 is met and #κ ≤ #A for all other feasible multi-indices A. The basic idea is to replace the coordinates u, u , . . .). 3 For this purpose, we forward-shift every component of the flat output (20) until it depends explicitly on the input u, and introduce as many of these functions as possible as new coordinates. Subsequently, the other components of the flat output are further shifted until they depend explicitly on the remaining components of u, and again as many of these functions as possible are introduced as new coordinates. Continuing this procedure until all m components of the original input u have been replaced by forward-shifts of the flat output (20) yields a minimal multi-index κ = (κ 1 , . . . , κ m ) such that with v = δ κ (ϕ) the condition of Theorem 4.1 is satisfied. In the following, we explain the procedure in detail.
which replaces the inputs u 1 and their forward-shifts by v 1 and its forward-shifts. The remaining inputs u rest1 = (u m1+1 , . . . , u m ) and their forward-shifts are left unchanged.
Proof. In every step i ≥ 1 of the procedure, it is possible to forward-shift the remaining components ϕ resti−1 of the flat output until every component depends explicitly on one of the remaining inputs u resti−1 (ϕ rest0 = ϕ and u rest0 = u for i = 1). Otherwise, the property that all forward-shifts of a flat output up to arbitrary order are functionally independent could not hold. Since in every step we have rank(∂ urest i−1 ϕ resti−1, [Ki] ) ≥ 1, at least one of the original inputs u can be eliminated, and the procedure terminates after at most dim(u) = m steps. Now let us prove that κ ≤ R. If the parameterization of x and ζ [−q1,−1] by the flat output is substituted into (23) and y [κ+α] , α ≥ 0 renamed according to y [κ+α] = v [α] , then the equations To prove #κ ≥ n, recall that there exist exactly n independent linear combinations of the differentials of a flat output and its forward-shifts which are contained in span{dx}. In the coordinates constructed during the above procedure, the forward-shifts of the flat output up to the order κ are given by the expressions in (23), and the higher forward-shifts are forward-shifts of v. Thus, there can exist at most #κ independent linear combinations which are contained in span{dx}, and hence #κ ≥ n. If the flat output (20) is independent of ζ [−q1] , . . . , ζ [−1] , then all expressions in (23) are independent of these variables. Consequently, there exist exactly #κ independent linear combinations of the differentials of the flat output and its forward-shifts which are contained in span{dx}, and hence #κ = n.
To prove the relation with Theorem 4.1, we use again the representation (23). In these coordinates, it can be immediately observed that with A = κ the differentials (10) are linearly independent. Moreover, it can also be seen that there exist exactly #κ independent linear combinations of the differentials of the flat output and its forward-shifts which are contained in span{dζ [−q1] , . . . , dζ [−1] , dx}. If there exists a multi-index A such that the differentials (10) are linearly independent, then there can exist at most #A independent linear combinations of the differentials of the flat output and its forward-shifts which are contained in span{dζ [−q1] , . . . , dζ [−1] , dx}. Thus, the existence of such a multi-index with #A < #κ would be a contradiction.
Since the condition of Theorem 4.1 is met, the forward-shifts y [κ] of the flat output (20) can be introduced as a new input v by a (dynamic) feedback according to Theorem 4.2, where the controller state z corresponds to suitable forward-shifts of the flat output that are contained in y [0,κ−1] . However, the representation (24) of y [0,κ−1] offers a convenient alternative. With the map . . .
such that the input-output behaviour of the closed-loop system is given by y [κ] = v. If the flat output (20) is independent of the variables ζ [−q1] , . . . , ζ [−1] , then the feedback has the form and #κ = n.
In contrast to a dynamic feedback (14) with the controller state z, the feedback (26) (26) is straightforward. However, even though there is no dedicated controller dynamics as in (14), the required past values ζ [−q1] , . . . , ζ [−1] have to be stored. Thus, the feedback (26) can be considered either as a special case of a dynamic feedback or a generalization of the class of discrete-time quasi-static feedbacks (as they are defined in Aranda-Bricaire and Kotta (2001)) to backward-shifts . . . , ζ [−2] , ζ [−1] of the system variables. A feedback of the special form (27) has been used in Diwold et al. (2022a) for the exact linearization of the discrete-time model of a gantry crane.

Tracking control design
Like in the continuous-time case, the exact linearization can be used as a first step in the design of a flatness-based tracking control. For an exact linearization according to Theorem 4.2 with the choice A = R, which is always possible, the closed-loop system has the form of a classical state representation. Thus, the design of a tracking control is straightforward. For A ≤ R, however, the closed-loop system depends also on forward-shifts v [0,R−A] of the new input v. Thus, when designing a control law for v, also the corresponding expressions for these forward-shifts have to be derived. For a discussion of this problem in the continuous-time case see e.g. Delaleau and Rudolph (1998), Rudolph (2021), or Gstöttner et al. (2021a. In the following, we demonstrate the design of a tracking control for flat outputs of the form (20) and an exact linearization by a feedback (26) according to Corollary 4.4. We assume that the multi-index κ which determines the new input v has been constructed in accordance with the procedure of Section 4.2, and make use of the corresponding notation. With the control law for the exactly linearized system y The eigenvalues of the s i=1 m i = m decoupled tracking error systems (29) can be placed arbitrarily by a suitable choice of the coefficients a ji,β i ∈ R. The forward-shifts v [0,R−κ] that are needed in the linearizing feedback (26) can be determined by shifting (28) and using y ji i, [κi+γ] = v ji i, [γ] , γ ≥ 0, which leads to equations of the form Since the future values y [0,κ−1] of the flat output which appear in (28) and (30) are in general not available as measurements, we use again the expressions (24) and finally obtain the system of equations . . .
Substituting (32) into the linearizing feedback (26) yields a tracking control law of the form Besides the known reference trajectory y d [0,R] , this tracking control law depends like the linearizing feedback (26) only on the state x and past values ζ [−q1] , . . . , ζ [−1] of the system trajectory. Thus, if the state x of the system (1) can be measured, an implementation is again straightforward.

Examples
As already mentioned in the introduction, an important application for the concept of discrete-time flatness are discretized continuous-time systems. In the following, we illustrate our results by the discretized models of a wheeled mobile robot and a 3DOF helicopter.

Wheeled mobile robot
As first example let us consider a wheeled mobile robot, which has already been studied in the context of discrete-time dynamic feedback linearization in Orosco-Guerrero, Velasco-Villa, and Aranda-Bricaire (2004) and Aranda-Bricaire and Moog (2008). The continuous-time system is given bẏ and is also known as kinematic car model, see e.g. Nijmeijer and van der Schaft (1990). The state variables x 1 and x 2 describe the position and x 3 the angle of the mobile robot. The control inputs u 1 and u 2 represent the translatory and the angular velocity. An exact discretization of the system (33) with the sampling time T > 0 yields the discrete-time system cf. Orosco-Guerrero et al. (2004) or Sira-Ramirez and Rouchon (2003). With the input transformationū this system can be simplified to x 1,+ = x 1 +ū 1 cos(ū 2 ) x 2,+ = x 2 +ū 1 sin(ū 2 ) x 3,+ = 2ū 2 − x 3 .
As shown in Kolar et al. (2021), the system (36) is not forward-flat. However, it is flat in the more general sense of Definition 3.1. With the choice for the variables ζ according to (3), a flat output is given by The corresponding parameterization (9) of the system variables has the form Thus, the orders of the highest forward-shifts of the flat output that appear in (9) are given by R = (3, 2), and an exact linearization by a dynamic feedback which leads to an input-output behaviour is possible with the standard approach discussed in Diwold et al. (2022b).
In the following, we investigate whether also lower-order forward-shifts of the flat output (37) can be chosen as a new input. Since the flat output is of the form (20), we can apply the procedure of Section 4.2 and use the corresponding notation. In the first step, both components of the flat output have to be shifted until they depend explicitly on the inputū. Because of this is the case for the second and the first forward-shift, respectively. Hence, we obtain K 1 = (2, 1), and since ϕ [K1] is independent ofū 1 we clearly have m 1 = rank(∂ūϕ [K1] ) = 1. 5 At this point, we can choose whether we introduce δ 2 (ϕ 1 ) or δ(ϕ 2 ) as new input v 1 = v 1 1 . 6 In the following, we proceed with ϕ 1 = ϕ 1 and ϕ rest1 = ϕ 2 . Consequently, we get κ 1 = k 1 1 = 2 and K rest1 = k 2 1 = 1. After the 5 In contrast to Section 4.2, for the sake of simplicity we do not renumber the componentsū 1 andū 2 of the input. 6 To emphasize that v 1 could in general consist of more than one component we write v 1 1 .

coordinate transformation
which replacesū 2 and its forward-shifts by v 1 1 and its forward-shifts, we have In the second step, we have to shift the remaining component ϕ rest1 = ϕ 2 of the flat output until it depends explicitly on the remaining inputū 1 . This is the case for its second forward-shift Because of rank(∂ū1ϕ 1 rest1,[2] ) = dim(ū 1 ) = 1, the procedure terminates with ϕ 2 = ϕ rest1 and κ 2 = K 2 = 2. After introducing (40) as new input v 2 = v 1 2 , the forward-shifts of the flat output (37) up to the orders κ = (κ 1 , κ 2 ) = (2, 2) are given by such that the input-output behaviour of the closed-loop system is given by with a total order of #κ = 2 + 2 = 4 instead of #R = 3 + 2 = 5 with the standard approach. Since the linearizing feedback (42) depends also on v 1 1,[1] , the system of equations (31) is given by with the functions ϕ 1 1 , ϕ 1 With the inverse of the input transformation (35), the corresponding control law for the system (34) or (33) with the original inputs u 1 and u 2 follows. The presence of the variable ζ 1 [−1] is no obstacle for a practical implementation, since it simply represents a past value of x 3 .

3DOF helicopter
As a second example, let us consider the three-degrees-of-freedom helicopter laboratory experiment of Kiefer, Kugi, and Kemmetmüller (2004). The continuous-time system is given bẏ with the travel angle q 1 , the elevation angle q 2 , and the pitch angle q 3 as well as the corresponding angular velocities ω 1 , ω 2 , and ω 3 . The control inputs u 1 and u 2 are the sum and the difference of the thrusts of the two propellers. The constant coefficients a 1 , a 2 , a 3 and b 1 , b 2 depend on the masses and the geometric parameters. As shown in Kiefer et al. (2004), the system (44) is flat and a flat output is given by 7 y = (q 2 , q 1 ) . (45) Since the system equations are significantly more complex than those of the wheeled mobile robot of Section 6.1, instead of an exact discretization we perform an approximate discretization with the Euler-method. The resulting system q 1,+ = q 1 + T ω 1 q 2,+ = q 2 + T ω 2 q 3,+ = q 3 + T ω 3 ω 1,+ = ω 1 + T b 1 cos(q 2 ) sin(q 3 )u 1 ω 2,+ = ω 2 + T a 1 sin(q 2 ) + a 2 cos(q 2 ) + b 2 cos(q 3 )u 1 ω 3,+ = ω 3 + T a 3 cos(q 2 ) sin( is forward-flat, and the flat output (45) is preserved. 8 This can be checked either with the systematic tests proposed in Kolar et al. (2021) and Kolar et al. (2019), or by simply verifying that all stateand input variables of (46) can indeed be expressed by (45) and its forward-shifts. The corresponding parameterization (9) is of the form with the orders of the highest required forward-shifts given by R = (4, 4). Thus, an exact linearization with a dynamic feedback according to the standard approach discussed in Diwold et al. (2022b) would lead to an input-output behaviour Since the flat output (45) is of the form (20), we can again apply the procedure of Section 4.2 in order to determine whether also lower-order forward-shifts can be used as new input. In the first step, both components of the flat output have to be shifted until they depend explicitly on the input u. Because of ϕ 1 = q 2 δ(ϕ 1 ) = q 2 + T ω 2 δ 2 (ϕ 1 ) = q 2 + 2T ω 2 + T 2 a 1 sin(q 2 ) + a 2 cos(q 2 ) + b 2 cos(q 3 )u 1 7 The components of the flat output are already sorted in such a way that we do not need a renumbering during our calculations. 8 Neither an exact nor an approximate discretization necessarily preserve the flatness or the static feedback linearizability of a continuous-time system, see e.g. Diwold et al. (2022b), Diwold et al. (2022a), or Grizzle (1986) for a further discussion. and ϕ 2 = q 1 δ(ϕ 2 ) = q 1 + T ω 1 δ 2 (ϕ 2 ) = q 1 + 2T ω 1 + T 2 b 1 cos(q 2 ) sin(q 3 )u 1 , this is the case for the second forward-shifts. Hence, we obtain K 1 = (2, 2), and since ϕ [K1] is independent of u 2 we obviously have m 1 = rank(∂ u ϕ [K1] ) = 1. Again, we can choose whether we introduce δ 2 (ϕ 1 ) or δ 2 (ϕ 2 ) as new input v 1 = v 1 1 . In the following we proceed with ϕ 1 = ϕ 1 and ϕ rest1 = ϕ 2 , and get κ 1 = k 1 1 = 2 as well as K rest1 = k 2 1 = 2. The other choice would lead to a feedback with a singularity for q 3 = 0, which is not suitable for a practical application since the pitch angle q 3 is zero in an equilibrium position. After the coordinate transformation v 1 1 = ϕ 1 1,[2] = q 2 + 2T ω 2 + T 2 a 1 sin(q 2 ) + a 2 cos(q 2 ) + b 2 cos(q 3 )u 1 v 1 1,[1] = ϕ 1 1,[3] (q 2 , q 3 , ω 2 , ω 3 , u 1 , u 1 [1] ) , . . . which replaces u 1 and its forward-shifts by v 1 1 and its forward-shifts, we have b2 q 2 − v 1 1 + 2T ω 2 + T 2 a 1 sin(q 2 ) + a 2 cos(q 2 ) .

Conclusion
In this contribution we have investigated the exact linearization of flat discrete-time systems. Since an exact linearization can always be achieved by choosing the highest forward-shifts of the flat output in (9) as new input v = y [R] , the point of departure of our considerations was the question whether also lower-order forward-shifts v = y [A] with A ≤ R can be used. Similar to the continuoustime case, this allows e.g. to achieve a lower-order error dynamics for a subsequently designed tracking control. Concerning the choice of a feasible new input v = y [A] , we have derived conditions which are formulated in terms of the linear independence of certain differentials and can be checked in a straightforward way. Furthermore, we have shown how the new input v can be introduced by a suitable dynamic feedback. For the practically quite important case of flat outputs (20) which do not depend on future values of the control input, we have shown how to construct a minimal multiindex κ such that v = y [κ] is a feasible input and #κ ≤ #A for all other feasible inputs v = y [A] . Such an input v = y [κ] can be introduced by a feedback (26) which depends only on the state x as well as past values of the system variables. This is particularly convenient for an implementation, since past values of the system variables are available anyway from past measurements or past inputs, which only need to be stored. Moreover, we have shown that such an exact linearization can be used as a basis for the design of a tracking control law which again only depends on x as well as past values of the system variables and the reference trajectory. To illustrate our results, we have computed tracking control laws for the discretized models of a wheeled mobile robot and a 3DOF helicopter.
which are all defined on the same manifold. Then dh ∈ span{dg 1 , . . . , dg k } (A1) is equivalent to the existence of a smooth function ψ : R k → R such that locally h = ψ(g 1 , . . . , g k ) (A2) holds identically. If the differentials dg 1 , . . . , dg k are linearly independent, then the function ψ is unique.
Proof. Let l ≤ k denote the maximal number of linearly independent differentials from the set {dg 1 , . . . , dg k }, and assume that these differentials are given by dg 1 , . . . , dg l (which is always possible by a renumbering). Then the functions g 1 , . . . , g l can be introduced as (a part of the) coordinates z i = g i , i = 1, . . . , l on the considered manifold. Moreover, by construction, also the functions g l+1 , . . . , g k can depend only on the coordinates z. With such coordinates, (A1) is equivalent to dh ∈ span{dz 1 , . . . , dz l } .
Thus, the function h can only depend on z 1 , . . . , z l , and hence be written in original coordinates as h = ψ(g 1 , . . . , g l ) .