On Optimization Techniques for a Class of Hybrid Mechanical Systems

Several classes of general hybrid and switched dynamic systems have been extensively studied, both in theory and practice [3,4,7,11,14,17,19,26,27,30]. In particular, driven by engineering requirements, there has been increasing interest in optimal design for hybrid control systems [3,4,7,8,13,17,23,26,27]. In this paper, we investigate some specific types of hybrid systems, namely hybrid systems of mechanical nature, and study the corresponding hybrid OCPs. The class of dynamic models to be discussed in this work concerns hybrid systems where discrete transitions are being triggered by the continuous dynamics. The control objective (control design) is to minimize a cost functional, where the control parameters are the conventional control inputs.


Introduction
Several classes of general hybrid and switched dynamic systems have been extensively studied, both in theory and practice [3,4,7,11,14,17,19,26,27,30]. In particular, driven by engineering requirements, there has been increasing interest in optimal design for hybrid control systems [3,4,7,8,13,17,23,26,27]. In this paper, we investigate some specific types of hybrid systems, namely hybrid systems of mechanical nature, and study the corresponding hybrid OCPs. The class of dynamic models to be discussed in this work concerns hybrid systems where discrete transitions are being triggered by the continuous dynamics. The control objective (control design) is to minimize a cost functional, where the control parameters are the conventional control inputs.
Recently, there has been considerable effort to develop theoretical and computational frameworks for complex control problems. Of particular importance is the ability to operate such systems in an optimal manner. In many real-world applications a controlled mechanical system presents the main modeling framework and can be specified as a strongly nonlinear dynamic system of high order [9,10,22]. Moreover, the majority of applied OCPs governed by sophisticated real-world mechanical systems are optimization problems of the hybrid nature. The most real-world mechanical control problems are becoming too complex to allow analytical solution. Thus, computational algorithms are inevitable in solving these problems. There is a number of results scattered in the literature on numerical methods for optimal control problems. One can find a fairly complete review in [3,4,8,24,25,29]. The main idea of our investigations is to use the variational structure of the solution to the specific two point boundary-value problem for the controllable hybrid-type mechanical systems in the form of Euler-Lagrange or Hamilton equation and to propose a new computational algorithm for the associated OCP. We consider an OCP in mechanics in a general setting and reduce the initial problem to a constrained multiobjective programming. This auxiliary optimization approach provides a basis for a possible numerical treatment of the original problem.
The outline of our paper is as follows. Section 2 contains some necessary basic facts related to the conventional and hybrid mechanical models. In Section 3 we formulate and study our main optimization problem for hybrid mechanical systems. Section 4 deals with the variational analysis of the OCP under consideration. We also briefly discuss the computational aspect of the proposed approach. In Section 5 we study a numerical example that constitutes an implementable hybrid mechanical system. Section 6 summarizes our contribution.

Preliminaries and some basic facts
Let us consider the following variational problem for a hybrid mechanical system that is characterized by a family of Lagrange functions {L p i }, p i ∈P where P is a finite set of indices (locations) and q(·) (q(t) ∈ R n ) is a continuously differentiable function. Here β [t i−1 ,t i ) (·) are characteristic functions of the time intervals [t i−1 , t i ), i = 1, ..., r associated with locations. Note that a full time interval [0, 1] is assumed to be separated into disjunct sub-intervals of the above type for a sequence of switching times: We refer to [3,4,7,8,13,17,23,26,27] for some concrete examples of hybrid systems with the above dynamic structure. Consider a class of hybrid mechanical systems that can be represented by n generalized configuration coordinates q 1 , ..., q n . The componentsq λ (t), λ = 1, ..., n ofq(t) are the so-called generalized velocities. Moreover, we assume thatL p i (t, ·, ·) are twice continuously differentiable convex functions. It is well known that the formal necessary optimality conditions for the given variational problem (1) describe the dynamics of the mechanical system under consideration. This description can be given for every particular location and finally, for the complete hybrid system. In this contribution, we study the hybrid dynamic models that free from the possible external influences (uncertainties) or forces. The optimality conditions for mentioned above can be rewritten in the form of the second-order Euler-Lagrange equations (see [1]) for all p i ∈P. The celebrated Hamilton Principle (see e.g., [1]) gives an equivalent variational characterization of the solution to the two-point boundary-value problem (2).
For the controllable hybrid mechanical systems with the parametrized (control inputs) Lagrangians L p i (t, q,q, u), p i ∈Pwe also can introduce the corresponding equations of motion d dt where u(·) ∈Uis a control function from the set of admissible controls U . Let where b 1,ν , b 2,ν , ν = 1, ..., m are constants. The introduced set U provides a standard example of an admissible control set. In this specific case we deal with the following set of admissible controls U C 1 m (0, 1). Note that L p i depends directly on the control function u(·). Let us assume that functions L p i (t, ·, ·, u) are twice continuously differentiable functions and every L p i (t, q,q, ·) is a continuously differentiable function. For a fixed admissible control u(·) we obtain for all p i ∈Pthe above hybrid mechanical system withL p i (t, q,q) ≡ L p i (t, q,q, u(t)). It is also assumed that L p i (t, q, ·, u) are strongly convex functions, i.e., for any holds for all p i ∈P . This natural convexity condition is a direct consequence of the classical representation for the kinetic energy of a conventional mechanical system. Under the above-mentioned assumptions, the two-point boundary-value problem (3) has a solution for every admissible control u(·) ∈U [18]. We assume that (3) has a unique solution for every u(·) ∈U. For an admissible control u(·) ∈Uthe solution to the boundary-value problem (3) is denoted by q u (·). We call (3) the hybrid Euler-Lagrange control system. Let us now give a simple example of the above mechanical model.

Example 1.
We consider a variable linear mass-spring system attached to a moving frame that is a generalization of the corresponding system from [22]. The considered control u(·) ∈U C 1 1 (0, 1) is the velocity of the frame. By ω p i we denote the variable masses of the system. The kinetic energy depends on the control input u(·). Therefore, we have By κ we denote here the elasticity coefficient of the spring system.
Note that some important controlled mechanical systems have a Lagrangian function of the following form (see e.g., [22])

www.intechopen.com
In this special case we easily obtain d dt Note that the control function u(·) is interpreted here as an external force.
Let us now consider the Hamiltonian reformulation for the controllable Euler-Lagrange system (3). For every location p i from P we introduce the generalized momenta and define the Hamiltonian function H p i (t, q, s, u) as a Legendre transform applied to every In the case of hyperregular Lagrangians L p i (t, q,q, u) (see e.g., [1]) the Legendre transform, namely, the mapping is a diffeomorphism for every p i ∈P,. Using the introduced Hamiltonian H(t, q, s, u),wecan rewrite system (3) in the following Hamilton-type forṁ Under the above-mentioned assumptions, the boundary-value problem (4) has a solution for every u(·) ∈U . We will call (4) a Hamilton control system. The main advantage of (4) in comparison with (3) is that (4) immediately constitutes a control system in standard state space form with state variables (q, s) (in physics usually called the phase variables). Consider the system of Example 1 with The Hamilton equations in this case are given as followṡ Clearly, for

Optimization of control processes in hybrid mechanical systems
Let us formally introduce the class of OCPs investigated in this paper: where f 0 p i : [0, 1] × R n × R m → R be continuous and convex on R n × R m objective functions. We have assumed that the boundary-value problems (3) have a unique solution q u (·) and that the optimization problem (5) also has a solution. Let (q opt (·), u opt (·)) be an optimal solution of (5). Note that we can also use the associated Hamiltonian-type representation of the initial OCP (5). We mainly focus our attention on the application of direct numerical algorithms to the hybrid optimization problem (5). A great amount of works is devoted to the direct or indirect numerical methods for conventional and hybrid OC problems (see e.g., [8,24,25,29] and references therein). Evidently, an OC problem involving ordinary differential equations can be formulated in various ways as an optimization problem in a suitable function space and solved by some standard numerical algorithms (e.g., by applying a first-order methods [3,24]).

Example 2.
Using the Euler-Lagrange control system from Example 1, we now examine the following OCP where k p i are given (variable) coefficients. Let ω p i ≥ 4κ/π 2 for every p i ∈P. The solution q u (·) of the associated boundary-value problem can be written as follows Let now k p i = 1 for all p i ∈P . Using the Hybrid Maximum Principle (see [4]), we conclude that the admissible control u opt (t) ≡ 0.5 is an optimal solution of the given OCP. Note that this result is also consistent with the Bauer Maximum Principle (see e.g., [2] ). For u opt (·) we can compute the corresponding optimal trajectory given as follows Evidently, we have κ/ω p i ≤ π/2 for every location p i . Moreover, q opt (t) ≤ 3 under the condition q opt (·) ∈ C 1 1 (0, 1).
Finally, note that a wide family of classical impulsive control systems (see e.g., [12]) can be described by the conventional controllable Euler-Lagrange or Hamilton equations (see [5]). Moreover, we refer to [6] for impulsive hybrid control systems and associated OCPs. Thus the impulsive hybrid systems of mechanical nature can also be incorporated into the modeling framework presented in this section.

The variational approach to hybrid OCPs of mechanical nature
An effective numerical procedure, as a rule, uses the specific structure of the problem under consideration. Our aim is to study the variational structure of the main OCP (5). Let where i = 1, ..., r.. The vectors c i , where i = 1, ..., r are defined by the corresponding switching mechanism of a concrete hybrid system. We refer to [3,4,26] for some possible switching rules determined for various classes of hybrid control systems. We now present an immediate consequence of the classical Hamilton Principle from analytical mechanics.  For an admissible control function u(·) from U we now introduce the following two functionals for all indexes p i ∈P . Generally, we define q u (·) as an element of the Sobolev space W 1,∞ n (0, 1), i.e., the space of absolutely continuous functions with essentially bounded derivatives. Let us give a variational interpretation of the admissible solutions q u (·) to a sequence of problems (3).
Proof. Let q u (·) ∈ W 1,∞ n (t i−1 , t i ) be a unique solution of a partial problem (3) on the corresponding time interval, where u(·) ∈U C 1 m (0, 1). Using the Hamilton Principle in every location p i inP, we obtain the following relations If the condition (6) is satisfied, then q u (·) is a solution of the sequence of the boundary-value problem (3). This completes the proof.
It is a challenging issue to develop necessary optimality conditions for the proper Pareto optimal (efficient) solutions. A number of theoretical papers concerning multiobjective optimization are related to this type of Pareto solutions. One can find a fairly complete review in [20]. Note that the formulation of the necessary optimality conditions (9) involves the Clarke generalized gradient of the Lagrange function. On the other hand, there are more effective necessary conditions for optimality based on the concept of the Mordukhovich limiting subdifferentials [20]. The use of the above-mentioned Clarke approach is motivated here by the availability of the corresponding powerful software packages.
When solving constrained optimization based on some necessary conditions for optimality one is often faced with a technical difficulty, namely, with the irregularity of the Lagrange multiplier associated with the objective functional [15,20]. Various supplementary conditions (constraint qualifications) have been proposed under which it is possible to assert that the Lagrange multiplier rule holds in "normal" form, i.e., that the first Lagrange multiplier is nonequal to zero. In this case we call the corresponding minimization problem regular. Examples of the constraint qualifications are the well known Slater (regularity) condition for classic convex programming and the Mangasarian-Fromovitz regularity conditions for general nonlinear optimization problems. We refer to [15,20] for details. In the case of a conventional multiobjective optimization problem the corresponding regularity conditions can be given in the form of so called KKT constraint qualification (see [28] for details). In the following, we assume that problems (7) and (8) are regular.
Consider now the numerical aspects of the solution procedure associated with (7) and recall that discrete approximation techniques have been recognized as a powerful tool for solving optimal control problems [3,25,29]. Our aim is to use a discrete approximation of (7) and to obtain a finite-dimensional auxiliary optimization problem. Let N be a sufficiently large positive integer number and where J N and P N are discrete variants of the objective functionals J and P from (7). Moreover, Γ N i is a correspondingly discrete set Γ i and C 1 m,N (0, 1) is set of suitable discrete functions that approximate the trajectories set C 1 m (0, 1). Note that the initial continuous optimization problem can also be presented in a similar discrete manner. For example, we can introduce the (Euclidean) spaces of piecewise constant trajectories q N (·) and piecewise constant control functions u N (·). As we can see the Banach space C 1 n (0, 1) and the Hilbert space L 2 m ([0, 1]) will be replaced in that case by some appropriate finite-dimensional spaces.
The discrete optimization problem (10) approximates the infinite-dimensional optimization problem (7). We assume that the set of all weak Pareto optimal solution of the discrete problem (10) is nonempty. Moreover, similarly to the initial optimization problem (7) we also assume that the discrete problem (10) is regular. If P(·) is a convex functional, then the discrete multiobjective optimization problem (10) is also a convex problem. Analogously to the continuous case (7) or (8) we also can write the corresponding KKT optimality conditions for a finite-dimensional optimization problem over the set of variables (q N (·), u N (·)). The necessary optimality conditions for a discretized problem (10) reduce the finite-dimensional multiobjective optimization problem to a system of nonlinear equations. This problem can be solved by some gradient-based or Newton-type methods (see e.g., [24]).
Finally, note that the proposed numerical approach uses the necessary optimality conditions, namely the KKT conditions, for the discrete variant (10) of the initial optimization problem (7). It is common knowledge that some necessary conditions of optimality for discrete systems, for example the discrete version of the classical Pontryagin Maximum Principle, are non-correct in the absence of some restrictive assumptions. For a constructive numerical treatment of the discrete optimization problem it is necessary to apply some suitable modifications of the conventional optimality conditions. For instance, in the case of discrete optimal control problems one can use so-called Approximate Maximum Principle which is specially designed for discrete approximations of general OCPs [21].

Mechanical example
This section is devoted to a short numerical illustration of the proposed hybrid approach to mechanical systems. We deal with a practically motivated model that has the following structure (see Fig. 1).
Let us firstly describe the parameters of the mechanical model under consideration: • q 2 is the position of inertia J 2 .
• J m is an inertia of motor.
• B m it corresponds to the friction of the motor.
• B 1 , B 2 they correspond to the frictions of the inertias J 1 , J 2 .
• k is a constant called the rate or spring constant.
• u it corresponds to the torque of motor.
The relations for the kinetic potential energies give a rise to the corresponding Lagrange dynamics: Finally, we have and the Euler-Lagrange equation with respect to the generalized coordinate q 1 has the following form We now considered the Euler-Lagrange equation with respect to the second generalized variable, namely, with respect to q 2 d dt We get the next relation J 2q2 (t)+B 2q2 (t)+k(q 2 (t) − q 1 (t)) = 0 12

Will-be-set-by-IN-TECH
Finally, let us present the simulation results (figure 2). As we can see, the state x 4 satisfies the switching condition x 4 + 10 = 0. The computed switching time is equal to t swi = 0.0057s. The dynamic behaviour on the second time-interval [0, 50] is presented on the figure (2). The obtained trajectories of the hybrid states converges to zero. As we can see the dynamic behaviour of the state vector X opt (t) generated by the optimal hybrid control u opt (·) guarantee a minimal value of the quadratic functional I(·). This minimal value characterize the specific control design that guarantee an optimal operation (in the sense of the selected objective) of the hybrid dynamic system under consideration.

Concluding remarks
In this paper we propose new theoretical and computational approaches to a specific class of hybrid OCPs motivated by general mechanical systems. Using a variational structure of the nonlinear mechanical systems described by hybrid-type Euler-lagrange or Hamilton equations, one can formulate an auxiliary problem of multiobjective optimization. This problem and the corresponding theoretical and numerical techniques from multiobjective optimization can be effectively applied to numerical solution of the initial hybrid OCP.
The proofs of our results and the consideration of the main numerical concepts are realized under some differentiability conditions and convexity assumptions. These restrictive smoothness assumptions are motivated by the "classical" structure of the mechanical hybrid systems under consideration. On the other hand, the modern variational analysis proceeds without the above restrictive smoothness assumptions. We refer to [20,21] for theoretical details. Evidently, the nonsmooth variational analysis and the corresponding optimization techniques can be considered as a possible mathematical tool for the analysis of discontinuous (for example, variable structure) and impulsive (nonsmooth) hybrid mechanical systems.
Finally, note that the theoretical approach and the conceptual numerical aspects presented in this paper can be extended to some constrained OCPs with additional state and/or mixed constraints. In this case one needs to choose a suitable discretization procedure for the sophisticated initial OCP and to use the corresponding necessary optimality conditions. It seems also be possible to apply our theoretical and computational schemes to some practically motivated nonlinear hybrid and switched OCPs in mechanics, for example, to optimization problems in robots dynamics.