Next Article in Journal
Extreme Value Statistics for Evolving Random Networks
Next Article in Special Issue
A More Efficient and Practical Modified Nyström Method
Previous Article in Journal
The Confluent Hypergeometric Beta Distribution
Previous Article in Special Issue
A Comprehensive Method to Evaluate Ride Comfort of Autonomous Vehicles under Typical Braking Scenarios: Testing, Simulation and Analysis
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Application of Fuzzy PID Based on Stray Lion Swarm Optimization Algorithm in Overhead Crane System Control

1
Rail Transit Department, Zhejiang Institute of Communications, Hangzhou 311112, China
2
College of Information Engineering, Nanjing University of Finance and Economics, Nanjing 210023, China
3
Alibaba Cloud Intelligence Business Group, Alibaba Co., Ltd., Hangzhou 310024, China
4
Post Industry Technology Research and Development Center of the State Posts Bureau (Internet of Things Technology), Nanjing University of Posts and Telecommunications, Nanjing 210023, China
5
Post Big Data Technology and Application Engineering Research Center of Jiangsu Province, Nanjing University of Posts and Telecommunications, Nanjing 210023, China
*
Authors to whom correspondence should be addressed.
Mathematics 2023, 11(9), 2170; https://doi.org/10.3390/math11092170
Submission received: 29 March 2023 / Revised: 22 April 2023 / Accepted: 23 April 2023 / Published: 5 May 2023
(This article belongs to the Special Issue Fuzzy Modeling and Fuzzy Control Systems)

Abstract

:
To solve the problem of crane anti-swing, fuzzy PID is a common method. However, the parameter configuration of fuzzy PID requires a lot of time and effort from professionals. Based on this, we introduce the LSO algorithm and add the stray operator, which effectively improves its global search performance. By combining SLSO and fuzzy PID and comparing them with other methods, this paper confirms that even without the targeted optimization by professionals, the optimization algorithm can find the appropriate parameter configuration for fuzzy PID which can be effectively used in the crane anti-swing problem.
MSC:
93-10; 93B45; 93C42

1. Introduction

Fuzzy logic control provides a system theory method for experts to construct language information and convert it into control strategies, which can solve many complex control problems that cannot establish accurate mathematical model systems, so it is an effective method to deal with imprecision and uncertainty in reasoning system and control systems [1,2,3,4,5]. Because of this, the parameter setting of fuzzy control has always depended on the personal ability of experts.
PID control is widely used in various fields because of its advantages of simple structure, strong stability, and convenient adjustment [6,7,8,9,10]. As the core content of control system design, PID parameter tuning is the key factor to determine the control effect. In general, PID parameter tuning can be divided into theoretical calculation tuning and engineering tuning. The former is mainly based on the mathematical model of the system and determines the controller parameters through theoretical calculation, but it still needs to be adjusted and modified on site. The latter mainly adjusts the parameters manually according to field operation experience. Because operator experience is not easy to accurately describe, various semaphores and evaluation indicators in the control process are not easy to quantitatively express, the adjustment process is not controllable, and the optimization effect is extremely dependent on personal ability.
Overhead cranes are indispensable in the construction of bridges, docks, and other buildings. An overhead crane is a typical underactuated system. During the usage, because the sling cannot fully control the load, the swing of the load may collide with other objects. At present, an overhead crane must be operated by experienced workers. However, due to the inaccuracy of manual operation, it is still impossible to avoid safety accidents. Therefore, the construction industry needs to design a stable and efficient anti-interference controller for the bridge crane system and realize automatic control of the bridge crane system. There are many studies in this field [11,12,13,14].
There are many examples of the combination of fuzzy control and PID [15,16,17], among which Sun et al. applied it to anti-swing control of an overhead crane, and achieved good control results [18]. This avoids the problem of the parameter optimization of PID, but also ushers in new problems. The parameter optimization of fuzzy control is more difficult than PID. This not only requires optimization personnel to have rich practical experience but also requires certain knowledge of fuzzy mathematics, which undoubtedly raises the application threshold of fuzzy control.
In 2016, the lion swarm optimization algorithm was proposed [19]. The lion swarm optimization algorithm is a nature-inspired algorithm based on the special lifestyle of lions and their cooperative behaviors [20]. Compared with some algorithms, the lion swarm optimization algorithm is a new meta-heuristic algorithm, which has the characteristics of simple operation, fast convergence speed, and a small amount of calculation. Subsequently, LSO has been continuously optimized or applied in various fields [21,22,23,24]. Although LSO has the characteristics of fast convergence speed and a small amount of calculation, it is still easy to fall into local optimization to a certain extent. Strengthening the algorithm is very important for the optimization performance of complex systems, and there are many papers worthy of reference in this regard [25,26,27,28,29].
PID does not perform well in the control of overhead cranes due to the difficulty in handling the control of nonlinear systems. After the introduction of fuzzy PID, although the x-performance is improved, the dependence of fuzzy PID on expert experience limits its control performance and generalization capability. To improve the performance of the fuzzy PID controller, we proposed an SLSO algorithm-based fuzzy PID controller for overhead crane systems. The contribution can be summarized as follows: (1) a stray operation is introduced to improve the LSO algorithm, which can enhance the population diversity and further reduce the risk of falling into local optimization, to improve the convergence accuracy of the algorithm. (2) Adaptive parameter adjustment based on the SLSO algorithm is designed to eliminate the dependency on experts. In addition, the effectiveness of adaptive fuzzy parameter configuration was verified via anti-swing experiments of the overhead crane.
This paper is divided into six sections. The Section 1 is a general introduction. Section 2 elaborates on the theoretical model and control formulation of an overhead crane. Section 3 introduces the LSO algorithm and our improvement, and conducts a comparison experiment with other algorithms on the test function. Section 4 describes how the SLSO algorithm is combined with fuzzy PID and applied to the control of overhead cranes. Section 5 gives the results and analysis of the simulation experiments. Section 6 provides a summary of this paper and an outlook for future work.

2. Introduction of the Overhead Crane System Model

As shown in Figure 1, the control system controls the horizontal movement of the trolley on the bridge, and the movement and swing of the load can only be indirectly controlled by controlling the movement of the trolley.
According to Euler Lagrange method, the dynamic model of an overhead crane is as follows:
( m l + m c ) x ¨ + m l l ( θ ¨ cos θ θ ˙ 2 sin θ ) = u
m l cos θ + m l l θ ¨ + m l g sin θ = 0
where x and θ denote the displacement of the trolley and the swing angle of the load, m l and m c , respectively, represent the mass of the load and the trolley, l is the length of the sling, u is the control force exerted on the trolley, and g is the acceleration of gravity.
Setting x ˙ = x 1 , x ¨ = x 2 , θ ˙ = x 3 , θ ¨ = x 4 , the following differential equations can be obtained by transformation:
{ x ˙ 1 = x 2 x ˙ 2 = m l g cos x 3 sin x 3 + m l l x ˙ 3 2 sin x 3 + u m l + m c m l cos 2 x 3 x ˙ 3 = x 4 x ˙ 4 = m l l x ˙ 3 2 cos x 3 sin x 3 + ( m l + m c ) g sin x 3 + u cos x 3 l ( m l + m c m l cos 2 x 3 )

3. The Stray Lion Swarm Optimization Algorithm

This section will employ many symbols, and their meanings are shown in Table 1.

3.1. Standard Lion Swarm Optimization Algorithm

In order to search for better solutions, the Lion King will conduct a range search based on the historical optimal solution. The formula for updating the position is as follows:
x i k + 1 = g k ( 1 + γ p i k g k )
A lioness randomly selects another lioness to cooperate with, and the formula for updating the position is as follows:
x i k + 1 = p i k + p c k 2 ( 1 + α f γ )
There are three updating strategies for young lions, namely follow the lioness, follow the lion king, or leave the location of the group to search for the updated location in reverse. The formula is as follows:
x i k + 1 = { g k + p i k 2 ( 1 + α c γ ) , 0 q 1 3 p m k + p i k 2 ( 1 + α c γ ) , 1 3 < q 2 3 g ¯ k + p i k 2 ( 1 + α c γ ) , 2 3 < q 1
where x i k refers to the i-th individual in the k-th generation population; γ is a random number generated according to the normal distribution N(0, 1); p i k is the historical best position of the i-th individual from the 1st to the k-th generation; g k is the best position of the k-th generation population; p c k is randomly selected from the k-th generation lioness group; p m k is randomly selected from the k-th generation lion group; q is the uniform random value generated according to the uniform distribution U [0, 1]; g ¯ k = l o w ¯ + u p ¯ g k ; l o w ¯ and u p ¯ are the minimum value and maximum value of each dimension within the range of lion activity space; α f and α c are the disturbance factor. The calculation method is as follows:
α f = 0.1 ( u p ¯ l o w ¯ ) × exp ( 30 t T ) 10
α c = 0.1 ( u p ¯ l o w ¯ ) × ( T t T )
where t is the current number of iterations and T is the maximum number of iterations.

3.2. Stray Lion Swarm Optimization Algorithm

Although LSO has the advantages of high search efficiency and fast convergence speed, it still cannot solve the problem where swarm intelligence can easily fall into local optimization. In the LSO, most individuals will iterate with the lion king as the core, so it is difficult to escape when they fall into the local optimal solution.
In this paper, a stray individual is introduced as optimization interference, which can effectively avoid falling into local optimal solutions and obtain better optimization results on the premise of ensuring the population size.

3.2.1. Stray Operation in SLSO

The stray individual introduced in this paper deviates from the algorithm as far as possible in scope. At the same time, to avoid the individual falling into an extremely bad state, it is necessary to introduce a certain random quantity to ensure the effect. The formula for each generation of the stray individual is as follows:
f k [ i ] = ( ( u p [ i ] l o w [ i ] ) × γ + 2 l o w [ i ] + u p [ i ] g k [ i ] ) / 2
where f k [ i ] is the value of the stray individual at the i-th dimension in the k-th generation. u p [ i ] / l o w [ i ] is the upper/lower limit at the i-th dimension. g k [ i ] is the value of the lion king at the i-th dimension in the k-th generation.

3.2.2. Iteration Strategy of the Lion Swarm in SLSO

To avoid the negative impact of dissociated individuals on the population, this paper sets a participation probability. When the probability is met, the cubs and females will be updated according to the new formula. In general, this probability is set to 0.1. Formula (11) is the new iterative strategy of the female lion, and Formula (12) is the new iterative strategy of the young lion.
x i k + 1 = p i k + f k 2
x i k + 1 = { g k + f k 2 , 0 q 1 3 x i k + f k 2 , 1 3 < q 2 3 x ¯ i k + f k 2 , 2 3 < q 1
where f k is the stray individual in the k-th generation. x ¯ i k + 1 = l o w ¯ + u p ¯ x i k .

3.2.3. Convergence Proof of SLSO

The SLSO algorithm is improved based on the LSO algorithm, and this paper first makes a proof of the convergence of the LSO algorithm. The proof refers to reference [30].
(1)
Markov chain model of the LSO algorithm
The position update of each individual is obtained by Gaussian sampling, where the position update distribution of the lion king is x i ( t + 1 ) ~ N ( g , | p i , g | 2 ) .
The position update distribution of the lioness is x i ( t + 1 ) ~ N ( P i + P c 2 , α f 2 ) .
The position update distribution of the young lion is as follows:
x i ( t + 1 ) ~ { N ( g + p i 2 , α c 2 ) , q < 1 / 3 N ( p c + p i 2 , α c 2 ) , 1 / 3 q < 2 / 3 N ( g ¯ + p i 2 , α c 2 ) , 2 / 3 q < 1
In which q = rand [0,1).
To illustrate the Markov chain model of the LSO algorithm, the following definitions and mathematical descriptions are given.
Definition 1.
Lion swarm state and state space. The set of all states in the pride constitutes the state space of the pride, denoted as follows:
| s = ( x 1 , x 2 , , x i , x N ) | x i = ( x i 1 , x i 2 , , x i d , , x i D ) , 1 i N , 1 d D
Definition 2.
State transfer of individuals, For  x i s , x j s , the lion is transferred from state  x i  to state  x j  in one step, denoted as  T s ( x i ) = x j .
Theorem 1.
Transfer probability of the LSO algorithm:
P ( T s ( x i ) = x j ) = { P m ( T s ( x i ) = x j ) , l i o n k i n g P f ( T s ( x i ) = x j ) , l i o n e s s P c ( T s ( x i ) = x j ) , y o u n g l i o n
Proof. 
The corresponding one-step transfer probabilities are different because of the different ways to update the positions of the three lions. The lions’ positions can be viewed as a set of points in the hyperspace, and the position update process is a point set transformation in the hyperspace. For computational convenience, let the changed point set obey a uniform distribution U(−1,1) so that the transfer probability of the male lion can be obtained. The transfer probability of the lion king is shown as follows:
P m ( T s ( x i ) = x j ) = { 1 2 ( | g p i | ) , x j [ g | g p i | , g + | g p i | ] 0 , e s l e
The transfer probability of the lioness is shown as follows:
P m ( T s ( x i ) = x j ) = { 1 2 α f ( | p c p i | ) , x j [ p i + p c 2 α f | p c p i | , p i + p c 2 + α f | p c p i | ] 0 , e s l e
The transfer probability of the young lion is shown as follows:
P c ( T s ( x i ) = x j ) = { 1 2 α c ( | g p i | ) , x j [ p i + g 2 α c | g p i | , p i + g 2 + α c | g p i | ] 1 2 α c ( | p m p i | ) , x j [ p i + g 2 α c | p m p i | , p i + g 2 + α c | p m p i | ] 1 2 ( | g ¯ p i | ) , x j [ p i + g ¯ 2 | g ¯ p i | , p i + g ¯ 2 + | g ¯ p i | ]
 □
Definition 3.
State transfer probabilities of lion swarm. For  s i S  and  s j S , S is the set of lion pride states, and the probability of a lion pride transferring from  s i  to  s j  in one step, denoted as  T s ( s i ) = s j , is  P ( T s ( s i ) = s j ) = i = 1 N P ( T s ( s i ) = x j i ) .
where N is the number of individuals in the pride, and x j i is the state corresponding to individual x i . The one-step transfer probability of the pride state in the LSO algorithm is the simultaneous transfer of the states of all lions in the pride.
(2)
Convergence analysis of the LSO algorithm
According to the authors in [31], the definitions of Markov chain, finite Markov chain, and chi-square Markov chain are no longer given in this paper; see [31] for details.
Theorem 2.
The population sequence generated by the LSO algorithm  { s ( t ) , t 0 }  is a finite chi-square Markov chain, where t is the number of iterations.
Proof. 
  • According to Definition 3, in the population sequence { s ( t ) , t 0 } , s ( t ) S and s ( t + 1 ) S , the transfer probability P ( T s ( s ( t ) ) = s ( t + 1 ) ) is determined by the transfer probability P ( T s ( x ( t ) ) = x ( t + 1 ) ) of all lions.
  • According to Theorem 1, the state transfer probability of any lion in the pride is only related to the state at moment t and other randomly selected individuals in the population at moment t. Therefore, P ( T s ( x ( t ) ) = x ( t + 1 ) ) is only related to the state at moment t, but not to t.
  • According to 1 and 2, it can be seen that the population sequence generated by the LSO algorithm has Markov property, and because the state space { s ( t ) , t 0 } of the lion population is finite, according to the definition of finite Markov chain, the population sequence { s ( t ) , t 0 } generated by the LSO algorithm constitutes a finite Markov chain.
  • According to Theorem 1, P ( T s ( s ( t ) ) = s ( t + 1 ) ) is also only related to the state at moment t of s, but not to t. Therefore, the population sequence produced by the LSO algorithm { s ( t ) , t 0 } is a finite chi-square Markov chain.
 □
According to the authors in [32], it is known that the stochastic algorithm converges globally, and the LSO algorithm is a stochastic search algorithm, so this paper will determine the convergence of the LSO algorithm according to the convergence criterion of the stochastic algorithm.
(3)
Convergence proof of LSO algorithm
Definition 4.
The set of optimal states of the lion population is G. Let the optimal solution of the optimization problem  < A , f >  be  g * , and define the set of optimal states of the lion swarm as follows:  G = { s = ( x 1 , x 2 , x i , , x N ) | f ( x i = f ( g * ) , x i S , s S ) } . If G = S, then every solution in the feasible space is not only a feasible solution, but also an optimal solution. At this point, the iteration is meaningless, the following discussion of  G S .
Theorem 3.
The optimal set of lion states G of the lion group algorithm is a closed set on the state space S.
Proof. 
s i G , s j G , s j S , the transfer probability of T s ( s i ) = s j is P ( T s ( s i ) = s j ) = i = 1 N P ( T s ( s i ) = x j i ) .
At least one lion state in G is optimal, and let g * ~ x i 0 k be the optimal state, i.e., at least x i 0 k G , P ( T S ( x i 0 k ) = x j k ) = 0 .
At this point, P ( T s ( s i ) = s j ) = 0 , so the set of optimal lion swarm states G is a closed set on the state space S. □
Theorem 4.
There is no nonempty closed set M in the state space S of the lion population such that  M G = φ .
Proof. 
Suppose there exists a nonempty closed set M in the state space S, and M G = φ , let s i = s ( g * , g * , , g * ) G ,   s j = ( x j 1 , x j 2 , , x j d ) M , and we have f ( x j ) > f ( g * ) .
According to the Chapman–Kolmogorov equation, we can obtain the result as follows:
P s j , s i l = s r 1 S s r l 1 S P ( T S ( s j ) = s r 1 ) P ( T S ( s r 1 ) = s r 2 ) P ( T S ( s r l 1 ) = s r i )
The algorithm will satisfy the conditions (12)–(14) in Theorem 1 after finitely many iterations of m. Therefore, the one-step transfer probability of each term of the expansion in Equation (15) satisfies P ( T s ( s r c + j ) = s r c + j + 1 ) > 0 when the step size is large enough.
Therefore, P s j , s i l > 0 , which yields that M is not a closed set. Thus, the Markov chain of lion group states is not approximately separable, and the z-state space S does not contain closed sets other than G. □
Theorem 5.
Assume that the Markov chain has a nonempty closed set E and there does not exist another nonempty closed set O, such that  E O = φ , when  j E , there is  lim k P ( x k = j ) = π j . When  j E , there is  lim k P ( x k = j ) = 0 .
Proof. 
For the proof process, please refer to [33]. □
Theorem 6.
When the iterations within the lion group tend to infinity, the lion group state must enter the optimal set of states G.
Proof. 
From Theorems 3–5, Theorem 6 holds. □
Theorem 7.
The LSO algorithm can converge to the global optimum.
Proof. 
The LSO algorithm is stochastic, so the LSO algorithm satisfies the condition of global convergence of stochastic algorithms H1 [33], and we know from Theorem 6 that the probability that the LSO algorithm does not search for the global optimal solution for an infinite number of consecutive times is 0. Then, we have k = 0 ( 1 u k [ B ] ) = 0 .
where u k [ B ] is the probability measure of the k-th iteration of the LSO algorithm to search for a solution to the set B, which satisfies the global convergence condition of the most taboo algorithm H2 [33]. For the LSO algorithm at each iteration, the update of the individual historical optimum takes the retention mechanism of the optimal individual, when the iteration tends to infinity. lim k P ( x k R ε , M ) = 1 . { x k } k = 0 is the sequence generated by the iteration of the LSO algorithm, according to the global convergence of the stochastic search algorithm. It can be concluded that the LSO algorithm is globally convergent. □
Theorem 8.
The SLSO algorithm is globally convergent.
Proof. 
The dissociation operator only sets up a stray individual outside the population and jointly searches for non-optimal solutions within the population at low probability (probability = 0.1). This means that the population sequence convergence of the SLSO algorithm with size n is equivalent to the population sequence convergence of the LSO algorithm with size 10n/9. The SLSO algorithm proposed in this article still meets the following requirements:
  • The population evolution direction in the SLSO algorithm is monotonic, i.e., F ( X ( n + 1 ) ) F ( X ( n ) )
  • The population sequence of the SLSO algorithm { X ( n ) , n N + } is a homogeneous Markov chain
  • The Markov chain of the SLSO algorithm { X ( n ) , n N + } converges with probability 1 to a subset of the satisfactory population M M 0 = M 0 * = { Y = ( y 1 , , y N p ) | y i M * } in the solution space, i.e., lim n P ( X ( n ) M 0 * | X ( 0 ) = X 0 ) = 1 .
Therefore, it can be inferred that the SLSO algorithm in this paper converges.
The relevant symbols are common symbols for the convergence proof of swarm intelligence algorithms, and there will be no expansion explanation here. □

3.3. Numerical Experiments

To verify the performance of the SLSO presented in this paper, six well-known benchmark functions are used. For comparison, the standard LSO, standard GA, and standard PSO algorithms are adopted during the test process.
For a fair comparison, the population = 50, dimension = 10, number of iterations = 100, and each algorithm runs 50 times for each test function. Some of these benchmark functions are lower than 10 dimensions. Since the goal of this paper is to optimize the parameter configuration of ADRC, all benchmark functions have been increased to 10 dimensions for calculation. We take the average of the results of 50 runs as the result to eliminate the uncertain factors in the search process. The final iteration result is compared with the number of iterations used to achieve the optimized iteration result, and the results are shown in Table 2. Information on these benchmark functions is shown in Table 2, too.
Please note that it is not that there are no more experiments, but that most of the test functions are not difficult to optimize for LSO. Therefore, we only select functions with poor LSO performance to show the improvement effect.
Figure 2 shows the convergence curves of four algorithms with benchmark functions, and shows the performance of the SLSO more intuitively and clearly. From Figure 2, Figure 3, Figure 4, Figure 5, Figure 6 and Figure 7, we can find that in Function Eason, the LSO obtains a worse result than GA, but the SLSO obtains a better result than the other three methods.
In Function Styblinski_Tang, Beale, Eggholder, and Holder_table, the LSO works worse than PSO, but better than GA. However, after being improved, it works better than PSO.
In Function Schwefel, we can find that LSO works worst, and the SLSO works best.
We can find that in Table 2, the standard deviation of the results of the function based on the SLSO algorithm for finding the best is smaller than that of the LSO-based, which means that SLSO can find the optimal solution more stably, rather than relying on randomness.
In conclusion, SLSO can not only further improve the optimization results of LSO, but also perform well in the face of functions where LSO is not good at optimizing. Therefore, we can think that the improvement in this paper not only improves the accuracy of the algorithm, but also improves the applicability of the algorithm, and the improvement effect is ideal.

4. Designing of SLSO-Based Fuzzy PID

4.1. Fuzzy PID of Overhead Crane

The structure of fuzzy PID is shown in Figure 8. By calculating the system error e ( t ) and error change rate e c ( t ) , and combining them with expert experience, the change rates of K p , K i and K d can be deduced through fuzzy rules.
The value ranges of e ( t ) , e c ( t ) and the fuzzy domains of K p , K i , and K d are [−10, 10], [−10, 10], and [−6, 6], respectively. Generally speaking, fuzzy rules include {NB, NM, NS, NZ, ZO, PZ, PS, PM, PB}, and may contain different numbers of fuzzy rules according to different situations. The update method of K p , K i , and K d is shown in Formula (16).
K p = K p + Δ K p , K i = K i + Δ K i , K d = K d + Δ K d
The fuzzy rules of K p , K i , and K d are shown in Table 3, Table 4 and Table 5.

4.2. SLSO-Based Fuzzy PID

The fuzzy rule setting of fuzzy PID can be obtained quickly according to expert experience, but the value setting needs repeated debugging.
In this paper, SLSO is introduced to the interval design of fuzzy numbers.
For PID control, three rules require fuzzy control, each with two input parameters and one output parameter. Each parameter has seven situations and is controlled by seven arrays. Due to the symmetry of the parameters themselves, each parameter requires six numbers to control.
The interval of parameters is determined; therefore, the optimization of fuzzy rules can be transformed into the segmentation of the interval, and the number of segmented nodes is the number we need. Therefore, we patrol through seven numbers, with a range of values in the range (0–100). The ratio of the seven numbers is equivalent to the length ratio between the divided partitions within the interval. In this way, we can obtain the six numbers of the segmentation interval.
In summary, each interval needs 7 parameters, each fuzzy rule needs 3 intervals, this experiment has 3 fuzzy rules, so each individual needs to have 63 dimensions to optimize the parameters of the fuzzy rule. Then, the basic PID parameters also need to be optimized, which means that the length of each individual is 66.
The objective function is set as the product of the actual travel distance and the cumulative swing angle.
The steps are as follows:
Step 1
Establish the overhead crane control system.
Step 2
Set the individual length to 66, where the first and the second mean Kp and Kd, the left mean values of fuzzy rules. The population number to 30, and the number of iterations to 1000 to initialize the population.
Step 3
Analyze individual values, generate FIS files, read them into the base workspace, start Simulink, read the output of the simulation, and calculate individual fitness.
Step 4
Set i = i + 1, update individual values according to SLSO.
Step 5
If the obtained parameters meet the termination criteria or i = I_itermax, stop the algorithm and output the result. Otherwise, return to Step 3.
Step 6
Save the best individual as FIS files.
where the FIS file is a file type, which is used to save fuzzy rules and values.

5. Simulation Experiment

Generally speaking, in fuzzy PID, a set of fuzzy rules contains dozens of intervals.
To verify the validity of the proposed method, fuzzy PID control based on SLSO, fuzzy PID control without adjustment, adaptive PID based on the DE algorithm (hereinafter referred to as PID-DE), and the traditional PID control method are simulated under different conditions. The conditions are shown in Table 6.
The parameters of the overhead crane are set as M T = 22 kg, l = 1 m, g = 9.81 m/s2. The parameters of traditional PID are set to (60, 0, 60), and the parameters of PID-DE refer to the relevant paper [34]. In addition, the relevant parameters of other methods are listed below.
The values of fuzzy PID are based on SLSO and which, without adjustment, are shown in Table 7, Table 8, Table 9 and Table 10. In addition, the parameters of fuzzy PID based on SLSO are optimized and set to (31.7, 0, 44.5). The parameters of fuzzy PID without optimization are set to (50, 0, 50) because the up limit is 100 and the low limit is 0 in the process of optimizing the PID parameters using the SLSO algorithm.
The clear values of fuzzy PID rules are shown in Table 7, Table 8 and Table 9. In addition, the values of fuzzy PID without optimization are shown in Table 10, where parameters are the average points of the interval. Because the values of fuzzy PID without optimization are set by average, we just show the values of Kp; the values of Ki and Kd are the same as Kp.
Introducing the parameters obtained by the SLSO algorithm, the comparative simulation experiment is implemented, and the simulation results are shown below.
From Figure 9, Figure 10, Figure 11, Figure 12, Figure 13 and Figure 14, we can see that, compared to PID without optimized parameters, fuzzy PID without targeted configuration of fuzzy rules has advantages over ordinary PID in swing-angle control, but its anti-swing performance is worse than the PID-DE. In terms of distance control, its oscillation amplitude is larger than that of ordinary PID. This can prove that fuzzy control lacks usability without parameter optimization.
However, in the fuzzy PID, where only basic rules are specified and specific parameters are optimized by the algorithm, its distance control completely exceeds the PID-DE. Most intuitively, the distance of the fuzzy PID almost does not exceed the maximum distance, which is very important in practical applications, meaning that collisions will not occur.
At the same time, the swing angle of the fuzzy PID is also well controlled, which means that the suspended object can reach the endpoint in a very stable attitude.
We conducted comparative experiments on both distance and counterweight dimensions, and the experimental results showed that in both cases, the fuzzy PID control based on SLSO parameter configuration can achieve a good anti-swing effect.

6. Conclusions

In this paper, an SLSO-based fuzzy PID controller is designed to suppress the swing of load during the operation of an overhead crane. To configure the parameter effectively, a modified lion swarm algorithm, which is based on the stray strategy, verifies the effectiveness of the improvement on several functions. By implementing simulation experiments and compared to other adaptive PID methods, the proposed method can dampen the load angle amplitude and residual swing. More precisely, in distance control, the percentages of invalid distance for the four methods of fuzzy PID-SLSO, fuzzy PID-non-optimization, PID-DE, and PID are 3.31%, 35.83%, 10.85%, and 37.03%, respectively. In addition, in the swing control, the swing angle of PID is set to 1, and the swing amplitudes of the four methods are 52.87%, 79.63%, 66.37%, and 100%, respectively. The numerical results show that the fuzzy PID-SLSO algorithm proposed in this paper has an excellent anti-swing control effect in an overhead crane system. This proposed method can also be applied to other under-actuated control systems, such as inverted pendulum systems, pendulum robots, and autonomous surface vehicles.

Author Contributions

Conceptualization, J.F. and Z.S.; methodology, Z.S.; software, D.X.; validation, J.L. and J.F.; formal analysis, Z.S.; investigation, J.F. and J.L.; resources, J.L.; data curation, D.X.; writing—original draft preparation, J.F.; writing—review and editing, Z.S.; visualization, D.X. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by the National Natural Science Foundation of China (grant nos. 61972208, 62272239, and 62022044) and the National Natural Science Foundation of Jiangsu Province (grant nos. BK20201043).

Data Availability Statement

The data used to support the findings of this study are available from the corresponding author upon request. Some models and codes used during the study are proprietary or confidential in nature.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Kuo, K.Y.; Linb, J. Fuzzy logic control for flexible link robot arm by singular perturbation approach. Appl. Soft Comput. 2003, 2, 24–38. [Google Scholar] [CrossRef]
  2. Lu, Y. Adaptive-Fuzzy Control Compensation Design for Direct Adaptive Fuzzy Control. IEEE Trans. Fuzzy Syst. 2018, 26, 3222–3231. [Google Scholar] [CrossRef]
  3. Ma, M.; Wang, T.; Qiu, J.; Karimi, H.R. Adaptive Fuzzy Decentralized Tracking Control for Large-Scale Interconnected Nonlinear Networked Control Systems. IEEE Trans. Fuzzy Syst. 2021, 29, 3186–3191. [Google Scholar] [CrossRef]
  4. Chiou, Y.C.; Lan, L.W. Genetic fuzzy logic controller: An iterative evolution algorithm with new encoding method. Fuzzy Sets Syst. 2005, 152, 617–635. [Google Scholar] [CrossRef]
  5. Jiang, H.; An, T.; Ma, B.; Li, Y.; Dong, B. Value Iteration-based Decentralized Fuzzy Optimal Control of Modular Reconfigurable Robots via Adaptive Dynamic Programming. In Proceedings of the 2022 5th International Conference on Robotics, Control and Automation Engineering (RCAE), Changchun, China, 28–30 October 2022; pp. 186–190. [Google Scholar]
  6. Sabir, M.M.; Ali, T. Optimal PID controller design through swarm intelligence algorithms for sun tracking system. Appl. Math. Comput. 2016, 274, 690–699. [Google Scholar] [CrossRef]
  7. Ismayil, C.; Kumar, R.S.; Sindhu, T.K. Optimal fractional order PID controller for automatic generation control of two—Area power systems. Int. Trans. Electr. Energy Syst. 2016, 25, 3329–3348. [Google Scholar] [CrossRef]
  8. Zamani, A.A.; Tavakoli, S.; Etedali, S. Fractional order PID control design for semi-active control of smart base-isolated structures: A multi-objective cuckoo search approach. Isa Trans. 2017, 67, 222. [Google Scholar] [CrossRef]
  9. Garrido, J.; VãZquez, F.; Morilla, F. Multivariable PID control by decoupling. Int. J. Syst. Sci. 2016, 47, 1054–1072. [Google Scholar] [CrossRef]
  10. Xie, M.; Li, X.; Wang, Y.; Liu, Y.; Sun, D. Saturated PID Control for the Optical Manipulation of Biological Cells. IEEE Trans. Control Syst. Technol. 2017, 26, 1909–1916. [Google Scholar] [CrossRef]
  11. Gao, P.; Wang, Z.; Zhang, Y.; Li, M. Prediction System for Overhead Cranes Based on Digital Twin Technology. Appl. Sci. 2023, 13, 4696. [Google Scholar] [CrossRef]
  12. Lisperguier, N.; López, Á.; Vielma, J.C. Seismic Performance Assessment of a Moment-Resisting Frame Steel Warehouse Provided with Overhead Crane. Materials 2023, 16, 2815. [Google Scholar] [CrossRef] [PubMed]
  13. Ungureanu, M.; Medan, N.; Ungureanu, N.S.; Pop, N.; Nadolny, K. Tribological Aspects Concerning the Study of Overhead Crane Brakes. Materials 2022, 15, 6549. [Google Scholar] [CrossRef] [PubMed]
  14. Mustapää, T.; Tunkkari, H.; Taponen, J.; Immonen, L.; Heeren, W.; Baer, O.; Brown, C.; Viitala, R. Secure Exchange of Digital Metrological Data in a Smart Overhead Crane. Sensors 2022, 22, 1548. [Google Scholar] [CrossRef] [PubMed]
  15. Shi, Q.; Lam, H.K.; Xuan, C.; Chen, M. Adaptive Neuro-Fuzzy PID Controller based on Twin Delayed Deep Deterministic Policy Gradient Algorithm. Neurocomputing 2020, 402, 183–194. [Google Scholar] [CrossRef]
  16. Wu, W.; Gong, G.; Chen, Y.; Zhou, X. Performance Analysis of Electro-Hydraulic Thrust System of TBM Based on Fuzzy PID Controller. Energies 2022, 15, 959. [Google Scholar] [CrossRef]
  17. Sun, L.; Ma, J.; Yang, B. Fuzzy PID Design of Vehicle Attitude Control Systems. In Proceedings of the 2020 Chinese Control and Decision Conference (CCDC), Hefei, China, 22–24 August 2020; pp. 1826–1830. [Google Scholar]
  18. Sun, Z.; Ling, Y.; Sun, Z.; Bi, Y.; Tan, S.; Ding, L. Designing and Application of Fuzzy PID Control for Overhead Crane Systems. In Proceedings of the 2019 2nd International Conference on Information Systems and Computer Aided Education (ICISCAE), Dalian, China, 28–30 September 2019; pp. 411–414. [Google Scholar]
  19. Yazdani, M.; Jolai, F. Lion Optimization Algorithm (LOA): A Nature-Inspired Metaheuristic Algorithm. J. Comput. Des. Eng. 2016, 3, 24–36. [Google Scholar] [CrossRef]
  20. Almezeini, N.; Hafez, A. Task Scheduling in Cloud Computing using Lion Optimization Algorithm. Int. J. Adv. Comput. Sci. Appl. 2017, 8, 77–83. [Google Scholar] [CrossRef]
  21. Zhang, D.Q.; Jiang, M.Y. Parallel discrete lion swarm optimization algorithm for solving traveling salesman problem. J. Syst. Eng. Electron. 2020, 31, 751–760. [Google Scholar]
  22. Qu, S.; Dou, Y.; Wang, Y.; Sun, R.; Liu, J.; Yang, W. Path Planning of Electric Power Inspection Robot Based on Improved Lion Swarm Algorithm. In Proceedings of the 2021 IEEE 5th Conference on Energy Internet and Energy System Integration (EI2), Taiyuan, China, 22–24 October 2021; pp. 3335–3339. [Google Scholar]
  23. Ji, F.; Jiang, M. Tabu Annealing Lion Swarm Optimization Algorithm. In Proceedings of the 2021 International Conference on Computer Engineering and Artificial Intelligence (ICCEAI), Shanghai, China, 27–29 August 2021; pp. 422–426. [Google Scholar]
  24. Wang, Z.; Wang, Q.; He, D.; Liu, Q.; Zhu, X.; Guo, J. An Improved Particle Swarm Optimization Algorithm Based on Fuzzy PID Control. In Proceedings of the 2017 4th International Conference on Information Science and Control Engineering (ICISCE), Changsha, China, 21–23 July 2017; pp. 835–839. [Google Scholar]
  25. Fu, J.; Wang, N.; Zhao, J.H.; Zang, S.C. A Membrane Computing Optimization Algorithm with Multi-Subsystem for Parameter Estimation of Heavy Oil Thermal Cracking Model. Int. J. Intell. Robot. Appl. 2022, 1, 139–151. [Google Scholar] [CrossRef]
  26. Wang, N.; Wang, D.X.; Xing, Y.Z.; Shao, L.M.; Afzal, S. Application of co-evolution RNA genetic algorithm for obtaining optimal parameters of SOFC model. Renew. Energy 2020, 150, 221–233. [Google Scholar]
  27. Fu, J.; Zhao, J.H.; Yu, L.D. Self-adaptive membrane computing algorithm and its application in ABS system. Con. Eng. China 2019, 26, 155–161. [Google Scholar]
  28. Zhu, X.H.; Wang, N. Cuckoo search algorithm with membrane communication mechanism for modeling overhead crane systems using RBF neural networks. Appl. Soft. Comput. 2017, 56, 458–471. [Google Scholar] [CrossRef]
  29. Debbah, A.; Kherfane, H.; Kelaiaia, R. Gas Turbine Aerodynamics Improvement Via a Design of Intelligent Fractional Control. Stroj. Časopis J. Mech. Eng. 2021, 71, 85–100. [Google Scholar]
  30. Liu, S.; Yang, Y.; Zhou, Y. A swarm intelligence algorithm-lion swarm optimization. Pattern Recognit. Artif. Intell. 2018, 31, 431–441. [Google Scholar]
  31. Wu, D.H.; Kong, F.; Ji, Z.C. Convergence Analysis of Chicken Swarm Optimization Algorithm. J. Cent. South Univ. 2017, 48, 2105–2112. [Google Scholar] [CrossRef]
  32. Solis, F.J.; West, J.B. Minimization by Random Search Techniques. Math. Oper. Res. 1981, 6, 19–30. [Google Scholar] [CrossRef]
  33. Zhang, W.X.; Liang, Y. Mathematical Foundation of Genetic Algorithm; Xi’an Jiaotong University Press: Xi’an, China, 2003. [Google Scholar]
  34. Sun, Z.; Wang, N.; Bi, Y.; Zhao, J. A DE based PID controller for two dimensional overhead crane. In Proceedings of the 2015 34th Chinese Control Conference (CCC), Hangzhou, China, 28–30 July 2015; pp. 2546–2550. [Google Scholar]
Figure 1. The structure diagram of an overhead crane.
Figure 1. The structure diagram of an overhead crane.
Mathematics 11 02170 g001
Figure 2. Schwefel.
Figure 2. Schwefel.
Mathematics 11 02170 g002
Figure 3. Styblinski-Tang.
Figure 3. Styblinski-Tang.
Mathematics 11 02170 g003
Figure 4. Beale.
Figure 4. Beale.
Mathematics 11 02170 g004
Figure 5. Eason.
Figure 5. Eason.
Mathematics 11 02170 g005
Figure 6. Eggholder.
Figure 6. Eggholder.
Mathematics 11 02170 g006
Figure 7. Holder-table.
Figure 7. Holder-table.
Mathematics 11 02170 g007
Figure 8. The diagram of fuzzy PID.
Figure 8. The diagram of fuzzy PID.
Mathematics 11 02170 g008
Figure 9. The results of condition 1.
Figure 9. The results of condition 1.
Mathematics 11 02170 g009
Figure 10. The results of condition 2.
Figure 10. The results of condition 2.
Mathematics 11 02170 g010
Figure 11. The results of condition 3.
Figure 11. The results of condition 3.
Mathematics 11 02170 g011
Figure 12. The results of condition 4.
Figure 12. The results of condition 4.
Mathematics 11 02170 g012
Figure 13. The results of condition 5.
Figure 13. The results of condition 5.
Mathematics 11 02170 g013
Figure 14. The results of condition 6.
Figure 14. The results of condition 6.
Mathematics 11 02170 g014
Table 1. The nomenclature list.
Table 1. The nomenclature list.
Symbols/AbbreviationsMeaning
x i k the i-th individual in the k-th generation population
p i k the historical best position of the i-th individual from the 1st to the k-th generation
g k the best position of the k-th generation population
p c k the individual randomly selected from the k-th generation lioness group
p m k the individual randomly selected from the k-th generation lion group
q , γ random value, q ~ N ( 0 , 1 ) , γ ~ U ( 0 , 1 )
α f , α c disturbance factor
f k [ i ] the value of the stray individual at the i-th dimension in the k-th generation
Table 2. Comparative results of benchmark functions.
Table 2. Comparative results of benchmark functions.
Function
Name
SLSOStandard LSOGAPSOMin
Value
Avg_ResultStdAvg_ResultStdAvg_ResultStdAvg_ResultStd
Schwefel3.55 × 10³5.05 × 104 3.66 × 10³6.36 × 103.64 × 10³5.753.61 × 10³1.44 × 100
Styblinski
Tang
−2.69 × 106.01 × 10−4−1.48 × 104.21−8.582.92−2.68 × 101.02 × 10−10−2.903534
Beale1.01 × 10−51.53 × 10−52.23 × 10−51.58 × 10−1 2.69 × 10−34.37 × 10−35.69 × 10−52.81 × 10−110
Easom−9.99 × 10−1 3.15 × 10−5−9.84 × 10−1 8.89 × 10−2−1.07 × 10−27.57 × 10−2−2.00 × 10−21.41 × 10−1 −1
Eggholder−9.42 × 1022.66 × 10−8.95 × 1026.58 × 10−8.66 × 1021.12 × 102−7.12 × 1029.21 × 10−959.6407
Holder_table−1.85 × 104.74 × 10−1 −1.82 × 101.13−1.74 × 101.52−1.83 × 104.15 × 10−1 −19.2085
Table 3. Fuzzy RULES of Kp.
Table 3. Fuzzy RULES of Kp.
e(t)()
Δkp
ec(t)
NBNMNSZPSPMPB
NBPBPBPBPBPMPSZ
NMPMPMPSPSPSZZ
NSPMPSZZZNSNM
ZPSPSZZZNMNB
PSNMNSZZZPSPM
PMZZPSPMPMPBPB
PBZPSPBPBPBPBPB
Table 4. Fuzzy RULES of Ki.
Table 4. Fuzzy RULES of Ki.
e(t)()
Δki
ec(t)
NBNMNSZPSPMPB
NBPBPBPBPBPMPSZ
NMPBPBPBPMPSZZ
NSPBPMPSPSZNSNM
ZNMNSZZZNSNM
PSNMNSZPSPSPMPB
PMZZPSPMPMPBPB
PBZPSPBPBPBPBPB
Table 5. Fuzzy RULES of Kd.
Table 5. Fuzzy RULES of Kd.
e(t)()
Δkd
ec(t)
NBNMNSZPSPMPB
NBPBPMPSPBNBNBNB
NMPMPSZPSNBNSZ
NSPBPMZPSPSPMPB
ZPBZPSPSPSPMPB
PSPBPMPSZPSPMPB
PMZNSNMNSZPSPM
PBNBNBNBNSPSPMPB
Table 6. Specific experimental conditions.
Table 6. Specific experimental conditions.
Conditions123456
m l / kg 777121212
x d 6122061220
Table 7. Values of fuzzy PID rules Kp based on SLSO.
Table 7. Values of fuzzy PID rules Kp based on SLSO.
NameNBNMNSZ
e(t)[−5.829,−4.457][−5.829,−4.457,−4.114,−2.742][−4.114,−2.742,−2.4,−1.658][−2.4,−1.658,1.658,2.4]
ec(t)[−5.143,−4.286][−5.143,−4.286,−3.429,−2.571][−3.429,−2.571,−1.714,−0.857][−1.714,−0.857,0.857,1.714]
Δ k p [−8.571,−7.143][−8.571,−7.143,−5.714,−4.286][−5.714,−4.286,−2.857,−1.429][−2.857,−1.429,1.429,2.857]
NamePSPMPB
e(t)[1.658,2.4,2.743,4.114][2.742,4.114,4.457,5.829][4.457,5.829]
ec(t)[0.857,1.714,2.571,3.429][2.571,3.429,4.286,5.143][4.286,5.143]
Δ k p ,[1.429,2.857,4.286,5.714][4.286,5.714,7.143,8.571][7.143,8.571]
Table 8. Values of fuzzy PID rules Ki based on SLSO.
Table 8. Values of fuzzy PID rules Ki based on SLSO.
NameNBNMNSZ
e(t)[−5.143,−4.286][−5.143,−4.286,−3.429,−2.571][−3.429,−2.571,−1.714,−0.857][−1.714,−0.857,0.857,1.714]
ec(t)[−5.073,−4.226][−5.073,−4.226,−3.339,−2.54][−3.339,−2.54,−1.614,−0.757][−1.614,−0.757,0.757,1.614]
Δ k i [−9.667,−7.0][−9.667,−7.0,−6.334,−3.666][−6.334,−3.666,−3.0,−0.333][−3.0,−0.333,0.333,3.0]
NamePSPMPB
e(t)[0.857,1.714,2.571,3.429][2.571,3.429,4.286,5.143][4.286,5.143]
ec(t)[0.757,1.614,2.54,3.339][2.54,3.339,4.226,5.073][4.226,5.073]
Δ k i ,[0.333,3.0,3.666,6.334][3.666,6.334,7.0,9.667][7.0,9.667]
Table 9. Values of fuzzy PID rules Kd based on SLSO.
Table 9. Values of fuzzy PID rules Kd based on SLSO.
NameNBNMNSZ
e(t)[−5.8,−4.2][−5.8,−4.2,−3.832,−2.232][−3.832,−2.232,−1.832,−0.232][−1.832,−0.232,0.232,1.832]
ec(t)[−5.76,−3.84][−5.76,−3.84,−3.36,−1.44][−3.36,−1.44,−0.96,0.96][−1.44,−0.96,0.96,1.44]
Δ k d [−9.667,−7.0][−9.667,−7.0,−6.334,−3.666][−6.334,−3.666,−3.0,−0.3333][−3.0,−0.333,0.333,3.0]
NamePSPMPB
e(t)[0.2,1.832,2.232,3.832][2.232,3.832,4.2,5.8][4.2,5.8]
ec(t)[−0.96,0.96,1.44,3.36][1.44,3.36,3.84,5.76][3.84,5.76]
Δ k d ,[0.333,3,3.0,3.666,6.334][3.666,6.334,7.0,9.667][7.0,9.667]
Table 10. Values of fuzzy PID rules without optimization.
Table 10. Values of fuzzy PID rules without optimization.
NameNBNMNSZ
e(t)[−5.25,−4.5][−5.25,−4.5,−3.75,−3][−3.75,−3,−2.25,−1.5][−2.25,−0.75,0.75,2.25]
ec(t)[−5.15,−4.3][−5.15,−4.3,−3.44,−2.58][−3.44,−2.58,−1.72,−0.86][−1.72,−0.86,0.86,1.72]
Δ k p [−8.58,−7.15][−8.58,−7.15,−5.72,−4.28][−5.72,−4.29,−2.86,−1.43][−2.86,−1.43,1.43,2.86]
NamePSPMPB
e(t)[1.5,2.25,3,3.75][3,3.75,4.5,5.25][4.5,5.25]
ec(t)[0.86,1.72,2.58,3.44][2.58,3.44,4.3,5.15][4.3,5.15]
Δ k p ,[1.43,2.86,4.29,5.72][4.29,5.72,7.15,8.58][7.15,8.58]
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Fu, J.; Liu, J.; Xie, D.; Sun, Z. Application of Fuzzy PID Based on Stray Lion Swarm Optimization Algorithm in Overhead Crane System Control. Mathematics 2023, 11, 2170. https://doi.org/10.3390/math11092170

AMA Style

Fu J, Liu J, Xie D, Sun Z. Application of Fuzzy PID Based on Stray Lion Swarm Optimization Algorithm in Overhead Crane System Control. Mathematics. 2023; 11(9):2170. https://doi.org/10.3390/math11092170

Chicago/Turabian Style

Fu, Jie, Jian Liu, Dongkai Xie, and Zhe Sun. 2023. "Application of Fuzzy PID Based on Stray Lion Swarm Optimization Algorithm in Overhead Crane System Control" Mathematics 11, no. 9: 2170. https://doi.org/10.3390/math11092170

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop