Comparative Analysis of Neural-Network and Fuzzy Auto-Tuning Sliding Mode Controls for Overhead Cranes under Payload and Cable Variations

The overhead crane is required to operate fast and precisely with minimal sway. However, high-speed operations cause undesirable load sways, hazardous to operating personnel, the payload being handled, and the crane itself. Thus, a high-quality control is required. In thiswork, the nonlinearmodel of the overhead cranewas established and the slidingmode control (SMC)was proposed that ensured the existence of sliding motion in the presence of payload and hoisting height variations, and viscous frictions. To maximize the benefits derived from the proposed control method, novel sliding slope-update based on intelligent neural-network and fuzzy algorithms were developed to tune the controller, guaranteeing precise tracking of the actuated variables as well as regulation of the unactuated variables.The proposedmethods adjust predetermined value of the slidingmanifold’s slope in response to variations in hoisting heights. Control applications were conducted, and results based on graphical, integral absolute error (IAE), and integral time absolute error (ITAE) proved the effectiveness of the proposed algorithms. It was observed that the response of the controller with back-propagation-trained neural-network was more effective relative to that of the fuzzy algorithm.


Introduction
The overhead crane, the tower crane, and the boom crane are the most common types of cranes in use today.Among other crane systems, the modern overhead crane is increasingly becoming more popular due to its cost-effectiveness and ease of operation.The crane is used in the transport industry for loading and unloading freight, in the construction industry for material and equipment handling, and in shipping yards for loading and unloading cargo.Other important areas of crane application include the mining sites, power plants, warehouses, the manufacturing industry [1], and other applications where human power is not a solution.
Like other crane systems, the overhead crane is required to operate precisely with high-speed, and with the absence or minimal sway for improved productivity and safety reasons.However, high-speed operations without a high-quality control strategy cause undesirable payload swings and positioning inaccuracies.The operator is able to decrease such hazardous swings by moving the cart in small increments; however, manual operation may result in increased operation time and operator workload.As a result, there is the need for automation and optimization of crane operation.The control problem is challenging due to the underactuated nature of the system.Other factors that significantly affect control quality include modeling errors, deliberately neglected nonlinearities, parametric variations, and disturbances.
Among research interests, the requirement for a highquality controller to precisely drive the crane with minimal payload swings has attracted attentions and many constructive results have been published.Broadly, the existing control strategies in literature can be categorized into three: open-loop (OL), closed-loop (CL), and hybrid control (HC) schemes.For the OL schemes, the input command shaping (ICS) [2][3][4][5][6][7][8], the filter control [9], the command smoothing techniques (CS) [10], and the trajectory planning (TP) techniques [11][12][13] had been proposed.ICS achieves sway minimization by exciting two or more transient oscillations at different instances that result in effective cancellation of the payload oscillations.For the filter technique, the infinite impulse response (IIR) filter was proposed by [9], where the effectiveness of 3rd-, 6th-, and 9th-order Butterworth low-pass and band-stop IIR filters was studied.Filtering is developed on the basis of extracting input energy around system's natural frequencies, preprocessing the signal so that no energy at system's natural frequency is fed into the system.The CS method was proposed in [10] for limiting vibration in crane systems by a way of smoothing the original reference command.The input command is smoothed to drive the crane without inducing payload oscillations.It has been noticed that the CS technique proposed by [10] was more robust at relatively higher frequencies compared to the ICS methods.On the other hand, the ICS methods were more robust at relatively lower frequencies compared to the CS technique.For the proposed TP techniques, energy efficiency of transportation has seldom been considered in planning trajectories.Wu and Xia [13] exploited this consideration and developed an optimal solution of trajectory planning in terms of energy efficiency for overhead cranes.It is worth pointing out that OL techniques focus only on the suppression of the acceleration-induced payload sways.Nonetheless, the merits of OL control techniques include ease of implementation and no extra feedback sensors are required.Also, for the case of robust ICS, there may be additional time delays due to delaying of the command signal.Moreover, OL techniques are sensitive to external disturbances [14].
Closed-loop techniques on the other hand achieve position tracking and sway suppression using feedback information to generate the right control signal(s).Several CL solutions have been developed for control of cranes.The proportional-integral control (PID) was proposed by [15][16][17] and positive results were obtained.For the PID techniques, the authors used a PID controller for position control and a PD controller for sway suppression.Control techniques using optimal linear quadratic regulator (LQR) were proposed by [8] and constructive results were obtained using linearized crane model.Sun et al. [18] developed an adaptive anti-swing control strategy for uncertain double-pendulum cranes.In another work published by [19], the fuzzy logic control was proposed.Control using fuzzy logic has a strong adaptability and does not require obtaining an accurate crane model.The pole placement control was proposed by the authors in [20] where several control applications were conducted to investigate the performances of three different sets of system poles based on time response criteria.The model predictive control (MPC) was proposed by Wu et al. [21].The SMC control (which is the focus of this work) had been studied in [1,[22][23][24][25][26][27][28][29][30][31][32].SMC is a special type of variable structure control characterized by a discontinuous control structure that switches as the system crosses certain manifold in the statespace to drive the system trajectory to reach and subsequently remain on the sliding manifold within the state space [33].In [21] the SMC controller was used to control two degrees of freedom (DOFs): cart poison and payload sway, where two sliding manifolds were designed for each DOF.The authors proposed the fuzzy logic algorithm to dynamically adjust a coupling parameter between the two manifolds.A method of combining SMC was proposed by [1]; an intermediate variable was introduced by a way of dividing system states into two groups and then defining a manifold on the basis of the intermediate variable.In this way, the number of states variables to consider for design gets reduced.Consequently, the manifold complexity also gets reduced.Simulation results proved the feasibility of the intermediate variable approach.The integral SMC for discrete-time systems was proposed by [23].The SMC with moving sliding manifold was proposed by [24] where adaptive neurofuzzy inference system was used to generate the value of the manifold slope.The authors in [25][26][27][28]30] proposed adaptive SMC for overhead cranes with uncertainties.The second-order SMC was proposed by [26].The major advantage of second-order SMC is eliminating the so-called chattering effect by having a continuous control effort.Other techniques that hybridize different control schemes had also been proposed in the literature [34][35][36].The interested reader may find the feedback linearization with the SMC in [34], the PID hybridized with fuzzy SMC by Hai et al. [35], and the adaptive NN SMC by Tuan et al. [36], to name a few.
In this study, the effectiveness of neural-network (NN) and fuzzy auto-tuning SMC techniques designed to update predetermined value of manifold's slope parameter are compared.Based on this "update-approach," there would be no singularity in the controller when the tuning system fails as could be the case using the "generate-approach" of the author in [24].To the best of the authors' knowledge, this is the first publication where the NN-based and fuzzy-based autotuning SMC algorithms are compared.Studies have shown that optimizing the SMC yields improved performance [24] regarding convergence and fast vanishing of residual sway.
The rest of the paper organization is as follows.Mathematical modelling of the system is presented in Section 2. Section 3 is devoted to the design of the proposed control strategy, and the intelligent NN-based and fuzzy-based SMC tuning algorithms.Section 4 is devoted to the applications of the proposed control methods, as well as the performance evaluations of the proposed methods based on graphical, IAE, and ITAE criteria.Section 5 concludes the paper.

Mathematical Modelling
As shown in Figure 1, the system under study is a twodimensional overhead crane.The parameters and variables that describe the system are defined in Table 1.Derivation of the mathematical model for the system is based on the Euler-Lagrange method.For modelling simplicity, the following assumptions are considered.Assumption 1. Mass of hoisting cable is insignificant, all rotating joints are well lubricated, hoisting is only needed for obstacle avoidance, and all-states are available for control design.
From Figure 1, the x-and y-coordinates of the payload (  ,   ) and their corresponding time-derivatives can be written as  (1) System equations-of-motion (EOM) are obtained using Euler-Lagrange equation given by where  =   and  =   ,   is a vector of nonconservative generalized forces acting along the direction of the generalized coordinates   , and  is the number of independent generalized coordinates.For this study, the independent generalized coordinates in ( 2) are defined as , while the nonconservative generalized forces are defined as and the lost terms as The EOM for the system can be summarized in matrix form as The term   ẋ opposes the cart force,   , and refers to the viscous damping of the driving cart due to friction between the cart and air.Similarly, the viscous damping term   φ refers to the viscous damping force of the swinging payload, given by the friction between payload and air.
It is evident that the EOM for the system presented as (3) are coupled in the actuated acceleration variable ẍ and the unactuated acceleration variable φ .The EOM can be decoupled into actuated and unactuated subsystems.Isolating φ and ẍ from (3), we have By noting that the variables notations  1 = ,  2 = ẋ ,  3 = , and  4 = φ apply, the EOM for the crane system (see ( 4) and ( 5)) can be presented as with In ( 6), the linear force,   , that drives the cart originates from the trolley DC motor torque.Taking the effect of DC motor dynamics into account, the following equations relating the linear force   to motor torque   , and motor input voltage   , are defined where   ,   ,   ,   , and   have been defined earlier in Table 1, while   refers to the angular velocity of the motor.From (8), one easily isolates   as In Section 3, we present the design of the proposed control strategy.The following assumption is considered for control design.

Control System Design and Stability Analysis
The problem is to transport the payload along the desired trajectory from an initial position to the final position in short time with no or attenuated sway.These conflicting requirements coupled with the underactuated nature of the crane make the control more challenging.The SMC is proposed for the crane control problem.To optimize the performance of the proposed controller, intelligent tuning systems based on the NN and the fuzzy logic will be designed.

Sliding Mode Control Design and Stability
Analysis.SMC is a special type of variable structure system where control law is designed to drive system trajectory to reach and remain on a designed manifold within the state-space called sliding manifold [33].As shown in Figure 2, the error trajectory after the initial reaching phase "slides" on the manifold (, ) = 0. Insensitivity to parametric and matched uncertainties and disturbance make the SMC particularly attractive in robust control.
For the second-order actuated subsystem, design the sliding manifold as where is error vector and   is sliding manifold parameters vector that characterizes the manifold.The position error,  1 , has been defined as  1 =  1 −   1 , while the velocity error,  2 , has been defined as  2 =  2 −   2 .The variables  1 and  2 represent the actual system trajectories with desired trajectories as   1 and   2 , respectively.Without loss of generality, define ; hence, (10) and its time-derivative are, respectively, given by All velocities are zero at steady state; hence, set ẋ  1 =   2 = ẋ  2 = 0. Eventually, submitting the crane system given by ( 6) into (12) we have Parameter  1 is designed for the polynomial + 1 = 0 to be Hurwitz, where  is a Laplace operator.Thus, it is required that  1 > 0. We adopt the equivalent control given by (14) where   and   are known as the equivalent and the switching control, respectively.
During the sliding phase, only   control is applied to maintain the trajectories sliding along (, ) = 0.However, during reaching phase, both   and   make the total control law,   .During sliding, σ (, ) = 0 exists.Hence, considering (13),   is designed as We will design   from stability analysis.Define the candidate Lyapunov function as One may have noticed that the selection of the Lyapunov function satisfies the stability requirements that (, ) = 0 for  = 0 and (, ) > 0 for  ̸ = 0 ∀.By differentiating ( 16) with respect to time along ( 15) one arrives at By submitting ( 14) and ( 15) into (17) and simplifying, (17) reduces to V (, ) =  (, )  1 ()   .
In ( 18), for the system to be asymptotically stable, it is required that V(, ) < 0 holds.Note that the factor  1 = 1/(  +   −   cos 2 ) in ( 18) is strictly positive.Hence, the values that the switching law   is set to achieve V(, ) ≤ 0 are given as and by LaSalle's invariance principle [37] we have V(, ) < 0 and the crane is asymptotically stable about the origin.To meet the requirements of ( 19), design   as where  is a positive constant and the signum function sign(⋅) is defined as Remark 3. To reduce the fast switching of the control law, we replace sign(⋅) by the smoothing function [38] given by (22), where  > 0.Here  = 0.05 is selected.The smoothing function eliminates the fast switching of the control law while preserving robustness property around some neighbourhood of the sliding manifold.
sign ( (, )) ≈  (, ) | (, )| +  (22) In this study, the controller parameters are designed as  = 70 and  1 = 5.48.The closed-loop system will maintain robust stability against matched and parametric uncertainties.However, as stated earlier, high-speed operation coupled with variations in hoisting heights may affect the reaching time to (, ) = 0 for sway.Linearizing (5) about  = 0 0 , one obtains Equation ( 23) represents a second-order system.When expressed in transfer function form, it can be easily proved that the undamped-natural frequency,   , of the crane is given by In (24), it is evident that   is -dependent.Changes in  are likely to affect the swaying duration.Studies show that optimizing the SMC yields improved performance [24] regarding convergence and fast vanishing of residual sway.
In this study, we compare the intelligent NN and fuzzy logic algorithms for tuning the slope parameter  1 of the controller.The approach to the SMC optimization problem in this study is to design intelligent systems to update the previously designed slope parameter  1 (here redefined as  0 1 ) according to It is to be noted that our approach is different from that proposed by [24] where neurofuzzy system was proposed to generate the slope parameter  1 .In this work, the intelligent system updates predetermined value of  1 by an amount Δ 1 (determined by the intelligent system) rather than completely generating it.Hence, there would be no singularity in the slope parameter  1 when the intelligent system fails as may be the case using the "slope-generate" approach of [24].
Using the "slope-update" approach, the system will remain operational (although with reduced effectiveness) even when intelligent tuning system fails.

Intelligent Tuning Algorithms Designs.
Optimal training dataset was obtained through tuning exercises for different sets of hoisting heights in the range 0.25 meters to 1.5 meters.
The knowledge from the tuning exercise was used to carry out supervised training of the NN and to design the fuzzy algorithm.The control architecture is as shown in Figure 3.The switch, , is used to select the algorithm of choice.The outputs of the intelligent algorithms adjust controller slope for all operating conditions.

Neural-Network Design.
As shown in Figure 4, the NN is a feed-forward, two-layered network with a 1-2-1 structure.The input node takes in the hoisting height data.The weighting factor linking the input node to the ℎ hiddenlayer is denoted by  1 , while the weighting factor linking the ℎ hidden-layer to the output-layer is denoted by  1 .The network output is change in slope, Δ  1 .Define the instantaneous error between the desired change in slope (Δ  1 ) and the NN-based change in slope (Δ  1 ) as Since the network's output (Δ  1 ) can be positive, negative, or zero, the hidden-and the output-layers use the tangent hyperbolic activation function defined as The input gets multiplied by the weights  1 linking the input node to the hidden-layer.The summation of the product operations is the input to the hidden-layer neurons given by The output from the ℎ neuron in the hidden-layer can be expressed as The output of the ℎ hidden-layer neuron gets multiplied by the weight  1 .Contributions from all nodes are sent to the output-layer neuron according to The output from the neuron in the output-layer is given by Adaptation of the network weights is by the steepest descent back-propagation algorithm [39].Define the cost function (to be minimized) as mean squared of the training error given by Generally, adjustment of each weight linking hidden-layer to output-layer can be expressed as where  and  are positive constants known as the learning and the momentum factor, respectively. is to avoid the solution from getting trapped in the so-called local minima [40].
In (33), the partial derivative ()/  can be expressed based on the chain rule as Next, we define the partial derivatives in (34).From (30), it happens that Also, considering (31), the following can be obtained: Similarly, considering (32), it can also be verified that Putting all defined derivatives together, ( 34) is given by Finally, the update algorithm for the next output-layer weights,  1 ( + 1), is given by By applying similar sets of calculations (see ( 33)-( 39)) for the output-layer, the hidden-layer weights are updated according to the update rule given by where in this case the change in the ℎ hidden-layer weight has been defined as .Triangular membership functions (MFs) are selected for the input and output variables as shown in Figures 5(a) and 5(b), respectively.The input takes the linguistic values: VS: Very Short ( is about 0.25 meters), S: Short ( is about 0.5 meters), MS: Medium Short ( is about 0.75 meters), ML: Medium Long ( is about 1 meter), L: Long ( is about 1.25 meters), and VL: Very Long ( is about 1.5 meters).The output is assumed to take the following linguistic values: NB (Negative Big), NM (Negative Medium), NS (Negative Small), ZE (zero), PS (Positive Small), and PM (Positive Medium).
The first step is to take the crisp hoisting height input and determine its degree of belonging in each of the fuzzy sets via MFs.Since we have single input and single output system, the rule antecedent and consequent parts are simple.The ℎ linguistic rule set can be expressed as where   is the  ℎ rule of the  rules and   and   are the corresponding MFs for  and Δ  1 . The one-dimensional rule is given by Table 2. Defuzzification for obtaining the crisp output is based on the following simplified inference method where    () is the firing strength of the  ℎ rule.
In Figure 5(c), the near-linear relationship between the crisp cable length and the crisp output is used to update the SMC slope parameter according to (25).

Applications of the Designed Control Algorithms
The parameters of the model are accepted as in Table 3. Payload changes according to the mass of the load to be transported.The hoisting height also changes during loading and unloading and when avoiding obstacles.The natural frequency of the system changes as cable length changes; thus the sway characteristic of the system changes.Changes in hoisting height are likely to cause deterioration in sway suppression.For these reasons, control applications were repeated by varying payload and hoisting height to demonstrate the effectiveness of the proposed control strategy with the designed intelligent tuning algorithms.In Figure 6, the performances of the SMC controller without intelligent tuning algorithms for hoisting heights of 1 m and 1.25 m are investigated.A 5 kg load is assumed to be transported to a target position of 1 m.As expected, examining the responses revealed that the payload sways as hoisting height increased from 1 m to 1.25 m.The sway lingers due to the decrease in the crane's   (see (24)).In order to improve the effectiveness of the controller for all operating conditions, fine-tuning of controller is required.
Figure 7 shows the responses obtained when the performance of the controller with intelligent tuning algorithms was investigated.For the purpose of comparison, the same parameters are used as in the previous case (Figure 6).One can see from the responses that the sway has been effectively suppressed despite the changes in hoisting height.Also, the responses of the fuzzy-tuned SMC (FZ-SMC) and the neuralnetwork-tuned SMC (NN-SMC) are overlapping.However, for a quantitative comparison of the performances of the two control strategies, we employ the IAE (see (44)) and the ITAE (see ( 45)) as criteria.The IAE and ITAE values for Figure 7 correspond to case ID 1 in Table 4 and are for the case when the hoisting height was set to 1.25m.Based on Table 4, the performance of the NN-SMC is only slightly better relative to that of the FZ-SMC in terms of sway attenuation.IAE and ITAE are, respectively, defined by ( 44) and (45), wherein here () refers to the  ℎ sway regulation error.
Figure 8 shows the case when a payload of 10 kg is transported to a 2 m position from the reference.For the first 10 seconds of operation, it was assumed that the required hoisting height is 1m, and between 10 and 20 seconds the height changed to 1.5 m, while between 20 and 30 seconds the required hoisting height is 0.  4. Like in the previous control application, the performance of the NN-SMC is only slightly better relative to that of the FZ-SMC in terms of sway attenuation (see Table 4, case ID 2).Two other control applications were performed (Case ID 3 and 4) to investigate the performances of the proposed control strategies (FZ-SMC and NN-SMC).For brevity, only the IAE and ITAE values for cases are shown in Table 4. Case ID 3 corresponds to the study case when a payload of 20 kg is transported at a fixed hoisting height of 1 m.During the first 10 seconds of operation, the target position is 1 m, and between 10 and 20 seconds of operation the cart is given command to move to the 2 m position, while between 20 and 30 seconds the target position is 3 m.Based on the IAE and ITAE values Case ID 3, the performance of the NN-SMC is slightly better than that of the FZ-SMC like in the previous control applications.On the other hand, Case ID 4 refers to the application when payload of 20 kg is transported.Position tracking for this case is the same as previous control application (Case ID 3).However, for this case, during the first 10 seconds of operation the cable length is 1 m, and between 10 and 20 seconds the length changed to 1.5 m, while between 20 and 30 seconds the length changed to 0.5 m for obstacle avoidance along the trajectory of the payload.From Table 4, the performance of the NN-SMC is slightly better as compared to that obtained using the FZ-SMC.
Remark 4. In this study, one can argue that both control strategies (FZ-SMC and NN-SMC) are equally effective in dealing with position tracking and sway suppression.However, it is worth noting that the effectiveness of the intelligent algorithms relies heavily on the proper design and training of these algorithms.
So far, we only investigate the effectiveness of the proposed algorithms within the range of the training dataset (0.25 m to 1.5 m).The responses shown in Figure 9 are those obtained for a hoisting height of 1.7 m (i.e., 0.2 m above dataset upper bound).Payload is accepted as 15 kg and target position is 1m.Examining the responses, the NN-SMC remains robust in terms of sway suppression, while the effectiveness of the FZ-SMC deteriorates.This is because the training of the NN based on the back-propagation learning and adaptation algorithm enables it to learn and establish an appropriate functional relationship between training sets.Consequently, the network can effectively predict the optimal values of "slope-updates" for those inputs outside the range of the training dataset.On the other hand, the accuracy of the fuzzy-based tuning algorithm relies heavily on the defined universe of discourse for the input variable as well as the values returned when the MFs are read.In order words, the design of the fuzzy does not account for a hoisting height of 1.7 m.Hence, the fuzzy-based algorithm could not accurately predict the corresponding change in slope for Case ID 5.
Remark 5.For practical cranes, there exists control input saturation problem.Also, the inclusion of integral term in the control law can reduce final positioning errors due to parametric uncertainties or unmodelled dynamics.These two problems might arise in practice and are not considered here.In fact, there is already an effective solution to these problems in [41] that can be applied to practical cranes to solve the problems.

Conclusion and Future Work
Payload mass and hoisting height take different values during crane operation.Hence, high-quality control requires robustness against parametric uncertainties.The invariance property of the SMC against matched uncertainty makes it particularly attractive in control engineering.In this work, the SMC strategy was designed to address the crane control requirements for high-speed of operation, accurate positioning, and minimal sway.To improve the robustness of the proposed SMC strategy, intelligent tuning algorithms based on fuzzy and the NN algorithms were designed to optimize the proposed SMC performance.Controls were repeated by varying payload, position set-point, and hoisting heights in order to demonstrate the quality of the proposed control algorithms to parametric variations.Analyses of performances based on graphical, IAE, and ITAE criteria showed the effectiveness of the proposed methods.However, it was observed based on IAE and ITAE criteria that the NN-SMC strategy was slightly more effective as compared to the FZ-SMC strategy.It was also observed that, for the case of the NN-SMC strategy, there might not be the need for complete redesign of the tuning algorithm in the case where the system requires expansion to cover for higher hoisting heights not considered during control design.Furthermore, attenuated chattering and fast convergence of the sliding variable were observed.
To verify the practical performance of the proposed controllers, experiments can be conducted on an industrial crane.Our next work will be to investigate the effectiveness of the proposed algorithms from practical perspective.

Figure 1 :
Figure 1: System schematic diagram.The motor is assumed stopped and the payload was at an angle.

Figure 2 :
Figure 2: Attractive property of the sliding manifold.

Figure 3 :
Figure 3: Closed-loop system block diagram with proposed intelligent SMC tuning algorithms.
Figure8shows the case when a payload of 10 kg is transported to a 2 m position from the reference.For the first 10 seconds of operation, it was assumed that the required hoisting height is 1m, and between 10 and 20 seconds the height changed to 1.5 m, while between 20 and 30 seconds the required hoisting height is 0.5 m for obstacle avoidance along the trajectory of the payload.Examining the responses, the performances of the two controllers are effective based on position tracking, minimal acceleration-induced sway, and residual sway suppression capabilities.Furthermore, the control efforts (Figure8(e)) revealed that the control efforts have attenuated chattering and (, ) = 0 attained in about

Table 2 :
One-dimensional rule table for fuzzy tuning algorithm.

Table 3 :
Numerical values for the simulation model parameters.

Table 4 :
Fuzzy-SMC and neural network-SMC comparisons based on IAE and ITAE.