Keywords

1 Introduction

The tower crane is a typical example of underactuated systems, characterized by having fewer input variables than output variables [1,2,3]. Despite cost and structural advantages, designing controllers for them is complex due to limited input and high state coupling, posing significant challenges. Current manual operation leads to low efficiency and safety risks. Efficient tower crane controllers are crucial for improved performance and safety [4].

Over the years, tower cranes have seen extensive research in various control methods, including Sliding Mode Control (SMC), adaptive algorithms, and their combinations, aimed at enhancing performance, safety, and efficiency [5,6,7]. SMC offers robustness, rapid response, and precision, but may generate chattering. To address this, studies combine adaptive methods with SMC for smoother and more adaptable control. Tower crane dynamics are influenced by uncertainties and disturbances, handled by adaptive control algorithms, which adjust parameters in real-time for improved robustness [8, 9]. Additionally, fuzzy control and Observer-Based Nonlinear Control are employed for systems with imprecise information, estimating states and disturbances for effective monitoring and correction [10,11,12].

In construction, tower cranes aim for rapid and precise positioning while suppressing cargo swing. Although significant progress has been made in achieving these goals, further improvements are needed. In certain scenarios, operating at different heights leads to variations in cable lengths, inducing swing due to factors like wind and inertia. Dynamic cable length adjustment is essential for stable operations. Strong coupling among state variables requires constraints to ensure precise load control, especially in complex work environments with potential obstacles. Effective constraints prevent collisions and ensure reliable control. Constraints on both actuated and underactuated variables are crucial to prevent excessive swing angles and instability, avoiding accidents. Reasonable constraints on composite load position variables enhance operational efficiency and trajectory tracking.

This paper proposes a nonlinear control method for a five-degree-of-freedom tower crane with varying cable lengths, aiming to achieve multi-variable state constraints. The contributions are:

  1. 1)

    Establishing a model for the tower crane with variable cable lengths, enabling precise cargo hoisting, jib rotation, trolley transport, and effective swing suppression.

  2. 2)

    Devising a multi-variable constraint strategy, confining all state variables within well-defined ranges, including actuated, underactuated, and composite variables representing the load position.

  3. 3)

    Applying multi-variable constraints to ensure stable system dynamics, enabling accurate control of the load position and orientation for safe and efficient tower crane operation.

The structure of this article is as follows: In Sect. 2, the dynamic model of the system is introduced, and in Sect. 3, the controller design is presented. In Sect. 4, simulation tests using Simulink are performed, comparing the proposed method with the PD (Proportional-Derivative) approach.

2 Problem Formulation

2.1 Tower Crane System Dynamics

Based on the Lagrangian modeling technique, we derive the dynamic equations corresponding to the five degrees of freedom (DOF), resulting in five second-order nonlinear differential equations expressed as follows:

$$M({\mathbf{q}}){\ddot{\mathbf{q}}} + C({\mathbf{q}},{\dot{\mathbf{q}}}){\dot{\mathbf{q}}} + G({\mathbf{q}}) = {\mathbf{U}} - {\mathbf{Uf}}$$
(1)

where \({\mathbf{q}} = [\phi \; x\; l\; \theta_{1} \; \theta_{2} ]^{{\text{T}}}\) denotes the system state vector, \(l\) corresponds to the cable length, \(x\) and \(\phi\) represent the displacement of the trolley and the angle of the jib slew, respectively. Additionally, \(\theta 1\) and \(\theta 2\) refer to the swing angles of the payload, the input vector \({\mathbf{U}}{ = }[F\phi \; Fx\; Fl\; 0\; 0]^{{\text{T}}}\) consists of three control inputs: the tower rotating torque (\(F\phi\)), the trolley driving force (\(Fx\)), and the rope tension (\(Fl\)). Additionally, \({\mathbf{Uf}}{ = }[f\phi \;\;fx\; fl \;\;d1\dot{\theta }1 \;d2\dot{\theta }2]^{{\text{T}}}\) represents friction vector, \(d1\), \(d2\) represents the coefficients of friction \(M({\mathbf{q}})\), \(C({\mathbf{q}},{\dot{\mathbf{q}}}) \in {\mathbb{R}}^{3 \times 3}\) are inertia and centripetal-Coriolis matrices, respectively, and \({\mathbf{G}}{(}{\mathbf{q}}{) = [}0 \, 0 \, mg{ - }mg{\text{cos}}\theta_{1} {\text{cos}}\theta_{2} \, mgl{\text{sin}}\theta_{1} {\text{cos}}\theta_{2} \, mgl{\text{cos}}\theta_{1} {\text{sin}}\theta_{2} {]}^{{\text{T}}}\) is the gravitational force vector.

Fig. 1.
figure 1

Model of 5-DOF varying-cable-length tower cranes.

The DOF can be categorized into two vectors: actuated states (\({\mathbf{q}}_{{\mathbf{a}}}\)) and unactuated states (\({\mathbf{q}}_{{\mathbf{u}}}\)). The actuated states control the jib slew angle, trolley position, and suspension cable length, while the unactuated states correspond to the swing angles of the payload.

$${\mathbf{q}}_{{\mathbf{a}}} = {[ }\phi \; x \, l {]}^{{\text{T}}} ,{\mathbf{q}}_{{\mathbf{u}}} = [\theta_{1} \, \theta_{2} ]^{{\text{T}}}$$
(2)

Therefore, Eq. (1) is arranged into two equations

$$M_{11} {\ddot{\mathbf{q}}}_{a} + M_{12} {\ddot{\mathbf{q}}}_{u} + C_{11} {\dot{\mathbf{q}}}_{a} + C_{12} {\dot{\mathbf{q}}}_{u} + {\mathbf{G}}_{1} = {\mathbf{u}} - \Lambda_{a} {\dot{\mathbf{q}}}_{a}$$
(3)
$$M_{21} \user2{\ddot{q}}_{a} + M_{22} \user2{\ddot{q}}_{u} + C_{21} \dot{\user2{q}}_{a} + C_{22} \dot{\user2{q}}_{u} + {\mathbf{G}}_{2} = - \Lambda_{u} \user2{\ddot{q}}_{u}$$
(4)

where \(M_{11} ,C_{11} \in {\mathbb{R}}^{3 \times 3} ,\)\(M_{21} ,C_{21} \in {\mathbb{R}}^{2 \times 3} ,\)\(M_{22} ,C_{22} \in {\mathbb{R}}^{2 \times 2} ,\) \(M_{12} ,C_{12} \in {\mathbb{R}}^{3 \times 2}\), \(G_{1} \in {\mathbb{R}}^{{3}} {,}\)

\(G_{2} \in {\mathbb{R}}^{{2}}\), \(\Lambda_{a} \in {\mathbb{R}}^{3 \times 3} ,\)\(\Lambda_{u} \in {\mathbb{R}}^{2 \times 2} ,\)\(\Lambda_{a} {\dot{\mathbf{q}}}_{a}\) and \(\Lambda_{u} {\dot{\mathbf{q}}}_{u}\) represent the part corresponding to the actuated and the underactuated of \({\mathbf{Uf}}\).

The following reformulation of the equations will allow the control inputs to affect the unactuated dynamics. Equations (3) and (4) are rewritten as follows:

$${\ddot{\mathbf{q}}}_{a} = M_{a}^{ - 1} ({\mathbf{u}} - \Lambda_{a} {\dot{\mathbf{q}}}_{a} - C_{a} {\dot{\mathbf{q}}}_{a} - C_{u} {\dot{\mathbf{q}}}_{u} - {\mathbf{G}}_{a} + M_{12} M_{22}^{ - 1} \Lambda_{u} {\dot{\mathbf{q}}}_{u} )$$
(5)

where \(M_{a} ,C_{a} \in {\mathbb{R}}^{{{3} \times {3}}} {,}C_{u} \in {\mathbb{R}}^{{{3} \times {2}}} {,}{\mathbf{G}}_{a} \in {\mathbb{R}}^{{3}}\),\(\Lambda_{a} \in {\mathbb{R}}^{3 \times 3} ,\) \(\Lambda_{u} \in {\mathbb{R}}^{2 \times 2} ,\) denote some auxiliary matrices/vectors defined as follows:

$$M_{a} = M_{11} - M_{12} M_{22}^{ - 1} M_{21} ,C_{a} = C_{11} - M_{12} M_{22}^{ - 1} C_{21}$$
(6)
$$C_{u} = C_{12} - M_{12} M_{22}^{ - 1} C_{22} ,{\mathbf{G}}_{{\mathbf{a}}} = {\mathbf{G}}_{1} - M_{12} M_{22}^{ - 1} {\mathbf{G}}_{2}$$
(7)

2.2 Control Objective

For system (1), our objective is to design an appropriate control input to achieve the following goals:

Realize the positioning performance of the jib and trolley while eliminating the double-pendulum angles. So that the cantilever and the cart can reach the desired position accurately respectively, the sway angle of the payload can be suppressed to zero, described as

$$\mathop {\lim }\limits_{t \to \infty } \left[ {\phi (t),x(t),l(t),\theta_{1} (t),\theta_{2} (t)} \right]^{{\text{T}}} = \left[ {\phi_{d} ,x_{d} ,l_{d} 0,0} \right]^{{\text{T}}}$$
(8)

Throughout the control process, the maximum amplitudes of the actuated and unactuated state variables are limited to a suitable range:

$$q_{im} < q_{i} < q_{iM} ,i \in \{ 1,2,...5\}$$
(9)

where \(q_{i} (t)\) represents the \(ith\) state variable, while \(q_{{i{\text{m}}}}\) and \(q_{{i{\text{M}}}}\) stand for the lower and upper bounds of \(q_{i} (t)\),respectively.

The payload position must be confined within an appropriate safety range. The expression for the payload position is as follows:

$$\phi_{1} (q) = x_{p} (t) = x + l\sin \theta_{1}$$
(10)
$$\phi_{1m} < \phi_{1} ({\mathbf{q}}) < \phi_{1M}$$
(11)

where \(\phi_{1}\) represents the state variable, while \(\phi_{1m}\) and \(\phi_{1M}\) stand for the lower and upper bounds of \(\phi_{1} (t)\), respectively.

Property1 [12]:\(M({\mathbf{q}})\) is positive-definite, and \(\dot{M}({\mathbf{q}})/2 - C({\mathbf{q}},{\dot{\mathbf{q}}})\) is skew-symmetric, meaning that

$${{\varvec{\upxi}}}^{{\text{T}}} [\frac{{\dot{M}({\mathbf{q}})}}{2} - C({\mathbf{q}},{\dot{\mathbf{q}}})]{{\varvec{\upxi}}} = 0,\forall {{\varvec{\upxi}}} \in {\mathbb{R}}^{5}$$
(12)

3 Control System Design

In this section, we aim to address the diverse constraints, encompassing both actuated and unactuated state constraints, as well as constraints on specific composite variables. To achieve the objectives specified in Eqs. (8) - (11), we will devise auxiliary terms, incorporating constrained variable signals and actuated velocity signals.

By examining the comprehensive expression of \(Ma\), it can be demonstrated that \(Ma\) is a positive-definite matrix. Moreover, the shaped mechanical energy function of Eq. (1) can be represented as follows:

$$E_{s} (t) = \frac{1}{2}{\dot{\mathbf{q}}}^{{\text{T}}} M({\mathbf{q}}){\dot{\mathbf{q}}} + mgl(1 - \cos \theta_{1} \cos \theta_{2} )$$
(13)

where \(m\) denote the mass of trolley. Kinetic energy is a nonnegative scalar quantity and the value of \(mgl(1 - \cos \theta_{1} \cos \theta_{2} )\) is always nonnegative. It is evident that \(E_{s} (t)\) is nonnegative. By calculating the time derivative of Eq. (13) and performing simplifications using Eqs. (1), (12), we can derive the following relationship:

$$\begin{gathered} \dot{E}_{s} = {\dot{\mathbf{q}}}^{T} M({\mathbf{q}}){\ddot{\mathbf{q}}} + \frac{1}{2}{\dot{\mathbf{q}}}^{T} \dot{M}({\mathbf{q}}){\dot{\mathbf{q}}} + mg\dot{l}(1 - \cos \theta_{1} \cos \theta_{2} ) \hfill \\ \quad \; + m_{p} gl\dot{\theta }_{1} \sin \theta_{1} \cos \theta_{2} + m_{p} gl\dot{\theta }_{2} \cos \theta_{1} \sin \theta_{2} \hfill \\ \quad = (F_{\phi } - f_{\phi } )\dot{\phi } + (F_{x} - f_{x} )\dot{x} + (F_{l} - f_{l} + mg)\dot{l} \hfill \\ \end{gathered}$$
(14)

The primary objective of the controller is to attain the desired position of the actuated states while eliminating the unactuated states, which increases complexity to the control design. First, we introduce the actuated state error vector as follows:

$${\mathbf{e}}_{a} = {\mathbf{q}}_{a} - {\mathbf{q}}_{ad} = \left[ {\begin{array}{*{20}c} {\phi - \phi_{d} \quad x - x_{d} } & {l - l_{d} } \\ \end{array} } \right]^{T}$$
(15)
$${\mathbf{e}}_{u} = {\mathbf{q}}_{u} - {\mathbf{q}}_{ud} = \left[ {\begin{array}{*{20}c} {\theta 1} & {\theta 2} \\ \end{array} } \right]^{T}$$
(16)

where \({\mathbf{e}}_{a}\) represents the tracking error of the actuated states. The desired positions of the trolley, jib and cable lengths are \(x_{d}\), \(\phi_{d}\) and \(l_{d}\), respectively. On the other hand, the error \({\mathbf{e}}_{u}\) corresponds to the unactuated states, where the desired swing angles are set to zero.

Furthermore, the positioning error of \(q_{i} (t)\) is defined as

$$e_{i} = q_{i} - q_{id} = {{\varvec{\upmu}}}_{i}^{{\text{T}}} {\mathbf{e}}_{a} ,i \in \{ 1,2,3\}$$
(17)

where \(\mu_{i} \in {\mathbb{R}}^{3}\) represents the unit vector as

$${{\varvec{\upmu}}}_{i}^{{\text{T}}} = \overbrace {{\left[ {\begin{array}{*{20}c} 0 & \cdots & 0 & 1 & 0 & \cdots & 0 \\ \end{array} } \right]}}^{i - 1}$$
(18)

Next, based on Eq. (14), we devise the auxiliary function \(\Delta_{1} (t)\) to address the actuated state constraints.

$$\Delta_{1} = \sum\limits_{i = 1}^{3} {\frac{{\alpha_{i} }}{2}} \frac{{e_{i}^{2} }}{{(q_{i} - q_{iM} )^{2} (q_{i} - q_{im} )^{2} }}$$
(19)

Following that, we define a scalar function as

$$V_{1} = k_{E} E_{s} + \frac{1}{2}k_{v} {\dot{\mathbf{q}}}_{a}^{{\text{T}}} M_{a} {\dot{\mathbf{q}}}_{a} + \Delta_{1} + \frac{1}{2}{\mathbf{e}}_{a}^{{\text{T}}} \kappa_{p} {\mathbf{e}}_{a} ,$$
(20)

where \(k_{E}\) and \(k_{V} \in {\mathbb{R}} +\) represent positive control gains, while \(\kappa p \in {\mathbb{R}}^{3 \times 3}\) signifies a positive definite diagonal control gain matrix. By calculating the time derivative of Eq. (20) and performing certain simplifications, we arrive at the ensuing relationship:

$$\begin{gathered} \dot{V}_{1} = - k_{E} {\dot{\mathbf{q}}}_{a}^{{\text{T}}} \Lambda_{a} {\dot{\mathbf{q}}}_{a} - k_{E} {\dot{\mathbf{q}}}_{u}^{{\text{T}}} \Lambda_{u} {\dot{\mathbf{q}}}_{u} + k_{E} {\dot{\mathbf{q}}}_{a}^{{\text{T}}} {\mathbf{u}} + k_{v} {\dot{\mathbf{q}}}_{a}^{{\text{T}}} M_{a} {\ddot{\mathbf{q}}}_{a} + \frac{1}{2}k_{v} {\dot{\mathbf{q}}}_{a}^{{\text{T}}} \dot{M}_{a} {\dot{\mathbf{q}}}_{a} + {\dot{\mathbf{q}}}_{a}^{{\text{T}}} \kappa_{p} {\mathbf{e}}_{a} + \dot{\Delta }_{1} \hfill \\ \quad = \dot{q}_{a}^{{\text{T}}} [(k_{E} + k_{v} )I_{3} {\mathbf{u}} + B_{1} ] - (k_{E} + k_{v} ){\dot{\mathbf{q}}}_{a}^{{\text{T}}} \Lambda_{a} {\dot{\mathbf{q}}}_{a} - k_{E} {\dot{\mathbf{q}}}_{u}^{{\text{T}}} \Lambda_{u} {\dot{\mathbf{q}}}_{u} \hfill \\ \end{gathered}$$
(21)

where \(I_{3}\) denotes the 3 × 3 identity matrix. To simplify and facilitate the derivation, an auxiliary term \(B_{1}\) is designed as

$$\begin{gathered} B_{1} = - k_{v} (C_{a} \dot{\user2{q}}_{a} + C_{u} \dot{\user2{q}}_{u} + {\mathbf{G}}_{a} ) + \frac{1}{2}k_{v} \dot{M}_{a} \dot{\user2{q}}_{a} + k_{\upsilon } M_{11} M_{12}^{ - 1} \Lambda_{u} \dot{\user2{q}}_{u} \hfill \\ {{OO}} + \{ \kappa_{p} + \sum\limits_{i = 1}^{3} {\alpha_{i} [\frac{{(q_{i} - q_{iM} )(q_{i} - q_{im} ) - e_{i} (2q_{i} - q_{iM} - q_{im} )}}{{(q_{i} - q_{iM} )^{3} (q_{i} - q_{im} )^{3} }}]\mu_{i} \mu_{i}^{{\text{T}}} \} \cdot {\mathbf{e}}_{a} } {{O}} \hfill \\ \end{gathered}$$
(22)

By deriving from Eq. (21), we first design a regulation controller:

$${\mathbf{u}} = [(k_{E} + k_{v} )I_{m} ]^{ - 1} \cdot [ - B_{1} - ({\dot{\mathbf{q}}}_{u}^{{\text{T}}} \kappa_{d1} {\dot{\mathbf{q}}}_{u} + {\mathbf{q}}_{u}^{{\text{T}}} \kappa_{d2} {\mathbf{q}}_{u} )\kappa_{d3} {\dot{\mathbf{q}}}_{a} ]$$
(23)

where \(\kappa_{d1} ,\kappa_{d2} \in {\mathbb{R}}^{2 \times 2} ,\kappa_{d3} ,\kappa_{p} \in {\mathbb{R}}^{3 \times 3}\) denote positive definite control gain diagonal matrices.

The regulation controller is meticulously formulated by iteratively analyzing and combining unactuated variables with actuated variables. During this process, careful consideration is given to the definitions of \(\delta i\) and \(\overline{q}_{i}\), resulting in an intricate controller design achieved through repetitive trial-and-error analysis [12].

$$\Delta_{2} = \sum\limits_{i = 4}^{5} {\frac{{\alpha_{i} }}{2}} \sec [\delta_{i} (q_{i} - \overline{q}_{i} )^{2} ]{\dot{\mathbf{q}}}_{a}^{{\text{T}}} {\dot{\mathbf{q}}}_{a}$$
(24)

which is an elaborate combination of unactuated variables and actuated variables derived by repetitive trial-and-error analysis, where \(\delta i\) and \(\overline{q}_{i}\) are defined as

$$\delta_{i} = \frac{2\pi }{{(q_{im} - q_{iM} )^{2} }},\overline{q}_{i} = \frac{{q_{im} + q_{iM} }}{2}$$
(25)

It is demonstrated that (24) effectively addresses unactuated state constraints in [12]. Based on this, concerning the composite variable \(\phi_{1}\), we design an auxiliary function, denoted as

$$\Delta_{3} = \frac{{\beta_{1} }}{2}\ln^{2} [1 - \varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )^{2} ]{\dot{\mathbf{q}}}_{a}^{{\text{T}}} {\dot{\mathbf{q}}}_{a}$$
(26)

where \(\beta_{1}\) is a nonnegative control gain, and \(\varepsilon_{1}\), \(\overline{\phi }_{1}\) are defined as

$$\varepsilon_{1} = \frac{4}{{(\phi_{1m} - \phi_{1M} )^{2} }},\overline{\phi }_{1} = \frac{{\phi_{1m} + \phi_{1M} }}{2}$$
(27)

Next, a scalar function \(V_{3} (t)\) is constructed based on Eqs. (20), (24), and (26) in the following manner:

$$V_{3} = V_{1} + \Delta_{2} + \Delta_{3} \Rightarrow \dot{V}_{3} = \dot{V}_{1} + \dot{\Delta }_{2} + \dot{\Delta }_{3} ,$$
(28)

where \(\dot{\Delta }_{2}\) and \(\dot{\Delta }_{3}\) are given by

$$\begin{gathered} \dot{\Delta }_{2} = \sum\limits_{i = 4}^{5} {\alpha_{i} } {\dot{\mathbf{q}}}_{a}^{{\text{T}}} \{ \sec [\delta_{i} (q_{i} - \overline{q}_{i} )^{2} ]{\ddot{\mathbf{q}}}_{a} \hfill \\ \, + \delta_{i} \tan [\delta_{i} (q_{i} - \overline{q}_{i} )^{2} ] \cdot \sec [\delta_{i} (q_{i} - \overline{q}_{i} )^{2} ](q_{i} - \overline{q}_{i} )\dot{q}_{i} {\dot{\mathbf{q}}}_{a} \} \hfill \\ \end{gathered}$$
(29)
$$\dot{\Delta }_{3} = \beta_{1} {\dot{\mathbf{q}}}_{a}^{{\text{T}}} \{ \ln^{2} [1 - \varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )^{2} ]{\ddot{\mathbf{q}}}_{a} - \ln [1 - \varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )^{2} ]\frac{{2\varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )\dot{\phi }_{1} }}{{1 - \varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )^{2} }}{\dot{\mathbf{q}}}_{a} \}$$
(30)

Following that, we obtain the following relationship based on Eqs. (21), (22), (28), (29) and (30):

$$\dot{V}_{3} = {\dot{\mathbf{q}}}_{a}^{{\text{T}}} (A{\mathbf{u}} + {\mathbf{B}} + {\mathbf{C}} + {\mathbf{D}}) - k_{E} {\dot{\mathbf{q}}}_{u}^{{\text{T}}} \Lambda_{u} {\dot{\mathbf{q}}}_{u}$$
(31)

where \(A, \, {\mathbf{B}}, \, {\mathbf{C}}, \, {\mathbf{D}}\) are explicitly given by

$$\begin{gathered} A = (k_{E} + k_{v} )I_{3} \hfill \\ + \{ \sum\limits_{i = 4}^{5} {\alpha_{i} } \sec [\delta_{i} (q_{i} - \overline{q}_{i} )^{2} ] + \beta_{1} \, \cdot {\text{l}}n^{2} [1 - \varepsilon_{1} (\phi_{1} - \overline{{\phi_{1} }} )^{2} ]\} M_{a}^{ - 1} , \hfill \\ {\varvec{D}} = W\gamma \hfill \\ \end{gathered}$$
(32)
$$\begin{gathered} {\mathbf{C}} = - (k_{v} + k_{E} )\Lambda_{a} {\dot{\mathbf{q}}}_{a} \hfill \\ \,\,\,\,\,\,\,\, - \{ \sum\limits_{i = 4}^{5} {\alpha_{i} } \sec [\delta_{i} (q_{i} - \overline{q}_{i} )^{2} ] + \beta_{1} \ln^{2} [1 - \varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )^{2} ]\} M_{a}^{ - 1} \Lambda_{a} {\dot{\mathbf{q}}}_{a} \hfill \\ \end{gathered}$$
(33)
$$\begin{gathered} {\mathbf{B}} = - k_{v} (C_{a} {\dot{\mathbf{q}}}_{a} + C_{u} {\dot{\mathbf{q}}}_{u} + {\mathbf{G}}_{a} ) + \frac{1}{2}k_{v} \dot{M}_{a} {\dot{\mathbf{q}}}_{a} \hfill \\ \, + \{ \kappa_{p} + \sum\limits_{i = 1}^{3} {_{{}} } \alpha_{i} [\frac{{(q_{i} - q_{iM} )(q_{i} - q_{im} ) - e_{i} (2q_{i} - q_{iM} - q_{im} )}}{{(q_{i} - q_{iM} )^{3} (q_{i} - q_{im} )^{3} }}]{{\varvec{\upmu}}}_{i} {{\varvec{\upmu}}}_{i}^{{\text{T}}} \} {\mathbf{e}}_{a} \hfill \\ \, - \sum\limits_{i = 4}^{5} {\alpha_{i} } \{ \sec [\delta_{i} (q_{i} - \overline{q}_{i} )^{2} ]M_{a}^{ - 1} (C_{a} {\dot{\mathbf{q}}}_{a} + C_{u} {\dot{\mathbf{q}}}_{u} + {\mathbf{G}}_{a} ) \hfill \\ \, - \delta_{i} \tan [\delta_{i} (q_{i} - \overline{q}_{i} )^{2} ]\sec [\delta_{i} (q_{i} - \overline{q}_{i} )^{2} ](q_{i} - \overline{q}_{i} )\dot{q}_{i} \cdot {\dot{\mathbf{q}}}_{a} \} \hfill \\ \, - \beta_{1} \{ \ln^{2} [1 - \varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )^{2} ]M_{a}^{ - 1} (C_{a} {\dot{\mathbf{q}}}_{a} + {\mathbf{G}}_{a} + C_{u} {\dot{\mathbf{q}}}_{u} ) \hfill \\ \, + \ln [1 - \varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )^{2} ]\frac{{2\varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )\dot{\phi }_{1} }}{{1 - \varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )^{2} }}{\dot{\mathbf{q}}}_{a} \} \hfill \\ \end{gathered}$$
(34)

where \(W \in {\mathbb{R}}^{3 \times 2}\), \(\gamma \in {\mathbb{R}}^{2}\) are defined as

$$\begin{gathered} W = k_{v} M_{12} M_{22}^{ - 1} + \{ \sum\limits_{i = 4}^{5} {\alpha_{i} } \sec [\delta_{i} (q_{i} - \overline{q}_{i} )^{2} ] \hfill \\ \, + \beta_{1} \ln^{2} [1 - \varepsilon_{1} (\phi_{1} - \overline{\phi }_{1} )^{2} ]\} M_{a}^{ - 1} M_{12} M_{22}^{ - 1} \hfill \\ \end{gathered}$$
(35)
$$\gamma = \begin{array}{*{20}c} {[\lambda_{4} \dot{q}_{4} } & {\lambda_{5} \dot{q}_{5} } \\ \end{array} ]^{{\text{T}}} = Q \cdot {{\varvec{\uptheta}}}$$
(36)

where \(Q \in {\mathbb{R}}^{2 \times 2} ,{{\varvec{\uptheta}}} \in {\mathbb{R}}^{2}\) are given by

$$Q = {\text{diag}}\{ \dot{\theta }_{1} ,\dot{\theta }_{2} \}$$
(37)
$${{\varvec{\uptheta}}} = [\lambda_{4} \;\lambda_{5} ]^{{\text{T}}}$$
(38)

Let \(Y({\mathbf{q}},{\dot{\mathbf{q}}})\) be defined as

$$Y({\mathbf{q}},{\dot{\mathbf{q}}}) = W \cdot Q$$
(39)

Subsequently, \(D\) can be transformed into the following expression:

$$D = Y({\mathbf{q}},{\dot{\mathbf{q}}}) \cdot {{\varvec{\uptheta}}}$$
(40)

Utilizing these auxiliary terms, a new controller is formulated as follows:

$${\mathbf{u}} = A^{ - 1} [ - B - ({\dot{\mathbf{q}}}_{u}^{{\text{T}}} \kappa_{d1} {\dot{\mathbf{q}}}_{u} + {\mathbf{q}}_{u}^{{\text{T}}} \kappa_{d2} {\mathbf{q}}_{u} )\kappa_{d3} {\dot{\mathbf{q}}}_{a} - Y({\mathbf{q}},{\dot{\mathbf{q}}}) \cdot \widehat{{{\varvec{\uptheta}}}}]$$
(41)

the vector \({\hat{\mathbf{\theta }}} \in {\mathbb{R}}^{2}\) represents the approximation for the unknown vector \({{\varvec{\uptheta}}}\), and its update law is as follows:

$$\mathop {\widehat{{{\varvec{\uptheta}}}}}\limits^{.} = \Lambda_{{{\varvec{\uptheta}}}}^{ - 1} Y({\mathbf{q}},{\dot{\mathbf{q}}})^{{\text{T}}} {\dot{\mathbf{q}}}_{a}$$
(42)

The matrix \(\Lambda_{{{\varvec{\uptheta}}}}^{{}} \in {\mathbb{R}}^{{2}}\) represents a positive definite update gain diagonal matrix. The parameters \(\kappa_{{{\text{d1}}}} ,\kappa_{{{\text{d2}}}} ,\kappa_{{{\text{d3}}}}\), and \(\kappa_{{\text{p}}}\) are defined in Eq. (23). Moreover, the parameters \(\alpha_{{\text{i}}}\) and \(\beta_{1}\) are selected as nonnegative values, while \(k_{E}\) and \(k_{v}\) are chosen from the set of positive real numbers.

Due to space constraints, we will not elaborate on the stability proof in this article.

4 Simulink Results

In this section, we conduct simulations using MATLAB/Simulink software to evaluate the performance of the proposed method. Additionally, we select the Proportional-Derivative (PD) method as a comparative approach and present corresponding experimental results for further validation. In this set of experiments, both the proposed controller and a PD controller are employed to accomplish the task of transporting the cargo from its initial position to the desired target location.

The simulation platform is set up with the following system parameters:

\(m = 1kg,M = 7kg,\)\(J = 6.8kg \cdot m,g = 9.8m/s^{2}\).

The initial/final conditions are set as \(\phi (0) = 0{\text{deg}},x(0) = 0{\text{m}},l(0) = 1.5{\text{m}},\)

$$\phi_{d} = 30\,\deg ,\,\,x_{d} = 0.5\,{\text{m,}}\,\,{\text{and}}\,\,{}^{a}l_{d} = 0.9\,{\text{m}}$$

Figures 23 show the simulation results of the jib slew angle \(\phi\), trolley translation displacement \(x\), cable length \(l\), payload swing angles \(\theta_{1}\), \(\theta_{2}\) and control torque/forces \(F\phi\), \(Fx\), \(Fl\).

4.1 Simulink Group1

In this group, to effectively demonstrate the control performance of the designed control strategy, we include a comparative analysis with the well-established Proportional-Derivative (PD) control method. The PD controller can be written as

$$F_{\phi } = - k_{p\phi } e_{\phi } - k_{d\phi } \dot{\phi } + F_{f\phi } - k_{\phi } (\dot{\theta }_{1}^{2} + \dot{\theta }_{2}^{2} )\dot{\phi }$$
(43)
$$F_{x} = - k_{px} e_{x} - k_{dx} \dot{x} + F_{fx} - k_{x} (\dot{\theta }_{1}^{2} + \dot{\theta }_{2}^{2} )\dot{x}$$
(44)
$$F_{l} = - k_{pl} e_{l} - k_{dl} i - m_{p} g + d_{l} \dot{l} - k_{l} (\dot{\theta }_{1}^{2} + \dot{\theta }_{2}^{2} )\dot{l}$$
(45)

In this group, the control gains of the designed control method are tuned as

$$\begin{gathered}k_{p\phi } = 28,k_{d\phi } = 0.8,k_{px} = 24.8,k_{dx} = 8,k_{pl} = 15,k_{dl} = 5, \hfill \\ k_{\phi } = 200,k_{x} = 200,k_{l} = 200.\hfill \\ \end{gathered}$$

Figure 2 displays the experimental results of the PD method: at 2 s, the cable length and the angle of the jib slew reach the target positions, and the trolley almost precisely reaches its target position. The swing angle \(\theta_{1} \in ( - 2{\text{deg}},2{\text{deg}})\) and stabilizes at 6 s. The swing angle \(\theta_{2} \in ( - 1.5{\text{deg}},1.5{\text{deg}})\) and stabilizes at 11 s.

Fig.2.
figure 2

The results of Simulink group1. (a) Bule line: jib slew angle, trolley translation displacement, cable length, payload swing angles. (b) Red line: Control torque/forces. (Color figure online)

4.2 Simulink Group2

In this group, the multi-variable constraint controller proposed in this paper is used for simulation experiment test.

In addition to achieving the target position, this controller also satisfies the variable constraints:

$$\begin{gathered} \phi \in ( - 1{\text{deg}},36{\text{deg}}),x \in ( - 0.01{\text{m}},0.51{\text{m}}),\theta_{1} \in ( - 4{\text{deg}},4{\text{deg}}), \hfill \\ \theta_{2} \in ( - 2{\text{deg}},2{\text{deg}}),l \in (0.8m,2m). \hfill \\ \end{gathered}$$

The simulation platform is set up with the following system parameters:

$$\begin{gathered} k_{E} = 7,k_{v} = 1,k_{p} = {\text{diag}}\{ {120,150,120}\} ,k_{d1} = {\text{diag}}\{ 3,7\} ,k_{d2} = {\text{diag}}\{ 7,3\} , \hfill \\ k_{d3} = {\text{diag}}\{ 103,94,85\} ,\alpha_{1} = \alpha_{2} = \alpha_{3} = \alpha_{4} = 0.01,\beta = 0.01,\Lambda_{\theta } = {\text{diag}}\{ 7,10\} . \hfill \\ \end{gathered}$$

Figure 3 displays the experimental outcomes of the proposed method in this study: at 2 s, the cable length reaches the target length. The trolley and the angle of the jib slew almost satisfy the target requirements. The swing angle \(\theta_{1} \in ( - 1{\text{deg}},1{\text{deg}})\) and begins to stabilize at 5 s. The swing angle \(\theta_{2} \in ( - 0.5{\text{deg}},0.5{\text{deg}})\) eventually stabilizing at 11 s.

Fig. 3.
figure 3

The results of Simulink group2. (a) Bule line: jib slew angle, trolley translation displacement, cable length, payload swing angles. (b) Red line: Control torque/forces. (Color figure online)

By comparing Figs. 2 and 3, it is evident that both the jib angle, trolley translation and cable length rapidly and accurately reach their respective desired values. The positioning errors of the jib and trolley are almost negligible. Additionally, the proposed controller effectively suppresses the load swing, resulting in minimal residual oscillation. Both the proposed controller and the PD controller achieve the control objectives effectively. However, the proposed method incorporates constraint variables to prevent the system from exceeding safety limits, which sets it apart from the PD controller. It is also observed that the PD controller achieves faster target positioning, but the proposed method exhibits satisfactory positioning speed as well. Furthermore, the PD method induces larger load swing compared to the proposed method. The swing range in the proposed method is only half that of the PD controller, although it requires slightly more time to reach the balance position. The experimental results demonstrate that the proposed control method excels in precise positioning and effective swing suppression.

5 Conclusion

This paper primarily focuses on the constrained actuated variables, underactuated variables, and compound variables in a 5-DOF tower crane. To tackle this issue, we propose a novel controller that incorporates relevant auxiliary terms and constructs a new Lyapunov function to satisfy various variable constraints. The effectiveness of the proposed controller is validated through comparative experiments with a traditional PD controller. The experimental results demonstrate the robustness and performance of our method, achieving the goals of precise cargo positioning and effective swing suppression. Moreover, the proposed controller exhibits stable and smooth control outputs for the system states, providing a practical solution for tower cranes with varying cable lengths, and the experimental results further confirm its superiority.