Short Communication - (2018) Volume 7, Issue 1

Speed Control of DC Motor Using PID Controller Based on Changed Intelligence Techniques

Walaa M Elsrogy1, Naglaa K Bahgaat2*, MI El-Sayed3 and MA Moustafa Hassan4
1Great Cairo Company for Water, Cairo, Egypt, E-mail:
2Department of Electrical Communication, Faculty of Engineering, Canadian International College (CIC), 6 October City, Giza, Egypt, E-mail:
3Department of Electrical Power Engineering, Faculty of Engineering, Al-Azhar University, Cairo, Egypt, E-mail:
4Department of Electrical Power Engineering, Faculty of Engineering, Cairo University, Giza, Egypt, E-mail:
*Corresponding Author: Naglaa K Bahgaat, Department of Electrical Communication, Faculty of Engineering, Canadian International College (CIC), 6 October City, Giza, Egypt, Tel: +20 102 722 7142 Email:


The objective from this paper is to design speed controller for DC motors by choice of a PID factors using Diverse Methods Ziegler and Nichols (ZN), Genetic Algorithm (GA), Modified Adaptive Acceleration Particle Swarm Optimization (MAACPSO) and Adaptive Neuro-Fuzzy Inference System (ANFIS). All of tuning methods for parameters of PID controller will be compared based on improved performance and effectiveness over them.

Keywords: DC motor; Ziegler Nichols (ZN); Genetic Algorithm (GA); Particle Swarm Optimization (PSO); PID controller; ANFIS


Proportional-Integral Derivative (PID) controllers have been largely used for speed control of DC motor [1-6]. The paper attainment is to design a control system using numerous techniques of intelligence controller. Particle Swarm Optimization (PSO) is one of the most influential stochastic optimization techniques [1]. It has lately involved more care due to its fast conjunction and algorithmic accurateness compared to other optimization methods. Several improved Algorithms of PSO have been developed in latest years by many researchers to find the best estimated solution [5,8]. Furthermore, applying Adaptive Neuro Fuzzy Inference System (ANFIS) based on genetic algorithms and MAACPSO will be studied. An optimization can be reached; this can be seen by comparing the results of the GA optimized system and MAACPSO in contradiction of the Ziegler- Nichols tuned system.

DC Motor

Electric motors are used for a wide-ranging of industrial operation. As reference the construction for a shunt-type DC motor is exemplified in Figure 1 [1]. The equations describing the energetic behavior of the DC motor based on the diagram displayed on Figures 1 and 2.


Figure 1: Diagram of DC shunt motor.


Figure 2: The schematic diagram of Dc motor.

Tuning PID Controller

Ziegler-Nichols method

The straight forward method is largely accepted method for tuning the PID controller [5,6] (Table 1).

Controller Type Kp Ki Kd
PID Ku/1.7 Tu/2 Tu/8

Table 1: Ziegler-Nichols tuning rule.

1. The integral and derivative parameters (gains) will be set to zero.

2. Slowly increase the proportional coefficient from zero to until the system just begins to oscillate continuously (sustained oscillation).

3. The proportional coefficient at this point is called the Ultimate gain (Ku).

4. However, the period of oscillation at this point is called Ultimate period (Tu).

The ultimate gain Ku=84 and the ultimate period Tu=0.15 sec where Kp=49.41, Ki=0.075 and Kd=0.01875. The output response is displayed in Figure 3. The block diagram of PID controller using ZN is shown in Figure 4.


Figure 3: Response of the system using PID controller.


Figure 4: Block diagram for the complete system using PID controller.

Genetic algorithm [GA]

GA has been recognized as an effective technique for optimization problems [7-9]. GA starts with an initial population containing several chromosomes. This algorithm is reiterated for many generations and finally stops when reaching individuals that represent the optimum solution to the problem (Table 2). The Genetic Algorithm Process Architecture is illustrated in Figure 5 and output response is displayed on Figure 6.


Figure 5: Genetic algorithm process construction.


Figure 6: Response of GA.

Parameters Gains
Kp 19.8
Ki 0.137
Kd 0.557

Table 2: The GA based PID controller gain values.

Modified adaptive acceleration particle swarm (MAACPSO)

In this modification, the first choice for the value of C1 which designated in the last section will be kept. Therefore, C1 will be changed exponentially (with inertia weight) in the time, with respect to their minimal and maximal values. The other one C2 changes as a factor of the first coefficient [10,11].


Figure 7: Block diagram for the complete system using PID controller tuning with particle Swarm optimization.

The presentation of each particle is evaluated using fitness (cost) function as obtainable. The o/p response for MAACPSO in Figure 6 block diagram is displayed in Figure 7. The results of the program using MAACPSO with IAE is itemized in Table 3.

No. of Iteration Kp Ki Kd Settling time IAE
200 1.9333 1.1951 0.4905 2.7028 0.0492

Table 3: The results of the program using MAACPSO with IAE are itemized.

Adaptive Neuro –Fuzzy inference system

It is a combination between an Artificial Neural Network (ANN) with a Fuzzy Inference System (FIS). It is functionally equivalent to FIS [12,13].

To find the optimal parameters of Fuzzy Logic, ANN is used for this optimization via extensive training. The final product is Fuzzy Logic which be exported to the simulation of the system using SIMULINK [14].

ANFIS based GA

These tools apply fuzzy inference techniques to data modelling [14,15] The form of the membership functions be contingent on parameters. Membership function parameters were chosen automatically using these Fuzzy Logic Toolbox Applications Fuzzy Logic Tool box software calculates the membership function parameters that best allow the associated fuzzy inference system to track the given input/output data. The ANFIS toolbox after training data is illustrated in Figure 8. Then, fuzzy logic controller based on ANFIS like PID controller the block diagram for the system is given in Figure 9 and output response is displayed in Figures 10 and 11.


Figure 8: ANFIS tool box after training data.


Figure 9: Block diagram for the complete system of ANFIS.


Figure 10: Response of ANFIS based GA.


Figure 11: Response of ANFIS based MAACPSO Controller.

Mp is around zero, Ts is about 0.8 sec. The comparisons of results for several methods for tuning PID controller for DC motor are showed with Table 4.

Tuning Method Maximum overshoot Settling Time (sec)
ZN 0.06 1.3
GA - 0.9
ANFIS based GA - 0.6
ANFIS based MAACPSO - 0.8

Table 4: Comparison between ZN, GA, and ANFIS responses.


ZN has badly over shoot and largest settling time. The settling time and over shoot in case of using GA is better than ZN and solve its problem The settling time in case of using MAACPSO is smaller than its value by using PSO, AWPSO and AACPSO. ANFIS has many advantages like it is simple and easy to use compared with the other methods used in this study. Furthermore, it takes less time in the program running. ANFIS based MAACPSO and ANFIS based GA have smallest Settling Time and Overshoot than GA, PSO, and ZN. This comparative study indicate that the best type of the controller to have the small value of settling time and overshoot was made by ANFIS controller tuning by GA.


  1. K Ogata (2010) Modern Control Systems, University of Minnesota, Prentice Hall, 1987. Frank D. Petruzella, Electric Motors and Control Systems, 1st Edition, Published by McGraw-Hill, New York.
  2. Sharaf AM, Masry M (2002) Nonlinear Speed Control of large Industrial DC Motor Drives with an Energy Efficiency Enhancement Loop. Canadian Conference on Electrical and Computer Engineering. Canada.
  3. Petruzella FD (2010) Electric Motors and Control Systems. 1st Edition Published by McGraw-Hill, New York.
  4. Hughes A (2006) Electric Motors and Drives Fundamentals, Types and Applications. Published by Elsevier Ltd.
  5. Ziegleri JG, Nichols NB (1993) Optimum Settings for Automatic Controllers. Transactions of The American Society of Mechanical Engineers 115: 220-222.
  6. Astrom KJ, Hagglund T (2004) Revisiting the Ziegler-Nicholsstep response method for PID control. Journal of Process Control 14: 635-650.
  7. Varsek A, Urbancic T, Filipic B (1993) Genetic algorithms in controller design and tuning. IEEE Trans Systems, Man and Cybernetics 23: 1330-1339.
  8. Krishnakumar K, Goldberg DE (1992) Control System Optimization Using Genetic Algorithms. Journal of Guidance, Control and Dynamics 15: 3.
  9. Wang Q, Spronck P, Tracht R (2003) An Overview Of Genetic Algorithms Applied To Control Engineering Problems. Proceedings of the 2nd International Conference on Machine Learning and Cybernetics. China.
  10. Panigrahi BK, Pandi VR, Das S (2008) Adaptive particleswarm optimization approach for static and dynamic economicload dispatch. Energy Conversion and Management 49: 1407-1415.
  11. Panigrahi BK, RavikumarPandi V, Das S (2008) Adaptive particle swarm optimization approach for static and dynamic economic load dispatch. Journal of Energy Conversion and Management  49: 1407-1415.
  12. Bates J, Elbuluk ME, Zinger DS (1993) Neural Network Control of a Chopper Fed DC Motor. 24th Annual IEEE 20-24 Proceedings of IEEE Power Electronics Specialist Conference - PESC 93 pp: 893-899.
  13. JSR Jang (1993) ANFIS: Adaptive Network Based Fuzzy Inference System. IEEE Transactions on Systems, Man and Cybernetics 23: 665-685.
  14. Mohamed M, Ali I, Mohamed A, Hassan M (2012) Speed sensor less field-oriented control of a six-phase saturated model of induction motors drive with online stator resistance estimation using ANFIS in EPS. International Journal of Modelling, Identification and Control 17: 334-347.
Citation: Elsrogy WM, Bahgaat NK, El-Sayed, Hassan MA (2018) Speed Control of DC Motor Using PID Controller Based on Changed Intelligence Techniques. J Swarm Intel Evol Comp 7: 163.

Copyright: ©2018 Elsrogy WM, et al. This is an open-access article distributed under the terms of the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original author and source are credited.