Вы находитесь на странице: 1из 3

Created by Simpo PDF Creator Pro (unregistered version)

http://www.simpopdf.com

Implementation and Analysis of PID Controller in


Simulink of MATLAB for DC Motor
M. Umer Shehzad1
1Department

Of Electronics Engineering
The Islamia University of Bahawalpur
1

breakker.2010@hotmail.com

Abstract This paper contains the simulations and analysis of PID


Controller when it implemented with DC Motor .The Response of a
DC Motor Without an PID controller is very poor that is it does not
get steady state in a very short time .So in this paper we implement a
PID controller to Drive a DC Motor Efficiently with a very small
transient time and with greater speed .We also discuss the tuning of
PID controller in Simulink.
Keywords Matlab , PID , Tuning , DC Motor , Step Response

I. INTRODUCTION
DC Motors play a vital role in our daily life .There is no
industry in the world which is operated without a Motor. So
Controlling of DC Motor is a major task of Control Engineer
before the invention of PID Controller DC Motor cannot be
operated in a Good manner mean we face many losses of power
and even then cannot achieve a good speed of DC Motor. So a
PID Controller is Introduce to overcome is this problem. PID
Controller is a Combination of Proportional, Integrator and
Derivation Controller .Each one has individual features and can
be implemented individually for specific Application .We will
discuss each controller in this paper and implementation in
Simulink and then method of tuning of PID controller.
II. PID CONTROLLER
PID is a Combination of Proportional, Integrator and
Derivative Controller. This three controller can be used
individually because each has specific properties and features.
The Proportional Controller is mainly used to minimize the
error produced in feedback loop system. The error produced is
multiply with Proportional Controller constant due to which it
will minimize but not totally eliminated. The second controller
that is integrator controller is used to integrate all previous error
and when it combine with Proportional controller then it will
capable to almost eliminate the residual error to achieve the set
point that can never be achieve by individual Proportional
Controller . The third Controller which is Derivative Controller
is used to give initial kick to motor to start rapidly. The Three
Controller is used in parallel form to derive and control the DC
Motor as shown in figure1.

Figure1
III. DC MOTOR
The DC Motor we used in this paper has specific parameters
whose transfer function is calculated in MATLAB .
DC Motor Specification
100 rad/sec
Operating Speed
Maximum Armature Current
1A
Voltage Constant
10VS/rad
5Nm/A
Torque Constant
Friction Torque
0.5 Nm
Armature Resistance
50
Armature Inductance
5H
Armature Moment of Inertia
2Nms2/rad
Armature Viscous Friction
0.1 NMs/rad
Mechanical Time Constant
20sec
0.1sec
Electrical Time Constant

When we enter following parameters then we will get the


Voltage Driven Transfer Function of DC Motor [1].

When This Transfer Function is implement in Simulink without


a PID Controller then we observe following step Response.

Step Input
Motor Response

Time
Figure2

Created by Simpo PDF Creator Pro (unregistered version)


http://www.simpopdf.com
IV. SIMULINK MODEL
The Simulink Model Of Parallel PID Controller is can be
implemented by following figure3.

Figure3.
This is Parallel PID controller when we double click on PID
box in Simulink then a following Window figure4 will appear
from which we can see the option of Parallel PID Controller.

Figure6.
After tuning we get the following Step Response as shown
in Figure7.
Step Input

Kp=153.9
11

Figure4.
V. SIMULATION AND ANALYSIS OF DC MOTOR TRANSFER
FUNCTION IN SIMULINK
In this section we will one by one analyse the response of
proportional integrator and derivative controller with suitable
constants of controller and then tune each controller and then
observe the response of controller by replacing previous
constant with calculated constants of PID by Simulink.
A. Proportional Controller
The Proportional controller is implement by the same
procedure which was discuss and show in fig3. When
Proportional Controller is Simulate without tuning then its step
response is shown in fig5.

Motor Response

Figure7.
From the result the purple line show the response of a motor
to step input when we tune the proportional controller to a such
value at which motor responed very good mean get a set point
approximately within very short time.
B. Proportional-Integral Controller
When we combine the proportional-integral (PI) Controller
then it is capable to eliminate the residual error.
The Response of Integral Controller to Step Input is shown
in figure8.
Step Input
Motor Response

Kp=0.5 ki=0.3
Step Input
Kp=.5

Motor Response

Figure5.
As it can be seen from the step response that a proportional
controller with a kp=.5 does not give a good response of a DC
motor so we tune this controller by built in function of simulink
as shown below in figure6.

Figure8.
As it can be seen that it does not achieve a set point because
the controller constants is not compatible for the DC motor
specifications. So we Tune the PI controller and then we
observe the following Results as shown below in fig9.

Created by Simpo PDF Creator Pro (unregistered version)


http://www.simpopdf.com

Step Input

Step Input

Motor Response

Motor Response
Kp=6.02 ki=9.72

Kp=18.42 ki=13.43 kd=-9.90


FIGURE9.

From the above result we can see that the dc motor achieve
its set point in a very short time with a very short transient delay.

Figure11.
Conclusion
C. PID Controller
When we drive a DC Motor withou any Controller then the
Now we implement the combination of all three controller efficiency of motor is very bad and it can be clear from fig2
that is Proportional-Integral-Derivative (PID) Controller. The when we apply the step input to the transfer function of DC
Alone Derivative Controller is not used because it give a rapid motor then shows very poor response with a very low amplitude
thrust to a system due to which a system becomes unstable it here amplitude mean its speed in rad/sec. So we feel a some
sometimes combines with Proportional Controller(PD) for rare sort of controller which would increase its efficiency as well as
applications. This Three Controller are combine in a parallel its speed . So we introdude a PID Controller and observe the
form just like in fig1. In Simulink we a box of PID Controller effects of individual P PI and PID controller and plot its graphs
in which this three controller already combine in a parallel form. for general Constants values and observe that we have to tune
The Step Response of a DC motor without tuning of PID is its value so that the step response of a DC motor can be improve
so we use a automatic tuning option in simulink which calculate
shown in fig10.
its controller constants for a specific parameters and conditions
of DC Motor. When we apply this tuned constants of PID
controller the we get a very good step response as shown in
fig11.So we can say that PID controller is a very important
controller to control a DC motor.
Step Input
Motor Response
Kp=.5 ki=.3 kd=.2

ACKNOWLEDGMENT
I am especially thankful to my father Shehzad Sami Khan and
mother Mrs .Shehzad for their efforts to facilitate and provide
us with most suitable environment for research and
development.
I would also like to thank my Sir Bilal Shahid for their sincere
help and prayers.

Figure10.
REFERENCES
From The Result we can see the effect of PID controller initially
there is a small kick of derivative and then the PI Controller
start to achieve set point but the whole process is very slow
because the given parameters of DC motor is compatible with
Controller constants. So we tune this PID controller then we get
the following results as shown below in figure11.
From the fig11 it can be seen that a Motor achieve its set point
in a very short time with a very small transient response .Hence
we have proved that with a proper tuning of PID controller
constant we can increase the efficiency and performance of a
DC Motor .All calculation of controller constant can be easily
done in Simulink and can be implemented on hardware as well.

[1]

http://www.mathworks.com/matlabcentral/fileexchange/10853-dcmotor-transfer-function by Taptej file id# 10853


M. Umer Shehzad Born in Bahawalpur the
city of Creators on 29th April 1992. Doing
Electronics Engineering from The Islamia
University of Bahawalpur. Major Fields of
study is control system, Antenna Theory and
Design, Digital signal processing and
Engineering Management.

Вам также может понравиться