Nonlinear optimal control for the 4-DOF underactuated robotic tower crane

Tower cranes find wide use in construction works, in ports and in several loading and unloading procedures met in industry. A nonlinear optimal control approach is proposed for the dynamic model of the 4-DOF underactuated tower crane. The dynamic model of the robotic crane undergoes approximate linearization around a temporary operating point that is recomputed at each time-step of the control method. The linearization relies on Taylor series expansion and on the associated Jacobian matrices. For the linearized state-space model of the system a stabilizing optimal (H-infinity) feedback controller is designed. To compute the controller’s feedback gains an algebraic Riccati equation is repetitively solved at each iteration of the control algorithm. The stability properties of the control method are proven through Lyapunov analysis. The proposed control approach is advantageous because: (i) unlike the popular computed torque method for robotic manipulators, the new control approach is characterized by optimality and is also applicable when the number of control inputs is not equal to the robot’s number of DOFs, (ii) it achieves fast and accurate tracking of reference setpoints under minimal energy consumption by the robot’s actuators, (iii) unlike the popular Nonlinear Model Predictive Control method, the article’s nonlinear optimal control scheme is of proven global stability and convergence to the optimum.


Introduction
Tower-cranes are complicated mechatronic systems which are widely used for the transportation of payloads in a large workspace and at large height [1][2][3]. Tower cranes can accomplish accurate transport and positioning of heavy items in construction sites, in multi-storey building erection,in loading and unloading of cargos in ports and in storage tasks for the logistics industry [4][5][6]. Tower cranes exhibit the advantages of simple structure, convenient installation, low cost, high payload capacity and low energy consumption [7][8][9]. Tower cranes usually consist of an actuated jib arm, an actuated translational trolley and an unactuated payload below the trolley [3,10,11]. Tower cranes have a complicated and strongly nonlinear dynam-ics and are also subject to underactuation [12][13][14]. Major issues in the precise and safe operation of tower cranes are the accurate trajectory tracking about the cranes' moving parts, as well as the suppression of the swinging and sway motion of the payload which can emerge when large and fast manoeuvres take place [15][16][17]. Under such operating conditions tower cranes are also exposed to bending and torsional deformations therefore their operation is a demanding and delicate task [18,19]. Even nowadays most cranes are manually operated by skilled personnel. However, for human operators it is often difficult to achieve precise positioning and suppression of swinging and swaying phenomena [20,21]. Operational mistakes occur frequently when pursuing highly repetitive tasks under timepressure. To avoid the deficiencies of the human operation of cranes, automation of such systems has become a pre-requisite and to this end elaborated nonlinear control methods have been developed [22,23].
The use of robotic tower cranes is rapidly deploying in several construction, industrial and supply-chain applications and the treatment of the associated nonlinear control problems has become a necessity. To this end new results have been recently developed. In [24] a neural adaptive control method is introducted for 4-DOF tower cranes. In [25] a 2-DOF overhead and a 4-DOF rotary crane are controlled through a neural adaptive control scheme. In [26] a control method is presented about vibrations suppression in a 4-DOF tower crane with a flexible jib. In [27] a neural adaptive control scheme is developed for a doublependulum tower crane. In [27] a 4-DOF tower crane is controlled by a nonlinear controller that consists of a PD control part and a sliding-mode control part. In [28] an input-shaping control technique is applied to suppress oscillations in the 4-DOF underactuated robotic crane. Finally, in [29] an adaptive control scheme is proposed for an underactuated 2-DOF overhead crane.
In the present article, a nonlinear optimal control method is proposed for the 4-DOF nonlinear and underactuated model of tower cranes [30,31]. The dynamic model of the 4-DOF underactuated tower crane undergoes first approximate linearization around a temporary operating point which is updated at each sampling instance. This operating point is defined by the present value of the crane's state vector and by the last sampled value of the control inputs vector. The linearization process relies on first-order Taylor series expansion and on the computation of the associated Jacobian matrices [32][33][34]. The modelling error which is due to the truncation of higher-order terms in the Taylor series expansion, is proven to be small and is asymptotically compensated by the robustness of the control algorithm. For the approximately linearized state-space description of the system a stabilizing H-infinity feedback controller is defined.
The proposed H-infinity controller achieves the solution of the optimal control problem for the tower crane under model uncertainty and external perturbations [16]. Actually, it represents a min-max differential game which takes place between the control inputs of the system that try to minimize a cost function comprising a quadratic term of the state vector's tracking error and the model uncertainty or exogenous perturbation terms which try to maximize this cost function. To compute the stabilizing feedback gains of this controller an algebraic Riccati equation has to be also solved at each time-step of the control method [35][36][37]. The global stability properties of the control scheme are proven through Lyapunov analysis. First, it is proven that the control loop satisfies the Hinfinity tracking performance criterion [16,38]. Next, it is proven that under moderate conditions, global asymptotic stability of the control loop is ensured. To implement state estimation-based control without need to measure the entire state vector of the system the H-infinity Kalman Fil-ter is used as a robust state estimator. The nonlinear optimal control method retains the advantages of linear optimal control, that is fast and accurate tracking of reference setpoints under moderate variations of the control inputs [16].
The article has also a meaningful contribution to the area of nonlinear control. One can point out the advantages of the nonlinear optimal control method against Nonlinear Model Predictive Control (NMPC) [16]. In NMPC the stability properties of the control scheme remain unproven and the convergence of the iterative search for an optimum often depends on initialization and parameter values' selection. It is also noteworthy that the nonlinear optimal control method is applicable to a wider class of dynamical systems than approaches based on the solution of State Dependent Riccati Equations (SDRE). The SDRE approaches can be applied only to dynamical systems which can be transformed to the Linear Parameter Varying (LPV) form. Besides, the nonlinear optimal control method performs better than nonlinear optimal control schemes which use approximation of the solution of the Hamilton-Jacobi-Bellman equation by Galerkin series expansions. The stability properties of the Galerkin series expansion-based optimal control are still unproven.
The structure of the paper is as follows: In Sect. 2 the dynamic model of the tower crane is given and the associated state-space model is formulated in the affine-in-the-input nonlinear state-space form. In Sect. 3 the dynamic model of the robotic crane undergoes approximate linearization through Taylor series expansion and with the computation of the associated Jacobian matrices. In Sect. 4 the Hinfinity optimal control problem for the dynamic model of the tower crane is analyzed. In Sect. 5 the global stability properties of the H-infinity control scheme are proven through Lyapunov analysis. Besides, the H-infinity Kalman Filter is introduced as a robust state estimator. In Sect. 6 the accuracy of setpoints tracking by the state variables of the robotic crane, under the nonlinear optimal control method, is further confirmed through Simulation experiments. Finally, in Sect. 7 concluding remarks are stated.

State-of-the-art in the control of underactuated robotic cranes
As noted, robotic cranes can find use in construction works, in buildings erection, in loading and unloading of cargo-ships in ports, in heavy material lifting for several industrial tasks and in heavy items pick-and-place tasks in logistics. The solution of the nonlinear optimal control problem for underactuated robotic cranes is important for ensuring the reliable performance of robotic cranes in such applications. In the following, the state-of-the-art in the control of underactuated robotic cranes is outlined. To this end, indicative results are overviewed about (a) the use of established model-based and model-free control approaches in robotics, (b) the use of the proposed nonlinear optimal control methods in specific types of autonomous cranes. There exist several recent results showing the performance of advanced nonlinear control techniques to the stabilization and trajectory tracking problem of robotic cranes. In [39] Lyapunov stability analysis is used to select the gains of a PID-type conntroller so as to ensure global stability for an overhead robotic crane. In [27] a feedback controller which comprises a PID-type control part and an SMC-type control part is proposed for a 4-DOF robotic tower crane. Lyapunov stability analysis is used to select the feedback gains of the controller and to ensure global stability of the control loop. In [40] an adaptive fuzzy controller jointly with a disturbances estimator are used to stabilize an offshore boom crane. The controller's feedback gains are chosen through Lyapunov stability analysis so as to ensure global stability for the control loop. In [41] an adaptive PID-type controller is developed for dual rotary cranes. The selection of the controller's gains is performed through the system's Lyapunov analysis. Global stability is proven through the Lyapunov technique and LaSalle's invariance principle. In [42] adaptive output feedback control is proposed for a double-pendulum shipmounted crane while also considering uncertainty about the cargo's mass. The controller's gains and the adaptation law which are used for compensating for the model's uncertainty are chosen through Lyapunov analysis. In [29] a state-variables transformation and the backstepping control technique are used for treating the stabilization of a 2-DOF crane. The stability properties of the control method are proven through Lyapunov analysis. In [43] an energybased control method is proposed for the dynamic model of a large gantry crane which comprises also elements that are subjected to elastic deformation. Stability properties are demonstrated with the use of Lyapunov analysis. In [44] a knuckle boom crane is controlled by a cascade controller where the inner control loop is designed to damp out the pendulum oscillation, and the crane tip is controlled by the outer loop. An extended Kalman filter is used for the estimation of payload angles and angular velocity. In [45] modified tracking error variables and Lyapunov stability analysis are used to define a feedback controller that finally stabilizes a 4-DOF overhead crane. The global stability proof makes use of LaSalle's invariance principle. Moreover, in [46] the dynamic model of a knuckle boom crane is considered and a stabilizing feedback controller is designed about it using the Nonlinear Model Predictive Control concept and a Lyapunov analysis-based auxiliary controller.
In particular, the proposed nonlinear optimal control method is suitable for use in a variety of autonomous robotic cranes and several related results have been obtained [1,16,17]. Thus, one can note nonlinear optimal control for (i) the 4-DOF overhead crane, (ii) offshore boom cranes, (iii) the double-pendulum overhead crane, (iv) the 4-DOF tower crane and (v) quay-side cranes. The use of the nonlinear optimal control method in robotic systems is not limited into specific state-space forms (e.g., canonical forms, strict feedback or pure feedback forms). The computational complexity of the nonlinear optimal control method remains also moderate because (a) it does not require complicated changes of state variables and transformations of the cranes' state-space representation, (b) it does not rely on matrices for computing the robots' control inputs and consequently it avoids the risk of singularities, (c) it performs linearization around one single operating point which is easy to define, (d) it does not require the solution of multiple Riccati equations or LMIs, (e) it avoids the deadlocks of pole-placement techniques which arise in the case of underactuation.

State-space model of the tower crane
The diagram of the 4-DOF robotic tower crane in depicted in Fig. 1. The tower crane consists of an actuated jib arm, an actuated translational trolley and an unactuated payload below the trolley. The trolley of mass M can perform an one-dimensional motion along the jib. The load mass m is suspended from the vehicle with a rope of length L. The jib can rotate around the vertical axis. The state variables of the tower-crane are defined as follows: (i) φ is the turn angle of the crane, (ii)φ is the rate of change of the turn angle of the crane, (iii) η is the displacement of the trolley along the jib, (iv)η is the velocity of the jib, (v) δ 1 is the primary projection angle of the link that connects the trolley with the suspended load (swinging angle), (vi)δ 1 is the rate of change of the primary projection angle, (vii) δ 2 is the secondary projection angle of the link that connects the trolley with the suspended load (sway angle), (viii)δ 2 is the rate of change of the secondary projection angle [2,3].

Approximate linearization with Taylor series expansion
The dynamic model of the tower crane being initially expressed in the state-space forṁ undergoes approximate linearization at each sampling instance around the temporary operating point (x * , u * ), where x * is the present value of the system's state vector and u * is the last sampled value of the control inputs vector. The linearization process is based on Taylor series expansion and giveṡ whered is the cumulative disturbances vector which may be due to truncation of higher-order terms from the Taylor series expansion, exogenous perturbations, and sensor measurements noise of any distribution. Matrices A and B are Jacobian matrices of the Taylor series expansion which are defined as: This linearization approach which has been followed for implementing the nonlinear optimal control scheme results into a quite accurate model of the system's dynamics. Consider for instance the following affine-in-the-input state-space model whered 1 is the modelling error due to truncation of higher order terms in the Taylor series expansion of f (x) and g(x).

Next, by defining
Moreover by denotingd = -Ax * + f (x * ) + g(x * )u * +d 1 about the cumulative modelling error term in the Taylor series expansion procedure one haṡ which is the approximately linearized model of the dynamics of the system of Eq. (17). The term f (x * ) + g(x * )u * is the derivative of the state vector at (x * , u * ) which is almost annihilated by -Ax * .

Computation of Jacobian matrices
The computation of the Jacobian matrices A and B proceeds as follows: and also and finally Third row of the Jacobian matrix ∇ and also and finally Fifth row of the Jacobian matrix ∇ x f (x)| (x * ,u * ) : ∂f 5 ∂x 1 = 0, and also and finally Seventh row of the Jacobian matrix ∇ and also and finally Computation of the Jacobian matrix ∇ Sixth row of the Jacobian matrix ∇ Second row of the Jacobian matrix ∇ x g 2 (x)| (x * ,u * ) : ∂g 22 Fourth row of the Jacobian matrix ∇ x g 2 (x)| (x * ,u * ) : ∂g 42 , for i = 1, 2, . . . , 8. Next, one computes the partial derivatives of the subdeterminants M ij and of the determinant det M: Equivalently, one has Next, the derivatives of the elements of the inertia matrix M are computed. It holds that m 11 = m(sin 2 (x 3 ) cos 2 (x 7 ) + sin 2 (x 7 ))L 2 + 2mLx 3 cos(x 7 ) sin(x 3 ) + (m + M)x 2 3 + J. Thus one has: It holds that for i = 1.3, 5, 7 and also Next, the following partial derivatives of the elements c ij i = 1, 2, 3, 4 and j = 1, 2, 3, 4 of the Coriolis matrix are computed. It holds c 11 = (m + M)x 3 x 4 + mLx 3 cos(x 5 ) cos(x 7 )x 6 -mLx 3 sin(x 5 ) sin(x 7 )x 8 + mL sin(x 5 ) sin(x 7 )x 4 + mL 2 sin(x 5 ) cos(x 5 ) cos 2 (x 7 )x 6 + mL 2 cos 2 (x 5 ) sin(x 7 ) cos(x 7 )x 8 .

Equivalent linearized dynamics of the tower crane
After linearization around its current operating point, the dynamic model for the tower crane is written aṡ Parameter d 1 stands for the linearization error in the tower crane's model that was given previously in Eq. (17). The reference setpoints for the state vector of the aforementioned dynamic model are denoted by x d = [x d 1 , . . . , x d 8 ]. Tracking of this trajectory is achieved after applying the control input u * . At every time instant the control input u * is assumed to differ from the control input u appearing in Eq. (88) by an amount equal to u, that is u * = u + u The dynamics of the controlled system described in Eq. (88) can be also written aṡ and by denoting d 3 = -Bu * +d 1 as an aggregate disturbance term one obtainṡ By subtracting Eq. (89) from Eq. (91) one haṡ By denoting the tracking error as e = xx d and the aggregate disturbance term asd = d 3d 2 , the tracking error dynamics becomeṡ e = Ae + Bu +d.
The above linearized form of the tower crane's model can be efficiently controlled after applying an H-infinity feedback control scheme.

The nonlinear H-infinity control
The initial nonlinear model of the tower crane is in the forṁ Linearization of the model of the tower crane is performed at each iteration of the control algorithm around its present operating point (x * , u * ) = (x(t), u(t -T s )). The linearized equivalent of the system is described bẏ where matrices A and B are obtained from the computation of the previously defined Jacobians and vectord denotes disturbance terms due to linearization errors. The problem of disturbance rejection for the linearized model that is described bẏ where x ∈ R n , u ∈ R m ,d ∈ R q and y ∈ R p , cannot be handled efficiently if the classical LQR control scheme is applied. This is because of the existence of the perturbation term d. The disturbance termd apart from modeling (parametric) uncertainty and external perturbation terms can also represent noise terms of any distribution.
In the H ∞ control approach, a feedback control scheme is designed for trajectory tracking by the system's state vector and simultaneous disturbance rejection, considering that the disturbance affects the system in the worst possible manner. The disturbances' effects are incorporated in the following quadratic cost function: The significance of the negative sign in the cost function's term that is associated with the perturbation variablẽ d(t) is that the disturbance tries to maximize the cost function J(t) while the control signal u(t) tries to minimize it. The physical meaning of the relation given above is that the control signal and the disturbances compete to each other within a min-max differential game. This problem of minmax optimization can be written as min u maxdJ(u,d).
The objective of the optimization procedure is to compute a control signal u(t) which can compensate for the worst possible disturbance, that is externally imposed to the tower crane. However, the solution to the min-max optimization problem is directly related to the value of the parameter ρ. This means that there is an upper bound in the disturbances magnitude that can be annihilated by the control signal.

Computation of the feedback control gains
For the linearized system given by Eq. (96) the cost function of Eq. (97) is defined, where coefficient r determines the penalization of the control input and weight coefficient ρ determines the reward of the disturbances' effects. It is assumed that (i) The energy that is transferred from the disturbances signald(t) is bounded, that is ∞ 0d In the case of a tracking problem the optimal feedback control law is given by with e = xx d to be the tracking error, and K = 1 r B T P where P is a positive definite symmetric matrix. As it will be proven in Sect. 5, matrix P is obtained from the solution of the Riccati equation where Q is a positive semi-definite symmetric matrix. The worst case disturbance is given bỹ The solution of the H-infinity feedback control problem for the tower crane and the computation of the worst case disturbance that the related controller can sustain, comes from superposition of Bellman's optimality principle when considering that the robotic crane is affected by two separate inputs: the control input u and the cumulative disturbance inputd(t). Solving the optimal control problem for u, that is for the minimum variation (optimal) control input that achieves elimination of the state vector's tracking error, gives u = -1 r B T Pe. Equivalently, solving the optimal control problem ford, that is for the worst case disturbance that the control loop can sustain givesd = 1 ρ 2 L T Pe. The diagram of the considered control loop for the tower crane is depicted in Fig. 2.

Stability proof
Through Lyapunov stability analysis it will be shown that the proposed nonlinear control scheme assures H ∞ tracking performance for the underactuated tower crane, and that in case of bounded disturbance terms asymptotic convergence to the reference setpoints is achieved. The tracking error dynamics for the tower crane is written in the forṁ where in the tower crane's case L =∈ R 8×8 to be the disturbance inputs gain matrix. Variabled denotes model uncertainties and external disturbances of the tower crane's model. The following Lyapunov equation is considered where e = x-x d is the tracking error. By differentiating with respect to time one obtainṡ The previous equation is rewritten aṡ Assumption For given positive definite matrix Q and coefficients r and ρ there exists a positive definite matrix P, which is the solution of the following matrix equation Moreover, the following feedback control law is applied to the system Lemma The following inequality holds Proof The binomial (ρα -1 ρ b) 2 is considered. Expanding the left part of the above inequality one gets The following substitutions are carried out: a =d and b = e T PL and the previous relation becomes Equation (116) shows that the H ∞ tracking performance criterion is satisfied. The integration ofV from 0 to T gives Moreover, if there exists a positive constant M d > 0 such that then one gets Thus, the integral ∞ 0 e 2 Q dt is bounded. Moreover, V (T) is bounded and from the definition of the Lyapunov function V in Eq. (102) it becomes clear that e(t) will be also bounded since e(t) ∈ e = {e|e T Pe ≤ 2V (0) + ρ 2 M d }. According to the above and with the use of Barbalat's Lemma one obtains lim t→∞ e(t) = 0.
After following the stages of the stability proof one arrives at Eq. (116) which shows that the H-infinity tracking performance criterion holds. By selecting the attenuation coefficient ρ to be sufficiently small and in particular to satisfy ρ 2 < e 2 Q / d 2 one has that the first derivative of the Lyapunov function is upper bounded by 0. This condition holds at each sampling instance and consequently global stability for the control loop can be concluded.

Robust state estimation with the use of the H ∞ Kalman filter
The control loop has to be implemented with the use of information provided by a small number of sensors and by processing only a small number of state variables. To reconstruct the missing information about the state vector of the tower crane it is proposed to use a filtering scheme and based on it to apply state estimation-based control [1,36]. By denoting as A(k), B(k) and C(k) the discretetime equivalents of matrices A, B and C of the linearized state-space model of the system, the recursion of the H ∞ Kalman Filter for the model of the tower crane, can be formulated in terms of a measurement update and a time update part. Measurement update: Time update: where it is assumed that parameter θ is sufficiently small to assure that the covariance matrix P -(k) -1θ W (k) + C T (k)R(k) -1 C(k) will be positive definite. When θ = 0 the H ∞ Kalman Filter becomes equivalent to the standard Kalman Filter. One can measure only a part of the state vector of the crane, for instance state variables x 1 , x 3 , x 5 , and x 7 and can estimate through filtering the rest of the state vector elements (rate of change of φ, η, δ 1 and δ 2 ). Moreover, the proposed Kalman filtering method can be used for sensor fusion purposes.

Simulation tests
The global stability properties of the control method and the elimination of the state vector's tracking error which were previously proven through Lyapunov analysis are further confirmed through simulation experiments. To compute the stabilizing feedback gains of the controller, the algebraic Riccati equation of Eq. (107) had to be repetitively solved at each iteration of the control algorithm. The parameters of the dynamic model of the tower crane which have been used in the simulation experiments were according to [2,3]. All parameters and variables of the crane's model are measured in SI units. The obtained results are depicted in Fig. 3 to Fig. 18. The real values of the state variables of the tower crane are printed in blue, their estimates which are provided by the H-infinity Kalman Filter are printed in green colour while the associated setpoints are printed in red. The performance of the nonlinear optimal control method was very satisfactory. Actually, through all test cases it has been shown that the control method can achieve fast and accurate tracking of reference trajectories (setpoints) under moderate variations of the control inputs. The simulation tests come to confirm that the control method has global (and not local) stability properties. Under the nonlinear optimal control method the state variables of the tower crane can track precisely setpoints with fast and abrupt changes. Moreover, the convergence to these setpoints is independent from initial conditions. Regarding the selection of values for the controller gains it can be noted that parameters r, ρ and Q which appear in the method's algebraic Riccati equations are assigned offline constant values, where the gains vector K is updated at each sampling instance, based on the positive definite and symmetric matrix P which is the solution of the method's algebraic Riccati equation. The tracking accuracy and the transient performance of the control scheme depends on the values of coefficients r, ρ and on the values of the elements of the diagonal matrix Q. Actually, for relatively small values of r one achieves elimination of the state vector's tracking error one. Moreover, for relatively high values of the diagonal elements of matrix Q one achieves fast convergence the state variables' reference trajectories, Finally, the smallest value of the attenuation coefficient ρ that results into a valid solution of the method's Riccati equation in the form of the positive definite and symmetric matrix P, it the one that provides the control loop with maximum robustness.
Comparing to past attempts for solving the H-infinity control problem for nonlinear dynamical systems, the ar-  ticle's control approach is substantially different [16]. Preceding results on the use of H-infinity control to nonlinear dynamical systems were limited to the case of affine-in-the-input systems with drift-only dynamics and considered that the control inputs gain matrix is not dependent on the values of the system's state vector. Moreover, in    computing the feedback gains of the controller is novel, so is the presented global stability proof through Lyapunov analysis.
The proposed H-infinity (optimal) control method for the robotic tower crane exhibits several advantages when compared against other linear or nonlinear control schemes [16]. For instance: (i) In contrast to global linearization-based control schemes (Lie algebra-based control and differential flatness theory-based control) it does not need complicated changes of state-variables (diffeomorphisms) and does not come against singularity problems in the computation of the control inputs, (ii)  In contrast to sliding-mode control or to backstepping control the proposed nonlinear optimal control scheme does not require the state-space model of the system to be in a specific form (e.g. triangular, canonical, etc.) (iii) In contrast to PID control the proposed nonlinear optimal control method is globally stable and functions well at changes of operating points, (iv) In contrast to multimodels based control and linearization around multiple  operating points, the nonlinear optimal control scheme requires linearization around one single operating point and thus it avoids the computational load for solving multiple Riccati equations or LMIs.
To elaborate on the tracking performance and on the robustness of the proposed nonlinear optimal control method for the ball and plate system the following Tables are given: (i) Table 1 which provides information about the accuracy of tracking of the reference setpoints by the state variables of the tower crane's state-space model, (ii) Table 2 which provides information about the robustness of the control method to parametric changes in the model of   Table 3 which provides information about the precision in state variables' estimation that is achieved by the H-infinity Kalman Filter, (iv) Table 4 which provides the approximate convergence times of the tower crane's state variables to the associated setpoints.

Conclusions
Tower cranes are mechatronic systems with complicated nonlinear and multivariable dynamics which exhibit also underactuation. They are also exposed to undesirable swinging and swaying motions of the payload and such phenomena may prevent the precise positioning of the  Tracking of setpoint 8 for the tower crane (a) control inputs u 1 , u 2 applied to crane, (b) tracking error variables e 1 , e 3 , e 5 , e 7 of the tower crane transferred cargos or may slow down the execution and completion of load transport tasks. To circumvent such deficiencies, full automation of tower cranes' operation has been pursued with the development of elaborated nonlinear control algorithms. In the present article a novel nonlinear optimal control approach has been proposed for the dynamic model of the 4-DOF underactuated tower crane. At a first-stage the tower crane's dynamic model undergoes approximate linearization with the use of the first-order Taylor series expansion and through the computation of the associated Jacobian matrices. The linearization point is updated at each sampling instance and is defined by the    present value of the system's state vector and by the last sampled value of the control inputs vector. At a second stage a stabilizing H-infinity feedback controller is designed. To compute the stabilizing feedback gains of the H-infinity controller an algebraic Riccati equation had to be repetitively solved at each time-step of the control algorithm. The global stability properties of the control scheme have been proven through Lyapunov analysis. To implement state estimation-based control, the Hinfinity Kalman Filter has been used as a robust state es-timator. The nonlinear optimal control approach retains the advantages of the standard linear optimal control, that is fast and accurate tracking of reference setpoints under moderate variations of the control inputs. Finally, it is noted that the nonlinear optimal control method is of generic use and can be applied to a variety of robotic cranes, such as 4-DOF underactuated overhead (moving bridge and trolley) cranes, offshore boom cranes, doublependulum overhead cranes, 4-DOF underactuated tower cranes, and quay-side cranes and so on.