Why Is My MATLAB Steady State Error Different from Manual Calculation?

Click For Summary

Discussion Overview

The discussion revolves around the calculation of steady state error for a control system using MATLAB and manual methods. Participants explore the differences between the MATLAB output and their own calculations, focusing on the implications of system stability and the application of the final value theorem.

Discussion Character

  • Technical explanation
  • Mathematical reasoning
  • Debate/contested

Main Points Raised

  • One participant reports a steady state error of 0.1128 calculated using MATLAB but is unsure about the calculation steps.
  • Another participant asks for clarification on whether the steady state error is for a step input and inquires about the value of the gain K used, noting instability at K = 1.
  • It is confirmed that the steady state error is for a step input, with K set to 0.375.
  • Participants suggest computing the closed-loop transfer function and applying the final value theorem for the calculation.
  • A participant describes their calculation process, arriving at a steady state error of 0.04891, which they believe is incorrect.
  • Another participant advises against multiplying terms out and suggests finding E(s) symbolically to simplify the limit calculation.
  • A further contribution provides a detailed calculation leading to a steady state error of approximately 0.1206, questioning the discrepancy with the MATLAB result of 0.1128 and suggesting it may be due to MATLAB's finite time approximation.

Areas of Agreement / Disagreement

Participants express differing views on the correct calculation method and results, with no consensus reached on the discrepancies between manual calculations and MATLAB outputs.

Contextual Notes

There are unresolved aspects regarding the assumptions made in the calculations, particularly concerning the stability of the system and the interpretation of the MATLAB output.

dontigeh
Messages
3
Reaction score
0
I am trying to calculate the steady state error of the following system but unable to do it. I have used MATLAB and calculated the steady state error to be 0.1128 but don't understand the steps that I need to do to calculate this.
Please help.

Thanks
image.jpg
 
Engineering news on Phys.org
dontigeh said:
I am trying to calculate the steady state error of the following system but unable to do it. I have used MATLAB and calculated the steady state error to be 0.1128 but don't understand the steps that I need to do to calculate this.
Do you mean the steady-state error to a step input?

What value of ##K## did you use? The system is unstable for ##K = 1##.

In general, you could find the transfer function from the input to ##E(s)##, verify it's stable, and use the final value theorem.
 
  • Like
Likes   Reactions: timthereaper
milesyoung said:
Do you mean the steady-state error to a step input?

What value of ##K## did you use? The system is unstable for ##K = 1##.

In general, you could find the transfer function from the input to ##E(s)##, verify it's stable, and use the final value theorem.

Yes I want the steady-state error to a step input.

And the value of K used was 0.375.
 
dontigeh said:
Yes I want the steady-state error to a step input.

And the value of K used was 0.375.
Right, so you could use the general method I described, or if you've had a lecture on error constants, you could calculate that instead.
 
I agree with @milesyoung and say you should compute the closed-loop transfer function and use the final value theorem.
 
Hi,
Thanks for the help.
I did the following: 1/s(1-(262.5s+262.5)+(700/0.375S^4+7.313s^3+37.313s^2+43.875s+276)), then i did E(infinity) = lim s-> 0 [ 1-700/736]= 0.04891. Which is not correct. The gain is 0.375.
 
dontigeh said:
Hi,
Thanks for the help.
I did the following: 1/s(1-(262.5s+262.5)+(700/0.375S^4+7.313s^3+37.313s^2+43.875s+276)), then i did E(infinity) = lim s-> 0 [ 1-700/736]= 0.04891. Which is not correct. The gain is 0.375.
I can't decipher what went wrong if you don't show more detail.

I'd suggest you don't multiply anything out. Just find ##E(s)## symbolically using ##G_1(s),G_2(s),G_3(s)##, and then take the limit.
 
Since you are going to take the limit of the final formula as s->0, you can do that in each part as the first step. That will simplify things tremendously.
That gives a steady state gain of .375 * 7/0.5 * 100/72 = 7.29166666666667 across the top and a steady state gain of 1 for G3 in the feedback loop.
For the entire system I get a steady state gain of 7.29166666666667/(1+7.29166666666667) = 0.879396984924623.
For a unit step input, that would give a steady state error of 1-0.879396984924623 = 0.120603015075377.
I don't know why the MATLAB answer 0.1128 is different. Is it possible that the MATLAB number is from a finite time plot that is an approximation to infinite time?
 
Last edited:
  • Like
Likes   Reactions: dontigeh and timthereaper

Similar threads

Replies
1
Views
15K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 6 ·
Replies
6
Views
3K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 4 ·
Replies
4
Views
1K
  • · Replies 12 ·
Replies
12
Views
4K
  • · Replies 8 ·
Replies
8
Views
9K
  • · Replies 24 ·
Replies
24
Views
6K
Replies
4
Views
5K