Design and Veriﬁcation of an Interval Type-2 Fuzzy Neural Network Based on Improved Particle Swarm Optimization

: In this study, we proposed an interval type-2 fuzzy neural network (IT2FNN) based on an improved particle swarm optimization (PSO) method for prediction and control applications. The noise-suppressing ability of the proposed IT2FNN was superior to that of the traditional type-1 fuzzy neural network. We proposed dynamic group cooperative particle swarm optimization (DGCPSO) with superior local search ability to overcome the local optimum problem of traditional PSO. The proposed model and related algorithms were veriﬁed through the accuracy of prediction and wall-following control of a mobile robot. Supervised learning was used for prediction, and reinforcement learning was used to achieve wall-following control. The experimental results demonstrated that DGCPSO exhibited superior prediction and wall-following control.


Introduction
Neural networks (NNs) and fuzzy NNs (FNNs) have been widely applied in various applications involving system identification prediction and control. For example, artificial NNs can be used to accurately predict cemented paste backfill strength [1]. Nonlinear autoregressive functions with an external input NN are combined with Simscape electronic systems to achieve high-accuracy identification in DC motors [2]. In autonomous robot control, fuzzy logic exhibits high toughness and noise-suppressing ability [3]. Reinforcement learning has been used in autonomous driving technology to provide convenience and to avoid crashes caused by driver errors. However, this approach has limited accuracy, and adaptive control is absent [4]. Anish and Parhi [5] connected infrared sensors to an adaptive neuro-fuzzy inference system to realize obstacle detection. The steering angle and speed were appropriately adjusted to achieve navigation and collision safety. In intelligent omnidirectional robots, a proportional-integral controller was designed for adjusting the steering angle to a predetermined final desired position to achieve satisfactory navigation and obstacle avoidance [6].
The traditional type-1 fuzzy system (T1FS) comprises two conceptual components: a set of rules and a reasoning mechanism. The rules contain fuzzy rule definitions; the variable provides a degree of membership for each fuzzy rule. The reasoning mechanism involves counting the degree of membership obtained by each rule to obtain the firing strength [7][8][9]. A neural fuzzy system combined with approximation exhibits superior chaotic time-series prediction and is considerably compact when compared with a traditional FNN [10]. However, noise from the environment can 2. Structure of IT2FNN Figure 1 depicts the structure of the IT2FNN, which includes multiple inputs and a single output. The input of the network is denoted by X and output is denoted by Y. In traditional IT2FS, the computational complexity in the defuzzification process is usually very high. Therefore, to increase the effectiveness and reduce complexity of the fuzzy system, this study used the type-reducer method, proposed by Castillo [12], in the defuzzification part. A functional link neural network (FLNN) with a nonlinear combined output was assigned a fuzzy rule in the consequent part [28]. Each fuzzy rule j in the IT2FNN structure is expressed as follows: where i is the input number, x i is the input variables, y j is the local output variables, A ij is the type-2 fuzzy set, ω k j is the link weight of local output, ϕ k is the basis trigonometric function of input variables, M is the basis function number, and rule j is the jth fuzzy rule. The proposed IT2FNN has a five-layer NN. Here, u (l) represents the lth layer output of a node, and each layer of a node operates as follows: Layer 1:This layer is the input layer, and each node is an input node. Only the input signal is passed to the next layer of the network.
Layer 2:This layer is the membership function layer that performs the fuzzification operations. Each node is defined as a type-2 fuzzy set. Each membership function is a Gaussian membership function represented by an uncertain mean [m ij1 , m ij2 ] and a fixed standard deviation (STD) σ ij . The function is expressed as follows: where m ij and σ ij represent the ith input of the j-term mean and standard Gaussian membership function, respectively. The footprint of uncertainty of the Gaussian membership function represents a bounded interval of the upper membership function u (2) ij and lower membership function u (2) ij . The output of each node in the second layer represents an interval u (2) ij , u _ (2) ij . The formula for calculating the membership degree is as follows: (4) and Layer 3:This layer is also called the firing layer, and each node is a rule node; an algebraic product calculation is used to receive the firing strength of each rule node u ij and u where i u (2) ij and i u (2) ij represent the firing strength of the rule corresponding to the upper and lower boundaries of the interval. Layer 4:This layer is called consequent layer and generates type-1 fuzzy sets through a type-reducer operation. In this layer, a numerical output is obtained after defuzzification process. The center of sets type-reducer was used to reduce the computational complexity of the type-reducer process [29]. The formula is as follows: This method simplifies the type-reducer process and only considers the combination of upper and lower boundary firing strength. The combination of firing strength and the corresponding output are expressed as follows: and where M k=1 ω k j ϕ k is obtained from the nonlinear combination of the FLNN input variables x = (x 1 , · · · , x N ), ω k j is the link weight of each node in the FLNN, and ϕ k is the function extension of the input variable. The function expansion consists of the basis functions of trigonometric polynomials.
where M = 3 × N, M represents the number of basis functions, and N represents the number of input variables.

Layer 5:This layer is the output layer, and the type-reducer operation is performed on the previous
layer. An interval type output u (4) , u (4) is obtained. Finally, defuzzification is completed by calculating the average of u (4) and u (4) , and the NN crisp value of output y is obtained.

Proposed Improved Particle Swarm Optimization
This study proposes an improved PSO method, namely DGCPSO. In DGCPSO, the concept of groups and collaborations are joined to achieve the search ability of traditional PSO. PSO has fast convergence and simple implementation but also has low accuracy, excessively fast convergence, and is susceptible to local ptimal solutions in complex problems. Figure 2 depicts the flowchart of DGCPSO. (1) Step 1: Coding The parameters of the IT2FNN are used to encode a particle; each particle is an IT2FNN. The DGCPSO proposed in this study is used to change the parameters of each IT2FNN, containing the uncertain mean [m  (2) Step 2: Sorting All particles are sorted from high to low according to their fitness values, and the group number 0 is the initialization of all particles, as depicted in Figure 4. Set the current group number to 0 and the highest fitness particle as the leader of the new group; update the group number g and the initial value of g to 1, as depicted in Figure 5. Then calculate the similarity threshold of this group, including the average distance and the average fitness. The values are the average distance difference and average fitness value difference between the ungrouped particles (the g is 0) and the group leader (L). Here, A g , B g are the distance threshold and fitness value threshold of the gth group, L g j is the jth dimension of the gth group leader, F(L g ) is the fitness value of the gth group leader, F P i is the fitness value of the ith particle, N is the total number of particles with group number 0 in the current swarm, J is the dimension of the code, and n is the total number of particles. The formulas are expressed as follows. Sequentially calculate the ungrouped particles using the following formulas to determine the distance difference (D i ) and fitness value difference (F i ) between the particle and the leader particle.
When D i < A g and F i < B g , the particles are associated with the group leader, placed in the same particle group, and the group number is updated to g; otherwise, the particle is not classified to the group and no operation is performed ( Figure 6). If ungrouped particles are present, then go back to step 4 and set the highest fitness particle among the ungrouped particles as the leader of the new group. Repeat steps 3 to 4 as depicted in Figure 7. If all the particles have been grouped, then the grouping step ends. CPSO changes the traditional PSO to a P group of one-dimensional vectors, with each group representing one dimension of the original issue. Figure 8 illustrates the flowchart of the CPSO method; instead of a group trying to detect the best P-dimensional vector, which is divided into components to P-group one-dimensional vectors, this study proposes a DGCPSO learning method combining the dynamic group and CPSO to enhance the global search ability to reduce computation time. The original position update formula is as follows.
The cooperative update particle formula is as follows.
Step 7: Whether the Terminal Condition is Reached Repeat steps 2 to 6 until the terminal condition is reached.

Experimental Results
Three experiments were performed to verify the effectiveness of the proposed method: dynamic system identification, chaotic time-series prediction, and mobile robot control.

Dynamic System Identification
The multiple time delays of the nonlinear dynamic system are expressed as follows: where Dynamic system identification was performed to change the parameters of the IT2FNN using the proposed DGCPSO. Table 1 lists the initial parameters of the DGCPSO settings, including the total number of particles (NP), inertia weight ω, acceleration constants C 1 and C 2 , and the generation and number of fuzzy rules. The compared items consist of the fitness value of the best, worst, average, and the standard deviation (SD). Table 2 and Figures 9-11 reveal that the proposed method exhibited superior learning performance to other algorithms [24][25][26][27].

Chaotic Time-Series Prediction
In this example, the Mackey-Glass chaotic time-series α(t) was considered. The following delayed differential equation was followed.
where τ = 17 and x (0) = 1.2. The proposed IT2FNN has four inputs, each corresponding to α(t), and one output represents α(t + ∆t) where ∆t is a prediction of the future time. The first 500 pairs were used as the training data set, and the remaining 500 pairs were used as the test data sets for validating the proposed method. The learning phase involved using the DGCPSO method for parameter learning, and the relevant parameter setting is presented in Table 3. The learning was performed for 200 generations and repeated 30 times. Figures 12-14 and Table 4 present the results for the chaotic time-series. The results indicate that the proposed method achieves superior performance to other methods. The root mean square error (RMSE) results from the chaotic time-series with noise added were 0.106 and 0.009 in the T1FNN and T2FNN, respectively ( Figure 15). Therefore, the performance of the T2FNN was considerably inferior to that of the T1FNN.     [24], (c) PSO [25], (d) QPSO [26], and (e) CPSO [27].

Wall-Following Control of a Mobile Robot
Reinforcement learning was used to achieve wall-following control of a mobile robot. A complex system need not be used to design the control rules of mobile robots. Figure 16 depicts the block diagram of the entire system. Only an appropriate fitness function should be defined to assess the effectiveness of mobile robots in a training setting. The IT2FNN had four input signals (ps 0 , ps 1 , ps 2 , ps 3 ), and two output signals (V L , V R ). The input signal ps i was the infrared sensing distance of the mobile robot, and the output signal was the turning speed of the left and right wheels of the mobile robot. Straight lines, right angles, smooth curves, and U-shaped curves were set as the training setting to verify the response of the mobile robot to various situations in uncertain environments. The size of the training setting was 2.1 (m) × 2 (m), as depicted in Figure 17.
Three termination conditions were set for the mobile robot to ensure wall-following without collision or moving away from walls during the experiment.

1.
The mobile robot moves more distance in the training setting than the distance of a circle around the training setting (only one circle of the training setting), indicating that the mobile robot successfully circled the training setting.

2.
One sensor of the mobile robot measures a distance of less than 1 cm. Figure 18a illustrates a collision between the mobile robot and the wall.

3.
A sensor S 2 to the side of the mobile robot detects a distance greater than 6 cm, indicating that the mobile robot has deviated from the wall, as depicted in Figure 18b.  Each individual represents a solution of an IT2FNN controller, and the controller controls the mobile robot to achieve the wall-following movement in the training setting. After movement, the mobile robot is returned to the initial position. The robot repeats this movement until it reaches a termination condition. The fitness function was used to assess the effectiveness of the mobile robot in the learning process.
The fitness function has three subfitness parameters, namely the total distance the mobile robot moved (SF 1 ), the distance the mobile robot maintained from the wall (SF 2 ), and the degree of parallelism between the mobile robot and the wall (SF 3 ).

1.
Total distance the mobile robot moved: The closer the moving distance R dis of the mobile robot is to the predefined value R stop , the closer the mobile robot is to completing one circle around the training setting.
If R dis > R stop , then the mobile robot successfully circumvents the training setting under all conditions. If R stop = R dis , then the fitness function SF 1 is zero.

2.
The distance the mobile robot maintained from the wall: The fitness function SF 2 is the average value of WD(t) during the moving time. The aim is to maintain a fixed distance between the mobile robot and the wall. In each time step, the distance WD(t) between the side of the mobile robot and the wall is calculated as follows: (25) where d wall is the expected distance of the robot from the wall. A predefined distance d wall was set to 4 cm, as shown in Figure 19a, and T stop is the time step of the mobile robot during the learning process of the wall-following motion. If the mobile robot maintains a fixed expected distance from the wall, then the value of SF 2 is equal to zero. 3.
The degree of parallelism between the mobile robot and the wall: The fitness function SF 3 was used to evaluate the degree of parallelism between the mobile robot and the wall. If the robot was parallel to the wall, then the angle between the sensor S 2 on the right side of the mobile robot and the wall was 90 • . According to the law of cosines, x(t) must be equal to RS 2 , forming an isosceles triangle, as depicted in Figure 19b. The formulas are expressed as follows: where S 1 and S 2 are the distances of the mobile robot sensors, and r is the radius of the mobile robot. The fitness function SF 3 is defined as the average value of the degree of parallelism between the mobile robot and the wall during the moving time. If the mobile robot is parallel to the wall, then the value of SF 3 is equal to zero.
Therefore, a fitness function F (·) was used to evaluate overall control performance. This fitness function was formed by combining the aforementioned subfitness functions (SF 1 , SF 2 , SF 3 ) as follows: This proposed DGCPSO was compared with other evolutionary algorithms. Table 5 lists the initial parameter settings of DGCPSO. To evaluate the algorithm stability, the experiment was performed ten times for each algorithm. The effectiveness of the algorithm in the wall-following mode can be verified with Table 6. The fitness value of the best, worst, average, SD, and number of successful runs (NSR) of each algorithm were compared. The number of times the mobile robot successfully learned to circle the training setting in ten evolutionary simulations was noted. Table 6 presents a comparison of the effectiveness of the fitness values of various algorithms for wall-following control in the training setting. Under the same conditions, DGCPSO exhibited superior wall-following learning. Furthermore, the STD data revealed that the algorithm proposed in this study has high stability ( Table 6). To verify whether different algorithms could successfully adapt the mobile robot to various settings after learning, two test settings were established and the results were compared with the original training setting to verify the effectiveness of the wall-following control of the mobile robot. In the wall-following control, the fitness value of the mobile robot was used to assess the wall-following control of the mobile robot. Table 7 indicates that the control efficiency of the proposed DGCPSO was superior to other algorithms (Figures 20 and 21).  [22], (c) WOA [23], (d) DE [24], (e) PSO [25], and (f) QPSO [26].  [22] 0.862 0.794 0.837 WOA [23] 0.933 0.826 0.872 DE [24] 0.848 0.824 0.853 PSO [25] 0.932 0.844 0.901 QPSO [26] 0.937 0.867 0.921 Figure 21. Moving path of setting 2 of (a) DGCPSO, (b) ABC [22], (c) WOA [23], (d) DE [24], (e) PSO [25], and (f) QPSO [26].

Conclusions
In this study, an IT2FNN based on DGCPSO learning was proposed for identification, prediction, and control applications. The noise suppressing ability of the IT2FNN was superior to the traditional T1FNN. In addition, the proposed DGCPSO has a superior local search ability compared to that of the traditional PSO. Three types of problems, namely two supervised learning identification and prediction problems and one reinforcement learning wall-following control of a mobile robot problem, were used to verify the proposed model and related algorithms. The results revealed that the average fitness value of the proposed DGCPSO was 1.2% higher than that of traditional PSO in identification, prediction, and wall-following control.
The advantages of the proposed IT2FNN based on DGCPSO learning are presented as follows: (1) The proposed DGCPSO uses the dynamic grouping and cooperative particle swarm optimization to improve search capabilities and reach near global optimum; (2) Interval type-2 fuzzy sets are used in IT2FNN to reduce sensor-sensing noise and disturbance; (3) The effectiveness and robustness of the proposed method are improved in identification, prediction, and control problems.
However, the proposed IT2FNN based on DGCPSO learning has limitations. That is, determining the initial parameters of the DGCPSO, such as the number of fuzzy rules, depends on user experience or trial and error. In future research, a self-adapting number of fuzzy rules will be considered in the IT2FNN model. Meanwhile, in order to achieve high-speed operation in real-time applications, the IT2FNN model will be also implemented on a field programmable gate array in a future study.

Conflicts of Interest:
The authors declare no conflict of interest.