1 Introduction

Due to their advantages of flexibility, efficient transportation and low cost, underactuated gantry cranes are widely utilized in construction, logistics and other industries [1, 2]. As a representative nonlinear underactuated system, the number of independent input control variables of the gantry crane is less than that of degrees of freedom in the system [3]. The goals of gantry cranes are not only to move the load to the target position accurately, but also to suppress and eliminate the system swings effectively [4]. In practice, it is prone to produce large swing angles of the system when the trolley moves rapidly or encounters external disturbances (wind load, impact, etc.), which affect the load accurate positioning, and even cause serious safety accidents. In some special conditions, such as the automatic driving of gantry cranes, the linkage control of the load hoisting/lowering motion and trolley horizontal motion improves the transport efficiency of gantry cranes. Compared with single control, the linkage control greatly improves the efficiency of gantry cranes, and deserves to be studied in depth. Gantry cranes may produce double pendulum effect when the hook mass or the rope length between the load and hook cannot be ignored [5]. Under this condition, the anti-swing controllers of single pendulum cranes are difficult to be applied to double pendulum cranes. If gantry cranes are operated manually, not only is the efficiency low, but also the trolley positioning is not accurate, and it will be prone to cause large hook/load swing angle, and poor safety. Therefore, the research of the anti-swing controller of the double pendulum underactuated gantry crane (DPUGC) has important practical significance and development prospects.

The DPUGC, however, has an extra underactuated degree of freedom, which leads to the challenge to establish the dynamic model and design the corresponding anti-swing controller. Moreover, although the linkage control makes the design of the anti-swing controller difficult, it is more in line with actual conditions and deserves to be studied in depth. The simplified single pendulum crane model has been utilized for the purpose of anti-swing control such as the trajectory planning controller [6] and nonlinear feedback controller [7,8,9,10,11]. The DPUGC-based research is still in its infancy [5]. At present, the input shaping controller is the most widely utilized strategy for the DPUGC [12]. However, many parts are linearized in the dynamic model and controller, which may lead to some errors inevitably. Tuan et al. proposed a sliding mode controller [13], which can improve the trolley positioning accuracy and suppress the system swings effectively. However, some nonlinear variables were ignored when they analyzed system stability. A super-twisting-based anti-swing controller that ensures the trolley positioning and suppresses system swings by utilizing a linear model was proposed in Ref. [14]. Qian et al. provided an input shaping anti-swing controller to avoid complex analysis of the crane dynamic model [15]. The time-optimal controller and energy-optimal controller were proposed in Refs. [16] and [17], respectively. However, the controllers proposed in Refs. [16, 17] require a large amount of offline calculation and without considering the linkage control of the load hoisting/lowering motion and trolley horizontal motion. Zhang et al. proposed an online trolley motion planning controller [18], which can suppress and eliminate the system swing angles effectively while ensuring the trolley precise positioning. However, partial approximations were applied to the process of dynamic analysis, and the load hoisting/lowering motion was not considered. A saturation controller was proposed in Ref. [19], but it should be pointed out that the load hoisting/lowering motion was not considered. An adaptive controller was proposed in Ref. [5], which was one of the few researches that considered double pendulum and load hoisting/lowering motion simultaneously. Unfortunately, the load and hook still had small repeated oscillations after the trolley stopped moving, which may affect safety seriously.

In previous researches, Zhang et al. proposed a partially saturated adaptive learning controller for overhead cranes with load hoisting/lowering [20], which suppressed and eliminated the load swing angle effectively. However, the driving force of the trolley changed suddenly when the trolley started. Sun et al. proposed a nonlinear tracking controller for underactuated cranes with load transferring and lowering [21], which can ensure the smooth startup of the trolley. However, the load oscillated repeatedly after the trolley stopped. Moreover, double pendulum was not considered in Refs. [20, 21] which cannot be ignored in practice.

With the continuous exploration of relevant scholars, various anti-swing controllers have been developed. However, there are still some core issues to be resolved, mainly including the following points.

  1. 1.

    Most existing methods were developed based on open-loop control; however, some of them, such as input shaping method [22,23,24], may be less robust to external disturbances or changes in system parameters due to insufficient feedback.

  2. 2.

    Partial linearizations or approximations existed in dynamic analysis and controller design in many studies, which may have insufficient accuracy.

  3. 3.

    For the DPUGC, most existing literature did not consider the load hoisting/lowering motion. However, linkage control is more challenging than single control and has to be considered in practice.

  4. 4.

    In addition, many researchers did not consider the impact of the swing angles, especially the coupling of the trolley displacement information, rope length information and swing angles information are necessary when considering the load hoisting/lowering motion.

Inspired by previous researches on the underactuated crane system [1, 3], a novel nonlinear coupled tracking anti-swing controller for the DPUGC with load hoisting/lowering motion is proposed. The proposed controller is suitable for both double pendulum and load hoisting/lowering motion, which are inevitable in practical engineering and are rarely studied simultaneously; in order to ensure that the proposed controller can control the gantry crane accurately, linearizations or approximations do not exist in the dynamic model establishment, controller design and stability analysis; in order to ensure the smooth startup and stable operation of the trolley, as well as to avoid the sudden changes of the driving force, a smooth expected trajectory is referenced into the proposed controller; in order to suppress and eliminate the system swing angles effectively, as well as to ensure that the system swing angles rapidly attenuate to the equilibrium state after the trolley stops running, a coupling signal, which includes the information of the load/hook swing angle, trolley displacement and rope lengths, is introduced into the proposed controller. Then, the system stability is strictly analyzed by utilizing Lyapunov techniques and Barbalat’s lemma. Finally, the actual effectiveness of the proposed controller is demonstrated by comparing simulations, experiments and robustness verification simulations; especially superior control results and strong robustness can still be obtained when changing the trolley target displacement, load mass, initial rope lengths, initial hook/load swing angle, and adding external disturbances. The main contributions of this paper lie as.

  1. 1.

    Not only does the proposed controller consider the double pendulum, but also considers the linkage control of the trolley motion and load hoisting/lowering motion simultaneously. In the process of the dynamic model establishment, controller design and stability analysis, linearizations and approximations are not applied, which can make the proposed controller control gantry cranes accurately.

  2. 2.

    A composite signal, which contains the information about actuated variables and underactuated variables, is constructed to suppress and eliminate the system swings. The transient performance is thereby improved. An expected trajectory is included to ensure the smooth startup and operation of the trolley.

  3. 3.

    The proposed controller admits strong robustness with respect to changes in system parameters and external disturbances, and the experiments demonstrate the excellent control performance of the proposed controller.

The remaining parts of this paper are stated as. The nonlinear dynamic model of the DPUGC with load hoisting/lowering is established in Sect. 2. The anti-swing controller design and stability analysis are performed in Sect. 3. The feasibility of the proposed controller is verified by a large number of simulations and experiments in Sect. 4. The conclusion is described in Sect. 5.

Fig. 1
figure 1

DPUGC linkage system

2 Nonlinear dynamic model of the DPUGC with load hoisting/lowering

The DPUGC linkage system is described in Fig. 1. M refers to the trolley mass, \({m_1}\) refers to the hook mass, \({m_2}\) refers to the load mass, \(x\left( t \right) \) refers to the trolley displacement, \({l_1}\left( t \right) \) refers to the rope length, \({l_2}\) denotes the distance from the hook to the load, \({\theta _1}\left( t \right) \) denotes the hook swing angle, \({\theta _2}\left( t \right) \) refers to the load swing angle. The horizontal driving force \({F_x}\left( t \right) \) drives the trolley to slide on the track, and the driving force \({F_l}\left( t \right) \) changes the rope length \({l_1}\left( t \right) \) to lift the load, which can ensure that the load reaches the target position quickly.

Remark 1

Double pendulum and load hoisting/lowering motion need to be considered when establishing the crane dynamics model and designing the anti-swing controller. However, only a few researchers, such as Lu et al. [5], have considered these two cases simultaneously. In practice, for improving the transportation efficiency, the trolley motion and load hoisting/lowering motion are usually combined; when the hook mass and rope length cannot be ignored, the double pendulum effect will occur. From the practical application, the anti-swing controller of the DPUGC is more worthy of research than that of the single pendulum crane.

The Euler–Lagrange equation is adopted to build the nonlinear dynamic model of the DPUGC linkage system [1, 5]:

$$\begin{aligned}&\left[ {\left( {{{{\ddot{l}}}_1} - {l_1}{{{{\dot{\theta }}} }_1}^2} \right) \sin {\theta _1} + \left( {{l_1}{{{\ddot{\theta }} }_1} + 2{{{{\dot{\theta }}} }_1}{{{\dot{l}}}_1}} \right) \cos {\theta _1}} \right] \nonumber \\&\qquad \cdot \left( {{m_1} + {m_2}} \right) + {m_2}{l_2}\left( {{{{\ddot{\theta }} }_2}\cos {\theta _2} - {{{{\dot{\theta }}} }_2}^2\sin {\theta _2}} \right) \nonumber \\&\qquad + \left( {M + {m_1} + {m_2}} \right) {\ddot{x}}{\mathrm{= }}{F_x} - {F_{rx}} - {d_x}{\dot{x}}, \end{aligned}$$
(1)
$$\begin{aligned}&{\left( {{m_1} + {m_2}} \right) \left( {\sin {\theta _1}{\ddot{x}} + {{{\ddot{l}}}_1} - {l_1}{{{{\dot{\theta }}} }_1}^2 - g\cos {\theta _1}} \right) }\nonumber \\&\qquad { + {m_2}{l_2}\left[ {\sin \left( {{\theta _1} - {\theta _2}} \right) {{{\ddot{\theta }} }_2} - \cos \left( {{\theta _1} - {\theta _2}} \right) {{{{\dot{\theta }}} }_2}^2} \right] }\nonumber \\&\quad { = {F_l} - {d_l}{\dot{l}}}, \end{aligned}$$
(2)
$$\begin{aligned}&\left( {{m_1} + {m_2}} \right) \left( {{l_1}\cos {\theta _1}{\ddot{x}} + {l_1}^2{{{\ddot{\theta }} }_1} + 2{l_1}{{{{\dot{\theta }}} }_1}{{{\dot{l}}}_1} + g{l_1}\sin {\theta _1}} \right) \nonumber \\&\qquad + {m_2}{l_1}{l_2}\left[ {\cos \left( {{\theta _1} - {\theta _2}} \right) {{{\ddot{\theta }} }_2} + \sin \left( {{\theta _1} - {\theta _2}} \right) {{{{\dot{\theta }}} }_2}^2} \right] \nonumber \\&\quad = - {d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}, \end{aligned}$$
(3)
$$\begin{aligned}&{m_2}{l_2}\left[ \begin{array}{l} \cos {\theta _2}{\ddot{x}} + \sin \left( {{\theta _1} - {\theta _2}} \right) \left( {{{{\ddot{l}}}_1} - {l_1}{{{{\dot{\theta }}} }_1}^2} \right) + {l_2}{{{\ddot{\theta }} }_2}\\ + \cos \left( {{\theta _1} - {\theta _2}} \right) \left( {{l_1}{{{\ddot{\theta }} }_1} + 2{{{{\dot{\theta }}} }_1}{{{\dot{l}}}_1}} \right) + g\sin {\theta _2} \end{array} \right] \nonumber \\&\quad = - {d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}, \end{aligned}$$
(4)

where \({d_x} \in {{{\mathbb {R}}}^ + }\) is the coefficient of air resistance on the trolley, \({d_l} \in {{{\mathbb {R}}}^ + }\) is the coefficient of mechanical friction on the rope, g is the acceleration of gravity, \({d_{{\theta _1}}}\) and \({d_{{\theta _2}}} \in {{{\mathbb {R}}}^ + }\) are the coefficients of air resistance. \({F_{rx}}\) is the friction force between the trolley and track, and its definition equation is [25,26,27,28]:

$$\begin{aligned} {F_{rx}} = {f_{r0x}}\tanh ({{{\dot{x}}} {\big /} {{\varepsilon _x}}}) + {k_{rx}}\left| {{\dot{x}}} \right| {\dot{x}}, \end{aligned}$$
(5)

where \({f_{r0x}}\), \({\varepsilon _x} \in {{{\mathbb {R}}}}\) are coefficients related to static friction, and \({k_{rx}} \in {{{\mathbb {R}}}}\) is coefficient related to viscous friction.

Furthermore, the following expressions are utilized to facilitate the description: \({s_i} = \sin {\theta _i}\), \({c_i} = \cos {\theta _i}\), \({s_{i \pm j}} = \sin \left( {{\theta _i} \pm {\theta _j}} \right) \), \({c_{i \pm j}} = \cos \left( {{\theta _i} \pm {\theta _j}} \right) \) , \(i,j = 1,2\left( {i \ne j} \right) \).

Remark 2

In the nonlinear dynamic model (1)–(4) of the DPUGC, external factors, such as the air resistance and mechanical friction, have been covered, and the model has not been linearized or approximated, which makes the model more accurate.

In order to facilitate controller development and stability analysis, the nonlinear dynamic model is rewritten:

$$\begin{aligned} {{{\varvec{M}}}}\left( {{{\varvec{q}}}} \right) {{\ddot{{\varvec{q}}}}} + {{{\varvec{V}}}} \left( {{{\varvec{q}}}, {{\dot{{\varvec{q}}}}}}\right) {{\dot{{\varvec{q}}}}} + {{{\varvec{G}}}}\left( {{{\varvec{q}}}} \right) = {{{\varvec{U}}}} + {{{{\varvec{F}}}}_d}, \end{aligned}$$
(6)

where \({{{\varvec{M}}}}\left( {{{\varvec{q}}}} \right) \) and \({{{\varvec{V}}}}\left( {{{{{\varvec{q}}},{{\dot{{{\varvec{q}}}}}}}}} \right) \in {{{\mathbb {R}}}^{4 \times 4}}\) are the system inertia matrix and system centripetal-Coriolis force matrix, respectively; \({{{\varvec{G}}}}\left( {{{\varvec{q}}}} \right) \), \({{{\varvec{U}}}}\), \({{{{\varvec{F}}}}_d}\) and \({{{\varvec{q}}}}\left( t \right) \in {{{\mathbb {R}}}^4}\) represent the system gravitational potential energy vector, system drive vector, system disturbance vector and system state vector, respectively.

The specific expressions of the above matrices and vectors are as follows:

$$\begin{aligned}&{{{\varvec{M}}}} = \left[ \begin{array}{l} {a_{11}}\;\;{a_{12}}\;\;{a_{13}}\;\;\,{a_{14}}\\ {a_{12}}\;\;{a_{22}}\;\;\;\;\,0\;\;\;\,{a_{24}}\\ {a_{13}}\;\;\;\;\,0\;\;\;\,{a_{33}}\;\,\,{a_{34}}\\ {a_{14}}\;\;{a_{24}}\;\;{a_{34}}\;\;\,{a_{44}} \end{array} \right] , {{{\varvec{V}}}} = \left[ \begin{array}{l} 0\;\;\;{b_{12}}\;\;\;\,{b_{13}}\;\;\,{b_{14}}\\ 0\;\;\;\;\;\,0\;\;\,\;\;{b_{23}}\;\;\,{b_{24}}\\ 0\;\;\; {b_{32}}\;\;\;\,{b_{33}}\;\,\,{b_{34}}\\ 0\;\;\;{b_{42}}\;\;\;\,{b_{43}}\;\;\;\;\,0 \end{array} \right] , \\&{{{\varvec{G}}}} = {\left[ {0\;\; - \left( {{m_1} + {m_2}} \right) g{c_1}\;\;\left( {{m_1} + {m_2}} \right) g{l_1}{s_1}\;\;{m_2}g{l_2}{s_2}} \right] ^{{{\mathrm{T}}}}},\\&{{{{\varvec{F}}}}_d} = {\left[ { - {F_{rx}} - {d_x}{\dot{x}}\;\; - {d_l}{{{\dot{l}}}_1}\;\; - {d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}\;\; - {d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}} \right] ^{{{\mathrm{T}}}}},\\&{{{\varvec{U}}}} = {\left[ {{F_x}\;\; {F_l}\;\; 0\;\; 0} \right] ^{{{\mathrm{T}}}}}, {{{\varvec{q}}}}\left( t \right) = {\left[ {x\left( t \right) \;\;{l_1}\left( t \right) \;\;{\theta _1}\left( t \right) \;\;{\theta _2}\left( t \right) } \right] ^{{{\mathrm{T}}}}}, \end{aligned}$$

where \({a_{11}} = M + {m_1} + {m_2}\), \({a_{12}} = \left( {{m_1} + {m_2}} \right) {s_1}\), \({a_{13}} = \left( {{m_1} + {m_2}} \right) {l_1}{c_1}\), \({a_{14}} = {m_2}{l_2}{c_2}\), \({a_{22}} = {m_1} + {m_2}\), \({a_{24}} = {m_2}{l_2}{s_{1 - 2}}\), \({a_{33}} = \left( {{m_1} + {m_2}} \right) {l_1}^2\), \({a_{34}} = {m_2}{l_1}{l_2}{c_{1 - 2}}\), \({a_{44}} = {m_2}{l_2}^2\), \({b_{12}} = \left( {{m_1} + {m_2}} \right) {{{{\dot{\theta }}} }_1}{c_1}\), \({b_{13}} = \left( {{m_1} + {m_2}} \right) {{{\dot{l}}}_1}{c_1} - \left( {{m_1} + {m_2}} \right) {l_1}{s_1}{{{{\dot{\theta }}} }_1}\), \({b_{14}} = - {m_2}{l_2}{s_2}{{{{\dot{\theta }}} }_2}\), \({b_{23}} = - \left( {{m_1} + {m_2}} \right) {l_1}{{{{\dot{\theta }}} }_1}\), \({b_{24}} = - {m_2}{l_2} {c_{1 - 2}}{{{{\dot{\theta }}} }_2}\), \({b_{32}} = \left( {{m_1} + {m_2}} \right) {l_1}{{{{\dot{\theta }}} }_1}\), \({b_{33}} = \left( {{m_1} + {m_2}} \right) {l_1}{{{\dot{l}}}_1}\), \({b_{34}} = {m_2}{l_1}{l_2}{s_{1 - 2}}{{{{\dot{\theta }}} }_2}\), \({b_{42}} = {m_2}{l_2}{c_{1 - 2}}{{{{\dot{\theta }}} }_1}\), \({b_{43}} = {m_2}{l_2}{{{\dot{l}}}_1}{c_{1 - 2}} - {m_2}{l_1}{l_2}{{{{\dot{\theta }}} }_1}{s_{1 - 2}}\).

The DPUGC linkage system has the following properties.

Property 1

Matrix \({{{\varvec{M}}}}\left( {{{\varvec{q}}}} \right) \) is always a positive definite symmetric matrix.

Property 2

The relationship between matrix \({{{\varvec{M}}}}\left( {{{\varvec{q}}}} \right) \) and matrix \({{{\varvec{V}}}}\left( {{{{{\varvec{q}}},{{\dot{{{\varvec{q}}}}}}}}} \right) \) is:

$$\begin{aligned} {{{{\varvec{y}}}}^{\mathop {{\mathrm{T}}}\nolimits } }\left[ {\frac{1}{2}{{{{\dot{{{\varvec{M}}}}}}}}\left( {{{\varvec{q}}}} \right) - {{{\varvec{V}}}}\left( {{{{{\varvec{q}}},{{\dot{{{\varvec{q}}}}}}}}} \right) } \right] {{{\varvec{y}}}}{\mathrm{= }}0,\;\; \forall {{{\varvec{y}}}} \in {{{\mathbb {R}}}^4}. \end{aligned}$$
(7)

According to the actual engineering situation of the gantry crane linkage system, the assumptions are presented as follows.

Assumption 1

Ignore the mass and flexibility of the rope.

Assumption 2

In the actual working process, the load is below the trolley, and the hook/load swing angle should meet the following conditions: [29, 30]: \( - {\pi {\big / } 2}< {\theta _1},\;{\theta _2} < {\pi {\big /} 2}\).

Assumption 3

Both the initial length \({l_1}\left( 0 \right) \) and target length \({p_{{\textit{dl}}}}\) of the rope are not longer than the maximum allowable length L of the crane: \(0 < {l_1}\left( 0 \right) ,{l_1},{p_{{\textit{dl}}}} \le ~L\).

Assumption 4

The driving forces of the motors are limited. On the basis of Newton’s second law, the accelerations of the trolley and rope are also bounded: \(0 \le \left| {{F_x}} \right| \le {{\bar{F}}}\), \(0 \le \left| {{\ddot{x}}} \right| \le {{{{\bar{a}}}}_x}\), \(0 \le \left| {{F_l}} \right| \le {{{{\bar{F}}}}_l}\), \({} 0 \le \left| {{{{\ddot{l}}}_1}} \right| \le {{{{\bar{a}}}}_l}\).

The control objectives of the DPUGC linkage system are as follows [29, 30]:

  1. 1.

    The trolley is driven from the initial position \(x\left( 0 \right) \) to the target position \({p_{{\textit{dx}}}}\), and the hook is driven from the initial length \({l_1}\left( 0 \right) \) to the target length \({p_{{\textit{dl}}}}\).

  2. 2.

    In the working process, the swing angles \({\theta _1}\left( t \right) \), \({\theta _2}\left( t \right) \) should be suppressed and eliminated.

    $$\begin{aligned}&\mathop {\lim }\limits _{t \rightarrow \infty } {\left[ {x\left( t \right) \;\;{l_1}\left( t \right) \;\;{\theta _1}\left( t \right) \;\;{\theta _2}\left( t \right) } \right] ^{\mathop {{\mathrm{T}}}\nolimits } } \nonumber \\&\quad = {\left[ {{p_{{\textit{dx}}}}\;\;{p_{{\textit{dl}}}}\;\;0\;\;0} \right] ^{\mathop {{\mathrm{T}}}\nolimits } }. \end{aligned}$$
    (8)

3 Main results

In this section, a nonlinear coupled tracking controller is proposed to improve the control performance. Then, Lyapunov techniques and Barbalat’s lemma are utilized to perform stability analysis. The DPUGC control system is described in Fig. 2.

Fig. 2
figure 2

DPUGC control system

3.1 Controller design

After the physical analysis of the DPUGC linkage system, its energy can be deduced:

$$\begin{aligned} \begin{array}{ll} E(t) =&{} \frac{1}{2}{{{{{{\dot{{{\varvec{q}}}}}}}}}^{\mathop {{\mathrm{T}}}\nolimits } }{{{\varvec{M}}}} ({{{\varvec{q}}}}){{{{\dot{{{\varvec{q}}}}}}}} + {m_2}g{l_2}(1 - {c_2})\\ &{}+ \left( {{m_1} + {m_2}} \right) g{l_1}\left( {1 - {c_1}} \right) . \end{array} \end{aligned}$$
(9)

In view of the relationship between the matrix \({{{\varvec{M}}}}\left( {{{\varvec{q}}}} \right) \) and matrix \({{{\varvec{V}}}}\left( {{{{{\varvec{q}}},{{\dot{{{\varvec{q}}}}}}}}} \right) \) in Eq. (7), it can be inferred that:

$$\begin{aligned} {{{{{\dot{{{\varvec{q}}}}}}}}^{\mathop {{\mathrm{T}}}\nolimits } }\left[ \! {{{{\varvec{M}}}}({{{\varvec{q}}}}){{\ddot{{\varvec{q}}}}} + \frac{1}{2}{{{{\dot{{{\varvec{M}}}}}}}}({{{\varvec{q}}}}){{{{\dot{{{\varvec{q}}}}}}}}}\!\right] = {{{{{\dot{{{\varvec{q}}}}}}}}^{\mathop {{\mathrm{T}}}\nolimits } }\left[ \! {{{{\varvec{U}}}} + {{{{\varvec{F}}}}_d} - {{{\varvec{G}}}}\left( {{{\varvec{q}}}} \right) }\! \right] , \end{aligned}$$
(10)

By calculating the first derivative of the energy equation shown in Eq. (9), and substituting Eq. (10) in the equation, the result can be obtained:

$$\begin{aligned} {\dot{E}}(t)= & {} {{{{{{\dot{{{\varvec{q}}}}}}}}}^{\mathop {{\mathrm{T}}}\nolimits } } \left( {{{{\varvec{M}}}}({{{\varvec{q}}}}){{\ddot{{\varvec{q}}}}} +\frac{1}{2}{{{{\dot{{{\varvec{M}}}}}}}} ({{{\varvec{q}}}}){{{{\dot{{{\varvec{q}}}}}}}}} \right) + {m_2}g{l_2}{{{{\dot{\theta }}} }_2}{s_2}\nonumber \\&+ \left( {{m_1} + {m_2}} \right) g\left( {{{{\dot{l}}}_1} - {{{\dot{l}}}_1}{c_1} + {l_1}{{{{\dot{\theta }}} }_1}{s_1}} \right) \nonumber \\= & {} {{{\dot{l}}}_1}\left[ {{F_l} - {d_l}{\dot{l}} + \left( {{m_1} + {m_2}} \right) g} \right] \nonumber \\&+ {\dot{x}}\left( {{F_x} - {F_{rx}} - {d_x}{\dot{x}}}\right) - {d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}^2 - {d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}^2, \end{aligned}$$
(11)

The linkage system has four underactuated variables, but only two control variables. Therefore, the suppression and elimination of swing angles need to be realized by the motion of the trolley and rope. However, it is difficult to add the factors relating to the hook/load swing into the controller directly while ensuring the system stability. Moreover, the trolley cannot respond to the swing angles timely and effectively when the controller contains the insufficient feedback signal of swing angles, which will make it difficult to obtain excellent transient control performance and strong robustness.

To solve this problem, a generalized horizontal displacement signal, which includes the trolley displacement and swing angles, is constructed:

$$\begin{aligned} \chi = x - {k_1}{l_1}\int _0^t {{\theta _1}} {\text {d}}t - {k_2}{l_2}\int _0^t {{\theta _2}} {\text {d}}t, \end{aligned}$$
(12)

where \({k_1} \in {{{\mathbb {R}}}^ + }\), \({k_2}{\mathrm{= }}\frac{{{m_2}}}{{{m_1} + {m_2}}}{k_1}\) represent positive gains. Furthermore, for facilitating controller design, an error signal vector is defined as:

$$\begin{aligned} {\left[ {{e_x}\;\;{e_{{l_1}}}\;\;{e_{{\theta _1}}}\;\;{e_{{\theta _2}}}} \right] ^T} = {\left[ {x - {x_r}\;\;{l_1} - {p_{{\textit{dl}}}}\;\;{\theta _1}\;\;{\theta _2}} \right] ^{{{\mathrm{T}}}}}, \end{aligned}$$
(13)

where \({x_r}\) represents an expected trajectory to ensure the smooth operation of the trolley. The determination of the expected trajectory should meet the following principle [21].

Principle 1

The expected trajectory \({x_r}\) is bounded, and the trolley is guaranteed to converge from the initial displacement \({x_r}\left( 0 \right) \) to the target displacement \({p_{{\textit{dx}}}}\) over time; the first derivative \({{\dot{x}}_r}\), second derivative \({{\ddot{x}}_r}\) and third derivative \({{x_r}^{\left( 3 \right) }}\) of the expected trajectory \({x_r}\) are bounded, and converge to 0 over time asymptotically. They can be described as: \(\left| {{x_r}\left( t \right) } \right| \le {p_{{\textit{dx}}}}\), \(0 \le {{\dot{x}}_r}\left( t \right) \le {v_{x\max }}\), \(\left| {{{{\ddot{x}}}_r}\left( t \right) } \right| \le {a_{x\max }}\), \(\left| {{x_r}^{\left( 3 \right) }\left( t \right) } \right| \le {j_{x\max }}\).

where \({v_{x\max }}\), \({a_{x\max }}\), and \({j_{x\max }}\) are the upper limit values of the velocity, acceleration and plus acceleration, respectively.

Based on Eqs. (12) and (13), a generalized horizontal trajectory tracking error signal is defined as:

$$\begin{aligned} {e_\chi } = \chi - {x_r} = x - {x_c}, \end{aligned}$$
(14)

where \({x_c}\) is a simple expression for \({x_r} + {k_1}{l_1}\int _0^t {{\theta _1}} {\text {d}}t + {k_2}{l_2}\int _0^t {{\theta _2}} {\text {d}}t\).

Then, for the DPUGC linkage system, a closed-loop feedback controller can be designed as follows:

$$\begin{aligned} \left\{ \!\begin{array}{@{}l} {F_x} = {F_{rx}} + {d_x}{\dot{x}} - {k_{px}}{e_\chi } - {k_{{\textit{dx}}}}{{{\dot{e}}}_\chi } + \left( {M + {m_1} + {m_2}} \right) {{{\ddot{x}}}_c}\\ {F_l} = {d_l}{{{\dot{l}}}_1} - {k_{pl}}{e_{{l_1}}} - {k_{{\textit{dl}}}}{{{\dot{e}}}_{{l_1}}} - \left( {{m_1} + {m_2}} \right) \left( {g - {{{\ddot{x}}}_c}{s_1}} \right) . \end{array} \right. \nonumber \!\!\!\\ \end{aligned}$$
(15)

where \({k_{px}}, {k_{dx}}, {k_{pl}}, {k_{dl}} \in {{\mathop {{\mathbb {R}}}\nolimits } ^ + }\) represent positive control gains to be adjusted.

Remark 3

The design of the controller \({F_x}\) mainly depends on the applied smooth trajectory \({x_r}\) and constructed coupling signal \(\chi \). The smooth tracking trajectory \({x_r}\) can ensure the smooth start and stable operation of the trolley, but the swing angles \(\left( {i.e.,{\theta _1},{\theta _2}} \right) \) are large and in a state of repeated swings, which are difficult to be suppressed and eliminated. However, the designed coupling signal \(\chi \) can solve this problem; meanwhile, it can also realize precise positioning and eliminate swing rapidly while ensuring stable operation. Among them, the first derivative of the applied trajectory should satisfy \({{\dot{x}}_r}\left( t \right) \ge 0\), which is to avoid the back-and-forth motion of the trolley, and reduce the wear of components and improve the efficiency.

Remark 4

The proposed controller (15) requires accurate model knowledge, which includes the trolley mass, hook mass, load mass and friction coefficients, to realize the precise control of gantry cranes. In practical engineering, the masses of the trolley and hook are known as equipment parameters of the gantry crane. Besides, in the automatic control of the port crane, the load mass is also a known constant. In addition, from the subsequent robustness verification, it can be seen that the proposed controller (15) has strong robustness; in other words, the changes of system parameters, such as the load mass, have little effect on the performance of the proposed controller. The friction coefficients can be obtained by offline tests and treated as known constants [31]. In addition, in order to solve these problems, an adaptive law of the load mass was designed by Lu et al. [5] to solve the problem that the load mass is difficult to determine; an adaptive law of the friction coefficient was developed by Zhang et al. [32] to solve the problem of the difficulty in determining the friction coefficient. Interested readers can refer to Lu et al. [5] and Zhang et al. [32] for more details.

3.2 Stability analysis

Theorem 1

The nonlinear coupled tracking controller ensures that the trolley can move to the target position \({p_{{\textit{dx}}}}\) accurately and the rope can reach the target length \({p_{{\textit{dl}}}}\) quickly, while suppressing and eliminating the system swing angles effectively, which can be stated as:

$$\begin{aligned}&\mathop {\lim }\limits _{t \rightarrow \infty } \\&\quad {\left[ {x\left( t \right) \;\,{\dot{x}}\left( t \right) \;\,{l_1}\left( t \right) \;\,{{{\dot{l}}}_1}\left( t \right) \;\,{\theta _1}\left( t \right) \;\,{{{{\dot{\theta }}} }_1}\left( t \right) \;\,{\theta _2}\left( t \right) \;\,{{{{\dot{\theta }}} }_2}\left( t \right) } \right] ^{{{\mathrm{T}}}}}\\&\quad = {\left[ {{p_{{\textit{dx}}}}\;\,0\;\,{p_{{\textit{dl}}}}\;\,0\;\,0\;\,0\;\,0\;\,0} \right] ^{{{\mathrm{T}}}}}.\end{aligned}$$

Proof

The tracking error signal vector \({{e}}\left( t \right) \) is constructed as follows:

$$\begin{aligned} {{{\varvec{e}}}}\left( t \right) = {{{\varvec{q}}}} - {{{{\varvec{q}}}}_d} = {\left[ {{e_\chi }\quad {e_{{l_1}}}\quad {\theta _1}\quad {\theta _2}} \right] ^{{{\mathrm{T}}}}}, \end{aligned}$$
(16)

where \({{{{\varvec{q}}}}_d} = {\left[ {{x_c}\quad 0\quad 0\quad 0} \right] ^{{{\mathrm{T}}}}}\).

Inspired by Eq. (9), an energy-like equation \({E_d}\left( t \right) \) is designed as:

$$\begin{aligned} \begin{array}{l} {E_d}\left( t \right) = \frac{1}{2}{{{{{{\dot{{{\varvec{e}}}}}}}}}^{\mathop {{\mathrm{T}}}\nolimits } }{{{\varvec{M}}}}({{{\varvec{q}}}}) {\dot{{\varvec{e}}}} + {m_2}g{l_2}(1 - \cos {\theta _2})\\ \quad \quad \quad \quad + \left( {{m_1} + {m_2}} \right) g{l_1}\left( {1 - \cos {\theta _1}} \right) . \end{array} \end{aligned}$$
(17)

In order to demonstrated the stability of the DPUGC system, and in view of Eq. (17), a positive scalar function \(V\left( t \right) \) is defined as the Lyapunov candidate function:

$$\begin{aligned} V\left( t \right) = {E_d}\left( t \right) + \frac{1}{2}{{k_{px}}}{e_\chi }^2 + \frac{1}{2}{k_{pl}}{e_{{l_1}}}^2. \end{aligned}$$
(18)

Equations (6), (16), and (17) are substituted in the first derivative of Eq. (18), and the result can be obtained:

$$\begin{aligned} \begin{array}{l} {\dot{V}}\left( t \right) = {{{{{{\dot{{{\varvec{e}}}}}}}}}^{\mathop {{\mathrm{T}}}\nolimits } }\left[ {{{{\varvec{M}}}}({{{\varvec{q}}}}){{\ddot{{\varvec{e}}}}} + \frac{1}{2}{{{{\dot{{{\varvec{M}}}}}}}}({{{\varvec{q}}}}){\dot{{\varvec{e}}}}} \right] + {{k_{px}}}{e_\chi }{{{\dot{e}}}_\chi }\\ \quad \quad \quad \; + {{k_{pl}}}{e_{{l_1}}}{{{\dot{e}}}_{{l_1}}} + \left( {{m_1} + {m_2}} \right) g{l_1}{{{{\dot{\theta }}} }_1}{s_1}\\ \quad \quad \quad \; + {m_2}g{l_2}{{{{\dot{\theta }}} }_2}{s_2} + \left( {{m_1} + {m_2}} \right) g{{{\dot{l}}}_1}\left( {1 - {c_1}} \right) \\ \quad \quad \; = {{{{{{\dot{{{\varvec{e}}}}}}}}}^{\mathop {{\mathrm{T}}}\nolimits } }\left[ \begin{array}{l} {{{\varvec{U}}}} + {{{{\varvec{F}}}}_d} - {{{\varvec{M}}}}\left( {{{\varvec{q}}}} \right) {{{{\ddot{{\varvec{q}}}}}}_d}\\ - {{{\varvec{G}}}}\left( {{{\varvec{q}}}} \right) - {{{\varvec{V}}}}\left( {{{\varvec{q}}},{\dot{{\varvec{q}}}}} \right) {{{{{{\dot{{{\varvec{q}}}}}}}}}_d} \end{array} \right] \\ \quad \quad \quad \; + {{k_{px}}}{e_\chi }{{{\dot{e}}}_\chi } + {{k_{pl}}}{e_{{l_1}}}{{{\dot{e}}}_{{l_1}}} + {m_2}g{l_2}{{{{\dot{\theta }}} }_2}{s_2}\\ \quad \quad \; = {{{\dot{e}}}_\chi }\left[ \begin{array}{l} {F_x} - {F_{rx}} - {d_x}{\dot{x}} + {{k_{px}}}{e_\chi }\\ - \left( {M + {m_1} + {m_2}} \right) {{{\ddot{x}}}_c} \end{array} \right] \\ \quad \quad \quad \; + {{{\dot{e}}}_{{l_1}}}\left[ \begin{array}{l} {F_l} - {d_l}{{{\dot{l}}}_1} + {{k_{pl}}}{e_{{l_1}}}\\ + \left( {{m_1} + {m_2}} \right) \left( {g - {{{\ddot{x}}}_c}{s_1}} \right) \end{array} \right] \\ \quad \quad \quad \; - {{{{\dot{\theta }}} }_1}\left[ {{{{\ddot{x}}}_c}{l_1}\left( {{m_1} + {m_2}} \right) {c_1} + {d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}} \right] \\ \quad \quad \quad \; - {{{{\dot{\theta }}} }_2}\left[ {{{{\ddot{x}}}_c}{m_2}{l_2}{c_2} + {d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}} \right] . \end{array} \end{aligned}$$
(19)

Equation (7) is applied in the derivation of Eq. (19), and its derivation principle is similar to Eq. (10).

Then, the proposed controller (15) is substituted in Eq. (19), and it can be deduced that:

$$\begin{aligned} \begin{array}{l} {\dot{V}}\left( t \right) {\mathrm{= }} - {k_{{\textit{dx}}}}{{{\dot{e}}}_\chi }^2 - {k_{{\textit{dl}}}}{{{\dot{e}}}_{{l_1}}}^2 - {d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}^2 - {d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}^2\\ \quad \quad \quad \; - {m_2}{l_2}{{{{\dot{\theta }}} }_2}{c_2}\left( \begin{array}{l} {k_1}{{{\ddot{l}}}_1}\int _0^t {{\theta _1}{\text {d}}t + 2} {k_1}{{{\dot{l}}}_1}{\theta _1}\\ + {k_1}{l_1}{{{{\dot{\theta }}} }_1} + {k_2}{l_2}{{{{\dot{\theta }}} }_2} - {{{\ddot{x}}}_r} \end{array} \right) \\ \quad \quad \quad \; - \left( {{m_1} + {m_2}} \right) {l_1}{{{{\dot{\theta }}} }_1}{c_1} \left( \begin{array}{l} {k_1}{{{\ddot{l}}}_1}\int _0^t {{\theta _1}{\text {d}}t + 2} {k_1}{{{\dot{l}}}_1}{\theta _1}\\ + {k_1}{l_1}{{{{\dot{\theta }}} }_1} + {k_2}{l_2}{{{{\dot{\theta }}} }_2} - {{{\ddot{x}}}_r} \end{array} \right) . \end{array} \end{aligned}$$
(20)

In view of the relationship between \({k_1}\) and \({k_2}\), and combined with \( - {\pi {\big /} 2}< {\theta _1} < {\pi {\big / } 2}\) (see Assumption 3), Eq. (20) is simplified and scaled. When \({k_1} \ge 0\), it can be seen that:

$$\begin{aligned} \begin{array}{l} {\dot{V}}\left( t \right) {\mathrm{= }} - {k_{{\textit{dx}}}}{{{\dot{e}}}_\chi }^2 - {k_{{\textit{dl}}}}{{{\dot{e}}}_{{l_1}}}^2 - {d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}^2 - {d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}^2\\ \quad \quad \quad \; - \left[ \begin{array}{l} {{{{\dot{\theta }}} }_1}^2{c_1} + \frac{{{m_2}^2{l_2}^2}}{{{{\left( {{m_1} + {m_2}} \right) }^2}{l_1}^2}}{{{{\dot{\theta }}} }_2}^2{c_2}\\ + \frac{{{m_2}{l_2}{{{{\dot{\theta }}} }_1}{{{{\dot{\theta }}} }_2}}}{{\left( {{m_1} + {m_2}} \right) {l_1}}}\left( {{c_1} + {c_2}} \right) \end{array} \right] \\ \quad \quad \quad \; \cdot \left( {{m_1} + {m_2}} \right) {k_1}{l_1}^2 - \left( \begin{array}{l} {k_1}{{{\ddot{l}}}_1}\int _0^t {{\theta _1}{\text {d}}t } \\ + 2{k_1}{{{\dot{l}}}_1}{\theta _1} \end{array} \right) \\ \quad \quad \quad \; \cdot \left[ {\left( {{m_1} + {m_2}} \right) {l_1}{{{{\dot{\theta }}} }_1}{c_1} + {m_2}{l_2}{{{{\dot{\theta }}} }_2}{c_2}} \right] \\ \quad \quad \quad \; - \left( {{m_1} + {m_2}} \right) {l_1}{{{{\dot{\theta }}} }_1}{{{\ddot{x}}}_r}{c_1} - {m_2}{l_2}{{{{\dot{\theta }}} }_2}{{{\ddot{x}}}_r}{c_2}\\ \quad \quad \; \le - {k_{{\textit{dx}}}}{{{\dot{e}}}_\chi }^2 - {k_{{\textit{dl}}}}{{{\dot{e}}}_{{l_1}}}^2 - {d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}^2 - {d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}^2\\ \quad \quad \quad \; + \frac{1}{2}{k_1}{m_2}{l_1}{l_2}{\left( {\sqrt{{c_1}} - \sqrt{{c_2}} } \right) ^2}\left( {{{{{\dot{\theta }}} }_1}^2 + {{{{\dot{\theta }}} }_2}^2} \right) \\ \quad \quad \quad \; - \eta \left[ {\left( {{m_1} + {m_2}} \right) {l_1}{{{{\dot{\theta }}} }_1}{c_1} + {m_2}{l_2}{{{{\dot{\theta }}} }_2}{c_2}} \right] \\ \quad \quad \quad \; + \left( {{m_1} + {m_2}} \right) {l_1}\left| {{{{{\dot{\theta }}} }_1}} \right| \left| {{{{\ddot{x}}}_r}} \right| + {m_2}{l_2}\left| {{{{{\dot{\theta }}} }_2}} \right| \left| {{{{\ddot{x}}}_r}} \right| , \end{array} \end{aligned}$$
(21)

where \(\eta \) stands for \({k_1}{{\ddot{l}}_1}\int _0^t {{\theta _1}{\text {d}}t + 2} {k_1}{{\dot{l}}_1}{\theta _1}\).

Arithmetic geometric mean inequality is applied in the derivation of Eq. (21). The specific derivation process is given as follows:

$$\begin{aligned} \begin{array}{l} - \left[ \begin{array}{l} {{{{\dot{\theta }}} }_1}^2{c_1} + \frac{{{m_2}^2{l_2}^2}}{{{{\left( {{m_1} + {m_2}} \right) }^2}{l_1}^2}}{{{{\dot{\theta }}} }_2}^2{c_2}\\ + \frac{{{m_2}{l_2}{{{{\dot{\theta }}} }_1}{{{{\dot{\theta }}} }_2}}}{{\left( {{m_1} + {m_2}} \right) {l_1}}}\left( {{c_1} + {c_2}} \right) \end{array} \right] \\ \le - 2\frac{{{m_2}{l_2}\left| {{{{{\dot{\theta }}} }_1}} \right| \left| {{{{{\dot{\theta }}} }_2}} \right| }}{{\left( {{m_1} + {m_2}} \right) {l_1}}}\sqrt{{c_1}{c_2}} - \frac{{{m_2}{l_2}{{{{\dot{\theta }}} }_1}{{{{\dot{\theta }}} }_2}}}{{\left( {{m_1} + {m_2}} \right) {l_1}}}\left( {{c_1} + {c_2}} \right) \\ \le - 2\frac{{{m_2}{l_2}\left| {{{{{\dot{\theta }}} }_1}} \right| \left| {{{{{\dot{\theta }}} }_2}} \right| }}{{\left( {{m_1} + {m_2}} \right) {l_1}}}\sqrt{{c_1}{c_2}} + \frac{{{m_2}{l_2}\left| {{{{{\dot{\theta }}} }_1}} \right| \left| {{{{{\dot{\theta }}} }_2}} \right| }}{{\left( {{m_1} + {m_2}} \right) {l_1}}}\left( {{c_1} + {c_2}} \right) \\ \le - \frac{{{m_2}{l_2}\left| {{{{{\dot{\theta }}} }_1}} \right| \left| {{{{{\dot{\theta }}} }_2}} \right| }}{{\left( {{m_1} + {m_2}} \right) {l_1}}}{\left( {\sqrt{{c_1}} - \sqrt{{c_2}} } \right) ^2}\\ \le - \frac{1}{2}\frac{{{m_2}{l_2}}}{{\left( {{m_1} + {m_2}} \right) {l_1}}}{\left( {\sqrt{{c_1}} - \sqrt{{c_2}} } \right) ^2}\left( {{{{{\dot{\theta }}} }_1}^2 + {{{{\dot{\theta }}} }_2}^2} \right) . \end{array} \end{aligned}$$

According to \(0 \le \left| {{{{\ddot{l}}}_1}} \right| \le {{{\bar{a}}}_l}\) (see Assumption 2) and \( - {\pi {\big / } 2}< {\theta _1} < {\pi {\big / } 2}\) (see Assumption 4), it can be known that within finite time \({t_d}\) (the time required for the rope to reach the target position), there are:

$$\begin{aligned} \left| \eta \right| \le \frac{\pi }{2}{k_1}{{{\bar{a}}}_l}{t_d} + \pi {k_1}{{{\bar{a}}}_l}{t_d} = \frac{3}{2}\pi {k_1}{{{\bar{a}}}_l}{t_d}{\mathrm{= }}{\left| \eta \right| _{\max }}.\end{aligned}$$

According to the properties of the arithmetic geometric mean inequality, Eq. (21) is scaled as:

$$\begin{aligned} \begin{array}{*{20}{l}} {{\dot{V}}\left( t \right) \le - {k_{{\textit{dx}}}}{{{\dot{e}}}_\chi }^2 - {k_{{\textit{dl}}}}{{{\dot{e}}}_{{l_1}}}^2 - {d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}^2 - {d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}^2}\\ {\quad \quad \quad \; + {} \frac{{{{\left( {{m_1} + {m_2}} \right) }^2}{l_1}^2}}{{{d_{{\theta _1}}}}}{{{\ddot{x}}}_r}^2 + \frac{1}{4}{d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}^2}\\ {\quad \quad \quad \; + \frac{{{m_2}^2{l_2}^2}}{{{d_{\theta 2}}}}{{{\ddot{x}}}_r}^2 + \frac{1}{4}{d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}^2}\\ \begin{array}{l} \quad \quad \quad \; - \eta \left[ {\left( {{m_1} + {m_2}} \right) {l_1}{{{{\dot{\theta }}} }_1}{c_1} + {m_2}{l_2}{{{{\dot{\theta }}} }_2}{c_2}} \right] \\ \quad \quad \quad \; + \frac{1}{2}{d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}^2 + \frac{1}{2}{d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}^2 \end{array}\\ {\quad \quad \le - {k_{{\textit{dx}}}}{{{\dot{e}}}_\chi }^2 - {k_{{\textit{dl}}}}{{{\dot{e}}}_{{l_1}}}^2 - \frac{1}{4}{d_{{\theta _1}}}{{{{\dot{\theta }}} }_1}^2 - \frac{1}{4}{d_{{\theta _2}}}{{{{\dot{\theta }}} }_2}^2}\\ {\quad \quad \quad \; + \frac{{{{\left( {{m_1} + {m_2}} \right) }^2}{l_1}^2}}{{2{d_{{\theta _1}}}}}{{{\ddot{x}}}_r}^2 + \frac{{{m_2}^2{l_2}^2}}{{2{d_{\theta 2}}}}{{{\ddot{x}}}_r}^2}\\ {\quad \quad \quad \; - \eta \left[ {\left( {{m_1} + {m_2}} \right) {l_1}{{{{\dot{\theta }}} }_1}{c_1} + {m_2}{l_2}{{{{\dot{\theta }}} }_2}{c_2}} \right] }, \end{array} \end{aligned}$$
(22)

where the control gain \({k_1}\) should satisfy the condition: \(\frac{1}{2}{k_1}{m_2}{l_1}{l_2}{\left( {\sqrt{{c_1}} - \sqrt{{c_2}} } \right) ^2} \le \frac{1}{2}{d_{{\theta _1}}},\;\frac{1}{2}{d_{{\theta _2}}}\).

\(0 < {l_1} \le L\) and \( - {\pi {\big / } 2}< {\theta _1} < {\pi {\big / } 2}\) (see Assumption 4) are substituted in the first-order integral of Eq. (22); it can be inferred:

$$\begin{aligned} \begin{array}{l} V\left( t \right) \le V\left( 0 \right) - {k_{{\textit{dx}}}}\int _0^t {{{{\dot{e}}}_\chi }^2{\text {d}}t } - {k_{{\textit{dl}}}}\int _0^t {{{{\dot{e}}}_{{l_1}}}^2{\text {d}}t } \\ \quad \quad \quad \; - \frac{{{d_{{\theta _1}}}}}{4}\int _0^t {{{{{\dot{\theta }}} }_1}^2{\text {d}}t } - \frac{{{d_{{\theta _2}}}}}{4}\int _0^t {{{{{\dot{\theta }}} }_2}^2{\text {d}}t } \\ \quad \quad \quad \; + \left[ {\frac{{{{\left( {{m_1} + {m_2}} \right) }^2}{L^2}}}{{2{d_{{\theta _1}}}}} + \frac{{{m_2}^2{l_2}^2}}{{2{d_{\theta 2}}}}} \right] \int _0^t {{{{\ddot{x}}}_r}^2{\text {d}}t } \\ \quad \quad \quad \; - \eta \left[ {\left( {{m_1} + {m_2}} \right) L\int _0^t {{{{{\dot{\theta }}} }_1}{\text {d}}t } + {m_2}{l_2}\int _0^t {{{{{\dot{\theta }}} }_2}^2{\text {d}}t } } \right] . \end{array} \end{aligned}$$
(23)

In the light of the description of the expected trajectory \({x_r}\) in Principle 1, it can be deduced [21]:

$$\begin{aligned} {x_r},{{\dot{x}}_r},{{\ddot{x}}_r},{x_r}^{\left( 3 \right) } \in {L_\infty }. \end{aligned}$$
(24)

According to Principle 1, utilizing the method of integration by parts, it can be obtained [21]:

$$\begin{aligned} \begin{array}{l} \int _0^t {{{{\ddot{x}}}_r}^2{\text {d}}t } \le \int _0^\infty {{{{\ddot{x}}}_r}^2{\text {d}}t } \\ \quad \quad \quad \;\; \le {{{\dot{x}}}_r}{{{\ddot{x}}}_r}|_0^\infty - \int _0^\infty {{{{\dot{x}}}_r}{x_r}^{\left( 3 \right) }{\text {d}}t } \\ \quad \quad \quad \;\; < 2{v_{x\max }}{a_{x\max }} + 2{j_{x\max }}{p_{{\textit{dx}}}}\\ \quad \quad \quad \;\; \Rightarrow {{{\ddot{x}}}_r} \in {L_2} \cap {L_\infty }. \end{array} \end{aligned}$$
(25)

Combining Eqs. (23)–(25), and in view of Assumption 2, the result can be obtained:

$$\begin{aligned} \begin{array}{l} V\left( t \right) \le V\left( 0 \right) + \left[ {\frac{{{{\left( {{m_1} + {m_2}} \right) }^2}{L^2}}}{{{d_{{\theta _1}}}}} + \frac{{{m_2}^2{l_2}^2}}{{{d_{\theta 2}}}}} \right] \\ \quad \quad \quad \;\; \cdot \left( {{v_{x\max }}{a_{x\max }} + {j_{x\max }}{p_{{\textit{dx}}}}} \right) \\ \quad \quad \quad \;\; + \frac{1}{2}\pi {\left| \eta \right| _{\max }}\left[ {\left( {{m_1} + {m_2}} \right) L + {m_2}{l_2}} \right] \ll + \infty . \end{array} \end{aligned}$$
(26)

Based on Eqs. (18), (23), (25), (26) and combined with Principle 1, it can be deduced [33]:

$$\begin{aligned} \begin{array}{l} V\left( t \right) \in {L_\infty } \Rightarrow {e_\chi },{{{\dot{e}}}_\chi },{e_{{l_1}}},{{{\dot{e}}}_{{l_1}}},{{{{\dot{\theta }}} }_1},{{{{\dot{\theta }}} }_2} \in {L_\infty }\\ \quad \quad \quad \quad \quad \, \Rightarrow x,{l_1},{\dot{x}},{{{\dot{l}}}_1},{F_x},{F_l},{F_{rx}} \in {L_\infty }. \end{array} \end{aligned}$$
(27)

Equation (26) is substituted in Eq. (23), and the shifting process is performed to obtain:

$$\begin{aligned} \begin{array}{l} \frac{{{d_{{\theta _1}}}}}{4}\int _0^t {{{{{\dot{\theta }}} }_1}^2{\text {d}}t } + \frac{{{d_{{\theta _2}}}}}{4}\int _0^t {{{{{\dot{\theta }}} }_2}^2{\text {d}}t } + {k_{{\textit{dx}}}}\int _0^t {{{{\dot{e}}}_\chi }^2{\text {d}}t } + {k_{{\textit{dl}}}}\int _0^t {{{{\dot{e}}}_{{l_1}}}^2{\text {d}}t } \\ \le V\left( 0 \right) - V\left( t \right) + \left( {{v_{x\max }}{a_{x\max }} + {j_{x\max }}{p_{{\textit{dx}}}}} \right) \\ \quad \cdot \left[ {\frac{{{{\left( {{m_1} + {m_2}} \right) }^2}{L^2}}}{{{d_{{\theta _1}}}}} + \frac{{{m_2}^2{l_2}^2}}{{{d_{\theta 2}}}}} \right] \\ \quad + \frac{1}{2}\pi {\left| \eta \right| _{\max }}\left[ {\left( {{m_1} + {m_2}} \right) L + {m_2}{l_2}} \right] \ll + \infty \\ \Rightarrow {{{\dot{e}}}_\chi },{{{\dot{e}}}_{{l_1}}},{{{{\dot{\theta }}} }_1},{{{{\dot{\theta }}} }_2} \in {L_2} \cap {L_\infty }. \end{array} \end{aligned}$$
(28)

By combining the conclusions of Eqs. (25)–(27) and substituting them in Eqs. (1)–(4), the conclusions can be deduced as:

$$\begin{aligned} {\ddot{x}},{{\ddot{l}}_1},{{\ddot{\theta }} _1},{{\ddot{\theta }} _2},{{\ddot{e}}_\chi },{{\ddot{e}}_{{l_1}}} \in {L_\infty }. \end{aligned}$$
(29)

By combining the conclusions of Eqs. (28) and (29), and utilizing the extended Barbalat’s lemma [33], it can be inferred that:

$$\begin{aligned} \mathop {\lim }\limits _{t \rightarrow \infty } {\left[ {{{{\dot{e}}}_\chi }\left( t \right) \;\;{{{\dot{e}}}_{{l_1}}}\left( t \right) \;\;{{{{\dot{\theta }}} }_1}\left( t \right) \;\;{{{{\dot{\theta }}} }_2}\left( t \right) } \right] ^{{{\mathrm{T}}}}} = {\left[ {0\;\;0\;\;0\;\;0} \right] ^{{{\mathrm{T}}}}}. \end{aligned}$$
(30)

According to \({{\dot{e}}_{{l_1}}}\left( t \right) = {{\dot{l}}_1}\left( t \right) \) and Eq. (30), it can be inferred that:

$$\begin{aligned} \mathop {\lim }\limits _{t \rightarrow \infty } {{\dot{l}}_1}\left( t \right) = 0. \end{aligned}$$
(31)

In combination with \(\mathop {\lim }\limits _{t \rightarrow \infty } {{\ddot{x}}_r}\left( t \right) = 0\), Eqs. (28) and (29), the proposed controller (15) is substituted in Eqs. (1)–(4). When \(t \rightarrow \infty \), the simple equation holds as follows:

$$\begin{aligned} \left\{ \begin{array}{l} \left( {M + {m_1} + {m_2}} \right) {{{\ddot{e}}}_\chi } + \left[ {\sin {\theta _1}{{{\ddot{l}}}_1} + {l_1}{{{\ddot{\theta }} }_1}\cos {\theta _1}} \right] \\ \cdot \left( {{m_1} + {m_2}} \right) + {m_2}{l_2}{{{\ddot{\theta }} }_2}\cos {\theta _2} = - {k_{px}}{e_\chi }\\ \left( {{m_1} + {m_2}} \right) \left[ {\sin {\theta _1}{{{\ddot{e}}}_\chi } + {{{\ddot{l}}}_1} - g\cos {\theta _1} + g} \right] \\ + {m_2}{l_2}\sin \left( {{\theta _1} - {\theta _2}} \right) {{{\ddot{\theta }} }_2} = - {k_{pl}}{e_{{l_1}}}\\ \left( {{m_1} + {m_2}} \right) \left[ {\cos {\theta _1}{{{\ddot{e}}}_\chi } + {l_1}{{{\ddot{\theta }} }_1} + g\sin {\theta _1}} \right] \\ + {m_2}{l_2}\cos \left( {{\theta _1} - {\theta _2}} \right) {{{\ddot{\theta }} }_2} = 0\\ \cos {\theta _2}{{{\ddot{e}}}_\chi } + \sin \left( {{\theta _1} - {\theta _2}} \right) {{{\ddot{l}}}_1} + {l_1}\cos \left( {{\theta _1} - {\theta _2}} \right) \\ \cdot {{{\ddot{\theta }} }_1} + {l_2}{{{\ddot{\theta }} }_2} + g\sin {\theta _2} = 0. \end{array} \right. \end{aligned}$$
(32)

\({g_1}\left( t \right) = {\ddot{x}} = {{\ddot{e}}_\chi }\), \({g_2}\left( t \right) = {{\ddot{l}}_1}\), \({g_3}\left( t \right) = {{\ddot{\theta }} _1}\), \({g_4}\left( t \right) = {{\ddot{\theta }} _2}\) are defined and substituted in Eq. (32). Then, the first derivative of the above equations is obtained, and the conclusion of Eq. (27) is substituted in this equation. When \(t \rightarrow \infty \),it can be inferred that:

\(\mathop {\lim }\limits _{t \rightarrow \infty } {{\dot{g}}_1}\left( t \right) \), \(\mathop {\lim }\limits _{t \rightarrow \infty } {{\dot{g}}_2}\left( t \right) \), \(\mathop {\lim }\limits _{t \rightarrow \infty } {{\dot{g}}_3}\left( t \right) \), \(\mathop {\lim }\limits _{t \rightarrow \infty } {{\dot{g}}_4}\left( t \right) \in {L_\infty }\).

The following basic knowledge of trigonometric functions is utilized to derive the equation:

\(\sin {\theta _i}\), \(\cos {\theta _i}\), \(\sin \left( {{\theta _i} - {\theta _j}} \right) \), \(\cos \left( {{\theta _i} - {\theta _j}} \right) \in {L_\infty }\).

Combined with the conclusions of Eqs. (30) and (31), and utilizing the extended Barbalat’s lemma, it can be inferred that:

$$\begin{aligned} \;\left\{ \begin{array}{l} \mathop {\lim }\limits _{t \rightarrow \infty } {{{\ddot{e}}}_\chi }\left( t \right) = \mathop {\lim }\limits _{t \rightarrow \infty } {\ddot{x}}\left( t \right) = 0\\ \mathop {\lim }\limits _{t \rightarrow \infty } {{{\ddot{\theta }} }_1}\left( t \right) = \mathop {\lim }\limits _{t \rightarrow \infty } {{{\ddot{\theta }} }_2}\left( t \right) = 0\\ \mathop {\lim }\limits _{t \rightarrow \infty } {{{\ddot{l}}}_1}\left( t \right) = 0. \end{array} \right. \end{aligned}$$
(33)

By substituting the conclusion of Eq. (33) in Eq. (32), the following result can be obtained:

$$\begin{aligned} \mathop {\lim }\limits _{t \rightarrow \infty } {\left[ {{e_\chi }\left( t \right) \;\;{e_{{l_1}}}\left( t \right) \;\;{\theta _1}\left( t \right) \;\;{\theta _2}\left( t \right) } \right] ^{{{\mathrm{T}}}}} = {\left[ {0\;\;0\;\;0\;\;0} \right] ^{{{\mathrm{T}}}}}. \end{aligned}$$
(34)

By combining \({{{\dot{e}}}_\chi } = {\dot{x}} - {k_1}{{{\dot{l}}}_1}\int _0^t {{\theta _1}} {\text {d}}t - {k_1}{l_1}{\theta _1} - {k_2}{l_2}{\theta _2} - {{{\dot{x}}}_r}\) and \(\mathop {\lim }\limits _{t \rightarrow \infty } {{\dot{x}}_r}\left( t \right) = 0\), with the conclusions of Eqs. (30) and (34), it can be deduced that:

$$\begin{aligned} \mathop {\lim }\limits _{t \rightarrow \infty } {{\dot{e}}_\chi } = \mathop {\lim }\limits _{t \rightarrow \infty } {\dot{x}} = 0. \end{aligned}$$
(35)

By combining the conclusion in Eq. (34), with Principle 1, Eqs. (13) and (14), it can be deduced that:

$$\begin{aligned} \mathop {\lim }\limits _{t \rightarrow \infty } {\left[ {x\left( t \right) \quad {l_1}\left( t \right) } \right] ^{{{\mathrm{T}}}}} = {\left[ {{p_{{\textit{dx}}}}\quad {p_{{\textit{dl}}}}} \right] ^{{{\mathrm{T}}}}}. \end{aligned}$$
(36)

Through the conclusions of Eqs. (30), (31) and (33)–(36), it can be concluded as:

$$\begin{aligned}&\mathop {\lim }\limits _{t \rightarrow \infty }\\&\quad {\left[ {x\left( t \right) \;\,{\dot{x}} \left( t \right) \;\,{l_1}\left( t \right) \;\,{{{\dot{l}}}_1}\left( t \right) \;\,{\theta _1}\left( t \right) \;\, {{{{\dot{\theta }}} }_1}\left( t \right) \;\,{\theta _2}\left( t \right) \;\,{{{{\dot{\theta }}} }_2}\left( t \right) } \right] ^{{{\mathrm{T}}}}}\\&\quad = {\left[ {{p_{{\textit{dx}}}}\;\,0\;\,{p_{{\textit{dl}}}}\;\,0\;\,0\;\,0\;\,0\;\,0} \right] ^{{{\mathrm{T}}}}}.\end{aligned}$$

According to the above equations, the state quantities of the DPUGC linkage system asymptotically converge to the equilibrium state described in Theorem 1.

Therefore, Theorem 1 is proved. \(\square \)

4 Simulation analysis and hardware experiment

In this section, the lowering process of the load is considered. The performance of the proposed controller is tested through a great quantity of simulations and experiments. The linkage system parameters are shown in Table 1. Firstly, the proposed controller is compared with the adaptive controller [5] and saturation controller [19] to demonstrate the excellent performance of the proposed controller. Then, the robustness of the proposed controller is tested by changing system parameters and adding external disturbances. Finally, the actual crane system parameters are adopted to simulate the anti-swing effect of the proposed controller.

Table 1 DPUGC linkage system parameters

Remark 5

Since a small number of controllers, such as the adaptive controller [5], consider the double pendulum effect and load hoisting/lowering motion simultaneously, it is difficult to find such controllers as the comparison object of the proposed controller. Therefore, the saturation controller [19], which has excellent control performance for double pendulum cranes, is utilized for comparative simulation analysis. However, the saturation controller does not consider the load hoisting/lowering motion. In order to facilitate comparison and analysis, this paper adds a PD controller, which has excellent performance for the load hoisting/lowering motion and is widely utilized at present, to the saturation controller to drive the load hoisting/lowering motion by referring to the practice of Lu et al. in Ref. [5]. The PD controller is:

$$\begin{aligned} {F_l} = {{d_l}{{{\dot{l}}}_1}} - 70{e_{{l_1}}} - 110{{\dot{e}}_{{l_1}}} - \left( {{m_1} + {m_2}} \right) g. \end{aligned}$$

The initial position \(x\left( 0 \right) \), initial hook swing angle \({\theta _1}\left( 0 \right) \) and initial load swing angle \({\theta _2}\left( 0 \right) \) are set as 0, the rope length \({l_2}\) is set as 0.2 m, and the initial rope length \({l_1}\left( 0 \right) \) is set as 0.2 m. The S-shaped expected trajectory is selected as:

$$\begin{aligned} {x_r}\left( t \right)= & {} \frac{{{p_{{\textit{dx}}}}}}{2} + \frac{{{k_v}^2}}{{4{k_a}}}\ln \\&\left( {\frac{{\cosh \left( {{{2{k_a}t} {\big / } {{k_v}}} - \varepsilon } \right) }}{{\cosh \left( {{{2{k_a}t} {\big / } {{k_v}}} - \varepsilon - {{2{p_{{\textit{dx}}}}{k_a}} {\big / } {{k_v}^2}}} \right) }}} \right) , \end{aligned}$$

where \({k_v} = 0.9\), \({k_a} = 0.5\), \(\varepsilon = 3\) refer to corresponding trajectory coefficients. \({k_v}\) represents the maximum allowable speed of the trolley, \({k_a}\) is the maximum allowable acceleration of the trolley, and \(\varepsilon \) can adjust the initial acceleration of the trolley. These parameters are all operating limit values set for the trolley.

To make sure the proposed controller can achieve superior control effects in simulations and experiments, the following procedure is utilized to select a set of control gains with excellent performance for the proposed controller.

  1. 1.

    To ensure the system stability, the control gain \({k_1}\) must ensure the validity of Eqs. (12), (21) and (22). That is, \({k_1}\) must meet the condition:

    $$\begin{aligned} 0 \le \frac{1}{2}{k_1}{m_2}{l_1}{l_2}{\left( {\sqrt{{c_1}} - \sqrt{{c_2}} } \right) ^2} \le \frac{1}{2}{d_{{\theta _1}}},\;\frac{1}{2}{d_{{\theta _2}}} ,\end{aligned}$$

    In practice, to avoid missing the appropriate value, the value of \({k_1}\) satisfies the condition:

    $$\begin{aligned} \begin{array}{ll} &{}0 \le \frac{1}{2}{k_1}{m_2}{l_1}\left( 0 \right) {l_2}{\left( {\sqrt{\cos \left( {0^\circ } \right) } - \sqrt{\cos \left( {3^\circ } \right) } } \right) ^2}\\ &{}\;\; \; \le {d_{{\theta _1}}},\;{d_{{\theta _2}}}. \end{array} \end{aligned}$$
  2. 2.

    Confirmation of the control gain \({k_2}\) shall satisfy condition: \({k_2} = \frac{{{m_2}}}{{\left( {{m_1} + {m_2}} \right) }}{k_1}\).

  3. 3.

    To ensure the positive definiteness of the Lyapunov function in Eq. (18) and the system stability, that is, Eqs. (18) and (23)–(26) need to be satisfied. Therefore, the position gains \({k_{px}},\;{k_{pl}}\) and velocity gains \({k_{{\textit{dx}}}},\;{k_{{\textit{dl}}}}\) should be positive values.

4.1 Comparative simulation analysis

For the sake of fairness, the gains of the proposed controller and two comparative controllers are fully debugged respectively, until a set of gains with the best performance are obtained. Specifically, the gains of the adaptive controller [5] are carefully adjusted as \({k_{\alpha 1}} = 2.8\), \({k_{\beta 1}} = 9.2\), \({k_{\alpha 2}} = 70\), \({k_{\beta 2}} = 120\), \(k = 0.015\), \(\lambda = 0.01\), \(L = 2\). The gains of the saturation controller [19] are fully debugged as \({k_p} = 4\), \({k_d} = 14.8\), \(\alpha = - 1\). And the gains of the proposed controller are selected as \({k_1} = 5\), \({k_{px}} = 4\), \({k_{{\textit{dx}}}} = 50\), \({k_{pl}} = 12\), \({k_{{\textit{dl}}}} = 18\).

Remark 6

Because the load swings with the swing of the hook, and the load is connected with the hook by the rope, the maximum load swing angle \({\theta _{2\max }}\) is generally larger than the maximum hook swing angle \({\theta _{1\max }}\). Moreover, from the stability analysis and Eqs. (32)–(34), it can be seen that no matter how the hook swing angle \({\theta _1}\) and load swing angle \({\theta _2}\) change, the DPUGC linkage system remains stable.

Then, the proposed controller, adaptive controller [5] and saturation controller [19] are simulated. The simulation results are shown in Fig. 3, and the performance index results are shown in Table 2. Among them, the quantitative performance indexes exist to better compare the control performance of each controller quantitatively. Their indexes are described as:

  1. 1.

    \({\theta _{i\max }},\;i = 1,\;2\) is the maximum hook/load swing angle during the crane operation.

  2. 2.

    \({\theta _{i{\mathop {\mathrm{res}}\nolimits } }},\;i = 1,\;2\) is the maximum hook/load swing angle after the crane stops running.

  3. 3.

    \({t_{{\mathop {\mathrm{st}}\nolimits } }}\) is the time taken for the trolley to transport the load.

Fig. 3
figure 3

Comparison simulation results

Table 2 Performance index results for different controllers
Table 3 Performance index results for different controllers without load hoisting/lowering

From the comparison results in Fig. 3 and the performance indexes in Table 2, it can be seen that the final positioning errors of these three controllers do not exceed 5 mm. However, the transportation time of the proposed controller is obviously less than that of the other two controllers; under the control of the proposed controller, the starting/running process of the trolley is relatively stable, and the hook/load swing curves are relatively smooth. Moreover, the proposed controller can better suppress the hook/load swing range, and there is no repeated swing phenomenon, which greatly improves the safety of the gantry crane system during operation. Although the hook/load swing is quickly suppressed under the control of the other two controllers, the swing hook/load angle changes drastically and the swings are too large when the trolley starts, which may lack safety. Specifically, the proposed controller has the minimum transportation time \({t_{\mathrm{st}}} = 7.7\;{\mathop {{\mathrm{s}}}\nolimits } \), maximum hook swing angle \({\theta _{1\max }} = 2.46\;\deg \), and maximum load swing angle \({\theta _{2\max }} = 2.53\;\deg \); the adaptive controller [5] has the minimum transportation time \({t_{\mathrm{st}}} = 9.1\;{\mathop {{\mathrm{s}}}\nolimits } \), maximum hook swing angle \({\theta _{1\max }} = 3.45\;\deg \), and maximum load swing angle \({\theta _{2\max }} = 5.07\;\deg \); the saturation controller [19] has the minimum transportation time \({t_{\mathrm{st}}} = 9.7\;{\mathop {{\mathrm{s}}}\nolimits } \), maximum hook swing angle \({\theta _{1\max }} = 5.47\;\deg \), and maximum load swing angle \({\theta _{2\max }} = 7.42\;\deg \). In summary, from the simulation results and the quantitative performance indexes, the proposed controller has an excellent effect on the swing suppression of the hook and load, and the transportation is fast, which significantly improves the transportation efficiency of the load.

In addition, it may be unfair to add a PD controller to the saturation controller because it does not take into account the load hoisting/lowering motion. However, when \({l_1}(0) = {p_{{\textit{dl}}}}\), the load hoisting/lowering motion is not performed. Therefore, let \({l_1}(0) = {p_{{\textit{dl}}}} = 0.2\,{\mathop {{\mathrm{m}}}\nolimits } \), other system parameters remain unchanged. Then, in the case of the control gains of the proposed controller are constant, a set of appropriate control gains are selected for the saturation controller. The comparative simulation results are shown in Table 3.

From the comparative simulation results in Table 3, compared with the saturation controller, the proposed controller still has superior control performance without considering the load hoisting/lowering motion.

4.2 Robustness verification

In the actual working process of gantry cranes, it is difficult to determine the load mass, trolley target displacement, initial rope lengths and initial hook/load swing angle. Moreover, external disturbances inevitably bring some difficulties to the control of anti-swing controller. For verifying the robustness of the proposed controller, simulation tests are implemented for different system parameters and external disturbances, respectively. Under the condition of the constant control gains, simulation tests are divided into the following four cases:

Case 1 The robustness is tested for different load masses. Therefore, three different load masses are set as:

$$\begin{aligned} 1. \;m = 1\;{\mathop {\mathrm{kg}}\nolimits } .\quad 2.\;m = 6\;{\mathop {\mathrm{kg}}\nolimits } .\;\quad 3. \;m = 0.3\;{\mathop {\mathrm{kg}}\nolimits }. \end{aligned}$$

As illustrated in Fig. 4, the proposed controller can also make the trolley reach the target position accurately under different load masses, and can suppress and eliminate the hook/load swing effectively. Specifically, when changing the load mass, the final positioning error of the trolley is no more than 2 mm, the time to reach the target position is no more than 7.7 s, and the maximum hook/load swing angle is no more than 2.53 deg. In addition, the starting/running process of the crane is relatively stable, and the hook/load does not produce violent repeated swings. The change of the load mass does not affect the performance of the system significantly. Therefore, the proposed controller has excellent robustness for different load masses.

Case 2 The robustness is tested for different trolley target displacements. Therefore, three different target displacements are set as:

$$\begin{aligned} 1. \;{p_{{\textit{dx}}}} = 2\;{\mathop {{\mathrm{m}}}\nolimits } .\quad 2. \;{p_{{\textit{dx}}}} = 1\;{\mathop {{\mathrm{m}}}\nolimits } .\;\quad 3. \;{p_{{\textit{dx}}}} = 5\;{\mathop {{\mathrm{m}}}\nolimits }. \end{aligned}$$
Fig. 4
figure 4

Simulation results of the first case

From the simulation results in Fig. 5, the proposed controller can lift the load to different target positions accurately. The time required for the trolley to reach the target position is 7.7 s, 6.6 s and 11 s, respectively; the final positioning error of the trolley is not more than 2 mm; the maximum hook/load swing angle is not more than 2.65 deg, and the hook/load swing angle is quickly eliminated. Therefore, different target displacements have little effect on the hook/load swing; although the arrival time varies with distance, the degree of the change is relatively small.

Fig. 5
figure 5

Simulation results of the second case

Case 3 In this case, this paper tests the robustness of the proposed controller against different initial rope lengths \({l_1}(0)\), \(l_2\). It is worth pointing out that when the initial rope length \({l_1}(0)\) is greater than the target length \({p_{{\textit{dl}}}}\), the crane is in the hoisting state; otherwise, the crane is in the lowering state; if the initial rope length \({l_1}(0)\) is equal to the target length \({p_{{\textit{dl}}}}\), the crane does not hoist/lower the load and is in the state of horizontal lifting. Here, three different initial rope lengths are set as:

  1. 1.

    \({l_1}(0) = 0.2\;{\mathop {{\mathrm{m}}}\nolimits } ,\;{l_2} = 0.2\;{\mathop {{\mathrm{m}}}\nolimits } .\)

  2. 2.

    \({l_1}(0) = 1\;{\mathop {{\mathrm{m}}}\nolimits } ,\;{l_2} = 1\;{\mathop {{\mathrm{m}}}\nolimits } .\)

  3. 3.

    \({l_1}(0) = 1.8\;{\mathop {{\mathrm{m}}}\nolimits } ,\;{l_2} = 1.8\;{\mathop {{\mathrm{m}}}\nolimits } .\)

It can be seen from the simulation results in Fig. 6 that when the initial rope lengths \({l_1}(0)\), \(l_2\) are changed, the proposed controller can still ensure that the trolley reaches the target position \({p_{{\textit{dx}}}}\) accurately, and the final positioning errors are controlled within 2 mm; the times \({t_{\mathrm{st}}}\) taken for the trolley to reach the target position \({p_{{\textit{dx}}}}\) are similar; and the rope length \(l_1\) tends to the target length \({p_{{\textit{dl}}}}\) accurately; the maximum hook/load swing angle does not exceed 2.72 deg, and the residual hook/load swing angle is eliminated quickly after the trolley reaches the target position \({p_{{\textit{dx}}}}\). Consequently, the proposed controller has superior robustness to deal with different initial rope lengths \({l_1}(0)\), \(l_2\).

Fig. 6
figure 6

Simulation results of the third case

Case 4 By adding different initial hook swing angles and initial load swing angles, the performance of the linkage system is tested in this case. Because the proposed controller has excellent performance in suppressing and eliminating swing angles, the initial swing angles are set as:

  1. 1.

    \(\;{\theta _1} = 0\;\deg ,\;{\theta _2} = 0\;\deg .\)

  2. 2.

    \(\;{\theta _1} = 3\;\deg ,\;{\theta _2} = 5\;\deg .\)

  3. 3.

    \(\;{\theta _1} = - 3\;\deg ,\;{\theta _2} = - 5\;\deg .\)

From the simulation results in Fig. 7, under the control of the proposed controller, the starting/running process of the trolley is relatively stable, and the existence of the initial hook/load swing angle has a negligible effect on the transportation efficiency of the trolley. Moreover, the positioning of the trolley is still accurate; the initial hook/load swing angle is quickly eliminated, and their swings quickly tend to the swing states without the initial swing angles. Hence, the proposed controller has excellent performance when dealing with the initial hook/load swing angle.

Fig. 7
figure 7

Simulation results of the fourth case

Case 5 For testing the robustness in response to external disturbances, a 5 deg sinusoidal disturbance signal is added to the load swing angle in 10–12 s to simulate the external disturbances.

From the simulation results in Fig. 8, the proposed controller can eliminate the external disturbances and restore the linkage system to the equilibrium state quickly when the system is subject to external disturbances. Specifically, the external disturbances have little impact on the positioning of the trolley; the positioning error does not exceed 5 mm; and the trolley can recover to the target position quickly. When the load is disturbed by external disturbances, the impact on the hook is small, and the maximum swing angle is less than 0.48 deg. The hook/load swing angle can return to the stable state within 2 s after the external disturbances disappear. Therefore, the proposed controller has superior robustness against external disturbances.

Fig. 8
figure 8

Simulation results of the fifth case

4.3 Experimental analysis

Although the proposed controller has excellent control performance in simulations, its control effects have not been verified in practice. Therefore, the crane experimental system is set up as shown in Fig. 9. The actual results of the proposed controller are obtained, and compared with the simulation results on the premise of keeping the control gains and crane system parameters unchanged. The trolley target displacement is set as 0.6 m, and the rope target length is set as 0.8 m.

Fig. 9
figure 9

Crane experimental system

The comparison results of the experiment and simulation are shown in Fig. 10. Through experimental measurements, the actual transportation time of the trolley is similar to the simulation transportation time, but the actual maximum hook/load swing angle is larger than that of the simulation result. Due to the inevitable external disturbances and hardware conditions in the experiment, the experimental curves have slight fluctuations, but the experimental curves are consistent with the overall trend of the simulation curves. Therefore, the proposed controller still achieves excellent control performance in the experiment and has objective practical application.

Fig. 10
figure 10

Comparison results of the experiment and simulation

4.4 Simulation analysis for actual working condition

Most existing controllers have been designed and simulated for the crane experiment system, but few researchers consider the application of actual crane system parameters to verify the effectiveness of the anti-swing controllers. Although some anti-swing controllers can realize the anti-swing control of the experimental crane system, it is difficult to realize the effective anti-swing control of the actual crane system. To solve this problem, a case of actual crane system parameters is selected to simulate and verify the anti-swing effect of the proposed controller.

The DPUGC system parameters are selected as:

\(M = 432\;{\mathop {\mathrm{kg}}\nolimits } \), \({m_1} = 257\;{\mathop {\mathrm{kg}}\nolimits } \), \({m_2} = 1750\;{\mathop {\mathrm{kg}}\nolimits } \), \({l_1}\left( 0 \right) = 2\;{\mathop {{\mathrm{m}}}\nolimits } \), \({l_2} = 1\;{\mathop {{\mathrm{m}}}\nolimits } \), \({p_{{\textit{dx}}}} = 20\;{\mathop {{\mathrm{m}}}\nolimits } \), \({p_{{\textit{dl}}}} = 6\;{\mathop {{\mathrm{m}}}\nolimits } \), \({k_v} = 2.4\), \({k_a} = 1.2\), \(\varepsilon = 3.5\).

The gains are selected as: \({k_1} = 5\), \({k_{px}} = 40\), \({k_{{\textit{dx}}}} = 500\), \({k_{pl}} = 200\), \({k_{{\textit{dl}}}} = 1150\).

The simulation results in Fig. 11 show that under the control of the proposed controller, the final positioning displacement \({p_{{\textit{dx}}}} = 20\;{\mathop {{\mathrm{m}}}\nolimits } \), transportation time \({t_{\mathrm{st}}} = 24.4\;{\mathop {{\mathrm{s}}}\nolimits } \), maximum hook swing angle \({\theta _{1\max }} = 2.99\;\deg \) and maximum load swing angle \({\theta _{2\max }} = 3.01\;\deg \). Specifically, not only does the proposed controller ensure the accurate positioning of the trolley, but also it ensures the fast transportation of the crane. In the starting process, the trolley starts smoothly, and the initial hook/load swing is very small; in the working process, the hook/load swing curve is relatively smooth and the swing amplitude is small; moreover, the residual swing angles are quickly eliminated when the trolley stops running. From the above performance indexes and analysis, it can be seen that compared with those controllers which do not consider the double pendulum or the load hoisting/lowering motion, the proposed controller still has superior anti-swing control effects in the actual crane system. This advantage lays a solid foundation for the application of the proposed controller, which is helpful to the development and implementation of the crane automatic driving in actual working condition, and has great practical value.

Fig. 11
figure 11

Simulation results under actual working condition

Remark 7

It can be seen from the Assumption 4 that the driving forces \({F_x}\), \({F_l}\) of the proposed controller (15) are always bounded during the driving process. In the simulations, the drive motors are assumed to be ideal and can give corresponding bounded drive forces; moreover, as can be seen from Table 2 and Fig. 3, the maximum driving forces of the proposed controller are smaller than that of the adaptive controller [5] and saturation controller [19]; in addition, when designing the controller, some nonlinear terms (such as \({k_{px}}{e_\chi }\), \({k_{{\textit{dx}}}}{{{\dot{e}}}_\chi }\), \({k_{pl}}{e_{{l_1}}}\), \({k_{{\textit{dl}}}}{{{\dot{e}}}_{{l_1}}}\), etc.), which are utilized to constrain the control inputs by adjusting the control gains, are also designed. In the future work, the control input saturation will be comprehensively considered to solve practical application problems.

5 Conclusion

This paper presents a novel nonlinear coupled tracking anti-swing controller, which can solve some difficult problems of the DPUGC linkage system, such as low working efficiency, inaccurate positioning of the trolley, large hook/load swing, and poor anti-disturbance ability. Compared with the existing adaptive controller and saturation controller, the proposed controller has more outstanding control performance, saves at least 15% of the transport time; and the hook/load swing range can be controlled within 3 deg. Besides, the proposed controller can meet the requirements of the efficient transportation and effective anti-swing of the crane; strong robustness can still be achieved under the condition of changing the system parameters and adding external disturbances. In addition, the proposed controller can still achieve excellent anti-swing control effect when the actual crane system parameters are adopted. In general, the proposed controller improves the transportation efficiency of the gantry crane system significantly, and can suppress and eliminate the hook/load swing angle effectively, which is helpful for the research and development of the automatic driving of the gantry crane system, and has a great practical significance and good application prospects.