Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
Tuning PID parameters of DC motor speed control using Ziegler Nicholas method

Subject: Tuning PID parameters of DC motor speed control using Ziegler Nicholas method

From: dfgdg dfgdfg

Date: 23 Dec, 2010 14:35:20

Message: 1 of 12

Is it impossible to implement a dc motor speed control using closed loop ziegler nicholas method? For some transfer function I used ziegler nicholas method but I couldn't determine the PID parameters for DC motor speed control.Could you propose anything for this operation?
Thanks.

Subject: Tuning PID parameters of DC motor speed control using Ziegler Nicholas method

From: dfgdg dfgdfg

Date: 23 Dec, 2010 20:30:25

Message: 2 of 12

And my transfer fuction is;
                1
-------------------------------------
       s^2 + 14s + 40.02
I couldn't find the PID parameters using Ziegler-Nichols method(closed loop).

Where is my mistake?Could you propose anything???
Thanks.

Subject: Tuning PID parameters of DC motor speed control using Ziegler Nicholas method

From: dfgdg dfgdfg

Date: 24 Dec, 2010 09:36:05

Message: 3 of 12

Am I writing unreasonable things that are impossible to implement in Simulink?

Subject: Tuning PID parameters of DC motor speed control using Ziegler Nicholas method

From: rajasekhara reddy

Date: 24 Dec, 2010 11:03:04

Message: 4 of 12

"dfgdg dfgdfg" wrote in message <ievmn8$g91$1@fred.mathworks.com>...
> Is it impossible to implement a dc motor speed control using closed loop ziegler nicholas method? For some transfer function I used ziegler nicholas method but I couldn't determine the PID parameters for DC motor speed control.Could you propose anything for this operation?
> Thanks.
Hi
I think it is not possible to design PID controller using ziegler nicholas method(closed loop) for a second order process and the order should not be less than 3 to design PID controller

Subject: Tuning PID parameters of DC motor speed control using Ziegler

From: Walter Roberson

Date: 24 Dec, 2010 16:55:37

Message: 5 of 12

On 24/12/10 3:36 AM, dfgdg dfgdfg wrote:
> Am I writing unreasonable things that are impossible to implement in
> Simulink?

Most of the regular posters do not have experience in Simulink, and not
many people answer questions about transfer functions. Also, a lot of
people are busy preparing for Christmas.

Myself, I have no idea whether the answer to your question is trivial or
difficult or impossible... sorry.

Subject: Tuning PID parameters of DC motor speed control using Ziegler

From: dfgdg dfgdfg

Date: 25 Dec, 2010 06:50:05

Message: 6 of 12

If you have no idea for the answer,you don't have to write something that is not useful for anybody.Here is MATLAB&Simulink user community and many people have experience in Simulink.
Walter Roberson <roberson@hushmail.com> wrote in message <eg4Ro.63647$wf4.32796@newsfe05.iad>...
> On 24/12/10 3:36 AM, dfgdg dfgdfg wrote:
> > Am I writing unreasonable things that are impossible to implement in
> > Simulink?
>
> Most of the regular posters do not have experience in Simulink, and not
> many people answer questions about transfer functions. Also, a lot of
> people are busy preparing for Christmas.
>
> Myself, I have no idea whether the answer to your question is trivial or
> difficult or impossible... sorry.

Subject: Tuning PID parameters of DC motor speed control using Ziegler

From: Walter Roberson

Date: 25 Dec, 2010 17:23:18

Message: 7 of 12

On 25/12/10 12:50 AM, dfgdg dfgdfg wrote:
> If you have no idea for the answer,you don't have to write something
> that is not useful for anybody.Here is MATLAB&Simulink user community
> and many people have experience in Simulink.

You posted a question about why you are not getting an answer to your
issue. I answered that question based upon my several years of
experience with this electronic resource.

Is it not of benefit to you to know that, in general, most Simulink
questions go unanswered, and that there are very few posters who
consistently answer Simulink questions? Flip the matter around: if I had
informed you that (hypothetically) most Simulink questions got answered
quickly, would that not have given you evidence that perhaps your
question was difficult or impossible? And thus by my informing you of
the opposite, that few Simulink questions get answered, let alone
quickly, does that not give you grounds for continuing to hope that
there is a solution?

The part where I said that I myself do not know: if I had just told you
that Simulink questions seldom get answered, would you not have been
left in doubt as to whether I could have instead answered the question
"if I could be bothered" ?

I gave you information which helps you manage your expectations about
receiving an answer to your question. If you consider that kind of
information to "not be useful", then you should probably find a support
resource in which people are obliged to answer rather than being volunteers.

Subject: Tuning PID parameters of DC motor speed control using Ziegler

From: Walter Roberson

Date: 25 Dec, 2010 17:37:43

Message: 8 of 12

On 23/12/10 8:35 AM, dfgdg dfgdfg wrote:
> Is it impossible to implement a dc motor speed control using closed loop
> ziegler nicholas method? For some transfer function I used ziegler
> nicholas method but I couldn't determine the PID parameters for DC motor
> speed control.Could you propose anything for this operation?
> Thanks.

Without having read the following paper in detail, it seems to me that
the paper indicates that what you want to do is possible.

http://umpir.ump.edu.my/413/1/Mohd_Azri_Bin_Abd_Mutalib_3244.pdf

Subject: Tuning PID parameters of DC motor speed control using Ziegler Nicholas method

From: Frank W.

Date: 26 Dec, 2010 10:53:04

Message: 9 of 12

"dfgdg dfgdfg" wrote in message <ievmn8$g91$1@fred.mathworks.com>...
> Is it impossible to implement a dc motor speed control using closed loop ziegler nicholas method? For some transfer function I used ziegler nicholas method but I couldn't determine the PID parameters for DC motor speed control.Could you propose anything for this operation?
> Thanks.

In newer releases of Simulink there is the PID block which allows autotuning. The control toolbox offers sophisticated methods for evaluating controls. So from the Matlab/Simulink side everything is there.
What btw have you done so far concerning Ziegler Nichols? What where the PID parameters you have found?

Subject: Tuning PID parameters of DC motor speed control using Ziegler Nicholas method

From: Arkadiy Turevskiy

Date: 28 Dec, 2010 19:59:07

Message: 10 of 12

Can I ask why you have to use Ziegler-Nichols?
We specifically added pid tuning capabilities to Simulink Control Design in R2009b and Control System Toolbox in R2010b to handle cases when Ziegler-Nichols does not work or does not provide good design.

To get good PID design with Control System Toolbox in R2010b:

>>s=tf('s');
>>sys=1/(s^2+14*s+40.02); % plant tf
>>pidtool(sys) % launch pid tuner tool

Now use the slider and various options to get good design. For example, if you just take the initial design that the tool comes up with, you get a PI controller with
Kp = 76.7
Ki=280

To check this design, evaluate this in MATLAB:

controller=pid(76.7, 280); % create PI controller
closed_loop=feedback(controller*sys,1); % compute closed-loop tf
step(closed_loop); % plot step response

If you insisit on using Ziegler-Nichols:

>>sisotool(sys);

then:
1)In the GUI that opens up, go to Automated Tuning tab, select "PID Tuning" under "Design Methods".
2) Select "PID" under controller type.
3) Under "Tuning method", select "Classical design formulas", and
4) under "Formula" select "Ziegler-Nichols step response"
5) Press "Update Compensator".

This gives you this PID design:
Kp=415.41
Ki=4929.8
Kd=8.75

To check its step response evaluate the code below in MATLAB:

controller_zn=pid(415.41,4929.8,8.75); % ziegler-nichols design
hold on;
step(feedback(controller_zn*sys,1),'r'); % step response for ZN design

The red line is Ziegler-Nichols design, blue line is Robust response time (MathWorks' tuning algorithm). If you want to make the design faster, you can use GUI you launch with PID tool to tune for faster response. For example, I got the following design which is as fast as Ziegler-Nichols, but is very stable with little overshoot and no oscillations:

Kp=449;
Ki=1707;
Kd=21.6;

To see its step response (green line).

controller_fast=pid(449,1707,21.6);
step(feedback(controller_fast*sys,1),'g');

HTH.
Arkadiy


"Frank W." <yohansan_nospam@web.de> wrote in message <if76qg$gou$1@fred.mathworks.com>...
> "dfgdg dfgdfg" wrote in message <ievmn8$g91$1@fred.mathworks.com>...
> > Is it impossible to implement a dc motor speed control using closed loop ziegler nicholas method? For some transfer function I used ziegler nicholas method but I couldn't determine the PID parameters for DC motor speed control.Could you propose anything for this operation?
> > Thanks.
>
> In newer releases of Simulink there is the PID block which allows autotuning. The control toolbox offers sophisticated methods for evaluating controls. So from the Matlab/Simulink side everything is there.
> What btw have you done so far concerning Ziegler Nichols? What where the PID parameters you have found?

Subject: Tuning PID parameters of DC motor speed control using Ziegler Nicholas method

From: MrKhanh Le

Date: 7 Jun, 2011 14:34:04

Message: 11 of 12

"Arkadiy Turevskiy" wrote in message <ifdfib$jno$1@fred.mathworks.com>...
> Can I ask why you have to use Ziegler-Nichols?
> We specifically added pid tuning capabilities to Simulink Control Design in R2009b and Control System Toolbox in R2010b to handle cases when Ziegler-Nichols does not work or does not provide good design.
>
> To get good PID design with Control System Toolbox in R2010b:
>
> >>s=tf('s');
> >>sys=1/(s^2+14*s+40.02); % plant tf
> >>pidtool(sys) % launch pid tuner tool
>
> Now use the slider and various options to get good design. For example, if you just take the initial design that the tool comes up with, you get a PI controller with
> Kp = 76.7
> Ki=280
>
> To check this design, evaluate this in MATLAB:
>
> controller=pid(76.7, 280); % create PI controller
> closed_loop=feedback(controller*sys,1); % compute closed-loop tf
> step(closed_loop); % plot step response
>
> If you insisit on using Ziegler-Nichols:
>
> >>sisotool(sys);
>
> then:
> 1)In the GUI that opens up, go to Automated Tuning tab, select "PID Tuning" under "Design Methods".
> 2) Select "PID" under controller type.
> 3) Under "Tuning method", select "Classical design formulas", and
> 4) under "Formula" select "Ziegler-Nichols step response"
> 5) Press "Update Compensator".
>
> This gives you this PID design:
> Kp=415.41
> Ki=4929.8
> Kd=8.75
>
> To check its step response evaluate the code below in MATLAB:
>
> controller_zn=pid(415.41,4929.8,8.75); % ziegler-nichols design
> hold on;
> step(feedback(controller_zn*sys,1),'r'); % step response for ZN design
>
> The red line is Ziegler-Nichols design, blue line is Robust response time (MathWorks' tuning algorithm). If you want to make the design faster, you can use GUI you launch with PID tool to tune for faster response. For example, I got the following design which is as fast as Ziegler-Nichols, but is very stable with little overshoot and no oscillations:
>
> Kp=449;
> Ki=1707;
> Kd=21.6;
>
> To see its step response (green line).
>
> controller_fast=pid(449,1707,21.6);
> step(feedback(controller_fast*sys,1),'g');
>
> HTH.
> Arkadiy

I am using MATLAB R2010a then I couldn't follow your instruction.
I wonder that we can apply Ziegler-Nichols method for this case.
Mr. Arkadiy, may you give me some more comments?

Subject: Tuning PID parameters of DC motor speed control using Ziegler Nicholas method

From: Arkadiy Turevskiy

Date: 7 Jun, 2011 14:53:04

Message: 12 of 12

Yes,
you can tune PID controllers using our algorithm (Robust response time) or Ziegler-Nichols in R2010a. Please read through this doc section for how to do that:
http://www.mathworks.com/help/releases/R2010a/toolbox/control/quick/f2-1033890.html#f2-1034877
Arkadiy

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us