# Design of Neutrosophic Self-Tuning PID Controller for AC Permanent Magnet Synchronous Motor Based on Neutrosophic Theory

Authors: Zhongliang Fu; Chunping Liu; Shengyi Ruan; Kun Chen
Journal: Mathematical Problems in Engineering
 (2021)

---

## Abstract

In practical control applications, AC permanent magnet synchronous motors need to work in different response characteristics. In order to meet this demand, a controller which can independently realize the different response characteristics of the motor is designed based on neutrosophic theory and genetic algorithm. According to different response characteristics, neutrosophic membership functions are constructed. Then, combined with the cosine measure theorem and genetic algorithm, the neutrosophic self-tuning PID controller is designed. It can adjust the parameters of the controller according to response requirements. Finally, three kinds of controllers with typical system response characteristics are designed by using Simulink. The effectiveness of the designed controller is verified by simulation results.


---

## Body

## 1. Introduction

Compared with the traditional electric excitation synchronous motor, permanent magnet synchronous motor (PMSM) has the advantages of less loss, high efficiency, and low power consumption. It is excited by a permanent magnet. The structure is simple and the cost is low. The collector ring and brush are omitted, and the reliability is improved. The rotor does not need an excitation current. So, the excitation loss no longer exists. And the efficiency and power factor of the motor are improved. In recent years, the research and application of PMSM have been very popular [1]. It is meaningful to study the method to make PMSM work effectively on the demand response characteristics.In fact, some parameters of the system are not constants but will change with time, such as manufacturing tolerances, aging of major components, and environmental changes. This will affect the control performance to a certain extent. In order to improve the control performance of the PMSM, Sun et al. [2] proposed an improved MPCC scheme for PMSM drives to overcome the high torque and current ripples. At the same time, the steady-state and dynamic performance of PMSM drives are further improved. In [3], a new method to extract accurate rotor position for the speed sensorless control of surface-mounted permanent magnet synchronous motors (SPMSMs) based on the back electromotive force (EMF) information is presented. In [4], a novel method for the sensorless control of interior permanent magnet synchronous motors is proposed. An iterative search strategy based on dichotomy is proposed to provide a finite number of rotor position angles with good accuracy. Hussein [5] proposed a variety of uncertainty system modeling methods and robust stability analysis methods for interval linear time invariant systems. Hote et al. [6] introduced the robust stability analysis of the PWM push-pull DC-DC converter. Then, Precup and Preitl [7] proposed the integral servo system with proportional integral (PI) and proportional integral derivative (PID) controllers to ensure stability and robustness of the controller. Elkaranshawy et al. [8] designed the PID robust controller of flexible arm robot by using the Kharitonov theorem.In order to further solve the problems of uncertainty and inconsistent information, the concept of neutrosophic set was first proposed by Smarandache [9]. Then, the neutrosophic theory developed rapidly. Wang et al. [10] proposed the single valued neutrosophic set. Ye [11] further proposed the concept of a simplified neutrosophic set, including the concepts of single valued neutrosophic set and interval neutrosophic set. Subsequently, researchers have solved many practical engineering problems based on the theory of neutrosophic set, such as fault diagnosis [12, 13], Multiattribute group decision making [14, 15], linear and nonlinear programming [16], linear equation of traffic flow [17], and roughness coefficient of rock discontinuity [18].PID algorithm is the most widely used in the field of engineering control. But the tuning of PID parameters is a tedious process. At present, the PID tuning methods studied by scholars include genetic algorithm [19], particle swarm optimization [20], and fuzzy control algorithm [21]. The tuning of PID parameters based on neutrosophic theory was proposed by Can and Ozguven [22]. However, it uses a traversal search algorithm, and the precision and speed cannot be considered at the same time. Ye [23, 24] proposed a cosine similarity measure. Combined with the genetic algorithm, the Can’s PID tuning method is optimized. Ruan et al. [25] further extended and compared the neutrosophic PID tuning methods with cosine similarity measure, exponential similarity measure, and simulated annealing algorithm.In this paper, the neutrosophic PID tuning control algorithm under different response characteristics is studied. Neutrosophic membership functions are constructed corresponding to different characteristics and the cosine measure theorem and genetic algorithm are used to tune the parameters and get the optimal values.The paper is organized as follows. In Section2, the PMSM model is described. And neutrosophic self-tuning PID controller is designed in Section 3. Simulations are shown in Section 4. Finally, the conclusion of this work is summarized in Section 5.


## 2. PMSM Model Description

### 2.1. Basic Equations of PMSM

PMSM control system is a high-order, nonlinear, multivariable strong coupling system, so its mathematical model contains time-varying parameters, and the magnetic circuit relationship is also complex.The section coordinate diagram of PMSM is shown in Figure1. The a-axis of the stationary coordinate system coincides with the A-phase winding, which is used to analyze the mathematical model of the PMSM.Figure 1
Schematic diagram of PMSM section coordinates.


#### 2.1.1. Voltage Equation [26]

In the coordinate system, the voltage matrix equation of PMSM is as follows:(1)uaubuc=Rs000Rs000Rsiaibic+pφaφbφc,where ua,ub, and uc are the stator phase voltages, ia, ib, and ic are the stator phase currents, φa, φb, and φc are stator flux, Rs is the stator resistance, and p is a differential operator.The voltage equation of AC permanent magnet synchronous motor in the two-phase rotatingd−q coordinate system is derived as follows:(2)Ud=pφd−ωφq+Rsid,(3)Uq=pφq−ωφd+Rsiq.


#### 2.1.2. Flux Linkage Equation [27, 28]

The flux linkage equation of PMSM in thed−q coordinate system is as follows:(4)φdφq=Ld00Lqidiq+φr10,where φr is rotor flux linkage and Ld and Lq are as follows:(5)Ld=L1−M1+32L0+L2,(6)Lq=L1−M1+32L0−L2.


#### 2.1.3. Electromagnetic Torque Equation

The power of PMSM is equal to the product of phase voltage and phase current of each phase. It can be expressed as follows:(7)P=uaia+ubib+ucic=32udid+uqiq=32Pdq.After coordinate transformation, the power is changed in form, but its magnitude is 3/2 of the input power in thed−q coordinate system. To further analyze the input power, the voltage equation is introduced into equation (7), and then the electromagnetic torque equation is obtained as follows:(8)Te=32Pnφdiq−φqid=32Pnφfiq−Lq−Ldidiq,where pn is the pole number of the motor and φf is the flux linkage of the permanent magnet. Generally speaking, Ld=Lq is satisfied.


#### 2.1.4. Equation of Motion

The electromagnetic torque of PMSM not only drives the motor load but also overcomes the friction damping and inertia of the permanent magnet rotor. The torque balance formula is as follows:(9)Te=TL+JPnpω+ωPnp+Bω.By integrating equations (2)–(4), (8), and (9), the mathematical model of three-phase AC PMSM can be obtained as follows:(10)pidiqω=−RsLPn0−Pnω−RsL−PnωfL03/2PnφfJ0idiqω+udLuqL−TLJ.


### 2.2. Vector Control Principle of PMSM

Since the mathematical model of PMSM is a nonlinear and strong coupling mathematical model, we need to use the vector control method to decouple the mathematical model. And combined with an appropriate control method, the speed control requirements can be achieved. The control method used in this paper is to makeid=0. More details can be found in [29, 30]. Then, the decoupling mathematical model can be obtained as follows:(11)pidiqω=Pnω0−RsL−PnωfL3/2PnφfJ0iqω+udLuqL−TLJ.


## 2.1. Basic Equations of PMSM

PMSM control system is a high-order, nonlinear, multivariable strong coupling system, so its mathematical model contains time-varying parameters, and the magnetic circuit relationship is also complex.The section coordinate diagram of PMSM is shown in Figure1. The a-axis of the stationary coordinate system coincides with the A-phase winding, which is used to analyze the mathematical model of the PMSM.Figure 1
Schematic diagram of PMSM section coordinates.


### 2.1.1. Voltage Equation [26]

In the coordinate system, the voltage matrix equation of PMSM is as follows:(1)uaubuc=Rs000Rs000Rsiaibic+pφaφbφc,where ua,ub, and uc are the stator phase voltages, ia, ib, and ic are the stator phase currents, φa, φb, and φc are stator flux, Rs is the stator resistance, and p is a differential operator.The voltage equation of AC permanent magnet synchronous motor in the two-phase rotatingd−q coordinate system is derived as follows:(2)Ud=pφd−ωφq+Rsid,(3)Uq=pφq−ωφd+Rsiq.


### 2.1.2. Flux Linkage Equation [27, 28]

The flux linkage equation of PMSM in thed−q coordinate system is as follows:(4)φdφq=Ld00Lqidiq+φr10,where φr is rotor flux linkage and Ld and Lq are as follows:(5)Ld=L1−M1+32L0+L2,(6)Lq=L1−M1+32L0−L2.


### 2.1.3. Electromagnetic Torque Equation

The power of PMSM is equal to the product of phase voltage and phase current of each phase. It can be expressed as follows:(7)P=uaia+ubib+ucic=32udid+uqiq=32Pdq.After coordinate transformation, the power is changed in form, but its magnitude is 3/2 of the input power in thed−q coordinate system. To further analyze the input power, the voltage equation is introduced into equation (7), and then the electromagnetic torque equation is obtained as follows:(8)Te=32Pnφdiq−φqid=32Pnφfiq−Lq−Ldidiq,where pn is the pole number of the motor and φf is the flux linkage of the permanent magnet. Generally speaking, Ld=Lq is satisfied.


### 2.1.4. Equation of Motion

The electromagnetic torque of PMSM not only drives the motor load but also overcomes the friction damping and inertia of the permanent magnet rotor. The torque balance formula is as follows:(9)Te=TL+JPnpω+ωPnp+Bω.By integrating equations (2)–(4), (8), and (9), the mathematical model of three-phase AC PMSM can be obtained as follows:(10)pidiqω=−RsLPn0−Pnω−RsL−PnωfL03/2PnφfJ0idiqω+udLuqL−TLJ.


## 2.1.1. Voltage Equation [26]

In the coordinate system, the voltage matrix equation of PMSM is as follows:(1)uaubuc=Rs000Rs000Rsiaibic+pφaφbφc,where ua,ub, and uc are the stator phase voltages, ia, ib, and ic are the stator phase currents, φa, φb, and φc are stator flux, Rs is the stator resistance, and p is a differential operator.The voltage equation of AC permanent magnet synchronous motor in the two-phase rotatingd−q coordinate system is derived as follows:(2)Ud=pφd−ωφq+Rsid,(3)Uq=pφq−ωφd+Rsiq.


## 2.1.2. Flux Linkage Equation [27, 28]

The flux linkage equation of PMSM in thed−q coordinate system is as follows:(4)φdφq=Ld00Lqidiq+φr10,where φr is rotor flux linkage and Ld and Lq are as follows:(5)Ld=L1−M1+32L0+L2,(6)Lq=L1−M1+32L0−L2.


## 2.1.3. Electromagnetic Torque Equation

The power of PMSM is equal to the product of phase voltage and phase current of each phase. It can be expressed as follows:(7)P=uaia+ubib+ucic=32udid+uqiq=32Pdq.After coordinate transformation, the power is changed in form, but its magnitude is 3/2 of the input power in thed−q coordinate system. To further analyze the input power, the voltage equation is introduced into equation (7), and then the electromagnetic torque equation is obtained as follows:(8)Te=32Pnφdiq−φqid=32Pnφfiq−Lq−Ldidiq,where pn is the pole number of the motor and φf is the flux linkage of the permanent magnet. Generally speaking, Ld=Lq is satisfied.


## 2.1.4. Equation of Motion

The electromagnetic torque of PMSM not only drives the motor load but also overcomes the friction damping and inertia of the permanent magnet rotor. The torque balance formula is as follows:(9)Te=TL+JPnpω+ωPnp+Bω.By integrating equations (2)–(4), (8), and (9), the mathematical model of three-phase AC PMSM can be obtained as follows:(10)pidiqω=−RsLPn0−Pnω−RsL−PnωfL03/2PnφfJ0idiqω+udLuqL−TLJ.


## 2.2. Vector Control Principle of PMSM

Since the mathematical model of PMSM is a nonlinear and strong coupling mathematical model, we need to use the vector control method to decouple the mathematical model. And combined with an appropriate control method, the speed control requirements can be achieved. The control method used in this paper is to makeid=0. More details can be found in [29, 30]. Then, the decoupling mathematical model can be obtained as follows:(11)pidiqω=Pnω0−RsL−PnωfL3/2PnφfJ0iqω+udLuqL−TLJ.


## 3. Design of Neutrosophic Self-Tuning PID Controller

### 3.1. Neutrosophic Theory

The variableX is defined as a universe of discourse. Any single-valued neutrosophic set N in X can be expressed as follows [31]:(12)N=x,TNx,INx,FNx|x∈X,where TNx is a true membership function, INx is an uncertain membership function, and FNx is a false membership function.And eachx satisfies the following conditions:(13)TNx,INx,FNx∈0,1,0≤TNx+INx+FNx≤3.For convenience,x=T,I,F is defined as a single-valued neutrosophic number in X.Definition 1.
(see [32]). If there are two neutrosophic sets N1 and N2 that belong to the universe of discourse X=x1,x2,…,xn, the specific forms are as follows:(14)N1=xi,TN1xi,IN1xi,FN1xi|xi∈X,N2=xi,TN2xi,IN2xi,FN2xi|xi∈X.
Then, the cosine similarity measure betweenN1 and N2 can be defined by(15)CsN1,N2=1n∑i=1ncosπ6TN1xi−TN2xi+IN1xi−IN2xi+FN1xi−FN2xi.
CsN1,N2 has the following properties:(1)
0≤CsN1,N2≤1(2)
IfN1=N2, then CsN1,N2=1(3)
CsN1,N2=CsN2,N1(4)
IfN3 is also a neutrosophicset belonged to X, and satisfies N1⊆N2⊆N3, then CsN1,N3≤CsN1,N2 and CsN1,N3≤CsN2,N3 is established


### 3.2. Genetic Algorithm

The flowchart of the genetic algorithm is shown in Figure2. Initialization includes generation population size, determination of iteration times, coding, selection, crossover, mutation probability, etc. The criterion for judging whether to end is to specify the number of iterations or to specify your own ending criteria, such as the emergence of a more suitable individual. In addition, it is possible to use decimal number operations directly without encoding and decoding. There are many pieces of research on genetic algorithms, which will not be repeated here.Figure 2
The flowchart of the genetic algorithm.


### 3.3. Neutrosophic Self-Tuning PID Control Method

This paper will adopt the PID control algorithm, which is very effective in engineering. In particular, the incremental PID is only related to the last three errors, which greatly improves the stability of the system. Its specific form is as follows [33]:(16)Δuk=Aek−Bek−1+Cek−2,where Δuk is the control signal. A, B, and C are parameters. More details can be found in [33].The PID parameter self-tuning method is designed based on the neutrosophic theory and genetic algorithm. The self-tuning method needs to consider multiple system response characteristics, that is, a multiobjective programming model problem. In order to comprehensively investigate the advantages and disadvantages of a system, we choose rising time, settling time, peak time, overshoot ratio, undershoot ratio, and steady-state error as the transient characteristics of the control system. According to different response characteristics, neutrosophic membership functions are constructed. Finally, the cosine similarity measure method is used to calculate the measurement value between the transient characteristics and the ideal response characteristics.The triangular and trapezoidal membership functions are adopted for neutrosophic processing. The six transient characteristics are taken as a whole feature setS=S1,S2,S3,S4,S5,S6. In the set S, element S1 means the rising time, S2 means the settling time, S3 means the peak time, S4 means the overshoot ratio, S5 means the undershoot ratio, and S6 means the steady-state error.Using the neutrosophic theory, the following form is given:(17)N=S1,T1,I1,F1,S2,T2,I2,F2,S3,T3,I3,F3,S4,T4,I4,F4,S5,T5,I5,F5,S6,T6,I6,F6,and the ideal N∗ is shown as follows:(18)N∗=S1,1,0,0,S2,1,0,0,S3,1,0,0,S4,1,0,0,S5,1,0,0,S6,1,0,0.Then, using cosine similarity measure, we can get the similarity ofN and N∗ as follows:(19)CN,N∗=1n∑i=1ncosπ6TNxi−TN∗xi+INxi−IN∗xi+FNxi−FN∗xi.The rule of PID parameter self-tuning is to minimize1−CN,N∗.The structure diagram of control system is shown in Figure3. The inner loop of the control system is current loop and the outer loop is speed loop.Figure 3
Structure diagram of the control system.Remark 1.
The main feature of this control system is that the neutrosophic self-tuning PID control method can realize the control of PMSM with different response characteristics. What users need to do is to give the response characteristics they want by simply adjusting the membership function. Cosine similarity measure method and genetic algorithm in the control system can find the optimal parameters of PID controller automatically, instead of manual adjustment.


## 3.1. Neutrosophic Theory

The variableX is defined as a universe of discourse. Any single-valued neutrosophic set N in X can be expressed as follows [31]:(12)N=x,TNx,INx,FNx|x∈X,where TNx is a true membership function, INx is an uncertain membership function, and FNx is a false membership function.And eachx satisfies the following conditions:(13)TNx,INx,FNx∈0,1,0≤TNx+INx+FNx≤3.For convenience,x=T,I,F is defined as a single-valued neutrosophic number in X.Definition 1.
(see [32]). If there are two neutrosophic sets N1 and N2 that belong to the universe of discourse X=x1,x2,…,xn, the specific forms are as follows:(14)N1=xi,TN1xi,IN1xi,FN1xi|xi∈X,N2=xi,TN2xi,IN2xi,FN2xi|xi∈X.
Then, the cosine similarity measure betweenN1 and N2 can be defined by(15)CsN1,N2=1n∑i=1ncosπ6TN1xi−TN2xi+IN1xi−IN2xi+FN1xi−FN2xi.
CsN1,N2 has the following properties:(1)
0≤CsN1,N2≤1(2)
IfN1=N2, then CsN1,N2=1(3)
CsN1,N2=CsN2,N1(4)
IfN3 is also a neutrosophicset belonged to X, and satisfies N1⊆N2⊆N3, then CsN1,N3≤CsN1,N2 and CsN1,N3≤CsN2,N3 is established


## 3.2. Genetic Algorithm

The flowchart of the genetic algorithm is shown in Figure2. Initialization includes generation population size, determination of iteration times, coding, selection, crossover, mutation probability, etc. The criterion for judging whether to end is to specify the number of iterations or to specify your own ending criteria, such as the emergence of a more suitable individual. In addition, it is possible to use decimal number operations directly without encoding and decoding. There are many pieces of research on genetic algorithms, which will not be repeated here.Figure 2
The flowchart of the genetic algorithm.


## 3.3. Neutrosophic Self-Tuning PID Control Method

This paper will adopt the PID control algorithm, which is very effective in engineering. In particular, the incremental PID is only related to the last three errors, which greatly improves the stability of the system. Its specific form is as follows [33]:(16)Δuk=Aek−Bek−1+Cek−2,where Δuk is the control signal. A, B, and C are parameters. More details can be found in [33].The PID parameter self-tuning method is designed based on the neutrosophic theory and genetic algorithm. The self-tuning method needs to consider multiple system response characteristics, that is, a multiobjective programming model problem. In order to comprehensively investigate the advantages and disadvantages of a system, we choose rising time, settling time, peak time, overshoot ratio, undershoot ratio, and steady-state error as the transient characteristics of the control system. According to different response characteristics, neutrosophic membership functions are constructed. Finally, the cosine similarity measure method is used to calculate the measurement value between the transient characteristics and the ideal response characteristics.The triangular and trapezoidal membership functions are adopted for neutrosophic processing. The six transient characteristics are taken as a whole feature setS=S1,S2,S3,S4,S5,S6. In the set S, element S1 means the rising time, S2 means the settling time, S3 means the peak time, S4 means the overshoot ratio, S5 means the undershoot ratio, and S6 means the steady-state error.Using the neutrosophic theory, the following form is given:(17)N=S1,T1,I1,F1,S2,T2,I2,F2,S3,T3,I3,F3,S4,T4,I4,F4,S5,T5,I5,F5,S6,T6,I6,F6,and the ideal N∗ is shown as follows:(18)N∗=S1,1,0,0,S2,1,0,0,S3,1,0,0,S4,1,0,0,S5,1,0,0,S6,1,0,0.Then, using cosine similarity measure, we can get the similarity ofN and N∗ as follows:(19)CN,N∗=1n∑i=1ncosπ6TNxi−TN∗xi+INxi−IN∗xi+FNxi−FN∗xi.The rule of PID parameter self-tuning is to minimize1−CN,N∗.The structure diagram of control system is shown in Figure3. The inner loop of the control system is current loop and the outer loop is speed loop.Figure 3
Structure diagram of the control system.Remark 1.
The main feature of this control system is that the neutrosophic self-tuning PID control method can realize the control of PMSM with different response characteristics. What users need to do is to give the response characteristics they want by simply adjusting the membership function. Cosine similarity measure method and genetic algorithm in the control system can find the optimal parameters of PID controller automatically, instead of manual adjustment.


## 4. Simulations

### 4.1. Simulink Module Building

In order to facilitate observation in the Simulink module, the main system is first established as shown in Figure4. The speed, angle, torque, and current of Ld and Lq can be displayed in the scope. Powergui sets the working frequency of the whole system, which is equivalent to the CPU working frequency of 20 microseconds. The sampling time of each sensor is different, which can be represented by different zero-order holders. Then the subsystem as shown in Figure 5 is built to assemble the core module.Figure 4
The diagram of the main control system.Figure 5
The diagram of the control subsystem.This is a double loop system. The inner loop is the current loop and the outer loop is the velocity loop. The sampling speeds of the angle sensor and speed sensor are set to 1 ms. The speed of the current sensor is faster, set to 0.2 ms. In order to be close to reality, the random white noise is added to the speed sensor with the amplitude of ±0.1 rad/s. The data of the speed sensor are processed by a sliding filter. The average value of five sampling data is taken as the measured value of actual speed. The sampling time of each sensor can be adjusted according to the actual situation.The two-phase DC to three-phase AC module is shown in Figure6. The operations in each submodule are slightly different. The angle offset of the first, second, and third modules in Figures 7–9 are 0, −120, and 120, respectively.Figure 6
The diagram of two-phase DC to three-phase AC module.Figure 7
The first module in the two-phase DC to three-phase AC module.Figure 8
The second module in the two-phase DC to three-phase AC module.Figure 9
The third module in the two-phase DC to three-phase AC module.The PMSM used in this simulation is shown in Figure10. The specific parameter settings are shown in Table 1.Figure 10
The PMSM used in simulations.Table 1
Simulation parameters of PMSM.
NameValueStator phase resistance0.0485 ΩFlux linkage0.1194 Wbd-axis inductance0.1 mHq-axis inductance0.1 mHRated speed1000 rpmRated power100 WMoment of inertia0.0027 kgm2Viscous damping0.0624924 FPolar logarithm1Static friction0


### 4.2. Scheme

The simulations are divided into three parts: nonovershooting system, fast response system, and comprehensive response system.


#### 4.2.1. Nonovershooting System

The nonovershooting system expects no overshoot in the response process. The design process of the overshoot ratio neutrosophic membership function should meet the following principles.The parameters of the true, false, and uncertain membership functions should be selected in the range of small overshoot ratio. The smaller the overshoot requirement is, the larger the true value should be. The larger the overshoot requirement is, the larger the false value should be. The system has relatively low requirements for the other five characteristics. So the neutrosophic membership functions are designed as shown in Figure11.Figure 11
Neutrosophic membership function of nonovershooting system.
(a)(b)(c)(d)(e)(f)The desired speed isud=5rad/s. The simulation results are shown in Figure 12 and Table 2. It can be seen from Figure 12 that the speed can converge to 5 rad/s. There is no overshoot in the response process of the rotor speed. In Table 2, the overshoot ratio of the response curve is 0% and the control objective without overshoot is satisfied.Figure 12
Simulation result of the nonovershooting system.Table 2
Simulation results of the nonovershooting system.
NameValueNameValueRising time0.0007786sp153.9968Settling time0.0016si12402.3231Overshoot ratio0%p2194.1634Undershoot ratio0%i24275.5304Peak time0.0027sOptimal value0.0951Stead-state error0.0010Running time509.0194sThe iteration of the group in the simulation is shown in Figure13. The red circle is the best individual in each generation, and the blue star is the average value of each generation. It can be seen from Figure 13 that the overall trend is downward. The red curve is convergent and finally stabilizes at 0.0951.Figure 13
Population iterative of the nonovershooting system.


#### 4.2.2. Fast Response System

The fast response system expects fast response speed. So, the rising time and peak time should be short, and the overshoot and undershoot ratio can be appropriately increased to bring faster speed. The design process of the rising time and peak time neutrosophic membership functions should meet the following principles.The parameters of the true, false, and uncertain membership functions should be selected in the range of short time. The smaller the response time requirement is, the larger the true value should be. The larger the response time requirement is, the larger the false value should be.The system has relatively low requirements for the other four characteristics. So, the neutrosophic membership functions are designed as shown in Figure14.Figure 14
Neutrosophic membership function of the fast response system.
(a)(b)(c)(d)(e)(f)The desired speed isud=5 rad/s. The simulation results are shown in Figure 15 and Table 3. It can be seen from Figure 15 that the speed can also converge to 5 rad/s. In Table 3, the rising time is 0.0006531 s and the peak time is 0.0013 s. The rising time and peak time are shorter than those in the above nonovershooting system. In other words, it has a faster response speed. But obviously, the overshoot ratio of the fast response system is increased to 16.1994%.Figure 15
Simulation result of the fast response system.Table 3
Simulation results of the fast response system.
NameValueNameValueRising time0.0006531 sp1205.5004Settling time0.0020 si12584.7556Overshoot ratio16.1994%p251.5292Undershoot ratio8.19%i28059.1018Peak time0.0013sOptimal value0.1961Stead-state error0.0013Running time707.9218 sThe iterative result of the population in the simulation is shown in Figure16. It can be seen from Figure 16 that the convergence speed of this iteration population is faster. The average and optimal values of each generation are declining. The optimal value is also convergent and finally stabilizes at 0.1961.Figure 16
Population iterative of the fast response system.


#### 4.2.3. Comprehensive Response System

The comprehensive response system expects to achieve a balance between response speed and overshoot indexes. The parameters of the overshoot ratio neutrosophic membership function in Figure14 will be further reduced, thus increasing the limit of overshoot. The other five indexes' neutrosophic membership functions in Figure 14 are basically unchanged. So, the neutrosophic membership functions are designed as shown in Figure 17.Figure 17
Neutrosophic membership function of comprehensive response system.
(a)(b)(c)(d)(e)(f)The desired speed is alsoud=5 rad/s. The simulation results are shown in Figure 18 and Table 4. It can be seen from Figure 18 that the speed can converge to 5 rad/s. The overshoot index is obviously reduced than the fast response system and the response speed is also fast. In Table 4, the rising time is 0.000664 s and the peak time is 0.0013 s. The two time indexes are basically unchanged than the above fast response system. At the same time, the overshoot index is reduced from 16.1994% to 8.7895%.Figure 18
Simulation result of the comprehensive response system.Table 4
Simulation results of the comprehensive response system.
NameValueNameValueRising time0.0006640 sp1104.1265Settling time0.0015 si12693.2360Overshoot ratio8.7895%p2102.5041Undershoot ratio0%i28310.7028Peak time0.0013sOptimal value0.1741Stead-state error0.0017Running time690.9025 sThe population iteration diagram is shown in Figure19. The optimal value is also convergent and finally stabilizes at 0.1741.Figure 19
Population iterative of the comprehensive response system.


## 4.1. Simulink Module Building

In order to facilitate observation in the Simulink module, the main system is first established as shown in Figure4. The speed, angle, torque, and current of Ld and Lq can be displayed in the scope. Powergui sets the working frequency of the whole system, which is equivalent to the CPU working frequency of 20 microseconds. The sampling time of each sensor is different, which can be represented by different zero-order holders. Then the subsystem as shown in Figure 5 is built to assemble the core module.Figure 4
The diagram of the main control system.Figure 5
The diagram of the control subsystem.This is a double loop system. The inner loop is the current loop and the outer loop is the velocity loop. The sampling speeds of the angle sensor and speed sensor are set to 1 ms. The speed of the current sensor is faster, set to 0.2 ms. In order to be close to reality, the random white noise is added to the speed sensor with the amplitude of ±0.1 rad/s. The data of the speed sensor are processed by a sliding filter. The average value of five sampling data is taken as the measured value of actual speed. The sampling time of each sensor can be adjusted according to the actual situation.The two-phase DC to three-phase AC module is shown in Figure6. The operations in each submodule are slightly different. The angle offset of the first, second, and third modules in Figures 7–9 are 0, −120, and 120, respectively.Figure 6
The diagram of two-phase DC to three-phase AC module.Figure 7
The first module in the two-phase DC to three-phase AC module.Figure 8
The second module in the two-phase DC to three-phase AC module.Figure 9
The third module in the two-phase DC to three-phase AC module.The PMSM used in this simulation is shown in Figure10. The specific parameter settings are shown in Table 1.Figure 10
The PMSM used in simulations.Table 1
Simulation parameters of PMSM.
NameValueStator phase resistance0.0485 ΩFlux linkage0.1194 Wbd-axis inductance0.1 mHq-axis inductance0.1 mHRated speed1000 rpmRated power100 WMoment of inertia0.0027 kgm2Viscous damping0.0624924 FPolar logarithm1Static friction0


## 4.2. Scheme

The simulations are divided into three parts: nonovershooting system, fast response system, and comprehensive response system.


### 4.2.1. Nonovershooting System

The nonovershooting system expects no overshoot in the response process. The design process of the overshoot ratio neutrosophic membership function should meet the following principles.The parameters of the true, false, and uncertain membership functions should be selected in the range of small overshoot ratio. The smaller the overshoot requirement is, the larger the true value should be. The larger the overshoot requirement is, the larger the false value should be. The system has relatively low requirements for the other five characteristics. So the neutrosophic membership functions are designed as shown in Figure11.Figure 11
Neutrosophic membership function of nonovershooting system.
(a)(b)(c)(d)(e)(f)The desired speed isud=5rad/s. The simulation results are shown in Figure 12 and Table 2. It can be seen from Figure 12 that the speed can converge to 5 rad/s. There is no overshoot in the response process of the rotor speed. In Table 2, the overshoot ratio of the response curve is 0% and the control objective without overshoot is satisfied.Figure 12
Simulation result of the nonovershooting system.Table 2
Simulation results of the nonovershooting system.
NameValueNameValueRising time0.0007786sp153.9968Settling time0.0016si12402.3231Overshoot ratio0%p2194.1634Undershoot ratio0%i24275.5304Peak time0.0027sOptimal value0.0951Stead-state error0.0010Running time509.0194sThe iteration of the group in the simulation is shown in Figure13. The red circle is the best individual in each generation, and the blue star is the average value of each generation. It can be seen from Figure 13 that the overall trend is downward. The red curve is convergent and finally stabilizes at 0.0951.Figure 13
Population iterative of the nonovershooting system.


### 4.2.2. Fast Response System

The fast response system expects fast response speed. So, the rising time and peak time should be short, and the overshoot and undershoot ratio can be appropriately increased to bring faster speed. The design process of the rising time and peak time neutrosophic membership functions should meet the following principles.The parameters of the true, false, and uncertain membership functions should be selected in the range of short time. The smaller the response time requirement is, the larger the true value should be. The larger the response time requirement is, the larger the false value should be.The system has relatively low requirements for the other four characteristics. So, the neutrosophic membership functions are designed as shown in Figure14.Figure 14
Neutrosophic membership function of the fast response system.
(a)(b)(c)(d)(e)(f)The desired speed isud=5 rad/s. The simulation results are shown in Figure 15 and Table 3. It can be seen from Figure 15 that the speed can also converge to 5 rad/s. In Table 3, the rising time is 0.0006531 s and the peak time is 0.0013 s. The rising time and peak time are shorter than those in the above nonovershooting system. In other words, it has a faster response speed. But obviously, the overshoot ratio of the fast response system is increased to 16.1994%.Figure 15
Simulation result of the fast response system.Table 3
Simulation results of the fast response system.
NameValueNameValueRising time0.0006531 sp1205.5004Settling time0.0020 si12584.7556Overshoot ratio16.1994%p251.5292Undershoot ratio8.19%i28059.1018Peak time0.0013sOptimal value0.1961Stead-state error0.0013Running time707.9218 sThe iterative result of the population in the simulation is shown in Figure16. It can be seen from Figure 16 that the convergence speed of this iteration population is faster. The average and optimal values of each generation are declining. The optimal value is also convergent and finally stabilizes at 0.1961.Figure 16
Population iterative of the fast response system.


### 4.2.3. Comprehensive Response System

The comprehensive response system expects to achieve a balance between response speed and overshoot indexes. The parameters of the overshoot ratio neutrosophic membership function in Figure14 will be further reduced, thus increasing the limit of overshoot. The other five indexes' neutrosophic membership functions in Figure 14 are basically unchanged. So, the neutrosophic membership functions are designed as shown in Figure 17.Figure 17
Neutrosophic membership function of comprehensive response system.
(a)(b)(c)(d)(e)(f)The desired speed is alsoud=5 rad/s. The simulation results are shown in Figure 18 and Table 4. It can be seen from Figure 18 that the speed can converge to 5 rad/s. The overshoot index is obviously reduced than the fast response system and the response speed is also fast. In Table 4, the rising time is 0.000664 s and the peak time is 0.0013 s. The two time indexes are basically unchanged than the above fast response system. At the same time, the overshoot index is reduced from 16.1994% to 8.7895%.Figure 18
Simulation result of the comprehensive response system.Table 4
Simulation results of the comprehensive response system.
NameValueNameValueRising time0.0006640 sp1104.1265Settling time0.0015 si12693.2360Overshoot ratio8.7895%p2102.5041Undershoot ratio0%i28310.7028Peak time0.0013sOptimal value0.1741Stead-state error0.0017Running time690.9025 sThe population iteration diagram is shown in Figure19. The optimal value is also convergent and finally stabilizes at 0.1741.Figure 19
Population iterative of the comprehensive response system.


## 4.2.1. Nonovershooting System

The nonovershooting system expects no overshoot in the response process. The design process of the overshoot ratio neutrosophic membership function should meet the following principles.The parameters of the true, false, and uncertain membership functions should be selected in the range of small overshoot ratio. The smaller the overshoot requirement is, the larger the true value should be. The larger the overshoot requirement is, the larger the false value should be. The system has relatively low requirements for the other five characteristics. So the neutrosophic membership functions are designed as shown in Figure11.Figure 11
Neutrosophic membership function of nonovershooting system.
(a)(b)(c)(d)(e)(f)The desired speed isud=5rad/s. The simulation results are shown in Figure 12 and Table 2. It can be seen from Figure 12 that the speed can converge to 5 rad/s. There is no overshoot in the response process of the rotor speed. In Table 2, the overshoot ratio of the response curve is 0% and the control objective without overshoot is satisfied.Figure 12
Simulation result of the nonovershooting system.Table 2
Simulation results of the nonovershooting system.
NameValueNameValueRising time0.0007786sp153.9968Settling time0.0016si12402.3231Overshoot ratio0%p2194.1634Undershoot ratio0%i24275.5304Peak time0.0027sOptimal value0.0951Stead-state error0.0010Running time509.0194sThe iteration of the group in the simulation is shown in Figure13. The red circle is the best individual in each generation, and the blue star is the average value of each generation. It can be seen from Figure 13 that the overall trend is downward. The red curve is convergent and finally stabilizes at 0.0951.Figure 13
Population iterative of the nonovershooting system.


## 4.2.2. Fast Response System

The fast response system expects fast response speed. So, the rising time and peak time should be short, and the overshoot and undershoot ratio can be appropriately increased to bring faster speed. The design process of the rising time and peak time neutrosophic membership functions should meet the following principles.The parameters of the true, false, and uncertain membership functions should be selected in the range of short time. The smaller the response time requirement is, the larger the true value should be. The larger the response time requirement is, the larger the false value should be.The system has relatively low requirements for the other four characteristics. So, the neutrosophic membership functions are designed as shown in Figure14.Figure 14
Neutrosophic membership function of the fast response system.
(a)(b)(c)(d)(e)(f)The desired speed isud=5 rad/s. The simulation results are shown in Figure 15 and Table 3. It can be seen from Figure 15 that the speed can also converge to 5 rad/s. In Table 3, the rising time is 0.0006531 s and the peak time is 0.0013 s. The rising time and peak time are shorter than those in the above nonovershooting system. In other words, it has a faster response speed. But obviously, the overshoot ratio of the fast response system is increased to 16.1994%.Figure 15
Simulation result of the fast response system.Table 3
Simulation results of the fast response system.
NameValueNameValueRising time0.0006531 sp1205.5004Settling time0.0020 si12584.7556Overshoot ratio16.1994%p251.5292Undershoot ratio8.19%i28059.1018Peak time0.0013sOptimal value0.1961Stead-state error0.0013Running time707.9218 sThe iterative result of the population in the simulation is shown in Figure16. It can be seen from Figure 16 that the convergence speed of this iteration population is faster. The average and optimal values of each generation are declining. The optimal value is also convergent and finally stabilizes at 0.1961.Figure 16
Population iterative of the fast response system.


## 4.2.3. Comprehensive Response System

The comprehensive response system expects to achieve a balance between response speed and overshoot indexes. The parameters of the overshoot ratio neutrosophic membership function in Figure14 will be further reduced, thus increasing the limit of overshoot. The other five indexes' neutrosophic membership functions in Figure 14 are basically unchanged. So, the neutrosophic membership functions are designed as shown in Figure 17.Figure 17
Neutrosophic membership function of comprehensive response system.
(a)(b)(c)(d)(e)(f)The desired speed is alsoud=5 rad/s. The simulation results are shown in Figure 18 and Table 4. It can be seen from Figure 18 that the speed can converge to 5 rad/s. The overshoot index is obviously reduced than the fast response system and the response speed is also fast. In Table 4, the rising time is 0.000664 s and the peak time is 0.0013 s. The two time indexes are basically unchanged than the above fast response system. At the same time, the overshoot index is reduced from 16.1994% to 8.7895%.Figure 18
Simulation result of the comprehensive response system.Table 4
Simulation results of the comprehensive response system.
NameValueNameValueRising time0.0006640 sp1104.1265Settling time0.0015 si12693.2360Overshoot ratio8.7895%p2102.5041Undershoot ratio0%i28310.7028Peak time0.0013sOptimal value0.1741Stead-state error0.0017Running time690.9025 sThe population iteration diagram is shown in Figure19. The optimal value is also convergent and finally stabilizes at 0.1741.Figure 19
Population iterative of the comprehensive response system.


## 5. Conclusion

In this paper, a neutrosophic self-tuning PID controller is designed for PMSM to match different characteristics. The neutrosophic membership functions of the designed controller can be adjusted according to different response requirements. Then the optimal parameters of the PID controller can be found based on the cosine similarity measure and genetic algorithm. Three kinds of AC permanent magnet motor control systems with different characteristics are designed in simulations. The results show that the designed controller can meet the requirements of different characteristics and has good control accuracy.It is noted that the determination of the parameters of the six membership functions depends on certain expert experience. The different choices will directly affect the final PMSM control performance. In practice, it is difficult to choose the optimal membership parameters. In future research, the adaptive adjustment method of membership function parameters will be studied.



---

*Source: 5548184-2021-05-12.xml*