Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Embedded intelligent adaptive PI controller for an electromechanical system

161 views

Published on

In this study, an intelligent adaptive controller approach using the interval type-2 fuzzy neural network (IT2FNN) is presented. The proposed controller consists of a lower level proportional - integral (PI) controller, which is the main controller and an upper level IT2FNN which tuning on-line the parameters of a PI controller. The proposed adaptive PI controller based on IT2FNN (API-IT2FNN) is implemented practically using the Arduino DUE kit for controlling the speed of a nonlinear DC motor-generator system. The parameters of the IT2FNN are tuned on-line using back-propagation algorithm. The Lyapunov theorem is used to derive the stability and convergence of the IT2FNN. The obtained experimental results, which are compared with other controllers, demonstrate that the proposed API-IT2FNN is able to improve the system response over a wide range of system uncertainties.

Published in: Technology
  • Be the first to comment

Embedded intelligent adaptive PI controller for an electromechanical system

  1. 1. Research Article Embedded intelligent adaptive PI controller for an electromechanical system Ahmad M. El-Nagar Department of Industrial Electronics and Control Engineering, Faculty of Electronic Engineering, Menofia University, Menuf 32852, Egypt a r t i c l e i n f o Article history: Received 20 January 2016 Received in revised form 2 May 2016 Accepted 7 June 2016 Available online 21 June 2016 This paper was recommended for publica- tion by Prof. A.B. Rad Keywords: Adaptive PI controller Interval type-2 fuzzy neural networks Nonlinear DC motor Lyapunov theorem a b s t r a c t In this study, an intelligent adaptive controller approach using the interval type-2 fuzzy neural network (IT2FNN) is presented. The proposed controller consists of a lower level proportional - integral (PI) controller, which is the main controller and an upper level IT2FNN which tuning on-line the parameters of a PI controller. The proposed adaptive PI controller based on IT2FNN (API-IT2FNN) is implemented practically using the Arduino DUE kit for controlling the speed of a nonlinear DC motor-generator system. The parameters of the IT2FNN are tuned on-line using back-propagation algorithm. The Lyapunov the- orem is used to derive the stability and convergence of the IT2FNN. The obtained experimental results, which are compared with other controllers, demonstrate that the proposed API-IT2FNN is able to improve the system response over a wide range of system uncertainties. & 2016 ISA. Published by Elsevier Ltd. All rights reserved. 1. Introduction The traditional PID controllers are still the most generally uti- lized control structure in a large portion of the modern processes. This is for the most part, since PID controllers have straight forward control structures, moderate cost, and adequacy of linear systems [1–3]. However, it can be difficult to define the suitable PID gains when the plant to be controlled has a high level of complexity, such as, modeling nonlinearities, time delay and structural uncertainties. All these factors could degrade the performance of a PID controller, which becomes unsatisfactory to guarantee the requirements in most of the practical systems [4]. For these reasons, many research papers focused on self-tuning PID controller [5–10], adaptive PID controller [11–14], self-tuning predictive PID controller [15]. In self- tuning and adaptive PID controllers, the parameters of the con- troller were tuned automatically based on the changes of the sys- tem parameters. However, favorable performance can be obtained, this adaptive PID controllers are still limited capabilities with uncertain and nonlinear systems. The conventional PID controller is combined with a fuzzy logic controller (FLC) in order to achieve better system performance over the conventional PID controller such as, the fuzzy PI control [16], the fuzzy PD control [17] and the fuzzy PID control [18–24]. Chen et al. [25] and Martins et al. [26] proposed an adaptive algorithm using the neural networks to tuning the parameters of PID controller. The PID neural network, which the hidden layer neurons work as the PID controller is proposed by Shu and Pi [27]. Lee and Teng [28] proposed a fuzzy neural network to calculate the parameters of the PID controller. Despite the significant improvement of system performance with the fuzzy PID controllers, PID neural network and adaptive PID controller based on fuzzy neural network over their conventional counterparts, it should be noted that they are usually not effective if the system to be con- trolled has structure uncertainties as the ordinary fuzzy systems (type-1 FLSs) and fuzzy neural network (Type-1 fuzzy neural net- work) have limited capabilities to directly handle data uncertainties. The type-2 fuzzy sets (T2-FSs) that introduced by Zadeh in 1975 are able to handle system uncertainties because their degree of membership functions are themselves fuzzy. The concept of a T2- FS is an extension of the concept of an ordinary fuzzy sets (type-1 fuzzy sets; T1-FSs). A T2-FS is characterized by a fuzzy member- ship function, unlike a T1-FS where the membership grade is a crisp number in [0, 1] [29]. The conventional PID controller is combined with an interval type-2 fuzzy logic system (IT2-FLS) in order to achieve better system performance over the conventional PID controller with type-1 FLS [30–44]. Although favorable per- formance can be obtained, these controllers are limited on tuning the controller parameters related to uncertain systems. In this paper, the adaptive PI controller using the IT2FNN is introduced. The proposed controller consists of a lower level PI controller, which is the main controller and an upper level IT2FNN. The IT2FNN provides a mechanism for tuning on-line the gains of a PI controller. The parameters of the IT2FNN are tuned on-line using the back-propagation algorithm. The Lyapunov theorem is Contents lists available at ScienceDirect journal homepage: www.elsevier.com/locate/isatrans ISA Transactions http://dx.doi.org/10.1016/j.isatra.2016.06.006 0019-0578/& 2016 ISA. Published by Elsevier Ltd. All rights reserved. E-mail address: Ahmed_elnagar@menofia.edu.eg ISA Transactions 64 (2016) 314–327
  2. 2. used to derive the stability and convergence of the IT2FNN. The proposed adaptive PI controller is implemented practically using the Ardunio DUE Kit for controlling the DC motor – generator set. The DC motor traditional mathematical model is a second order linear system that ignores the motor Coulomb friction. Unfortu- nately, the dead-zone and Coulomb friction can cause the DC motor system to have nonlinear characteristics. The generator, which combined with the DC motor is used as an electrical load. The obtained results show that the ability of the API-IT2FNN controller to handle the uncertainty in measurement error and the effect of an electrical load. In addition, the proposed controller is not designed for a special DC motor-generator system and consequently, it can be utilized for any DC motor type. Moreover, the proposed controller can be used to control other mechanical or electrical systems. The rest of this paper is organized as follows. The dynamic model of nonlinear DC motor – generator system is presented in Section 2. In Section 3, the adaptive PI controller based on the IT2FNN is included. Section 4, presents the hardware imple- mentation of the proposed API-IT2FNN. The experimental results is presented in Section 5. Finally, Section 6 concludes the paper. 2. Dynamic model of the nonlinear DC motor – generator system The system described in this study combines a DC motor with an electrical load (DC generator). The DC motor – generator system is shown in Fig. 1. The dynamic equations, which represent a DC motor are given as [45]: vam ¼ Ramiam þLam diam dt þeam ð1Þ eam ¼ kemωm ð2Þ Tm ¼ ktmiam ð3Þ Jm dωm dt ¼ Tm ÀBmωm ÀTs ð4Þ where the parameters of the motor are described in Table 1. The dynamic equations representing a DC generator are given as [45]: Jg dωg dt ¼ Ts ÀBgωg ÀTg ð5Þ Tg ¼ ktgiag ð6Þ eag ¼ kegωg ¼ Ragiag þLag diag dt þRLiag ð7Þ Ts ¼ ksðθm ÀθgÞþBsðωm ÀωgÞ ð8Þ with dθm dt ¼ ωm; dθg dt ¼ ωg ð9Þ where the parameters of the generator are described in Table 1. The linear model lacks reliability and accuracy because the Coulomb friction and the dead zone appear as hard nonlinearities when the system rotates in both directions [45]. A general model including Coulomb friction is [46]: Tf ðωÞ ¼ β0sgnðωÞþβ1eÀ β2 ωj j sgnðωÞ ð10Þ where β0; β1; β2 are constants. The function sgn is defined as [46]: sgnðωÞ ¼ 1 ω40 0 ω ¼ 0 À1 ωo0 8 >< >: ð11Þ Eqs. (4) and (5) are modified in order to represent the nonlinear model as follows: Jm dωm dt ¼ Tm ÀBmωm ÀTs ÀTf ðωmÞ ð12Þ Jg dωg dt ¼ Ts ÀBgωg ÀTg ÀTf ðωgÞ ð13Þ 3. Adaptive PI controller based on IT2FNN In this section, the adaptive PI controller using the IT2FNN is presented as shown in Fig. 2. It consists of a lower level classical controller and an upper level intelligent system. The upper level system provides a mechanism to tuning the gains of a classical PI controller, whereas the lower level controller is the main con- troller. In the proposed controller structure, a conventional PI controller is selected for the lower level and the IT2FNN is used in the upper level. Fig. 1. Diagram of the DC motor – generator set. Table 1 Parameters of the DC motor – generator system. Parameter Description Unit iam and iag The motor and generator armature current A Ram and Rag The motor and generator armature coil resistance Ω Lam and Lag The motor and generator armature coil inductance H eam and eag The motor and generator back electromotive-force voltage V ωm and ωg The motor and generator angular speed rad=s Tm and Tg The motor and generator torque Nm kem and keg The motor and generator electrical constant Vs=rad ktm and ktg The motor and generator mechanical constant Jm and Jg The moment of motor and generator inertia kg m2 Bm and Bg The coefficient of viscous motor and generator friction Nm=ðrad=sÞ θm and θg The motor angle and generator angle displacements rad Ts The transmitted shaft torque Nm ks The shaft elasticity Nm=rad Bs The inner damping coefficient of the shaft Nm=ðrad=sÞ RL The load resistance Ω vam The motor armature applied voltage V A.M. El-Nagar / ISA Transactions 64 (2016) 314–327 315
  3. 3. 3.1. PI controller A typical classical PI controller can be expressed as [43]: uðtÞ ¼ kpeðtÞþki Z eðtÞdt eðtÞ ¼ yrðtÞÀymðtÞ ð14Þ where uðtÞ is the control signal at time t. kp and ki are the pro- portional and the integral gains, respectively. The set-point, the measured output and the error signal are denoted as yrðtÞ, ymðtÞ and eðtÞ, respectively. In the classical PI controller, the values of kp and ki in Eq. (14) are adjusted by the operator according to the changes in the process condition. 3.2. Adaptive PI controller The Eq. (14) can be rewritten as: uðtÞ ¼ kpðtÞeðtÞþkiðtÞ Z eðtÞdt ð15Þ where kpðtÞ ¼ k 0 p þρ1ðtÞ kiðtÞ ¼ k 0 i þρ2ðtÞ The parameters k 0 p and k 0 i to be pre-tuned are time invariant constants while the PI controller is working. The parameters ρ1ðtÞ and ρ2ðtÞare time varying and updated in real time. Thus the adaptation of ρ1ðtÞ and ρ2ðtÞ means the adaptation of the kpðtÞ and kiðtÞ. The adaptation parameters ρ1ðtÞ and ρ2ðtÞ are calculated using the IT2FNN. By developing the IT2FNN, these parameters can be updated on-line, according to the changes in the process con- dition and further it will enhance the conventional controller performance over a wide operating range. The structure of upper-level IT2FNN is shown in Fig. 3. It has two inputs (error signal eðkÞ and the change in error signal ΔeðkÞ ¼ eðkÞÀeðkÀ1Þ) and two outputs (ρ1 and ρ2); where k denotes the number of iterations. Fig. 4 shows the interval type-2 Gaussian membership function (MF) with a fixed mean, m, and an uncertain standard deviation in ½σ1; σ2Š. This MF can be described as Eq. (16) [47]: μ~A ðxÞ ¼ exp À 1 2 xÀm σ 2 ! ; σA½ σ; σŠ ð16Þ The IT2-FS is limited by an upper MF (UMF) and a lower MF (LMF), which are denoted μ~A ðxÞ and μ ~A ðx0 Þ, respectively. The regionFig. 2. Adaptive PI controller based on IT2FNN. Fig. 3. Structure of IT2FNN. A.M. El-Nagar / ISA Transactions 64 (2016) 314–327316
  4. 4. between them is called the footprint of uncertainty. The IF-THEN rule for the IT2FNN can be described as: Rin : IF x1 1 is ~M n i1; and x1 2 is ~M n i2; then ρi is w4 in; _w_ 4 in h i ð17Þ where n ¼ 1; 2; ::::; N is the rule number; i ¼ 1; 2, x1 1 ¼ eðkÞ and x1 2 ¼ ΔeðkÞ are the inputs of the IT2FNN; ~M n i1 and ~M n i2 are the IT2-FSs of the antecedent part; ½w4 in; w4 in Šis a centroid set of the output MF, which can be called weighting interval set. The IT2FNN is intro- duced as the following: Input Layer: The input and output for every node s are described as: net1 s ðkÞ ¼ x1 s ; x1 s ¼ f 1 s ðnet1 s ðkÞÞ ¼ net1 s ðkÞ; s ¼ 1; 2 ð18Þ Membership Layer: Each node executes an interval type-2 fuzzy MF, for the jth node. v2 ijðkÞ ¼ ~M j sðx2 s Þ ¼ f 2 ijðnet2 ijðkÞÞ ¼ expðnet2 ijðkÞÞ ¼ v2 ijðkÞ as σsj ¼ σsj _v_ 2 ijðkÞ as σsj ¼ _σ_sj ; j ¼ 1; :::; 6 and i ¼ 1; 2 8 : ð19Þ where net2 ijðkÞ ¼ Àð1=2Þðx2 s ÀmsjÞ2 =ðσsjÞ2 ; f is the number of MFs in each input node. The output of this layer v2 ijðkÞ is also denoted as ½v2 ij ðkÞ; v2 ijðkފ. Rule Layer: For the Nth rule node net3 inðkÞ ¼ ∏ j w3 jnx3 ijðkÞ u3 inðkÞ ¼ f 3 inðnet3 inðkÞÞ ¼ net3 inðkÞ v3 inðkÞ ¼ ∏ n j ¼ 2 w3 jnv2 ij v3 in ðkÞ ¼ ∏ n j ¼ 1 w3 jnv2 ij n ¼ 1; :::; N 8 : ð20Þ where x3 ij represents the j th input to the node of this layer; w3 jn are weights between the membership layer and the rule layer. These weights are set to be unity to simplify the implementation of the IT2FNN for the real-time applications. The output of this layer; v3 in ðkÞ is denoted as ½v3 in ðkÞ; v3 inðkފ. Type-Reduction Layer: This layer is used to perform the TR using our simplified TR method [48]. The process of this layer is introduced as the following: net4 ilðkÞ ¼ PN n ¼ 1 w4 inv3 inðkÞ PN n ¼ 1 v3 inðkÞ ð21Þ v4 ilðkÞ ¼ f 4 ilðnet4 ilðkÞÞ ¼ net4 ilðkÞ ¼ v4 il ¼ XN n ¼ 1 w4 inv3 inðkÞ XN n ¼ 1 v3 inðkÞ ¼ WT i V v4 il ¼ XN n ¼ 1 w4 inv3 in ðkÞ XN n ¼ 1 v3 in ðkÞ ¼ WT i V ; l ¼ 1 8 : ð22Þ where w4 in A½w4 in w4 in Š is the centriod of the output MF; w4 in ¼ ðw4 in þw4 in Þ=2 is the average value between the two endpoints of the centriod; Wi ¼ w4 i1 w4 i2…w4 in  ÃT . V ¼ v 3 i1ðkÞ XN n ¼ 1 v3 inðkÞ v 3 i2ðkÞ XN n ¼ 1 v3 inðkÞ ⋯ v 3 inðkÞ XN n ¼ 1 v3 inðkÞ 2 6 4 3 7 5 T and V ¼ v3 i1 ðkÞ XN n ¼ 1 v3 in ðkÞ v3 i2 ðkÞ XN n ¼ 1 v3 in ðkÞ ⋯ v3 in ðkÞ XN n ¼ 1 v3 in ðkÞ 2 6 4 3 7 5 T Output Layer: This layer performs the output of the network as: ρi ¼ v4 il þv4 il 2 ¼ 1 2 WT i V þWT i V ¼ 1 2 WT i VðX1 ; m; σÞ i ¼ 1; 2 ð23Þ where αi is the output of the IT2FNN, V ¼ V V  ÃT , X1 ¼ x1 1 x1 2  à , m ¼ m11…m1s m21 …m2s½ Š, and σ ¼ σ11 …σ1s σ21…σ2s½ Š: 3.3. Learning algorithm The back-propagation algorithm is used to updating the weights of the IT2FNN. So, the target function is represented as: J ¼ 1 2 yrðkÞÀymðkÞ À Á2 ð24Þ where yrðkÞ is the desired output, and ymðkÞ is the measured out- put. w4 inðkþ1Þ ¼ w4 inðkÞþΔw4 inðkÞ ð25Þ Δw4 in ¼ Àη1 ∂J ∂w4 in ¼ Àη1 ∂J ∂ym : ∂ym ∂u : ∂u ∂ρi ∂ρi ∂w4 in ð26Þ Δw4 inðkÞ ¼ 1 2 ηw ðyrðkÞÀymðkÞÞ : δu : δρi : 1 2 v3 inðkÞ PN n ¼ 1 v3 inðkÞ þ 1 2 v3 in ðkÞ PN n ¼ 1 v3 inðkÞ 0 B B B @ 1 C C C A ; n ¼ 1; 2; :::; N ð27Þ where ηw is the learning rate for tuning the weighting interval factor of the IT2FNN, Δw4 in is the increment of weight w4 in, δu is the change of the output towards the change of the input which defined as follows: δu ¼ ∂ym ∂u ffi ymðkÞÀymðkÀ1Þ uðkÞÀuðkÀ1Þ ð28Þ Fig. 4. Interval type-2 fuzzy set with uncertain mean. A.M. El-Nagar / ISA Transactions 64 (2016) 314–327 317
  5. 5. In many practical cases the derivative in Eq. (28) can be easily estimated or replaced þ1 or -1 [49]. From Eq. (15), δρi can be defined as: δρ1 ¼ ∂u ∂ρ1 ¼ ΔeðkÞ; and δρ2 ¼ ∂u ∂ρ2 ¼ eðkÞ ð29Þ Through the same principle, it can change the weight Δ_w_ 4 in as follows: w4 in ðkþ1Þ ¼ w4 in ðkÞþΔw4 in ðkÞ ð30Þ Δw4 in ðkÞ ¼ 1 2 ηw ðyrðkÞÀymðkÞÞ:δu: δρi : 1 2 v3 inðkÞ PN n ¼ 1 v3 inðkÞ þ 1 2 v3 in ðkÞ PN n ¼ 1 v3 inðkÞ 0 B B B @ 1 C C C A ; n ¼ 1; 2; :::; N ð31Þ Also, the mean and standard deviation of the IT2FNN can be updated as follow: m1ijðkþ1Þ ¼ m1ijðkÞþ 1 2 ηm ðyrðkÞÀymðkÞÞ: δu δρi PN n ¼ 1 u3 LNðkÞ : Xjf n ¼ 1þhf Xf v ¼ 1 w4 in ðkÞ:v2 1ij:v2 2iv: eðkÞÀm1ijðkÞ σ1ij 2 ðkÞ j ¼ 1; 2; :::; f ; h ¼ 0; 1; 2; :::; f À1 and i ¼ 1; 2 ð32Þ m2ijðkþ1Þ ¼ m2ijðkÞþ 1 2 ηm ðyrðkÞÀymðkÞÞ: δu δρi PN n ¼ 1 _v_ 3 in ðkÞ : X n ¼ j Xf v ¼ 1 _w_ 4 inðkÞ:v2 1iv:v2 2ij: ΔeðkÞÀm2ijðkÞ σ2ij 2 ðkÞ j ¼ 1; 2; :::; f ; n ¼ j; jþf ; jþ2f ; :::; jþf ðf À1Þ and i ¼ 1; 2 ð33Þ σ1ijðkþ1Þ ¼ σ1ijðkÞþ 1 2 ησ ðyrðkÞÀymðkÞÞ: δu δρi PN n ¼ 1 v3 inðkÞ : Xjf n ¼ 1 þ if Xf v ¼ 1 w4 in ðkÞ:v2 1ij:v2 2iv: ðeðkÞÀσ1ijðkÞÞ2 σ1ij 3 ðkÞ j ¼ 1; 2; :::; f ; h ¼ 0; 1; 2; :::; f À1 and i ¼ 1; 2 ð34Þ σ1ij ðkþ1Þ ¼ σ1ij ðkÞþ 1 2 ησðyrðkÞÀymðkÞÞ: δu δρi Pn N ¼ 1 v3 inðkÞ : Xjf n ¼ 1 þ if Xf v ¼ 1 w4 inðkÞ:v2 1ij :v2 2iv : ðeðkÞÀσ1ij ðkÞÞ2 σ1ij 3ðkÞ j ¼ 1; 2; :::; f ; h ¼ 0; 1; 2; :::; f À1 and i ¼ 1; 2 ð35Þ σ2ijðkþ1Þ ¼ σ2ijðkÞþ 1 2 ησðyrðkÞÀymðkÞÞ: δu δρi PN n ¼ 1 _u_ 3 in ðkÞ : X n ¼ j Xf v ¼ 1 _w_ 4 inðkÞ:v2 1iv:v2 2ij: ðΔeðkÞÀσ2ijðkÞÞ2 σ2ij 3 ðkÞ j ¼ 1; 2; :::; f ; n ¼ j; jþf ; jþ2f ; :::; jþf ðf À1Þ and i ¼ 1; 2 ð36Þ _σ_2ijðkþ1Þ ¼ _σ_2ijðkÞþ 1 2 ησðyrðkÞÀymðkÞÞ: δu δρi PN n ¼ 1 u3 inðkÞ : X n ¼ j Xf v ¼ 1 w4 inðkÞ:_v_ 2 1iv:_v_ 2 2ij: ðΔeðkÞÀ_σ_2ijðkÞÞ2 _σ_2ij 3ðkÞ j ¼ 1; 2; :::; f ; N ¼ j; jþf ; jþ2f ; :::; jþf ðf À1Þ and i ¼ 1; 2 ð37Þ where ηm and ησ are the learning rate parameters of mean and standard deviation of the IT2FNN. 3.4. Convergence analysis In the learning procedures of the IT2FNN, the update para- meters require a proper choice of learning rates η. In this section, the approach of selecting properly η is developed. The Lyapunov function can be defined as: VðkÞ ¼ 1 2 e2 ðkÞ ð38Þ where eðkÞ is the control error. The change in the Lyapunov func- tion is obtained by: ΔVðkÞ ¼ Vðkþ1ÞÀVðkÞ ¼ 1 2 e2 ðkþ1ÞÀe2 ðkÞ Â Ã ð39Þ The error difference of the IT2FNN can be represented by [50,51]: eðkþ1Þ ¼ eðkÞþΔeðkÞ ¼ eðkÞþ ∂eðkÞ ∂W !T ΔW ð40Þ where W is the parameter vector of the IT2FNN weighting vector, W ¼ ½ w4 in w4 in m1ij m2ij σ1ij σ1ij σ2ij σ2ij Š and ΔW repre- sent the corresponding change of this weight. In the IT2FNN, the weight change is obtained from the update rules of Eqs. (25)–(37) as: ΔWðkÞ ¼ ÀηW eðkÞ ∂eðkÞ ∂W % ηW eðkÞ ∂ρiðkÞ ∂W ð41Þ where ηW is the learning rate of corresponding weight component in the IT2FNN. Theorem: Let ηW ¼ ηw ηm ησ h i be the learning rates of the IT2FNN and define HW max as HW max ¼ max k‖HW ðkÞ‖, where HW ðkÞ ¼ ∂ρiðkÞ=∂W, and ‖:‖ is the Euclidean norm. Then, the asymptotic convergence of the IT2FNN controller is guaranteed if ηW are chosen to satisfy: 0oηW o 2 HW max 2 ð42Þ in which Wis the weights of the IT2FNN parameters w; m; σ. Proof: From Eqs. (39 and 40), the change in the Lyapunov function is: ΔVðkÞ ¼ 1 2 e2 ðkþ1ÞÀe2 ðkÞ Â Ã ¼ ΔeðkÞ eðkÞþ 1 2 ΔeðkÞ ! ð43Þ ΔVðkÞ ¼ ∂eðkÞ ∂W !T ηW eðkÞ ∂ρi ∂W : eðkÞþ 1 2 ∂eðkÞ ∂W !T ηW eðkÞ ∂ρi ∂W ( ) ð44Þ Since for the IT2FNN, ∂eðkÞ=∂W ¼ À∂ρi=∂W, and let HW ðkÞ ¼ ∂ρiðkÞ=∂W, HW max ¼ max k‖HW ðkÞ‖, we obtain Fig. 5. Experimental setup for DC motor – generator system. A.M. El-Nagar / ISA Transactions 64 (2016) 314–327318
  6. 6. Fig. 6. Response of the DC motor – generator system for step change. Fig. 7. MAE for task 1. Fig. 8. Response of the DC motor – generator system for uncertainty in measurement error (20%). A.M. El-Nagar / ISA Transactions 64 (2016) 314–327 319
  7. 7. Fig. 9. Response of the DC motor – generator system for uncertainty in measurement error (40%). Fig. 10. MAE for task 2 (20%). Fig. 11. MAE for task 2 (40%). A.M. El-Nagar / ISA Transactions 64 (2016) 314–327320
  8. 8. ΔVðkÞ ¼ ÀeðkÞ‖HW ðkÞ‖2 ηW eÀ 1 2 eηW ‖HW ðkÞ‖2 ð45Þ ΔVðkÞ ¼ À 1 2 e2 ðkÞ‖HW ðkÞ‖2 ηW 2ÀηW ‖HW ðkÞ‖2 Àβe2 ðkÞ: ð46Þ where β ¼ 1 2 ‖HW ðkÞ‖2 ηW 2ÀηW ‖HW ðkÞ‖2 ð47Þ If β40, then ΔVðkÞo0 is satisfied. Thus, the asymptotic con- vergence of the proposed control system is guaranteed, and from Eq. (47), we obtain Eq. (42). This completes the proof. 4. Embedded adaptive PI controller In this section, the proposed API-IT2FNN is implemented practi- cally using an Arduino DUE microcontroller kit for controlling the DC Fig. 12. Response of the DC motor – generator system for uncertainty due to the load (23%). Fig. 13. Response of the DC motor – generator system for uncertainty due to the load (46%). A.M. El-Nagar / ISA Transactions 64 (2016) 314–327 321
  9. 9. Fig. 14. MAE for task 3 (23%). Fig. 15. MAE for task 3 (46%). Fig. 16. Response of the DC motor – generator system (Task 4). A.M. El-Nagar / ISA Transactions 64 (2016) 314–327322
  10. 10. motor – generator system. An Arduino DUE kit has many features such as: a 84 MHz crystal frequency, a 32 bit CortexM3 ARM micro- controller, 4 universal asynchronous receiver transmitter (UART), 512 KB flash memory and 96 KB random access memory (RAM). The proposed controller program is done using Arduino Integrated Development Environment (Arduino IDE) with version 1.6.5 software. Fig. 5 shows the experimental setup for the DC motor – gen- erator system. The speed is measured using the tachometer and the DC motor drive circuit is 3 Amp. H-Bridge, which used to drive the DC motor – generator system. The electric lamps are used as an electrical load for the DC motor. The implementation procedure of the proposed API-IT2FNN for the DC motor – generator system using an Arduino kit is summarized as follows: – Step 1: Measure the speed of the motor using the tachometer and sent it to the Arduino kit via analog input. – Step 2: Compute the input variables (input layer) for the IT2FNN using Eq. (18). – Step 3: Compute the output of membership layer for the IT2FNN using Eq. (19). Fig. 17. MAE for task 4. Fig. 18. Updating the controller gains for the API-IT2FLS. Fig. 19. Updating the controller gains for the API-IT2FNN. A.M. El-Nagar / ISA Transactions 64 (2016) 314–327 323
  11. 11. – Step 4: Compute the rule layer output using Eq. (20). – Step 5: Perform the type-reduction to calculate the output of the IT2FNN (updating factors) using Eqs. (21)–(23). – Step 6: Compute the control signal using Eq. (15) and sent it to the drive circuit via PWM output. – Step 7: Calculate the target function using Eq. (24) and updating the parameters of the IT2FNN using Eqs. (25)–(37), go to step 1. 5. Practical results In this section, the experimental results for the DC motor – gen- erator system using the embedded API-IT2FNN are presented. In order to clarify the improvements of the proposed API-IT2FNN, the practical results with the adaptive PI controller based on the IT2FLS (API- IT2FLS) which is proposed previously [43] are also presented. Six different experimental tasks are considered where the desired speed is 500 rev= min. Three performance indices are measured for comparing the API-IT2FNN controller and the API-IT2FLS controller; the mean absolute errors (MAE), the root mean square of errors (RMSE) and the integral of square of errors (ISE) criteria which are defined as: MAE ¼ 1 kf Xkf k ¼ 1 eðkÞ ð48Þ RMSE ¼ ffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi 1 kf Xkf k ¼ 1 ðeðkÞÞ2 v u u t ð49Þ ISE ¼ Z 1 0 e tð Þ½ Š2 dt ð50Þ where eðtÞ is the error signal and kf is the number of iterations The type-2 MFs are initialized as follows: m11 ¼ m14 ¼ m21 ¼ m24 ¼ À0:5; m12 ¼ m15 ¼ m22 ¼ m25 ¼ 0; m13 ¼ m16 ¼ m23 ¼ m26 ¼ 0:5; σij ¼ 0:25; σij ¼ 0:15. Fig. 20. Response of the DC motor – generator system (Task 5). Fig. 21. MAE for task 5. A.M. El-Nagar / ISA Transactions 64 (2016) 314–327324
  12. 12. The initial values for the layer weights of the IT2FNN network are chosen randomly between [À0.5, 0.5]. After the initial values of the controller parameters are chosen based on the limitations of the universe of discourse, the online learning algorithm shown in Eqs. (25)–(37) is updated with controller parameters. Any other values of the universe of discourse are acceptable because on-line learning algorithm is updated with the final values, which guar- antee the system stability. Fig. 22. Response of the DC motor – generator system (Task 6). Fig. 23. MAE for task 6. Table 2 ISE values for the controllers. Task 1 Task 2 (20%) Task 2 (40%) Task 3 (23%) Task 3 (46%) Task 4 Task 5 Task 6 Classical PI 729.77 86.94 93.87 91.57 95.18 102.99 63.07 95.21 STPIC 510.20 44.05 52.79 47.01 48.61 54.97 51.88 83.52 API-IT2FLS [43] 490.50 43.00 50.46 44.87 45.97 51.03 47.01 78.03 API- IT2FNN 314.75 37.95 41.17 38.99 37.73 40.98 31.98 51.43 Table 3 RMSE values for the controllers. Task 1 Task 2 (20%) Task 2 (40%) Task 3 (23%) Task 3 (46%) Task 4 Task 5 Task 6 Classical PI 0.7798 0.1474 0.1532 0.1513 0.1543 0.1605 0.1025 0.0976 STPIC 0.3571 0.1049 0.1149 0.1084 0.1102 0.1172 0.0930 0.0914 API- IT2FLS [43] 0.2022 0.1037 0.1123 0.1059 0.1072 0.1129 0.0885 0.0883 API- IT2FNN 0.1620 0.0974 0.1014 0.0987 0.0971 0.1012 0.0730 0.0717 A.M. El-Nagar / ISA Transactions 64 (2016) 314–327 325
  13. 13. In this paper, the initial values of the PI controller gains are set by trial and error method to make the transient response of the system as good as possible. It is possible to use well-defined methods such as Ziegler – Nichols method to set the initial values. 5.1. Task 1: step change in the set-point To test the tracking of the DC motor – generator system, the set-point of the speed is changed from 500 rev= min to À500 rev= minas shown in Fig. 6. It is clear that the response of the DC motor speed for the proposed API-IT2FNN is made significantly better than the API-IT2FLS. Fig. 7 shows that the MAE for the proposed API-IT2FNN is lower than that obtained for the API- IT2FLS. Therefore, the proposed API-IT2FNN is able to respond the Coulomb friction and the dead zone nonlinearity better than the API-IT2FLS. 5.2. Task 2: uncertainty due to the measurement error Figs. 8 and 9 show the response of the controlled system when there is an uncertainty due to the measurement error with 20% and 40%, respectively at the time (t ¼ 20 s). It is clear that the response of the proposed API-IT2FNN has lower settling time after adding the uncertainty value compared with API-IT2FLS. Figs. 10 and 11 show that the MAE for the proposed API-IT2FNN is less than that obtained for the API-IT2FLS. Therefore, the proposed API-IT2FNN is able to reduce the effect of the uncertainty due to the measurement error compared with the API-IT2FLS. 5.3. Task 3: uncertainty due to an electric load Figs. 12 and 13 show the response of the controlled system when there is an uncertainty in the load with 23% and 46%, respectively at the time (t ¼ 20 s). It is clear that the response of the proposed API-IT2FNN is made significantly better than the API- IT2FLS. Figs. 14 and 15 show that the MAE for the proposed API- IT2FNN is less than that obtained for the API-IT2FLS. Therefore, the proposed API-IT2FNN is able to respond the uncertainty due to an electric load on the DC motor compared with the API-IT2FLS. 5.4. Task 4: uncertainty due to the measurement error and the electric load In this task, 20% measurement error and 23% electric load at the time (t¼20 s) are applied to the DC motor. Fig. 16 shows the response of the controlled system for this task. Fig. 17 shows that the MAE for the proposed API-IT2FNN is less than that obtained for the API-IT2FLS. So, the response of the proposed API-IT2FNN is able to respond the effect of the uncertainty due to the measure- ment error and an electric load on the DC motor – generator system. Figs. 18 and 19 show the varying of the proportional and integral gains for the API-IT2FLS and the API-IT2FNN, respectively. It’s clear that the proportional and integral gains for the PI con- troller at the transient period and at the effect of uncertainty (20 s) are tuned on-line using the adaption mechanisms (IT2FLS and IT2FNN). The IT2FNN is tuned the PI controller gains larger than the IT2FLS which make the proposed controller is able to respond to the system uncertainties compared with the API-IT2FLS. 5.5. Task 5: input disturbance Fig. 20 shows the effect of adding random disturbance for the control signal at time equal 20 s. for both controllers. It is clear that the performance of the DC motor – generator system for the proposed API-IT2FNN have made significantly better than the performance for the API-IT2FLS. Fig. 21 shows that the MAE for the proposed controller is lower than that obtained for the API-IT2FLS. 5.6. Task 6: simulated neglected dynamics In this simulation task, we show the effect of neglected dynamics by adding uncertainty values for the system parameters to show the robustness of the proposed controller. Figs. 22 and 23 show the performance of the proposed API-IT2FNN and API-IT2FLS for this task. It is clear that the performance of the proposed API- IT2FNN is able to reduce the effect of neglected dynamics better than the API-IT2FLS. Tables 2 and 3 list the ISE and the RMSE values, respectively, for the classical PI controller, the self-tuning PI controller (STPIC), the API-IT2FLS and the proposed API-IT2FNN for all the above practical results. As shown in Tables 2 and 3, the values of the ISE and the RMSE for the proposed API-IT2FNN are lower than that obtained for other controllers. So, the proposed API-IT2FNN is superior to respond the uncertainties in the DC motor – generator system rather than other controllers. The computational complexity of the adaptive algorithm is depended on the following: 1) the number of the updated para- meters. 2) The structure of the adaptive algorithm (IT2FNN) (such as the number of membership in each input). 3) The TR method, which used in the layer 4. In this paper, we have reduced the computational complexity of the adaptive algorithm by: 1) selecting the lower level of the structure PI controller instead of PID controller. 2) Selecting the simplified TR method, which is less computational cost comparing to other methods [48]. 6. Conclusion In this paper, the adaptive PI controller based on the IT2FNN is proposed. The proposed controller consists of a lower level PI controller, which is the main controller and an upper level IT2FNN. The IT2FNN provides a mechanism for tuning on-line the gains of a PI controller. Back-propagation algorithm is used to train IT2FNN. The Lyapunov theorem is used to derive the stability and con- vergence of the IT2FNN. The proposed API-IT2FNN is implemented using the Ardunio DUE Kit for controlling the DC motor – gen- erator system. Six experimental tasks have been performed including the step change in DC motor speed, the uncertainty due to the measurement error in the motor speed, the uncertainty due to an electric load, input disturbance and the effect of neglected dynamics. The experimental results of the proposed API-IT2FNN are compared with the results of the adaptive PI based on the IT2FLS. The proposed controller based on the IT2FNN is able to varying the PI gains larger than the IT2FLS. Three performance indices; MAE, ISE and RMSE are measured for the proposed API- IT2FNN and the API-IT2FLS for all experimental tasks and these indices establish the superiority of the proposed API-IT2FNN to respond to system uncertainties compared with the API-IT2FLS. Thus, the methodology proposed in this study can be used to realize a robust, practically realizable, adaptive PI controller cap- able of controlling a real-life plant with system uncertainties with acceptable closed-loop response. The main contributions of this study are summarized as: 1) proposing adaptive PI controller based on the IT2FNN. 2) Imple- menting practically the proposed controller using the Arduino DEU kit for controlling the nonlinear DC motor – generator system. A.M. El-Nagar / ISA Transactions 64 (2016) 314–327326
  14. 14. References [1] Bandyopadhyay R, Patranabis D. A new autotuning algorithm for PID con- trollers using dead-beat format. ISA Trans 2001;40:255–66. [2] Dey C, Mudi RK. An improved auto-tuning scheme for PID controllers. ISA Trans 2009;48:396–409. [3] Tran HD, Guan ZH, Dang XK, Cheng XM, Yuan FS. A normalized PID controller in networked control systems with varying time delays. ISA Trans 2013;52:592–9. [4] Kim JH, Oh SJ. A fuzzy PID controller for nonlinear and uncertain systems. Soft Comput 2000;4:123–9. [5] Gawthrop PJ. Self-tuning PID controllers: algorithms and implementation. IEEE Trans Autom Control 1986;31:201–9. [6] Tan KK, Huang S, Ferdous R. Robust self-tuning PID controller for nonlinear systems. J Process Control 2002;12:753–61. [7] Cameron F, Seborg DE. A self-tuning controller with a PID structure. Int J Control 1983;38:401–17. [8] Hsu YY, Liou KL. Design of self-tuning PID power system stabilizers for syn- chronous generators. IEEE Trans Energy Convers 1987;3:343–8. [9] Chang WD, Hwang RC, Hsieh JG. A self-tuning PID control for a class of non- linear systems based on the Lyapunov approach. J Process Control 2002;12:233–42. [10] Kim JH, Choi KK. Self-tuning discrete PID controller. IEEE Trans Ind Electron 1987;43:298–300. [11] Radke F, Isermann R. A parameter-adaptive PID-controller with stepwise parameter optimization. Automatica 1987;23:449–57. [12] Pomerleau A, Desbiens A, Hodouin D. Development and evaluation of an auto- tuning and adaptive PID controller. Automatica 1996;32:71–82. [13] Chang WD, Hwang RC, Hsieh JG. A multivariable on-line adaptive PID con- troller using auto-tuning neurons. Eng Appl Artif Intell 2003;16:57–63. [14] Howell MN, Gordon TJ, Best MC. The application of continuous action rein- forcement learning automata to adaptive PID tuning. IEEE Semin Learn Syst Control 2000:1–4. [15] Vega P, Prada C, Aleixander V. self-tuning predictive PID controller. IEE Proc – Control Theory Appl 1991;138:301–11. [16] Patel AV, Mohan BM. Analytical structures and analysis of the simplest fuzzy PI controllers. Automatica 2002;38:981–93. [17] Mohan BM, Patel AV. Analytical structures and analysis of the simplest fuzzy PD controllers. IEEE Trans Syst Man Cybern B 2002;32:239–48. [18] Mohan BM, Sinha A. Analytical structure and stability analysis of a fuzzy PID controller. Appl Soft Comput 2008;8:749–58. [19] Xu JX, Hang CC, Liu C. Parallel structure and tuning of a fuzzy PID controller. Automatica 2000;36:673 684. [20] Rakhtala SM, Roudbari E Shafiee. Fuzzy PID control of a stand-alone system based on PEM fuel cell. Int J Electr Power Energy Syst 2016;78:576–90. [21] Natsheh E, Buragga KA. Comparison between conventional and fuzzy logic PID controllers for controlling DC Motors. Int J Comput Sci 2010;7:128–34. [22] Kumar V, Mittal AP. Parallel fuzzy Pþfuzzy Iþfuzzy D controller: design and performance evaluation. Int J Autom Comput 2010;7:463–71. [23] Fadaei A, Salahshoor K. Design and implementation of a new fuzzy PID con- troller for networked control systems. ISA Trans 2008;47:351–61. [24] Blanchett TP, Kember GC, Dubay R. PID gain scheduling using fuzzy logic. ISA Trans 2000;39:317–25. [25] Chen J, Huang TC. Applying neural networks to on-line updated PID con- trollers for nonlinear process control. J Process Control 2004;14:211–30. [26] Martins FG, Coelho M. Application of feed-forward artificial neural to improve process control of PID-based control algorithms. Comput Chem Eng 2000;24:853–8. [27] Shu H, Pi Y. PID neural networks for time-delay systems. Comput Chem Eng 2000;24:859–62. [28] Lee CH, Teng CC. Calculation of PID controller parameters by using a fuzzy neural network. ISA Trans 2003;42:391–400. [29] Castillo O, Melin P. Type-2 fuzzy logic: Theory and application. Studfuzz 2008;223:29–43. [30] D. Wu, W. W. Tan, Interval type-2 fuzzy PI controllers: Why they are more robust. In: Proceedings of the 2010 IEEE International Conference on Granular Computing (GrC); 2010. pp. 802–07. [31] Yesil E. Interval type-2 fuzzy PID load frequency controller using Big Bang–Big Crunch optimization. Appl Soft Comput 2014;15:100–12. [32] Khooban MH, Alfi A, Abadi DNM. Teaching–learning-based optimal interval type-2 fuzzy PID controller design: a nonholonomic wheeled mobile robots. Robotica 2013;31:1059–71. [33] Nie M, Tan WW. Analytical structure and characteristics of symmetric Karnik– Mendel type-reduced interval type-2 fuzzy PI and PD controllers. IEEE Trans Fuzzy Syst 2012;20:416–30. [34] M. Biglarbegian, W. W. Melek, J. M. Mendel, A practical approach for design of PD and PI like interval type-2 TSK fuzzy controllers. In: Proceedings of IEEE International Conference on Systems, Man and Cybernetics, 2009; SMC 2009. pp. 255–61. [35] Kumbasar T. A simple design method for interval type-2 fuzzy PID controllers. Soft Comput 2014;18:1293–304. [36] El-Nagar AM, El-Bardini M. Practical implementation for the interval type-2 fuzzy PID controller using a low cost microcontroller. Ain Shams Eng J 2014;5:475–787. [37] El-Nagar AM, El-Bardini M. Practical realization for the interval type-2 fuzzy PDþI controller using a low cost microcontroller. Arab J Sci Eng 2014;39:6463–76. [38] El-Nagar AM, El-Bardini M. Derivation and stability analysis of the analytical structures of the interval type-2 fuzzy pid controller. Appl Soft Comput 2014;24:704–16. [39] El-Nagar AM, El-Bardini M. Hardware-in-the-loop simulation of interval type- 2 fuzzy PD controller for uncertain nonlinear system using low cost micro- controller. Appl Math Model 2016;40:2346–55. [40] T. Kumbasar, H. Hagras, A Gradient Descent based online tuning Mechanism for PI Type Single input Interval Type-2 fuzzy logic controllers. In: Proceedings of 2015 IEEE International Conference on Fuzzy Systems (FUZZ-IEEE), 2015, pp. 1-6. [41] C. M. T. Yip, W. W. Tan, Ensuring zero steady state error in interval type-2 fuzzy PI control system with non-symmetrical fuzzy sets. In: Proceedings of the 2015 IEEE International Conference on Fuzzy Systems (FUZZ-IEEE), 2015, pp. 1-8. [42] Kumbasar T, Hagras H. A self-tuning zslices-based general type-2 fuzzy PI controller. IEEE Trans Fuzzy Syst 2015;23:991–1013. [43] El-Bardini M, El-Nagar AM. Interval type-2 fuzzy PID controller for uncertain nonlinear inverted pendulum system. ISA Trans 2014;53:732–43. [44] El-Bardini M, El-Nagar AM. Interval type-2 fuzzy PID controller: analytical structures and stability analysis. Arab J Sci Eng 2014;39:7443–58. [45] Peng J, Dubay R. Identification and adaptive neural network control of a DC motor system with dead-zone characterstics. ISA Trans 2011;50:588–98. [46] Kara T, Eker I. Nonlinear modeling and identification of a DC motor for bidirectional operation with real time experiments. Energy Convers Manag 2004;45:1087–106. [47] Chen C, Lin W. Self-adaptive interval type-2 neural fuzzy network control for PMLSM drive. Expert Syst Appl 2011;38:14679–89. [48] El-Nagar AM, El-Bardini M. Simplified interval type-2 fuzzy logic system based on new type-reduction approach. J Intell Fuzzy Syst 2014;27:1999–2010. [49] Tanomaru J, Omatu S. Process control by on-line trained neural controllers. IEEE Trans Ind Electron 1992;39:511–22. [50] Polycarpou M, Ioannou P. Learning and convergence analysis of neural-type structured networks. IEEE Trans Neural Netw 1992;3:39–50. [51] Ku CC, Lee KY. Diagonal recurrent neural networks for dynamics systems control. IEEE Trans Neural Netw 1995;6:144–56. A.M. El-Nagar / ISA Transactions 64 (2016) 314–327 327

×