×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Are you an
Engineering professional?
Join Eng-Tips Forums!
• Talk With Other Members
• Be Notified Of Responses
• Keyword Search
Favorite Forums
• Automated Signatures
• Best Of All, It's Free!

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

#### Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

# Determining first order process parameter

 Forum Search FAQs Links MVPs

## Determining first order process parameter

(OP)
Hello Peter,

You got the Impulse-reaction of the motor with an brake (to get a higher inertia - the braking effect is near zero). It was the green marked line at http://www.loaditup.de/345634.html

At this sheet I was astonished, that the curve of the impulse response didnt have a typical exponential behaviour.

As from the step experiment, I got the information, that the process amplification is about 4 and the time constant Tau was about 1s. You can see it at the upper curve of

Then I build a model under Scicos from the Motor controller and the motor with load and then I understand the result of the response impulse behaviour:

The current of the motor produces an "electrical torque". To get the net effective torque - which acellerates the inertia - you must subtract the "load torque" from the electrical torque. (Sometimes you will understand it better if you use the word friction instead torque).

The load torque consists ot three different types:

1. Type: Speed dependend torque. This type produces a linear (or more complex) speed dependend load torque. At speed = 0, the torque is zero.

This type is not the explanation for the impulse response. If the load torque is dominated by this type, the speed decreasing may not be almost linear - it must be exponential.

2. Type: Speed independent torque with torque at zero speed:
You got theis type e.g. with a fixed wheel with a spooled wire and a fixed mass. The result is a speed independent torque.
If the load is dominated by this type then the impulse response is the following: After the impulse, the motor has a certain speed. Now the electrical current is zero. We suppose, that the constant load torque is working in a way, that the motor begins to speed down. At any time the motor stops and is accellerated in the opposite direction - friven by the constant load torque of the wheel with mass. But because the "back electrc motoric force" (which is speed dependent) works against the accelleration and so the motor reaches a certain speed in the other direction a at the impulse. The motor reaches the speed limit, when the BEMF-force has the same amount as the load torque of the wheel/mass.
Because of the speed dependent BEMF, this change of the speed immediatelly after the impulse and the stationary speed in opposite direction has an exponential character.

But this load cant explain the measured impulse response. Because the motor decreases to speed 0 and stops.

3. Type: Speed independent torque with zero torque at zero speed. You get this load torque for example at a ideal disk brake. At zero speed, no torque is produced. It the disk of the brake has a speed > 0, a constant torque against the motor is produced.

This type of load torque is responsible for the shown impulse response. After the impulse, the decreasing speed behaviour is the same as at type 2. The important difference is, that at zero speed, the BEMF force of the motor reaches zero and the load torque of the disk brake reaches zero. The motor stops. (Only at type 2 the the fixed mass at the wire produces further torque and the motor speeds up in the oposite direction.)

I hope you understand what I tried to explain. As in the meantime written by you at sci.engr.control , the impulse response is the first part of a exponential curve with the stationary speed <> zero.

If you understand the principle - it would not be mantadory to send you the Scicos files. It you dont understand it after a longer time - please let me know and I send you the Scicos modell and the explanation of it.

After understanding I made a further impulse experiment: At first I gave an impulse for 120ms. then I reduced the current not to zero, but rather to a value that the motor speeds down. This fix current after the impuls was at always new experiments decreased until I got the limit that the motor stops and didnt rotate stationary. So I compensated the constant load torque.

And now look at the curve of the impuls result with the torque compensation:

And now you can see as at the step experiment:

1. Tau is about 1s
2. with h(t) = impulse response
k = amplification of the
first oder system G(s) = k/(1+s*T)
it is

k = integral (from 0 to infinite) of h(t) dt

And if I use this for evaluation of the impulse response, I get K = 4 !!!

So Tau and K is in this case the same as got by the step experiment.

Best regards

Wolfgang

### RE: Determining first order process parameter

Can you use K and tau in the gain calculation formulas and calculate gains that work?

It would be nice if you provided units for K.  It should be velocity/control output. It would be nice if you described better what the control is.

What are you going to do when the excitation can't be a step or impulse?

### RE: Determining first order process parameter

(OP)
Hello,
"Can you use K and tau in the gain calculation formulas and calculate gains that work?"

yes

K ist the quotient of velocity/current.

the Velocity is a value which is 8,192 times higher than the value in rpm

speed = 8,192*rpm

and current has the range from -32767 to 32767 which is physical about -7A ... 7A.

But I make the calculation, determination of K all with the "special values" and not in SI-Units.

But this doesn´t matter... If you make this consequent, the "behaviour" is the same. Its not mandatory to use SI-units.

The reason for using the impulse is the little need of revolutions for Autotuning. 80% of my applications have less freedom as 20 revolutions.

Wolfgang

### RE: Determining first order process parameter

Excellent, so are you going to find a more automated way of calculating K and tau or do you consider your project to be completed?

### RE: Determining first order process parameter

(OP)
Hello Peter,

sorry - but I saw your reply just now. I will yet test the parameter detection by a testdrive and the least-square-error methode to get the parameters Tau and K. I think this is your favourite...
Wolfgang

### RE: Determining first order process parameter

Actually I would use the Levenberg Marquardt algorithm.  The least squares algorithm is where I started but I ran into problems with it when trying to identify more complex systems. Least squares should should be good enough for a simple system and you will learn much.

Did you see my auto tuning video?  I have updated it with better encoding so the file is playable on VLC and is much smaller.

### RE: Determining first order process parameter

(OP)
Hello,
Im starting the discussion again. At first, I will recapitulate some points, we talked about in the past and they were not completely clear for me.

1. For calculating the PID-controler-gains you talked from a "Symbolic method" and the "Ackerman method". Further you said, that the symbolic method needs a high sample rate. So I think your "Symbolic method"  is a (in german) "quasi-time-continous" approach. The parameters are calculated as at a analogue OPA-based PID-Controller. That presumes, that the sampling rate is much higher than the signal-frequency of the system and the software PID-controller emulates this analogue PID.
.
Further I think the "Ackerman method" is based at a time discrete approach. That means, that the PID-controller must be based on a z-transformation time discrete system.

As for me, I use the "quasi-time-continous" approach, because I did nothing til today on a time discrete approch.

2. Back to the http://www.engin.umich.edu/group/ctm/PID/PID.html

a)At the PID section you made the approach K*lambda^3/(s+lambda)^3 for the CLTF

Why did you add the K? I expect that K must be 1?!?

3. In a older thread you suggested severals appoaches for the CE as:
a: (s+lamba)^3
b: ((s+a)^2+b^2)*(s+c)
c: (s+lambda)^2*(s+mu)
d: (s+lambda)*(s+mu)^2

Can you tell something about the characteristics of the four approaches?

4. You know my process of my work:
v-control: P(s) = K1/(s*T1 + 1)
s-control  P(s) = K2/((s*T1+ 1)*s)

The motor is a stepper motor with FOC by encoder feedback. Now if I use for v-control only a P-controller then there is a border of accoustic noise. If I further increase the P-Part, the motor "cries" terrible. The motor turning is superposed with a swinging of about 100Hz with a small amplitude. I tested if this is the resonance frequency of the rotor: I add clambs of the osci at the not powered motor taps and let it fall from a little height. The voltage swings then with also 100 Hz. So the problem is the resonance frequency of the rotor.
So if I calculate the PID-parameters, especially at s-control the D-Part causes this crying. At a first step I limited the D-Part. But sadly different motors have different D-Part limits of "crying". And if  I use the smalles D-Part of all motors then its too less for some drives and the process has a swinging tendence - naturally with much less frequency as 100 Hz.
a)So do you also have the problem with this rotor swinging?
b)Do you modell it for parameter determination?
c)Do you use a first order filter at the D-Part calculation for reducing high D-Part amplitudes?

Best regards and thank you for your help.   Wolfgang

### RE: Determining first order process parameter

1. Ackermann's method and the symbolic method will both yield the same result as the sample time approaches 0.  The difference between the Ackermann method and symbolic method is very small when the sample time is very small.  When the sample time is 1 millisecond the difference is insignificant.

2. The Closed Loop Transfer Function should have been  CLTF(s)=λ3/(s+λ)3.  There is no K.  In the CTM-PID example Ki=λ3.  The extra Kd and Kp terms in the numerator are also there in a normal motion control PID.  These introduce zeros that extend the bandwidth.

3.  Normally I just place all the closed loop poles on the negative real axis.  Most motion control people don't like overshoot and a critically damped response to a step change is preferred when not using a motion profile generator.

Another option is to use an over damped CE where the CE is either
(s+λ)2*(s+μ) or (s+λ)*(s+μ)2 which are the same thing. The reason why one would chose to use an over damped response is that you know that λ can not be reduced to less than α/3 when critically damped without calculated a negative Kd.

I have seen competitors that auto tune their systems to have a damping factor of about 0.8.  The speeds up the response a bit with little overshoot.  In this case the CE would be  (s+λ)*((s+a)2+b2) where a is the real part of a complex pair of poles and b is the imaginary part.

#### Quote:

4 The motor is a stepper motor with FOC by encoder feedback.
This part confuses me.  A stepper motor with FOC?  Are you sure you don't mean brushless DC motor with PWM control?
http://en.wikipedia.org/wiki/Stepper_motor
This is what a stepper motor is to me. Every pulse moves the motor a small fraction of a turn.

I have found that Europeans use the term Step controller which is actually what we would call a PWM controller.
https://www.infineonsamples.com/applicationkits/pdf/FOC_Application_Kit_brief.pdf

#### Quote:

a)So do you also have the problem with this rotor swinging?
No but we buy our amplifiers and pulse width modulated frequency is very high.  Too high for the motor to respond to even though they are low inertia motors.  Another problem may be low resolution feed back.   The motor also has poles it is sometime hard to get a motor to stop at one spot between the poles.

#### Quote:

b)Do you modell it for parameter determination?
We don't use a model to determine the PID gains.  We have a very good auto tuning program that calculates the PID gains. I believe you have seen the video.  If not then
http://www.deltamotion.com/peter/videos/AutoTuneMotor.mp4

#### Quote:

Do you use a first order filter at the D-Part calculation for reducing high D-Part amplitudes?
Yes.  We have a low pass filter on the output.  That effectively filters all the PID terms.  We don't filter the feed forwards.   We also have filters on the feedback/obsrevers that provide a much cleaned up state ( Position, Velocity and Acceleration, PVA ).   However, you can't use the observer technique until you can identify the system. I should make a video about filtering the feedback.

Delta Computer Systems
http://www.deltamotion.com

### RE: Determining first order process parameter

(OP)
1. Ackermann / symbolic method

#### Quote:

The difference between the Ackermann method and symbolic method is very small when the sample time is very small.  When the sample time is 1 millisecond the difference is insignificant.

So the Ackermann method is also applicable for the "quasi time-continious" PID-approach.

2. CLTF with K ...

#### Quote:

The Closed Loop Transfer Function should have been  CLTF(s)=λ3/(s+λ)3.  There is no K.

at 25.Ferb. you wrote:

#### Quote:

desired CLTF(s)= K*lamda^3/(s+lamba)^3 so the deisred characteristic
equation is...

This K above should be = 1. Do you agree?

3. CE for overdamped CLTF

#### Quote:

Another option is to use an over damped CE where the CE is either(s+λ)2*(s+μ) or (s+λ)*(s+μ)2 which are the same thing. The reason why one would chose to use an over damped response is that you know that λ can not be reduced to less than α/3 when critically damped without calculated a negative Kd.

So this approach ist for systems where a large T of the system response is needed.

4. Stepper with FOC

#### Quote:

A stepper motor with FOC?  Are you sure ... This is what a stepper motor is to me. Every pulse moves the motor a small fraction of a turn.

Yes - a stepper with FOC. Your stepper "view" is the "old" classical stepper use: The stepper is driven by a certain stepping frequency and the user "hopes" that no step is lost. But there are also new concepts for stepping motor drives: Put an encoder with sufficient high resolution to the stepper and you know the position of the rotor. Now you can set the rotfield in dependence of the rotor position. Naturally you need a driving electronics where you can realise a high res rotating magnetic field. So you can realuze a FOC with a stepper motor. You dont loose steps, there are no resonances and so on. With this technique the stepper has a behaviour as a good old DC-motor.

5. Crying motor

#### Quote:

So do you also have the problem with this rotor swinging?

#### Quote:

No but we buy our amplifiers and pulse width modulated frequency is very high.
I think the PWM frequency is not the problem at my system. The problem is the fact, that the rotor of the motor is a mechanical swinging system with about 100Hz. Now if the PID-controller outputs a signal with 100Hz, the rotor begins to swing. If you look at the motor, your eyes will see only a "normal rotation". But this rotation is overlayed by this 100Hz signal and the acoustic crying of the motor. Maybe the swinging influences also the encoder and so the rotfield and so the swinging is amplified.

6. Signal Filtering

#### Quote:

We have a low pass filter on the output.
you mean the PID output?

7. Back again to the sci-thread
At 6. March you wrote:

#### Quote:

What time constant?  The closed loop time constant is 1/lambda.

I wrote at 8. March:

#### Quote:

The closed loop transfer function of your approach is:
TFCL = lambda^3/(s + lambda)^3
TLTF = lambda^3/[s^3 + 3*lambda*s^2 + 3* lambda^2 * s + lambda^3]

if I ignore the higher order of s I get the CLTF_approx

CLTF_approx = lamda^3/[3*lambda^2*s + lambda^3]
= lamda^3/[lambda^3*((3/lambda)*s + 1]
= 1/[(3/lambda)*s + 1]

So the time constant is 3/lambda.

And thats right. I tested It with Scicos and the CLTF 30^3/(s + 30)^3 --> lambda = 30 --> time constant is 3s/30 = 0.1s
I will send you the Scicos file.

Best regards  Wolfgang

### RE: Determining first order process parameter

1  Yes, the Ackermann solution approaches the continuous symbolic solution as the sample time approaches 0.
2. Yes K=1
3. Yes.
4. OK, I will need to research that.
5. How fast do you close your loop?
6. I put a single pole low pass filter on the output of the PID.
The low pass filter pole can be 'merged' with the PID pole locations calculations.  This way you can take the low pass filter pole location into account when calculating the PID gains.

It is hot here 42C yesterday.  My reply is short because I am doing this at work where there is air conditioning.

Peter Nachtwey

l

Delta Computer Systems
http://www.deltamotion.com

### RE: Determining first order process parameter

It is cooler now and I can think.   Look at my continuous solution to the CTM PID problem.  This should be easy enough to follow but it not a motor control example.
http://www.engin.umich.edu/group/ctm/PID/PID.html
My solution
It should be clear that λ=cuberoot(K*Ki).  However there are still Kp and Kd terms in the numerator.  These extra terms add zeros to the closed loop transfer function and extend bandwidth.

Delta Computer Systems
http://www.deltamotion.com

#### Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

#### Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

#### Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!

Close Box

# Join Eng-Tips® Today!

Join your peers on the Internet's largest technical engineering professional community.
It's easy to join and it's free.

Here's Why Members Love Eng-Tips Forums:

• Talk To Other Members
• Notification Of Responses To Questions
• Favorite Forums One Click Access
• Keyword Search Of All Posts, And More...

Register now while it's still free!