Position tracking of DC motor with PID controller utilizing particle swarm optimization algorithm with Lévy flight and Doppler effect
Position tracking of DC motor with PID controller utilizing particle swarm optimization algorithm with Lévy flight and Doppler effect
Corresponding Author:
Nur Iffah Mohamed Azmi
Faculty of Manufacturing and Mechatronic Engineering Technology, Universiti Malaysia Pahang Al-
Sultan Abdullah
Pekan, Pahang, 26600, Malaysia
Email: [email protected]
1. INTRODUCTION
High-performance motor drives are experiencing rapid growth due to their diverse applications in
electric trains, robotics, household direct current (DC) appliances, biomedical equipment, and various
industrial sectors. DC motors are favored for their wide speed range, torque capacities exceeding 400% of
their rated value, superior speed regulation, and cost-effective control systems [1], [2]. One of the widely
used control methods for DC motors is the proportional-integral-derivative (PID) controller, known for its
simple design and dependable performance. However, PID controllers are vulnerable to system
unpredictability, which can lead to significant degradation in control performance, necessitating regular fine-
tuning to maintain optimal functionality [3]–[5].
In recent years, metaheuristic algorithms like particle swarm optimization (PSO), genetic algorithms
(GA), and adaptive neuro-fuzzy inference systems (ANFIS) have gained prominence for their efficiency and
effectiveness in solving complex optimization problems [6], [7], [8], [9]. The industry has shown significant
interest in the importance of metaheuristic PID tuning algorithms, which have demonstrated high
dependability over the last twenty years. PSO is a simple, easily implementable, and computationally
efficient concept, producing reliable results compared to other methods [10]–[13]. PSO is a metaheuristic
algorithm that maintains a balanced equilibrium between exploration and exploitation phases, enabling it to
converge towards promising areas in the search space [14]. PSO has more attractive attributes than
conventional evolutionary estimation methods, preserving memory, fostering collaboration, and facilitating
knowledge exchange among particles [15]. It can generate superior solutions within a limited timeframe with
a concise theoretical foundation and positive programming approach [16].
The proximity principle in PSO involves particles responding to quality factors simultaneously in both
their immediate surroundings and their optimal position. The stability principle allows swarms to modify the
environment only when individual or collective positions change, ensuring the continued pursuit of the best
position [17], [18]. The PSO algorithm stands out due to its flexible and well-coordinated mechanism,
enhancing global and local exploration abilities [19]–[21]. Optimization theory focuses on finding the best ways
to solve problems, including techniques, methods, processes, and algorithms. Engineers often deal with
optimization problems in various fields, such as modeling, characterization, and maintenance [22], [23]. Despite
advancements in swarm intelligence algorithms, achieving optimal performance in a DC motor with a PID
controller system requires a balance between exploration and exploitation processes. This research aims to
explore the application of PSO in PID controller tuning for DC motors, despite its widespread use. It aims to
provide insights into its advantages and limitations, addressing the lack of comprehensive analysis considering
different models, load conditions, and performance criteria in previous studies.
This study proposes a new method called particle swarm optimization with Lévy flight and Doppler
effect (PSO-LFDE) to enhance position control performance in a DC motor system with a PID controller.
The present study focuses on utilizing the PSO-LFDE algorithm to implement a DC motor with PID controller
for position control. The objective is to evaluate and compare the performance of DC motors through simulation
analysis in MATLAB Simulink. The mathematical model of the DC motor is derived using principles from
physics and electromagnetism. The PID controller is specifically engineered to accurately track and maintain
the position of the DC motor. An analysis is performed to assess the effectiveness of the PID controller in
precisely following the desired position during steady-state conditions. The subsequent sections of the paper are
organized as follows: Section 2.1 provides a detailed explanation of the mathematical model of the DC motor
coupled with the PID controller system. Section 2.2 focuses on the design of a PSO-LFDE algorithm. Section 3
examines the simulation results obtained in MATLAB. The conclusions are presented in Section 4.
2. METHOD
2.1. Mathematical model of DC motor
The mathematical model of a DC motor is derived by formulating equations that enhance our
understanding of its operation. The key variables include Ra, the armature resistance; La, the armature
inductance; ia, the armature current; and va, the input voltage. These quantities are measured in ohms (Ω),
Henries (H), amperes (A), and volts (V), respectively. In this model, the rotor is treated as a single coil
characterized by inductance (La) and resistance (Ra). Additionally, the back electromotive force (EMF),
which is the voltage generated across the DC motor during operation and is directly proportional to its speed,
must be considered. The voltage supplied to the armature can be independently adjusted from the voltage
supplied to the field. To derive the corresponding equation for this electric circuit, we first apply Kirchhoff's
voltage law (KVL) and Newton's second law of motion to the armature circuit diagram, leading to the
differential equation (1) to (3) for the armature circuit.
𝑑𝑖𝑎 (𝑡)
𝑣𝑎 (𝑡) = 𝑖𝑎 (𝑡)𝑅𝑎 + 𝐿𝑎 + 𝑣𝑏 (𝑡) (1)
𝑑𝑡
𝑑𝜃
𝑣𝑏 (𝑡) ∝ 𝜔(𝑡) ⇒ 𝑣𝑏 (𝑡) = 𝑘𝐸 = 𝑘𝐸 𝜔(𝑡) (2)
𝑑𝑡
𝑑 2 𝜔(𝑡) 𝑑𝜔
𝑇(𝑡) = 𝐽 +𝑏 = 𝑘 𝑇 𝑖𝑎 (𝑡) (3)
𝑑𝑡 2 𝑑𝑡
The induced voltage vb represents the EMF and the symbol kE represents the constant of electromotive force.
The EMF equation may be derived by using Faraday's law of induction and taking into account the angular
velocity. The variables in the equation are as follows: T(t) represents the motor torque, and J represents the
moment of inertia of the motor shaft. The torque equation is derived from the mechanics of a motor,
specifically when angular velocity is given by ω(t). The viscous frictional coefficient and torque constants of
IAES Int J Rob & Autom, Vol. 14, No. 1, March 2025: 67-73
IAES Int J Rob & Autom ISSN: 2722-2586 69
the motor are denoted by the correspondence b and kT, respectively. By using the Laplace transform and
assuming zero starting conditions for (1Error! Reference source not found.) to (3), we get (4) to (6).
Replacing the equation represented by (5) in (4) and simplifying (4) and (6) yields (7) and (8).
1 𝑘𝑇
𝜔(𝑠) = 𝑇(𝑠) = 𝐼 (𝑠) (8)
𝑠𝐽 + 𝑏 𝑠𝐽 + 𝑏 𝑎
Algorithm 1. Particle swarm optimization with Lévy flight and the Doppler effect
Begin
for each particle in the swarm
Initialize its position and velocity randomly
end for
while iter < max_iter do
for each particle, j do
Update velocity with the Doppler Effect equation replaces the inertia weight equation.
( ) ( )
v j , g = dev j , g + c1r1 pbest j . g − s j , g − c2 r2 gbest j . g − s j , g
k +1 k k k
Position tracking of DC motor with PID controller utilizing particle swarm … (Nur Iffah Mohamed Azmi)
70 ISSN: 2722-2586
the DC motor with a PID controller system for position control utilizing the PSO-LFDE algorithm in the
Simulink block diagram.
Figure 1. Simulink model of DC motor with PID controller system for position control
The performance evaluation results collected for the proposed algorithms are compared with those
of other fundamental optimization algorithms. The evaluation focused on four key time-domain
specifications: settling time, rise time, overshoot, and steady-state error. The performance evaluation is
graphically depicted in Figure 2 for all set points with the numerical results presented in Table 2.
Table 2. Optimum values obtained by PSO-LFDE with four different methods at step inputs 10 cm, 30 cm,
and 60 cm
10 cm 30cm 60cm
Best Mean Worst σ Best Mean Worst σ Best Mean Worst σ
PSO-LFDE 0.2224 0.2381 0.2604 0.0101 0.2119 0.2309 0.2616 0.0132 0.2002 0.2097 0.2505 0.014062
PSO 0.3148 0.3172 0.3194 0.0021 0.2879 0.2898 0.2919 0.0019 0.2553 0.2567 0.2581 0.001453
WOA 1.2622 3.3372 7.5143 1.7487 1.1794 3.0917 5.9886 1.5697 0.4325 2.7734 8.7769 1.771845
GWO 0.2882 0.3032 0.3184 0.0134 0.2881 0.3031 0.3192 0.0140 0.2553 0.2606 0.3630 0.019774
MFO 0.3156 0.3167 0.3168 0.0004 0.2879 0.2879 0.2880 1.09e-05 0.2553 0.2563 0.2653 0.003039
The analysis of the PSO-LFDE algorithm showed significant improvements in key metrics:
− Rise time: for a 10 cm step input, PSO-LFDE achieved a rise time of 0.1733 seconds, outperforming the
MFO method by 41.63%. In comparison, PSO, WOA, and GWO methods had risen times of 0.2941,
0.1857, and 0.2951 seconds, respectively.
− Settling time: PSO-LFDE achieved a settling time of 0.2644 seconds, far outperforming PSO, which
required 2.000 seconds. WOA and GWO achieved settling times of 0.3189 and 2.0000 seconds,
respectively.
− Peak time: The PSO-LFDE algorithm recorded a peak time of 0.3304 seconds, 70.20% faster than PSO
(1.1089 seconds). WOA, GWO, and MFO recorded peak times of 0.8860, 1.1127, and 1.1287 seconds,
respectively.
These findings demonstrate that the PSO-LFDE algorithm significantly enhances the dynamic response of
the DC motor with the PID controller system, particularly in optimizing rise time, settling time, and peak
time. The study underscores the superior performance of PSO-LFDE in real-world control system
applications, surpassing traditional optimization techniques. This work highlights the novelty and practical
value of PSO-LFDE as a robust solution for optimizing PID controllers in DC motor systems.
IAES Int J Rob & Autom, Vol. 14, No. 1, March 2025: 67-73
IAES Int J Rob & Autom ISSN: 2722-2586 71
Figure 2. Step response for position control performance of a DC motor with PID controller
Position tracking of DC motor with PID controller utilizing particle swarm … (Nur Iffah Mohamed Azmi)
72 ISSN: 2722-2586
4. CONCLUSION
This study successfully implemented the PSO-LFDE algorithm to optimize the control parameters
of a DC motor with a PID controller system. Through extensive simulations using MATLAB/Simulink, the
performance of the proposed PSO-LFDE algorithm is thoroughly evaluated and compared against other
established optimization methods, including PSO, WOA, GWO, and MFO. The results demonstrated that
PSO-LFDE significantly outperforms the competing algorithms in terms of key time-domain performance
metrics such as rise time, settling time, and peak time. Specifically, PSO-LFDE exhibited faster response
times and superior stability, indicating its effectiveness in optimizing the dynamic behavior of the DC motor
with PID controller. The findings validate the PSO-LFDE algorithm as a robust and efficient optimization
technique, capable of achieving improved control performance in real-world applications. The study
highlights the algorithm's ability to balance exploration and exploitation in search space, avoiding premature
convergence and ensuring global optimization. Consequently, the PSO-LFDE algorithm represents a valuable
advancement in optimizing PID controllers for DC motor systems and holds great potential for broader
applications in control systems engineering.
ACKNOWLEDGEMENTS
The authors express their gratitude to the Ministry of Higher Education for the financial support
received through the UMPSA Internal Grant (University Reference RDU240309) and to Universiti Malaysia
Pahang Al-Sultan Abdullah for providing lab facilities.
REFERENCES
[1] D. Barkas, G. C. Ioannidis, C. Psomopoulos, S. D. Kaminaris, and G. Vokas, “Brushed DC motor drives for industrial and
automobile applications with emphasis on control techniques: A comprehensive review,” Electronics, vol. 9, p. 887, 2020, doi:
10.3390/electronics9060887.
[2] S. P. Simon, L. Dewan, and M. P. R. Prasad, “Design and analysis of ITAE tuned robust PID controller for brushed DC motor,” in
2022 IEEE Silchar Subsection Conference, SILCON 2022, 2022, pp. 1–6. doi: 10.1109/SILCON55242.2022.10028938.
[3] S. Pandey, “Optimization of PID controller parameters for speed control of DC motor using firefly and fminsearch algorithms,”
SSRN Electronic Journal, pp. 1–9, 2023, doi: 10.2139/ssrn.4378784.
[4] Z. Qi, Q. Shi, and H. Zhang, “Tuning of digital PID controllers using particle swarm optimization algorithm for a CAN-Based DC
motor subject to stochastic delays,” IEEE Transactions on Industrial Electronics, vol. 67, no. 7, pp. 5637–5646, 2020, doi:
10.1109/TIE.2019.2934030.
[5] A. Abdulameer, M. Sulaiman, M. S. M. Aras, and D. Saleem, “Tuning methods of PID controller for DC motor speed control,”
Indonesian Journal of Electrical Engineering and Computer Science, vol. 3, no. 2, pp. 343–349, 2016, doi:
10.11591/ijeecs.v3.i2.pp343-349.
[6] L. F. Fraga-Gonzalez, R. Q. Fuentes-Aguilar, A. Garcia-Gonzalez, and G. Sanchez-Ante, “Adaptive simulated annealing for
tuning PID controllers,” AI Communications, vol. 30, pp. 347–362, 2017, doi: 10.3233/AIC-170741.
[7] S. B. Joseph, E. G. Dada, A. Abidemi, D. O. Oyewola, and B. M. Khammas, “Metaheuristic algorithms for PID controller
parameters tuning: Review, approaches and open problems,” Heliyon, vol. 8, no. 5, p. e09399, 2022, doi:
10.1016/j.heliyon.2022.e09399.
[8] B. Allaoua, B. Gasbaoui, and B. Mebarki, “Setting up PID DC motor speed control alteration parameters using particle swarm
optimization strategy,” Leonardo Journal of Practices and Technologies, no. 14, pp. 19–32, 2009, doi:
10.2174/978160805126711201010003.
[9] W. M. Elsrogy, M. A. Fkirin, and M. A. M. Hassan, “Speed control of DC motor using PID controller based on artificial
intelligence techniques,” in 2013 International Conference on Control, Decision and Information Technologies (CoDIT),
Hammamet, Tunisia, 2013, pp. 196–201. doi: 10.1109/CoDIT.2013.6689543.
[10] E. S. Rahayu, A. Ma’arif, and A. Cakan, “Particle swarm optimization (PSO) tuning of PID control on DC motor,” International
Journal of Robotics and Control Systems, vol. 2, no. 2, pp. 435–447, 2022, doi: 10.31763/ijrcs.v2i2.476.
[11] H. Feng, W. Ma, C. Yin, and D. Cao, “Trajectory control of electro-hydraulic position servo system using improved PSO-PID
controller,” Automation in Construction, vol. 127, p. 103722, 2021, doi: https://doi.org/10.1016/j.autcon.2021.103722.
[12] A. K. Kashyap and D. R. Parhi, “Particle swarm optimization aided PID gait controller design for a humanoid robot,” ISA
Transactions, vol. 114, pp. 306–330, 2021, doi: 10.1016/j.isatra.2020.12.033.
[13] Z. Xiang, D. Ji, H. Zhang, H. Wu, and Y. Li, “A simple PID-based strategy for particle swarm optimization algorithm,”
Information Sciences, vol. 502, pp. 558–574, 2019, doi: 10.1016/j.ins.2019.06.042.
[14] F. Rezaei and H. R. Safavi, “GuASPSO: a new approach to hold a better exploration–exploitation balance in PSO algorithm,” Soft
Computing, vol. 24, no. 7, pp. 4855–4875, 2020, doi: 10.1007/s00500-019-04240-8.
[15] J. Nayak, H. Swapnarekha, B. Naik, G. Dhiman, and S. Vimal, “25 years of particle swarm optimization: Flourishing voyage of
two decades,” Archives of Computational Methods in Engineering, vol. 30, no. 3, pp. 1663–1725, Apr. 2023, doi:
10.1007/s11831-022-09849-x.
[16] A. J. Malik, W. Shahzad, and F. A. Khan, “Network intrusion detection using hybrid binary PSO and random forests algorithm,”
Security and Communication Networks, vol. 5, no. 4, pp. 422–437, 2012, doi: 10.1002/sec.
[17] A. J. Mohammed, “A particle swarm optimization (PSO) based optimum of tuning PID controller for a separately excited DC
motor (SEDM),” Engineering and Technology Journal, vol. 29, no. 16, pp. 3331–3344, 2011, doi: 10.30684/etj.29.16.7.
[18] L. Xu-zhou, Y. Fei, and W. You-bo, “PSO algorithm based online self-tuning of PID controller,” in 2007 International
Conference on Computational Intelligence and Security, CIS, 2007, pp. 128–132. doi: 10.1109/CIS.2007.188.
[19] N. Mat Yahya and M. N. Osman Zahid, “Application of adaptive bats sonar algorithm for solving a single objective of practical
business optimisation,” E-Journal of Artificial Intelligence & Computer Science, vol. 4, pp. 1–13, 2016.
IAES Int J Rob & Autom, Vol. 14, No. 1, March 2025: 67-73
IAES Int J Rob & Autom ISSN: 2722-2586 73
[20] T. M. Shami, A. A. El-Saleh, M. Alswaitti, Q. Al-Tashi, M. A. Summakieh, and S. Mirjalili, “Particle swarm optimization: A
comprehensive survey,” IEEE Access, vol. 10, pp. 10031–10061, 2022, doi: 10.1109/ACCESS.2022.3142859.
[21] D. Sedighizadeh, E. Masehian, M. Sedighizadeh, and H. Akbaripour, “GEPSO: A new generalized particle swarm optimization
algorithm,” Mathematics and Computers in Simulation, vol. 179, pp. 194–212, 2021, doi: 10.1016/j.matcom.2020.08.013.
[22] S. M. GirirajKumar, D. Jayaraj, and A. R. Kishan, “PSO based tuning of a PID controller for a high performance drilling
machine,” International Journal of Computer Applications, vol. 1, no. 19, pp. 12–18, 2010, doi: 10.5120/410-607.
[23] D. Chen, G. Zhang, and C. Yao, “PSO algorithm based PID parameters optimization of hydraulic screwdown system of cold strip
mill,” in Proceedings of 2011 International Conference on Fluid Power and Mechatronics, Beijing, China, 2011, pp. 113–116.
doi: 10.1109/FPM.2011.6045740.
[24] M. M. Mafarja, R. Jarrar, S. Ahmad, and A. A. Abusnaina, “Feature selection using binary particle swarm optimization with time
varying inertia weight strategies,” 2018. doi: 10.1145/3231053.3231071.
[25] N. Mat Yahya, “Improvement of the feedback control system performance by optimizing the PID controller parameters using the
particle swarm optimization algorithm,” (in Malaysian: Peningkatan prestasi sistem pemacu suap balik dengan mengoptimumkan
parameter pengawal PID menggunakan algoritma pengoptimuman kawanan partikel) M.S. Thesis, FKP UMPSA, Pahang,
Malaysia, 2009.
BIOGRAPHIES OF AUTHORS
Nafrizuan Mat Yahya graduated with his first degree from the Universiti
Sains Malaysia, in Manufacturing Engineering with Management. He then obtained his
Master of Engineering (Manufacturing) from Universiti Malaysia Pahang and his Ph.D. in
automatic control and systems engineering from the University of Sheffield, UK. His
interests include bio-inspired computation intelligence, control system optimization,
intelligent manufacturing automation, and ergonomics for industrial applications. He is also a
professional technologist of the Malaysia Board of Technologists (MBOT). He can be
contacted at [email protected].
Position tracking of DC motor with PID controller utilizing particle swarm … (Nur Iffah Mohamed Azmi)