Input Decoupling of Lagrangian Systems via Coordinate Transformation: General Characterization and Its Application to Soft Robotics

Suitable representations of dynamical systems can simplify their analysis and control. On this line of thought, this article aims to answer the following question: <italic>Can a transformation of the generalized coordinates under which the actuators directly perform work on a subset of the configuration variables be found?</italic> We not only show that the answer to this question is <italic>yes</italic> but also provide necessary and sufficient conditions. More specifically, we look for a representation of the configuration space such that the right-hand side of the dynamics in Euler–Lagrange form becomes <inline-formula><tex-math notation="LaTeX">$[\boldsymbol{I}\; \boldsymbol{O}]^{T}\boldsymbol{u}$</tex-math></inline-formula>, being <inline-formula><tex-math notation="LaTeX">$\boldsymbol{u}$</tex-math></inline-formula> the system input. We identify a class of systems, called <italic>collocated</italic>, for which this problem is solvable. Under mild conditions on the input matrix, a simple test is presented to verify whether a system is collocated or not. By exploiting power invariance, we provide necessary and sufficient conditions that a change of coordinates decouples the input channels if and only if the dynamics is collocated. In addition, we use the collocated form to derive novel controllers for damped underactuated mechanical systems. To demonstrate the theoretical findings, we consider several Lagrangian systems with a focus on continuum soft robots.

Figure 1.Graphical representation of the proposed change of coordinates addressing the input decoupling problem for a fully actuated Lagrangian system.In the q coordinates, the input u undergoes a nonlinear transformation through the actuation matrix A(q) when performing work on q, i.e., τ q = A(q)u.The proposed change of coordinates θ = h(q) bends the configuration space so that each component of u acts directly on one component of θ, namely τ θ = u.The existence of this transformation is possible because of the conservation of power Ḣq, represented by the yellow area, under change of coordinates, i.e., Ḣq = Ḣθ .ear dynamics.To cope with their high nonlinearity and large number of degrees of freedom (DOF), representations with specific structures play a crucial role in simplifying analysis, as well as control design and synthesis.For example, coordinate transformations are often used to highlight some internal structure that simplify derivation of feedback controllers for robotic systems and prove their stability [6]- [9].This paper considers the Input Decoupling (ID) problem for input-affine Lagrangian systems.In particular, given a Lagrangian system whose inputs enter the second-order equations of motion through a configuration-dependent actuation matrix, we study under which conditions on the definition of generalized coordinates each input affects one and only one equation of motion.The coordinates solving the ID problem constitute a set of variables that simplify control design and synthesis because the input directly affects the equations of motion in a decentralized form.If the decoupling coordinates are regarded as system outputs, any control law implemented in these coordinates automatically decouples also the input-output channels.For fully actuated or overactuated Lagrangian systems, i.e., when the number of independent inputs is equal or larger than the number of generalized coordinates, the ID problem can be solved by a configuration-dependent input transformation that inverts (or pseudoinverts) the actuation matrix.On the ©2024 IEEE.Personal use of this material is permitted.Permission from IEEE must be obtained for all other uses, in any current or future media, including reprinting/republishing this material for advertising or promotional purposes, creating new collective works, for resale or redistribution to servers or lists, or reuse of any copyrighted component of this work in other works.other hand, in the case of underactuated systems, a solution is available so far if the actuation matrix is constant and requires only a linear change of generalized coordinates [10].
For multi-input-multi-output (MIMO) plants described in state space form, the input-output decoupling problem is solved by an inversion-based feedback controller, both in the linear [11] and nonlinear case [12]- [14].For this, a feedback transformation is needed that requires a state and input transformation together with a feedback action.In particular, input-output decoupling is possible by a static state feedback if and only if the system has well defined vector relative degree, namely a nonsingular decoupling matrix [15], [16].This result can be used to solve the ID problem for Lagrangian systems by taking the configuration variables (or a subset of them) as system outputs.In fact, in this way, the system has a vector relative degree, with all outputs having uniform relative degree two.It can be shown that, in case of underactuation, the necessary and sufficient condition is the involutivity of the distribution spanned by the columns of the actuation matrix [17].Unfortunately, involutivity is not easy to check, especially for high dimensional dynamics, and has to be evaluated case by case, see [18]- [21].Furthermore, finding the input decoupling state variables in this case requires solving a system of nonlinear partial differential equations [16,Chap. 5], which could be impractical for control synthesis.Finally, in [22], the authors have proposed input transformations for dynamic processes that achieve exact linearization and input decoupling, under complete model knowledge.However, the analysis is restricted to systems with equal number of states, inputs and outputs.
In this paper, we focus on Lagrangian systems and we show that the choice of particular coordinates, called actuation coordinates, solves the ID problem without requiring a configuration-dependent transformation of the input nor a state-feedback.We derive necessary and sufficient conditions under which the actuation coordinates exist and constructively show that these coordinates solve the ID problem for fully actuated, overactuated, and underactuated Lagrangian systems.In particular, the unactuated coordinates remain arbitrary when the system is underactuated.
These results stem from power invariance under change of coordinates, as graphically illustrated in Fig. 1 for the fully actuated case.Remarkably, similar considerations hold also when the dynamics is underactuated.We apply the results to several mechanical examples as archetypal Lagrangian systems.In addition, we prove that robotic systems driven by thread-like actuators, such as inelastic tendons or thin fluidic chambers, always admit actuation coordinates.Our results have relevant consequences on the control of continuum soft robots and other underactuated mechanical systems.Indeed, recent control laws for planar underactuated soft robots [10], [23]- [26] generalize to all collocated mechanical systems with damping, such as soft robots moving in 3D.Interestingly, the energy-based regulator in [27] uses in fact actuation coordinates to decouple the equations of motion of a 3-DOF underactuated soft robotic system.Similarly, in flexible link robots, the actuation coordinates are the clamped angles at the base of each beam, which have been extensively used in Positive real numbers n TvX Tangent space of manifold Special Euclidean algebra of dimension 3 so(3) Special orthogonal algebra of dimension 3 Vector obtained by applying tanh(•) componentwise to v control design [28].
The paper is organized as follows.In Sec.II, we introduce the notation and formalize the ID problem.Section III defines the class of Lagrangian systems, called collocated, for which the ID problem is solvable.Necessary and sufficient conditions for solving the ID problem are then derived for fully actuated or overactuated dynamics (Sec.IV), and for underactuated systems (Sec.V).In Sec.VI, we prove that thread-like actuators yield collocated mechanical systems.Section VII extends two control strategies derived for underactuated mechanical systems with constant actuation matrix to the collocated case, validating one of these controllers on a 3D tendon-driven underactuated soft robot.Finally, conclusions and future works are summarized in Sec.VIII.

II. PRELIMINARIES A. Notation
We denote vectors and matrices with bold letters.Arguments of the functions are omitted when clear from the context.Table I presents the notation adopted in the paper.

B. Dynamic model
Let q ∈ M be the generalized coordinates of a dynamical system evolving on a n-dimensional smooth manifold M with Lagrangian L q (q, q).The system trajectories satisfy the Euler-Lagrange equations of motions where u ∈ R m are the available actuation inputs, A(q) ∈ R n×m is the actuation matrix, and τ q (q, u) ∈ Im(A(q)) collects the generalized forces performing work on q.For all q ∈ M, we assume that A(q) is a full-rank matrix, i.e., r = rank(A(q)) = min(m, n).When the dynamics is fully actuated (m = n) or underactuated (m < n), this is equivalent to asking that the actuation channels are all independent.On the other hand, if (1) is overactuated (m > n), we assume that there are exactly n independent inputs.Note that, for the following derivations, when r = m * < min(m, n) one can consistently discard m − m * linearly dependent columns of A(q) and consider the dynamics as underactuated.
In Appendix A, we recall two basic properties of Lagrangian systems used in the following results.

C. Problem statement
We look for a change of coordinates θ = h(q) from B(q) ⊂ M to N where each of the first r equations of motion in ( 1) is affected by one, and only one, independent actuator input, i.e., the right-hand side of the transformed equations of motion (see Property 2 in Appendix A) takes the form We refer to such problem as the Input Decoupling (ID) problem for the Lagrangian dynamics (1).If a solution exists, then we say that (1) admits a collocated form.Note that (2) covers only the fully-and underactuated cases.When the dynamics is overactuated, i.e., m > n, it is impossible to obtain (2) because only r = n input channels can be decoupled, and the remaining m − n inputs will affect the dynamics through a configuration-dependent actuation matrix.

III. COLLOCATED LAGRANGIAN SYSTEMS
In this section, we characterize a new class of Lagrangian systems, which we call collocated because only such Lagrangian dynamics admit a collocated form under a change of generalized coordinates.In addition, a set of coordinates that solve the ID problem come for free without further system analysis.
To this end, we will exploit a concept that is known as the passive output in the context of passivity-based control [29].Consider the following vector function linear in the velocity ẏ = A T (q) q, which is called the passive output because (1) is passive with respect to the pair (u, ẏ), with the storage function being the system Hamiltonian (see Appendix A).We will assume that (1) has ẏ integrable, i.e., Integrability assumption.For all q ∈ M, there exists a function g(q) : M → R m such that If the passive output is integrable, then we say that the Lagrangian system (1) is collocated because it admits a collocated form as defined in Section II-C.Furthermore, we define y = g(q) as actuation coordinates because, in such coordinates, u acts directly on the equations of motion according to (2).
Remark.Each component of g(q) is defined up to a constant since any function ḡ(q) = g(q) + k, with k ∈ R m , satisfies the condition J ḡ = J g .
The integrability assumption requires each column of A(q) to be the gradient of a scalar function of the configuration variables.If A(q) is constant, i.e., A(q) = A, then g(q) = A T q.More in general, when the column A i (q) has continuous partial derivatives, ẏi = A T i (q) q is integrable [30, Chap.2] if and only if Note that this condition is equivalent to asking that, when u i is constant, the generalized work done by u i on q does not depend on the system trajectories but only on the initial and final configurations q a and q b , respectively, i.e., where the last equality follows from the Gradient Theorem [30, Prop. 1, Chap.2].In other words, P i (u i , q) := u i g i (q) plays the role of a potential energy for the dynamics.If the actuation matrix is obtained using a differential formalism, such as the virtual works principle, it is reasonable to expect-although without any guarantee-that the integrability holds due to the inherent differentiation involved.It is also worth observing the following.
Remark.If A T (q) is integrable according to (3), then the orthogonal complement to the co-distribution spanned by A T (q) satisfies the Frobenius theorem.However, in general, the inverse implication does not hold without also an input transformation.
Even when ( 4) is satisfied, it could be challenging to integrate the passive output ẏ in closed form.Nonetheless, it is always possible to perform the numerical integration online based on the measure of q and q.Assuming an exact knowledge of A(q) and neglecting integration errors, there is formally no difference in having y in closed form or computing it online.Furthermore, in many cases, the numerical integration should not be necessary.This is because the actuation coordinates are inherently related to the system inputs and should be easily measurable.
In some cases, the integrability may come directly as a consequence of the physical nature of the system, as illustrated in the following.
Example 1 (Cartesian forces on a robot).Inspired by [31], consider a manipulator with n-DOF subject to m external forces applied on its structure.Assume that each force f i changes its magnitude over time but keeps the same direction in the global Cartesian frame so that with ∥d f ,i ∥ = 1, and where d f ,i ∈ R 3 represents the direction of f i and u i ∈ R >0 its magnitude.If p i (q) ∈ R 3 denotes the Figure 2. A geostationary satellite actuated by a normal force u 1 and a tangential force u 2 .The body configuration is described by the distance q 1 from the Earth center and the angle q 2 with respect to the horizontal axis.Only the normal force is collocated because it performs work directly and only on q 1 .point of application of f i in the global frame, then the effect of the force in the dynamics is

Thus, one can integrate
On the other hand, the integrability conditions may not hold even for elementary dynamics.
Example 2 (Geostationary satellite).Consider a geostationary satellite orbiting around the Earth in a plane.The configuration q = (q 1 q 2 ) T describes its motion, being q 1 the distance from the Earth center and q 2 the angle with respect to a reference axis, as shown in Fig. 2. The satellite is controlled by a normal and tangential force, denoted as u 1 and u 2 , respectively.The application of the Lagrangian formalism yields The first column of A(q) is already in the collocated form because u 1 performs work only on q 1 .However, the second column of A(q) is non-integrable because Indeed, the generalized work done on q by the tangential force u 2 depends on the time evolution of q 1 .◁ In the following, we consider the three different actuation scenarios, namely fully actuated, overactuated and underactuated dynamics.

IV. CHANGE OF COORDINATES FOR FULLY ACTUATED SYSTEMS
In this section, we show that when the system is fully actuated, the existence of n actuator coordinates is necessary and sufficient to bring the dynamics to the collocated form.This case allows illustrating the results in the most simple scenario, where an input transformation is sufficient to solve the ID problem.However, the same arguments will be used also for underactuated systems.
Theorem 1. Suppose the system is fully actuated, i.e., m = n.There exists a change of coordinates θ = h(q) : B(q) → N such that (1) takes the form i.e., A θ (θ) = I n , if and only if the integrability assumption (3) holds.Let g(q) be the integral of A T (q) q.Then, a possible choice for θ is θ = g(q).
Proof.Under the integrability assumption, θ = g(q) defines a change of coordinates because its Jacobian J g (q) = A T (q) has rank n at q. Since the generalized power is coordinate invariant (Property 2 in Appendix A), it follows θT τ θ = qT τ q .
Noting that θ = J g (q) q and using τ q = A(q)u, the above equation rewrites as Since ( 6) holds for all q ∈ T q M, it follows that Furthermore, J g (q) = A T (q) leads to The above equation defines a homogeneous linear system in the unknown τ θ −u, which admits the unique solution τ θ = u since A(q) is nonsingular, thus yielding the sufficiency of (5).
As for the necessity, suppose that a change of coordinates θ = h(q) exists such that (5) holds.Property 2 implies that, for all q ∈ T q M, qT J T h (q) − A(q) u = 0, leading to Thus, it holds J T h (q) = A(q) and g(q) = h(q).The following example illustrates the above result.
Example 3 (Spring actuated mechanism).Consider a planar mechanism with two passive revolute joints, having angles q 1 and q 2 so that q = (q 1 q 2 ) T .A spring with stiffness k i is Figure 3.A planar mechanism with two rotational joints having configuration q ∈ S 1 × S 1 .Positive (relative) rotations are counted counterclockwise.For i = 1, 2, the force u i actuates a cart coupled to the robot by a linear spring of stiffness k i .The dynamics of the carts is negligible, and thus the forces u act instantaneously on the mechanism.attached to the distal end of each link, whose length is l i , i = 1, 2. The springs are also connected to two carts moving on linear rails under the forces u 1 and u 2 , with reference to Fig. 3. Assuming that the dynamics of the carts is negligible, it can be shown that the actuator inputs u directly affect the joint motion through the actuation matrix where s i (c i ) = sin(q i )(cos(q i )) and s ij (c ij ) = sin(q i + q j )(cos(q i + q j )).Outside of singularities q 1 ∈ {0, π} and q 1 + q 2 ∈ {±π/2}, rank(A(q)) = 2 and the integrability test ( 4) is successful because The passive output is integrable as Note that y 1 is the x-coordinate of the position of the spring end attached to link 1.Similarly, y 2 is the y-coordinate of the spring attached to link 2. Indeed, the forces u 1 and u 2 perform work on the distal ends of the spring attached to the mechanism along these directions.◁

A. Overactuated case
The previous result extends to overactuated systems, namely dynamics with more inputs than generalized coordinates.Thus, we have r = n < m.We partition A(q), which is a wide matrix, as where A a (q) ∈ R n×n and A o (q) ∈ R n×(m−n) .Without loss of generality, we can have that rank (A a (q)) = n and the integrability condition holds for A a (q).
Corollary 1.If the system is overactuated, i.e., r = n < m and the same hypotheses of Theorem 1 hold for A a (q), then there exists a change of coordinates θ = h(q) : B(q) → N such that (1) takes the form where If g(q) is the integral of A T a (q) q, then θ can be chosen as θ = g(q).Proof.Choosing again θ = g(q) and following steps similar to those of the proof of Theorem 1, one obtains A a (q)τ θ = A(q)u.
Expanding A(q) into ( 7) and left-multiplying the above equation by A −1 a (q) gives τ )u, with q = g −1 (θ).Now, assume a change of coordinates θ = h(q) exists such that (8) holds.After some computations, power invariance leads to the algebraic system which must hold for all u ∈ R m .By taking . Hence, at least n passive outputs are integrable as y = h(q).Note that it is not possible, in general, to simplify the expression of both terms in the actuation matrix because there are too many input variables to be decoupled.
Example 4 (Tendon driven joint).Consider the tendon driven finger of [32,Chap. 6.4] with 1-DOF q and two actuator inputs u = (u 1 u 2 ) T , as sketched in Fig. 4. Assume for simplicity that the angle q > 0 (similar results hold for q < 0).The system input is τ q = A(q)u, where and u collects the cable tensions.Thus, the passive output is A tendon-driven rotational joint having a single configuration variable q ∈ S 1 .The cables tension u 1 and u 2 generate a torque at the joint.
Since the system is overactuated, there are two possible choices of the actuation coordinates out of singularities of A(q).When q = −2 tan −1 a b , the first column of A(q) becomes zero, and the first actuator does not have any effect on the motion.In this case, one can easily integrate ẏ as As expected, the choice of either the first or second component of y yields dynamics in the form of (8).Note that y is the tendon displacement with respect to the straight configuration.In fact, the system inputs perform work directly on the finger tendons.◁

V. CHANGE OF COORDINATES FOR UNDERACTUATED SYSTEMS
We now focus on underactuated systems, specifically dynamics for which the number of independent actuator inputs is less than that of degrees of freedom.In the following, we show that also in this case the actuation coordinates solve the input decoupling problem.First, it is convenient to expand the actuation matrix as where A a (q) ∈ R m×m is nonsingular and A u (q) ∈ R (n−m)×m .Note that such partition is always possible after reordering the linearly independent rows of A(q).Furthermore, since n > r = m, ẏ is an m-dimensional vector.
The integrability assumption is a necessary and sufficient condition for a change of coordinates θ = h(q) : B(q) → N to exist such that (1) becomes i.e., A θ (θ) has the form .
Let g(q) be the integral of A T (q) q.Then, a possible choice of θ is Proof.The choice of θ as given in (11) qualifies as a change of coordinates because its Jacobian is nonsingular at q. Power invariance and ( 12) imply θT τ θ = qT J T h (q)τ θ = qT A(q)u = qT τ q .
Furthermore, being q arbitrary, it follows J T h (q)τ θ = A(q)u, which can be rewritten as where we expanded τ θ into the two vectors τ θa ∈ R m and τ θu ∈ R n−m performing work on θ a and θ u , respectively.Equation ( 13) describes a homogeneous linear system with the unique solution being that J T h (q) is nonsingular.To prove the necessary part of the statement, suppose there exists θ = h(q) such that (10) holds and partition J h (q) = J ha (q) J hu (q) , with J ha (q) ∈ R m×n and J hu (q) ∈ R (n−m)×n .Exploiting once again power invariance, we obtain, after some computations, qT J T ha (q) − A(q) u = 0, or, equivalently, J ha (q) = A T (q).
Thus, the first m components of h(q) satisfy the integrability assumption.
In Appendix B, we report an alternative proof of the sufficient part of Theorem 2, which uses algebraic arguments instead of power invariance.
Remark.There is no constraint on choosing the unactuated variables, except that the corresponding Jacobian is nonsingular.Indeed, the factorization given in (13) holds independently of θ u .In other words, Theorem 2 does not rely on a specific choice of θ u , which could be used to further simplify the structure of the equations of motion.
Note that the previous results can also be derived in a Hamiltonian formulation by considering the type 2 generating function [33] G 2 (q, p) = h T (q)p, where p is the momentum in the actuation coordinates.
We illustrate the application of Theorem 2 on a soft robotic arm.
Figure 5.A continuum soft robot discretized into two bodies.Under the piecewise constant curvature assumption, the configuration of each body is described by its curvature κ i , bending angle ϕ i and elongation δL i for i = 1, 2. Three tendons run from the base to the tip, and spatial motion is obtained by applying a suitable cable tension u ∈ R 3 .
Example 5 (Continuum soft robot).Consider a continuum soft robot discretized into two bodies, modeled under the piecewise constant curvature (PCC) hypothesis.Then, each body has three DOF, corresponding to its curvature κ i , bending direction ϕ i and elongation δL i , i = 1, 2, so that Three tendons that run from the base to the tip actuate the robot.Each actuator is located at a distance d ∈ R + from the backbone and rotated from the previous by 120 • , as illustrated in Fig. 5.By exploiting the principle of virtual works, one can show that τ q = A(q)u, where and u ∈ R 3 collects the cables tension.It is easy to verify that rank(A(q)) = 3 except when q 1 = q 4 = 0 and q 2 = q 5 + kπ with k ∈ Z.In fact, control authority is lost when the arm is in the stretched configuration.However, this is an artifact due to the choice of the bending direction as generalized coordinate [34].Thus, the system is underactuated with m = 3 and n = 6.
It can be shown that (derivations are omitted for the sake of space) ẏ = A T (q) q ∈ R 3 can be integrated as According to Theorem 2, the ID problem is solvable through a coordinate change having the form where θ u ∈ R 3 is any complement to y.For example, a possible choice is Remarkably, the components of θ a correspond to the change of tendons length inside the arm.Similarly, θ u collects the tendons elongation in the first body only.
The reader can verify that J −T h takes the expression given by ( 17), which yields

VI. INTEGRABILITY OF THREAD-LIKE ACTUATORS
This section shows that the conclusions drawn in Examples 4 and 5 hold for any mechanical system driven by threadlike actuators.This type of actuation is growing in popularity because it allows creating lightweight structures with high power density, and precise and distributed actuation [35].We first prove the existence of the actuation coordinates for chains of rigid bodies.We then extend such result to continuum bodies described by reduced-order models.Consider a mechanical system of rigid bodies with n-DOF actuated through m inelastic tendons.As described in [32,Chap. 6], one can always define m extension functions g i (q); i ∈ {1, • • • , m}, that measure the tendons displacement as a function of q.The application of the principle of virtual works yields τ q = J T g (q)u = A(q)u, where u ∈ R m collects the tendons tension.It immediately follows that the passive output ẏ is integrable as y = g(q).This result extends to mechanical systems with continuum bodies modeled under the Geometric Variable Strain (GVS) technique, see [36], [37] for a detailed presentation of all the quantities defined in the following.We denote the strain as ξ ∈ R 6 , where X ∈ [0, L] is the curvilinear abscissa with L the body rest length.The GVS approach reduces the infinitedimensional state of the system by assuming that ξ admits a representation of the form where q ∈ R n is the configuration vector, parameterizing the strain.Under (18), the dynamic model of a continuum takes the form of (1) [38].For thread-like actuators, such as tendons and thin fluidic chambers, the generalized actuation force is τ q = A(q)u where and Φ a (X, q) ∈ R 6×m is the spatial actuation matrix, whose i-th column represents the distributed force of the i-th actuator.In the above expression, d i (X) ∈ R 3 and t i (X, q) ∈ R 3 are the actuator distance to the body backbone and its unit tangent vector [39], respectively.The latter can be computed as , where d i is expressed in homogeneous coordinates and (•) . Given t i (X, q) it is also possible to compute the length L ci of the actuator as or, after some manipulations, The time derivative of (20) is which implies that the passive output ẏ = A T (q) q is integrable as Thus, the actuation coordinates correspond to the length of the actuators, as for rigid systems.The above results are independent of the number of DOF and actuators.In other words, finite-dimensional models of mechanical systems actuated via tendons always admit a collocated form, independently of being fully-, over-, or underactuated.Recalling that the actuator coordinates are defined up to a constant, it is also possible to consider the actuator elongation δL ci := L ci − L * ci ; i ∈ {1, • • • , m}, with respect to a reference length L * ci ∈ R, such as that in the stress-free configuration.This way, proprioceptive sensors like encoders can easily measure the actuation coordinates.Consequently, the proposed change of coordinates is also helpful for control synthesis.
In Appendix C, we show that similar arguments apply to soft robots with volumetric actuators.

VII. CONTROL OF COLLOCATED UNDERACTUATED MECHANICAL SYSTEMS
The above results prove a fact empirically observed in soft and continuum robot control.In particular, several works [40]- [43] have shown that it is possible to obtain excellent closedloop performance in shape and position tasks by controlling the actuator length.This is the case for both model-based and model-free approaches.However, to the best of Authors knowledge, it has never been clarified why these coordinates represent a better choice than others, such as the curvature and bending direction.In the actuation coordinates, the dynamics is collocated, which is expected to simplify and robustify the closed loop, especially when the control law does not require significant system knowledge.When a controller is implemented in the actuation coordinates, explicit inversion of the actuation matrix is unnecessary because these coordinates inherently incorporate the inversion.It is also worth noting that any control problem formulated in the initial configuration space can be reformulated in the actuation coordinates.Remarkably, the above considerations remain true also when the dynamics is underactuated.Furthermore, note that direct inversion of A(q) is not possible in this case being A(q) a tall matrix.These results allow extending the controllers of [10], [23]- [26], [37] for planar underactuated mechanical systems with damping to those moving in 3D.The following corollary formalizes such statement for the regulators of [10] and [26].
Corollary 2. Consider an underactuated mechanical system satisfying the same hypotheses of Theorem 2. Suppose that there exists a dissipation function F(q, q) such that, for all q ∈ T q M, ∂F(q, q) ∂ q q > 0, and, in the actuation coordinates, Let K P , K D , K I ∈ R m×m > 0 and γ > 0. There exist constants α > 0 and γ > 0 such that, if K P > αI m and γ > γ, both the following regulators 1) PD+ (with feedforward) [10]: 2) P-satI-D [26]: will globally asymptotically stabilize the closed-loop system at (θ a θ u θa θu ) = (θ ad θ ud 0 0), where θ ad ∈ R m and θ ud ∈ R n−m is the unique solution to Under (22), for any value of the actuated coordinates θ a , there is a unique equilibrium of those unactuated, i.e., the system equilibria are uniquely determined by θ a .Instead, (21) guarantees internal stability of the closed-loop system.Note that the above controllers admit more general structures, see [10] and [26].In addition, despite being developed for continuum soft robots, these apply to any underactuated mechanical system with damping on the unactuated variables.
We exploit the previous corollary to perform a shape regulation task for a continuum soft robot moving in 3D.The robot has rest length L = 0.
where q ∈ R 15 , q * = 0 15 and ξ * = (0 0 1 0 0 0) T denote the stress-free configuration and strain, respectively, Σ(X) ∈ R 6×6 is the positive definite body stiffness matrix and the columns of Φ a ∈ R 6×8 are defined as in (19).The strain basis Σ −1 Φ a (X, q * ) has proven to accurately describe the deformations due to the actuation forces [39].Instead, encodes three Legendre polynomials modeling the angular deformations due to the gravitational field, not captured by Σ −1 Φ a .Since n = 15 and r = m = 8, the system is underactuated.Note that only shape regulation tasks can be achieved in general.We compare (24) with the PD+ regulator in q space of [44] u = −A † (q d ) ∂L q (q d , 0) ∂q Due to A(q), the above control law guarantees only local asymptotic stability [2], [44], and it requires information of the entire state of the robot to be implemented.The control gains of ( 24) and ( 25 ∂L q (q eq , 0) ∂q with u ∈ R 8 , can be controlled.We command the three desired shapes given in (26) as step references spaced in time by 2 [s].Furthermore, q d,i is converted into a desired tendon displacement θ ad,i (t) = y d,i (t); i = 1, 2, 3, for (24).The robot starts from the straight (stress-free) configuration at rest, and the simulation runs for 6 [s].In the following simulations, y has been computed through numerical integration because it was impossible to derive its closed form expression. On the other hand, in a experimental setup equipped with motor encoders y could have been directly evaluated or obtained from the available measurements.On the other hand, the PD+ in q space fails this task, always showing a steady state error.However, the closed-loop system remains stable.The control action for the two closed-loop systems is reported in Fig. 6.Note that the controllers outputs are quite different.Finally, Fig. 8

VIII. CONCLUSIONS
This article has considered the input decoupling problem for Lagrangian systems.We have shown that there exists a class of Lagrangian dynamics, called collocated, for which a coordinate transformation decouples actuator inputs entering the equations of motion through a configuration-dependent actuation matrix.These coordinates have a physical interpretation and can be easily computed.Under mild conditions on the differentiability of the actuation matrix, a simple test allows verifying if the dynamics is collocated or not.As a consequence of power invariance, the results equally apply to fully actuated, overactuated and underactuated systems.In case of underactuated dynamics, inputs are collocated with the actuation coordinates, while some freedom in left in the definition of the unactuated coordinates.Since we consider only coordinate transformations, the proposed method differs from the standard differential geometric approach used for controlling input-affine nonlinear systems, which typically makes use of complete feedback transformations.As a byproduct of our approach, we have shown that all mechanical systems driven by thread-like actuators are collocated.Moreover, we were able to extend control laws recently developed for underactuated systems with constant actuation matrix to collocated mechanical systems with damping.Future work will be devoted to the experimental validation of the proposed method and to special choices of the unactuated variables that further simplify the equations of motion, ease the check of conditions for obtaining input-state or inputoutput exact linearization via feedback, or even reveal the existence of flat outputs for the system.Additionally, we will consider relaxing the integrability hypothesis at the cost of transforming the input.

A. Properties of Lagrangian systems
We recall two important properties of Lagrangian systems that play a key role in deriving the results in this paper.Property 1.Let H q (q, q) := ∂L q (q, q) ∂ q q − L q (q, q) be the system Hamiltonian.For all q ∈ M, q ∈ T q M and u ∈ R m , it holds Ḣq (q, q) = qT τ q (q, u).
Equation (27) states that the time rate of change of the Hamiltonian, i.e., the system total energy, equals the input power.It also follows from ( 1) and ( 27) that the dynamics is passive with respect to the pair (u, ẏ) = u, A T (q) q with storage function H q (q, q). where ).This also implies that, for all θ ∈ N , θ ∈ T θ N , q ∈ M, q ∈ T q M and u ∈ R m , it holds Ḣθ (θ, θ) = θT τ θ (θ, u) = qT τ q (q, u) = Ḣq (q, q), (29) being H θ (θ, θ) = H q (q = h −1 (θ), q = J −1 h θ).According to the above property, the Euler-Lagrange equations and the power are invariant, i.e., they do not depend on the choice of coordinates representing the dynamics.

B. Alternative proof of Theorem 2
We provide an alternative proof of the if part of Theorem 2. Similar considerations also hold for Theorem 1 and Corollary 1.
Proof.From Property 2, we have By exploiting the block triangular structure of J h (q) it follows which yields A a (q) A u (q) = I m O (n−m)×m .q 1 q 2 q 3 q 4 q 5 q 6 q 7 q 8 q 9 q 10 q 11 q 12 q 13 q 14 q 15 ref (d)

C. Integrability of volumetric actuators
Following arguments similar to those of [45], it is possible to extend the results of Sec.VI to robotic systems with volumetric actuators [46].
Let V * i be the volume of the i-th actuator inside the robot when in the reference configuration.Similarly, denote with V i (q) the volume in the current deformed configuration.The work performed by the actuator on the robot is To determine the effect of u i on the generalized coordinates it is possible to apply the principle of virtual works δW (τ q )i = δq T (τ q ) i = δq T ∂V i (q) ∂q T u i = δW ui , obtaining A i (q) = ∂V i (q) ∂q T .
The above equations imply that ẏi = A T i (q) q is integrable and the corresponding actuation coordinate can be chosen as δV i := V i (q) − V * i , which is the volume variation in the actuator chamber.
4 [m] and cross section radius R ∈ [0.02; 0.008] [m], which varies linearly from the base to the tip.The mass density is ρ = 680 [kg/m 3 ].Furthermore, we consider a linear visco-elastic stress-strain curve with Young modulus E = 8.88 × 10 5 [N/m 2 ], Poisson ratio P = 0.5 and material damping D = 1 × 10 4 [N/m 2 s].Eight tendons actuate the robot.The first six have an oblique routing and are displaced 60 • each.Their initial distance from the center line is 0.0016 [m].Three of these run from the base to half of the robot, while the remaining ones up to the tip.The last two tendons have an helical routing with pitch 0.4 2π [m] and are displaced 180 • , with a distance from the backbone of 0.006 [m].The strain is modeled as ) are K P = k P I 8 , K D = k D I 8 , K I = k I I 8 and γ = 1, with k P = 2.5 × 10 3 [N/m], k D = 10 [Ns/m] and k I = 2 × 10 3 [N/ms].Because of the underactuation, only the configurations satisfying the equilibrium equation Figures 7(a)-7(c) and 7(a)-7(c) show the evolution of the actuation coordinates and the configuration variables under (24) and (25), respectively, for three sub-intervals of length 1 [s].As expected, the P-satI-D regulates the actuation coordinates to the desired set point.
presents a photo sequence of the two closed-loop systems.The end-effector reaches the correct position only under the P-satI-D.Indeed, the average norm of the steady-state Cartesian error is 5.8•10 −5 [m] for the P-satI-D and, respectively, 1.2•10 −2 [m] for the PD+ regulator.

q d, 1 =Figure 6 .
Figure 6.Time evolution of the control inputs under the P-satI-D (24) in y space and the PD+ (25) in q space, respectively.

Figure 7 .
Figure 7. Time evolutions of (a)-(c) actuator elongations and (d)-(f) configuration variables under the P-satI-D (24) in y space and the PD+ (25) in space, respectively.The P-satI-D regulates the actuation coordinates to the desired target.On the other hand, the closed-loop system under the PD+ regulator is stable but has a steady-state error.

Figure 8 .
Figure 8. Frame sequences of robot motion, divided in three time windows.Figs.(a)-(c) and (d)-(f) show the robot when controlled in the y or q coordinates using the laws (24) and (25), respectively.The initial and final configurations of each interval are shown in blue, while light gray shapes represent intermediate configurations.A red star indicates the constant target position of the end-effector.