# Force Optimization of Elongated Undulating Fin Robot Using Improved PSO-Based CPG

Authors: Van Dong Nguyen; Quang Duy Tran; Quoc Tuan Vu; Van Tu Duong; Huy Hung Nguyen; Thi Thom Hoang; Tan Tien Nguyen
Journal: Computational Intelligence and Neuroscience
 (2022)

---

## Abstract

Biorobotic fishes have a huge impact on the development of underwater devices due to both fast swimming speed and great maneuverability. In this paper, an enhanced CPG model is investigated for locomotion control of an elongated undulating fin robot inspired by black knife fish. The proposed CPG network includes sixteen coupled Hopf oscillators for gait generation to mimic fishlike swimming. Furthermore, an enhanced particle swarm optimization (PSO), called differential particle swarm optimization (D-PSO), is introduced to find a set of optimal parameters of the modified CPG network. The proposed D-PSO-based CPG network is not only able to increase the thrust force in order to make the faster swimming speed but also avoid the local maxima for the enhanced propulsive performance of the undulating fin robot. Additionally, a comparison of D-PSO with the traditional PSO and genetic algorithm (GA) has been performed in tuning the parametric values of the CPG model to prove the superiority of the introduced method. The D-PSO-based optimization technique has been tested on the actual undulating fin robot with sixteen fin-rays. The obtained results show that the average propulsive force of the untested material is risen 5.92%, as compared to the straight CPG model.


---

## Body

## 1. Introduction

Robotic technologies are attracting significant attention from researchers, especially in the fields of outer space and ocean exploration that are difficult for humans to access. For example, in the area of ocean science, autonomous underwater vehicle (AUV) has been strongly developed by using different propulsion mechanisms such as jets, axial propellers, and body or fin [1–3]. Because of low noise, high maneuverability, and rapid speed, bionic fish robots with fin propulsion systems have been widely applied for a large number of underwater devices. Recently, many researchers have investigated to improve the motion performance of biorobotic fishes using fin-ray as a propulsion [4, 5], in which dynamic modeling, locomotion control, and optimization are mainly focused.In motion control, the rhythmic movements of biorobotic fishes are produced by central pattern generator (CPG) networks [6–8]. Biological CPG serves neural networks that can generate patterned neural without any periodical inputs obtained by higher control centers or the feedback signal from sensors [9]. However, using some differential equations with various imprecise parameters, selecting a set of CPG characteristic parameters for improved performance is necessary.To simulate the CPG behavior, many researchers have established some of the different mathematical models to seek the parametric values of CPG to obtain the desired oscillation profiles. These researchers have attempted to adopt the CPG model to generate the rhythmic movements of a species of elongated undulating fin robot, which comprises multiadjacent fin-rays interconnected to a flexible membrane. The authors in reference [10] proposed a CPG integrated with PID to establish a motion controller for a prototype of the fish robot. In paper [11], a CPG network comprising ten Matsuoka oscillators is offered to generate rhythmic signals. In 2012, Zhou et al. introduced a CPG model using two motors to drive two pectoral fins for a manta ray robot [12]. Due to the slow response time, an improved CPG using a genetic algorithm is performed for the thrust generation of the fish robot [13]. In paper [14], a CPG model is adopted to achieve the undulating motion pattern for finding the critical factor, which affects the propulsion. Although the above mathematical models have been successfully applied for establishing a CPG-based motion controller, enhancing the propulsive force of the robotic fish using a CPG network is still a significant challenge. To overcome this problem, optimization algorithms have been performed for parameter selection by some researchers. A Hopf oscillator-based CPG network performed the parameter synthesis subjecting to some learning rules to obtain the desired swimming pattern [15]. Meanwhile, the modified CPG in paper [16] can produce different locomotion patterns of an actual fish by combining Andronov–Hopf oscillators and an artificial neural network (ANN). Recently, heuristic search has been widely applied for tuning the parameters of the CPG network. In paper [17], the genetic algorithm (GA) is used for the rhythmic generation based on CPG models by establishing the weight values of the coordination between oscillators. The authors in references [18, 19] both use particle swarm optimization (PSO) to find the optimal characteristic parameters of the Hopf oscillator-based CPG for improved propulsive performance. Although these metaheuristic algorithms are well resulted in seeking the CPG parameters, they are often trapped in local optima. In this brief, a new differential particle swarm optimization (D-PSO) is investigated to improve optimization problems.A brief of our main contributions can be expressed as follows: At first, a CPG using the chain topology of sixteen coupled Hopf oscillators is offered to generate fishlike rhythmic movements. Following this, the improved D-PSO is exploited to optimize the amplitude values of the CPG network to increase the average propulsive force of the undulating fin robot to make a faster movement. Finally, the obtained result of CPG parameter synthesis using the different optimization methods, including D-PSO, PSO, and GA, is implemented to prove the superiority of the proposed D-PSO algorithm.The rest of this study is categorized into four parts. In Section2, material and research methods, including dynamic modeling and the modified CPG-based locomotion control, are presented. Section 3 presents the optimization method of the CPG model using the variant of PSO. Simulation results and discussions are illustrated in Section 4. Finally, Section 5 gives a conclusion.


## 2. Materials and Methods

### 2.1. Dynamic Modeling of Elongated Undulating Fin Robot

The elongated undulating fin robot is composed of sixteen links and a flexible membrane mounted on the straight axis base of underwater vehicles. Each link includes an RC servo motor and an oblique fin ray that can rotate around a joint, as illustrated in Figure1. The distance between the adjacent link is 32 mm, and the length of the fin-ray is 150 mm. The elongated undulating fin generates a sinusoidal oscillatory whose amplitude envelope is defined by sine wave trajectory to perform forward moving. The sinusoidal oscillatory is propagated along to the fin from the anterior to the posterior and is determined by the following equation:(1)θit=θmmaxisin2πft+ϕi,where θi is the sway angle of the ith fin-ray at the time t; θimax is the maximum sway angle for each fin-ray; f is the oscillatory frequency; ϕi is the phase difference angle between two adjacent fin-rays called the phase lag angle.Figure 1
Actual experiment model.It can be observed from Figure2 that there is a discontinuity in the sinusoidal oscillatory trajectory at the arbitrary time t∗ corresponding to the change of the amplitude envelope (Figure 2(a)) and the oscillatory frequency (Figure 2(b)). In this paper, a modified CPG is introduced to obtain flexible fishlike locomotion in the following section.Figure 2
Output of sinusoidal equation under the change of amplitude and frequency.
(a)(b)


### 2.2. Hopf Oscillator-Based CPG Model

CPGs are known as neural neuron whose oscillator is spiked after each cycle, resulting from mutant inhibition of neurons. To construct the CPG model, various research studies have been employed, including Wilson–Cowan, Kuramoto, Matsuoka, amplitude-controlled phase, Rowat–Selverston, and Hopf. The Hopf oscillator is known as the most promising model for simulating the CPG behavior. The Hopf oscillator can generate the continuous sinusoidal oscillation even when there is a sudden change of both amplitude envelope and oscillatory frequency at the arbitrary timet∗, as shown in Figure 3, demonstrating its superiority as compared to the traditional sinusoidal generator. Furthermore, the Hopf oscillator has a direct relationship between model parameters and output variables in nonlinear oscillators. Therefore, this paper chooses the Hopf oscillator as the best tool for building the CPG network.Figure 3
Output of Hopf oscillator under the change of amplitude and frequency.
(a)(b)The dynamic of the Hopf oscillator is defined as follows:(2)pit⋅=kAi2−pi2t−qi2tpit−2πfqit,qit⋅=kAi2−pi2t−qi2tqit−2πfpit,where p and q present the state variables of the nonlinear oscillator, A and f are known as the amplitude and the intrinsic frequency of the oscillator, and k is the convergence speed. Due to using a harmonic limit cycle, in the steady-state condition, the Hopf oscillator is expressed as follows:(3)p∞t⋅=kAcos2πt+φ0,q∞t⋅=kAsin2πt+φ0,where φ0 denotes the initial phase of the oscillation. From (3), we can clearly see that it is easy to adjust the convergence speed of the Hopf oscillator according to the change of the parameter k. In other words, the Hopf oscillator gives a faster convergence speed to the limit cycle corresponding to an increase of k. Furthermore, due to the limit cycle being structurally stable, the general behavior of the system remains constant with a small perturbation on the oscillator or return to the original orbit in case of larger perturbation.


### 2.3. A Modified CPG

As mentioned above, the structure of the elongated undulating fin robot includes a set of joints in which a CPG unit regulates each joint. In other words, each CPG output corresponding to a state variablep of the Hopf oscillator will define the sway angle around a joint. To generate the rhythmic oscillatory for swimming pattern, it is necessary to link these oscillators together through a proper coupling configuration known as an additive perturbation on the nonlinear oscillatory generator. The perturbed oscillator can be presented as follows:(4)U.i=FUi+Yi=kAi−pi2−qi2pi−2πfqikAi−pi2−qi2qi+2πfpi+yp,iyq,i,where Ui. is the state vector of the ith oscillatory generator; F(Ui) is a nonlinear function; Yi is a perturbation vector.It is noted that the amplitude values of an oscillator are affected by the perturbation signal, and hence each oscillator can be coordinated with another through a perturbation to recognize the change of amplitude and maintain the stable frequency and phase. There are various proposed coupling structures, including ring, chain, star, and full topologies. In the paper, however, the chain structure with adjacent neighbor connections is chosen to obtain the oscillatory coordination of fin-rays. It means a chain of CPGs will use serially connected joints for the gait generation of the elongated undulating robot. Furthermore, the proposed CPG structure uses bidirectional couplings that can be influenced by both anterior and posterior adjacent fin-rays, as shown in Figure4.Figure 4
Structure of the CPG network with bidirectional couplings.It is clear from Figure4 that one oscillator is only affected from the nearest neighbor oscillator though the perturbation, so the perturbed oscillator equation can be rewritten as follows:(5)U.i=kAi−pi2−qi2pi−2πfqikAi−pi2−qi2qi+2πfpi+0βpi−1sinφj+qi−1cosφj−pi+1sinφj+qi+1cosφj.From the above equation, we can see that the modified CPG network can generate the rhythmic movement of the undulating fin robot by adjusting the amplitude valuesAi to obtain the different propulsive forces. In this research, a novel variant of PSO is introduced to optimize the oscillatory amplitudes of the modified CPG model for the purpose of improving the swimming ability of the undulating fin robot.


## 2.1. Dynamic Modeling of Elongated Undulating Fin Robot

The elongated undulating fin robot is composed of sixteen links and a flexible membrane mounted on the straight axis base of underwater vehicles. Each link includes an RC servo motor and an oblique fin ray that can rotate around a joint, as illustrated in Figure1. The distance between the adjacent link is 32 mm, and the length of the fin-ray is 150 mm. The elongated undulating fin generates a sinusoidal oscillatory whose amplitude envelope is defined by sine wave trajectory to perform forward moving. The sinusoidal oscillatory is propagated along to the fin from the anterior to the posterior and is determined by the following equation:(1)θit=θmmaxisin2πft+ϕi,where θi is the sway angle of the ith fin-ray at the time t; θimax is the maximum sway angle for each fin-ray; f is the oscillatory frequency; ϕi is the phase difference angle between two adjacent fin-rays called the phase lag angle.Figure 1
Actual experiment model.It can be observed from Figure2 that there is a discontinuity in the sinusoidal oscillatory trajectory at the arbitrary time t∗ corresponding to the change of the amplitude envelope (Figure 2(a)) and the oscillatory frequency (Figure 2(b)). In this paper, a modified CPG is introduced to obtain flexible fishlike locomotion in the following section.Figure 2
Output of sinusoidal equation under the change of amplitude and frequency.
(a)(b)


## 2.2. Hopf Oscillator-Based CPG Model

CPGs are known as neural neuron whose oscillator is spiked after each cycle, resulting from mutant inhibition of neurons. To construct the CPG model, various research studies have been employed, including Wilson–Cowan, Kuramoto, Matsuoka, amplitude-controlled phase, Rowat–Selverston, and Hopf. The Hopf oscillator is known as the most promising model for simulating the CPG behavior. The Hopf oscillator can generate the continuous sinusoidal oscillation even when there is a sudden change of both amplitude envelope and oscillatory frequency at the arbitrary timet∗, as shown in Figure 3, demonstrating its superiority as compared to the traditional sinusoidal generator. Furthermore, the Hopf oscillator has a direct relationship between model parameters and output variables in nonlinear oscillators. Therefore, this paper chooses the Hopf oscillator as the best tool for building the CPG network.Figure 3
Output of Hopf oscillator under the change of amplitude and frequency.
(a)(b)The dynamic of the Hopf oscillator is defined as follows:(2)pit⋅=kAi2−pi2t−qi2tpit−2πfqit,qit⋅=kAi2−pi2t−qi2tqit−2πfpit,where p and q present the state variables of the nonlinear oscillator, A and f are known as the amplitude and the intrinsic frequency of the oscillator, and k is the convergence speed. Due to using a harmonic limit cycle, in the steady-state condition, the Hopf oscillator is expressed as follows:(3)p∞t⋅=kAcos2πt+φ0,q∞t⋅=kAsin2πt+φ0,where φ0 denotes the initial phase of the oscillation. From (3), we can clearly see that it is easy to adjust the convergence speed of the Hopf oscillator according to the change of the parameter k. In other words, the Hopf oscillator gives a faster convergence speed to the limit cycle corresponding to an increase of k. Furthermore, due to the limit cycle being structurally stable, the general behavior of the system remains constant with a small perturbation on the oscillator or return to the original orbit in case of larger perturbation.


## 2.3. A Modified CPG

As mentioned above, the structure of the elongated undulating fin robot includes a set of joints in which a CPG unit regulates each joint. In other words, each CPG output corresponding to a state variablep of the Hopf oscillator will define the sway angle around a joint. To generate the rhythmic oscillatory for swimming pattern, it is necessary to link these oscillators together through a proper coupling configuration known as an additive perturbation on the nonlinear oscillatory generator. The perturbed oscillator can be presented as follows:(4)U.i=FUi+Yi=kAi−pi2−qi2pi−2πfqikAi−pi2−qi2qi+2πfpi+yp,iyq,i,where Ui. is the state vector of the ith oscillatory generator; F(Ui) is a nonlinear function; Yi is a perturbation vector.It is noted that the amplitude values of an oscillator are affected by the perturbation signal, and hence each oscillator can be coordinated with another through a perturbation to recognize the change of amplitude and maintain the stable frequency and phase. There are various proposed coupling structures, including ring, chain, star, and full topologies. In the paper, however, the chain structure with adjacent neighbor connections is chosen to obtain the oscillatory coordination of fin-rays. It means a chain of CPGs will use serially connected joints for the gait generation of the elongated undulating robot. Furthermore, the proposed CPG structure uses bidirectional couplings that can be influenced by both anterior and posterior adjacent fin-rays, as shown in Figure4.Figure 4
Structure of the CPG network with bidirectional couplings.It is clear from Figure4 that one oscillator is only affected from the nearest neighbor oscillator though the perturbation, so the perturbed oscillator equation can be rewritten as follows:(5)U.i=kAi−pi2−qi2pi−2πfqikAi−pi2−qi2qi+2πfpi+0βpi−1sinφj+qi−1cosφj−pi+1sinφj+qi+1cosφj.From the above equation, we can see that the modified CPG network can generate the rhythmic movement of the undulating fin robot by adjusting the amplitude valuesAi to obtain the different propulsive forces. In this research, a novel variant of PSO is introduced to optimize the oscillatory amplitudes of the modified CPG model for the purpose of improving the swimming ability of the undulating fin robot.


## 3. Developed PSO-Based CPG Optimization

### 3.1. D-PSO

PSO simulates the social behavior of some species such as flocks of birds and schools of fish to exploit the best solution in a nonlinear search space. Each particle updates its next positions by three following values, including the current velocity of that particle, its previous best position (Pbest), and the best fitness value (Gbest). The theory of PSO can be consulted in detail in references [20–22]. However, the main disadvantage of traditional PSO is easy to be fallen into the local extreme domain. To overcome this problem, a new version of PSO, namely D-PSO, is developed in this study to enhance the optimization performance.D-PSO is performed by adding a feature into the velocity equation of PSO. The additive feature is known as the best position of an individual that is randomly taken in the population. The velocity equation of particle after adding one more term can be written as follows:(6)Vi,jite+1=w×Vi,jite+c1r1Pbesti,jite−Xi,jite+c2r2Gbestjite−Xi,jite+c3r3Xh,jite−Xi,jite,(7)Xi,jite+1=Xi,jite+Vi,jite+1.In the above equation,c3 denotes the scaling factor and r3 is selected randomly in the range of [0, 1], whereas h is a varying parameter (from 1 to N) that denotes the expert particle corresponding to the target particle p. The new position updating process of D-PSO is shown in Figure 5.Figure 5
Diagram of the updating process of the particlei at the iteration ite.It is clear from Figure5 that Pbesti,jite is the jth best component of the ith particle and Gjite is the jth component of the best particle in the swarm at the iteration ite. It is noted that ViDiff is the additive feature in the velocity equation whose randomly scaled difference and another particle make them avoid the local optima points.


### 3.2. Application of D-PSO to CPG Model

The performance of the CPG model is susceptible to the value of amplitude, and hence it is necessary to seek the best parametric values for the purpose of improving the propulsive performance. In this section, a novel D-PSO is applied to obtain a set of optimum amplitudes by maximizing the average propulsive force called the objective function. The optimization problem of the CPG model can be posed in the following way:(8)Maximizing:F=1Δt∫0ΔtFtdt,Subject to:Amin≤A≤Amax,Ai<Ai+1,i=1÷16.The developed D-PSO-based CPG optimization problem is performed as follows:(1)
Select some parameters of D-PSO, includingw, c1, c2, and c3(2)
The initial positions and velocities of each individual in the swarm are selected by random values(3)
Initialize oscillation amplitudes of the CPG model within their ranges(4)
Call the Hopf oscillator-based CPG model(5)
The fitness function of each individual is evaluated by(9)FNiite=fXiite,∀i. The particle having the best position is indexed as p, and hence the personal experience and the overall experience are selected as follows:(10)Pbestite=Xiite,andGbestite=Xpite.(6)
Initialize the iteration atite = 1(7)
The velocity and position of each individual are updated by (6) and (7)(8)
The updated fitness function of each particle is re-evaluated:FNiite+1=fXiite+1,∀i and indexing for the particle with the best position as qThe personal experience and the overall experience of the swarm are updated as follows:(11)IfFNiite+1<FNiitethenPbestiite+1=Xiite+1elsePbestiite+1=Pbestiite,IfFNqite+1<FbkthenGbestite+1<Pbestiite+1andselectp=qelseGbestite+1<Gbestite,(9)
Ifite < Maxite, then ite = ite + 1 and goto the step 7 else goto the step 10(10)
The optimal parameters of CPG are obtained asGbestite, and hence the maximum thrust force is defined. A detailed flowchart of the proposed D-PSO-based CPG model considering the above steps is shown in Figure 6.Figure 6
Flowchart of the proposed approach.


## 3.1. D-PSO

PSO simulates the social behavior of some species such as flocks of birds and schools of fish to exploit the best solution in a nonlinear search space. Each particle updates its next positions by three following values, including the current velocity of that particle, its previous best position (Pbest), and the best fitness value (Gbest). The theory of PSO can be consulted in detail in references [20–22]. However, the main disadvantage of traditional PSO is easy to be fallen into the local extreme domain. To overcome this problem, a new version of PSO, namely D-PSO, is developed in this study to enhance the optimization performance.D-PSO is performed by adding a feature into the velocity equation of PSO. The additive feature is known as the best position of an individual that is randomly taken in the population. The velocity equation of particle after adding one more term can be written as follows:(6)Vi,jite+1=w×Vi,jite+c1r1Pbesti,jite−Xi,jite+c2r2Gbestjite−Xi,jite+c3r3Xh,jite−Xi,jite,(7)Xi,jite+1=Xi,jite+Vi,jite+1.In the above equation,c3 denotes the scaling factor and r3 is selected randomly in the range of [0, 1], whereas h is a varying parameter (from 1 to N) that denotes the expert particle corresponding to the target particle p. The new position updating process of D-PSO is shown in Figure 5.Figure 5
Diagram of the updating process of the particlei at the iteration ite.It is clear from Figure5 that Pbesti,jite is the jth best component of the ith particle and Gjite is the jth component of the best particle in the swarm at the iteration ite. It is noted that ViDiff is the additive feature in the velocity equation whose randomly scaled difference and another particle make them avoid the local optima points.


## 3.2. Application of D-PSO to CPG Model

The performance of the CPG model is susceptible to the value of amplitude, and hence it is necessary to seek the best parametric values for the purpose of improving the propulsive performance. In this section, a novel D-PSO is applied to obtain a set of optimum amplitudes by maximizing the average propulsive force called the objective function. The optimization problem of the CPG model can be posed in the following way:(8)Maximizing:F=1Δt∫0ΔtFtdt,Subject to:Amin≤A≤Amax,Ai<Ai+1,i=1÷16.The developed D-PSO-based CPG optimization problem is performed as follows:(1)
Select some parameters of D-PSO, includingw, c1, c2, and c3(2)
The initial positions and velocities of each individual in the swarm are selected by random values(3)
Initialize oscillation amplitudes of the CPG model within their ranges(4)
Call the Hopf oscillator-based CPG model(5)
The fitness function of each individual is evaluated by(9)FNiite=fXiite,∀i. The particle having the best position is indexed as p, and hence the personal experience and the overall experience are selected as follows:(10)Pbestite=Xiite,andGbestite=Xpite.(6)
Initialize the iteration atite = 1(7)
The velocity and position of each individual are updated by (6) and (7)(8)
The updated fitness function of each particle is re-evaluated:FNiite+1=fXiite+1,∀i and indexing for the particle with the best position as qThe personal experience and the overall experience of the swarm are updated as follows:(11)IfFNiite+1<FNiitethenPbestiite+1=Xiite+1elsePbestiite+1=Pbestiite,IfFNqite+1<FbkthenGbestite+1<Pbestiite+1andselectp=qelseGbestite+1<Gbestite,(9)
Ifite < Maxite, then ite = ite + 1 and goto the step 7 else goto the step 10(10)
The optimal parameters of CPG are obtained asGbestite, and hence the maximum thrust force is defined. A detailed flowchart of the proposed D-PSO-based CPG model considering the above steps is shown in Figure 6.Figure 6
Flowchart of the proposed approach.


## 4. Test Results and Discussion

The proposed D-PSO-based CPG optimization method is performed both on the simulation model in MATLAB and during an experiment with the real elongated undulating fin. For the simulation test, a dynamic analysis of the elongated undulating fin robot that was presented in our previous works [23, 24] is adopted to evaluate the thrust force produced by the undulating fin-ray. An actual sixteen fin-ray robot with a size of 775 mm long, 90 m wide, and 290 m deep was designed for the experimental purpose. The oscillatory frequency is chosen at 1 Hz, and the coupling strength is 0.8. The actual testing result of the output signals of CPG is illustrated in Figure 7.Figure 7
The output of the real CPG model.In the term of simulation, each joint of the undulating fin is driven by the CPG unit, whose amplitude values are chosen in the range of [0, 40] degree based on the actual mechanical structure. According to a set of parameters, as given in Table1, the output of CPG model is presented in Figure 8(a) and the thrust curve obtained by the Hopf-based CPG outputs is illustrated in Figure 8(b). In the term of simulation, each joint of the undulating fin is driven by the CPG unit, whose amplitude values are chosen in the range of [2.5, 40] degree based on the actual mechanical structure. According to a set of parameters, as given in Table 1, the output of CPG model is presented in Figure 8(a) and the thrust curve obtained by the Hopf-based CPG outputs is illustrated in Figure 8(b).Table 1
Parameters of CPG network.
f (Hz)φ (°)A1A2A3A4A5A6A7A8A9A10A11A12A13A14A15A161−60°2.55.07.510.012.515.017.520.022.525.027.530.032.535.037.540.0Figure 8
Simulation results with the random values of amplitude. (a). The CPG outputs. (b) The characteristic curve of average thrust.
(a)(b)It can be seen from Figure8(b) that the average push force of sixteen fin-ray system can reach 2.92 N; however, there is an oscillation around a steady state.To reach the best performance of CPG units, a new D-PSO algorithm is governed for the first time to obtain the maximum average propulsive force. However, the D-PSO only achieves the best optimum results once the appropriate parameters are selected in order to increase the converge speed as well as avoid trapping the local optimal point. After ten times repeated running, we obtained the parameters of D-PSO corresponding to the population size of ten particles as follows:(1)
The weight coefficient (w) is in the range of [0.1, 0.9](2)
The constant factors (c1 and c2) are set as 2(3)
The scaling factor (c3) is selected as 0.04(4)
The updating procedure is employed in 100 iterations


### 4.1. Testing the D-PSO Algorithm on the Basic Math Function

To prove the feasibility of the developed D-PSO technique in finding the extremum of functions, some of basic math functions given have been initially tested, as shown in Table2. It is noted that D-PSO is performed using the above selected parameters corresponding the population size of 10 particles.Table 2
The tested five math functions.
Function nameEquationVariable rangeExtreme valueMSEBealeF1=1.5−u1−u1u22+2.25−u1−u1u222+2.625−u1−u1u232[−10, 10]F3,0.5=08.11E − 05LeviF2=sin23πu1+u12−121+sin23πu2+u22−121+sin23πu2[−10, 10]F1,1=00.000928BoothF3=u1+2u2−72+2u1+u2−52[−10, 10]F3,1=00.000389SphereF4=∑i=1nui2[−20, 20]F0,0,...,0=03.37E − 15AckleyF5=20+e−20exp−0.21n∑i=1nui2−exp1n∑i=1ncos2πui[−20, 20]F0,0,...0=02.80E − 12It is clear from Table2 that the proposed D-PSO technique is the ability to optimize the basic five math functions successfully. For the population size of ten particles, the D-PSO achieves the least value of mean square error (MSE) of five math functions as 8.11E − 05, 0.000928, 0.000389, 3.37E − 15, and 2.80E − 12, respectively.


### 4.2. Testing the D-PSO Algorithm on the Modified CPG Network

Table3 gives the average propulsive force of the undulating fin with the dynamic model driven by Hopf oscillator-based CPG unit using both with and without D-PSO optimization.Table 3
Optimization results of CPG model with/without D-PSO algorithm.
ModelA1A2A3A4A5A6A7A8A9A10A11A12A13A14A15A16F(N)Straight CPG2.55.07.510.012.515.017.520.022.525.027.530.032.535.037.540.02.92D-PSO CPG2.3245.27812.69816.50819.00220.22121222425.2492830.20532.1133638403.60Note. v denotes the average propulsive speed, and t is the convergence time.It can be observed from Table3 that the average push force before optimization with the random chosen parameters is 0.52 N, whereas this value is increased to 3.6 N after using the D-PSO-based CPG. According to the constant values of the intrinsic frequency of 1 Hz, the best amplitude parameters of A1–A16 is given in Table 3. Furthermore, the D-PSO-based CPG output and the corresponding average thrust force are shown in Figures 9(a) and 9(b), respectively.Figure 9
Simulation results with D-PSO-based CPG. (a). The outputs of D-PSO-based CPG. (b) The average thrust force.
(a)(b)Table4 shows a comparison of D-PSO with the traditional PSO and GA to prove the superiority of the developed method in this study. The parameter selection of PSO and GA is also performed through running repeatedly many times corresponding to the different population sizes. As a result, the best acceleration coefficients are both selected as 2.0 for PSO, while GA uses the best crossover probability as 0.75 and the best mutation fraction as 0.015.Table 4
Optimization results of CPG model using different metaheuristic algorithms.
ModelA1A2A3A4A5A6A7A8A9A10A11A12A13A14A15A16F(N)GA-CPG1.3625.0488.91111.75412.49517.48422.48923.10823.61724.62526.50033.76532.43835.67938.47339.0493.57PSO CPG15.8187.1251113.98816.74723.97724.21725.234262735.32536.76337.35838.94639.4033.58D-PSO CPG2.3245.27812.69816.50819.00220.22121222425.2492830.20532.1133638403.60From Table4, we can see that the optimum results obtained by the D-PSO are better than those obtained by any other CPG parameter optimizers. The average thrust is 3.60 N in the case of using the proposed D-PSO, while the values of force only reach 3.58 N and 3.57 N by PSO and GA, respectively. Moreover, Figure 10 illustrates the convergence characteristic of average thrust obtained using three different optimization techniques, including D-PSO, PSO, and GA. We can see clearly from Figure 10 that the convergence time of the proposed D-PSO is faster than that of PSO and GA. The D-PSO only takes 2.3 iterations to converge; meanwhile, these values are 3.9 iterations for PSO and 10.5 iterations for GA, respectively. It can be further seen from Figure 10 that there are two steps in the convergence characteristic of PSO and GA, so it is easy for these two optimization methods to get trapping the local maxima. This problem has been solved by using the proposed D-PSO, whose optimization result only shows one step. It means the D-PSO is the ability to achieve the global best position better than the others.Figure 10
The convergence characteristic of some CPG optimization techniques.


## 4.1. Testing the D-PSO Algorithm on the Basic Math Function

To prove the feasibility of the developed D-PSO technique in finding the extremum of functions, some of basic math functions given have been initially tested, as shown in Table2. It is noted that D-PSO is performed using the above selected parameters corresponding the population size of 10 particles.Table 2
The tested five math functions.
Function nameEquationVariable rangeExtreme valueMSEBealeF1=1.5−u1−u1u22+2.25−u1−u1u222+2.625−u1−u1u232[−10, 10]F3,0.5=08.11E − 05LeviF2=sin23πu1+u12−121+sin23πu2+u22−121+sin23πu2[−10, 10]F1,1=00.000928BoothF3=u1+2u2−72+2u1+u2−52[−10, 10]F3,1=00.000389SphereF4=∑i=1nui2[−20, 20]F0,0,...,0=03.37E − 15AckleyF5=20+e−20exp−0.21n∑i=1nui2−exp1n∑i=1ncos2πui[−20, 20]F0,0,...0=02.80E − 12It is clear from Table2 that the proposed D-PSO technique is the ability to optimize the basic five math functions successfully. For the population size of ten particles, the D-PSO achieves the least value of mean square error (MSE) of five math functions as 8.11E − 05, 0.000928, 0.000389, 3.37E − 15, and 2.80E − 12, respectively.


## 4.2. Testing the D-PSO Algorithm on the Modified CPG Network

Table3 gives the average propulsive force of the undulating fin with the dynamic model driven by Hopf oscillator-based CPG unit using both with and without D-PSO optimization.Table 3
Optimization results of CPG model with/without D-PSO algorithm.
ModelA1A2A3A4A5A6A7A8A9A10A11A12A13A14A15A16F(N)Straight CPG2.55.07.510.012.515.017.520.022.525.027.530.032.535.037.540.02.92D-PSO CPG2.3245.27812.69816.50819.00220.22121222425.2492830.20532.1133638403.60Note. v denotes the average propulsive speed, and t is the convergence time.It can be observed from Table3 that the average push force before optimization with the random chosen parameters is 0.52 N, whereas this value is increased to 3.6 N after using the D-PSO-based CPG. According to the constant values of the intrinsic frequency of 1 Hz, the best amplitude parameters of A1–A16 is given in Table 3. Furthermore, the D-PSO-based CPG output and the corresponding average thrust force are shown in Figures 9(a) and 9(b), respectively.Figure 9
Simulation results with D-PSO-based CPG. (a). The outputs of D-PSO-based CPG. (b) The average thrust force.
(a)(b)Table4 shows a comparison of D-PSO with the traditional PSO and GA to prove the superiority of the developed method in this study. The parameter selection of PSO and GA is also performed through running repeatedly many times corresponding to the different population sizes. As a result, the best acceleration coefficients are both selected as 2.0 for PSO, while GA uses the best crossover probability as 0.75 and the best mutation fraction as 0.015.Table 4
Optimization results of CPG model using different metaheuristic algorithms.
ModelA1A2A3A4A5A6A7A8A9A10A11A12A13A14A15A16F(N)GA-CPG1.3625.0488.91111.75412.49517.48422.48923.10823.61724.62526.50033.76532.43835.67938.47339.0493.57PSO CPG15.8187.1251113.98816.74723.97724.21725.234262735.32536.76337.35838.94639.4033.58D-PSO CPG2.3245.27812.69816.50819.00220.22121222425.2492830.20532.1133638403.60From Table4, we can see that the optimum results obtained by the D-PSO are better than those obtained by any other CPG parameter optimizers. The average thrust is 3.60 N in the case of using the proposed D-PSO, while the values of force only reach 3.58 N and 3.57 N by PSO and GA, respectively. Moreover, Figure 10 illustrates the convergence characteristic of average thrust obtained using three different optimization techniques, including D-PSO, PSO, and GA. We can see clearly from Figure 10 that the convergence time of the proposed D-PSO is faster than that of PSO and GA. The D-PSO only takes 2.3 iterations to converge; meanwhile, these values are 3.9 iterations for PSO and 10.5 iterations for GA, respectively. It can be further seen from Figure 10 that there are two steps in the convergence characteristic of PSO and GA, so it is easy for these two optimization methods to get trapping the local maxima. This problem has been solved by using the proposed D-PSO, whose optimization result only shows one step. It means the D-PSO is the ability to achieve the global best position better than the others.Figure 10
The convergence characteristic of some CPG optimization techniques.


## 5. Conclusions

In this paper, the locomotion control and optimization task have been successfully performed on the elongated undulating fin robot inspired by the black knife fish. A bidirectionally coupled sixteen Hopf oscillator-based CPG network is investigated to create rhythmic movement as a perfect paradigm for robotic locomotion. In addition, a novel variant of PSO, namely D-PSO, has been developed to obtain a set of optimum amplitudes of the modified CPG network for the purpose of maximizing the average propulsive force. In brief, the new contributions in our study can be drawn as follows:(1)
In the term of motion control scheme, the CPG based on coupled Hopf oscillators not only generates the desired rhythm for the undulating fin robot but also removes the effect of radial interference on the oscillatory amplitude.(2)
The proposed D-PSO algorithm is the capacity to successfully solving the basic math functions and effectively improving the average thrust of the untested undulating fin fish obtained from the output signals of modified CPG.(3)
The novel D-PSO algorithm gives the fastest propulsive force as compared to PSO and GA. Moreover, the superiority of the proposed method is presented in the ability to avoid the local maxima in order to increase the accuracy of the optimization process.



---

*Source: 2763865-2022-03-09.xml*