필터 지우기
필터 지우기

Finding time constant and steady state error with Simulink

조회 수: 72 (최근 30일)
Jason Gauthier
Jason Gauthier 2017년 10월 23일
편집: Birdman 2017년 10월 24일
Hello Everyone,
I am working on an assignment for school. I'm working with a single order Transfer Function, and the issue is that I do not know how to acquire the requested items, the way they are requested.
I'm asked to find the time constant and steady-state error. I did this, it's not problem. (Technically it's not a transfer function, it's the path forward function of a unity feedback system).
Here's where I am stuck:
2. Now, determine the output of the system using MATLAB/Simulink for the above systems for a reference input of 1 volt, i.e. a unit step input. Place responses for the three values of K (given in part (1)) on the same plot. Find the time constants and compare these with the results found in part 1. Also, find the steady-state errors and compare the results with those obtained in part (1).
Note: I have no problem with creating the Simulink diagram for all three variations, and getting the output with the scope. My issue is that I do not know how to find the Ttime Cconstant or the steady state error using Simulink output.
Understand, at this point, we basically know how to use the scope output and not much else.
Is there a way to achieve these results?
Thanks!

채택된 답변

Birdman
Birdman 2017년 10월 24일
If you are talking about a single order(first order) transfer function with no zeros and one poles, then the time constant is the value where the output reaches to its 63% of its final value. For instance if the final value is 1, the time constant can be found where the output is 0.63. The other way to find the time constant is as follows:
Consider a first order transfer function as
G(s)=K/a*s+1
If the transfer function has this shape, where the s^0 term in the denominator is 1, then the time constant is equal to a. You can both try these ways in order to verify the results.
There is no tool in Simulink that automatically gives the time constant to you. You have to derive it yourself.
Secondly, to find the steady state error, you can do it as follows:
Imagine you have the same transfer function as above and you are asked to calculate it by hand. Then, in closed loop with a unit gain controller, the expression for the error will be
E(s)=R(s)/1+G(s)
Then, you can calculate steady state error(ess) by
lim s*E(s) = s*s+2/(s*s+3) where the s will cancel each other and when s=0, the ess will be 2/3.
s->0
Also in closed loop, we know that
T(s)=G(s)/1+G(s)
and the final value for the step response will be 1/3. So the steady state can be also found by
1-1/3=2/3.
Hope this helps.
  댓글 수: 2
Jason Gauthier
Jason Gauthier 2017년 10월 24일
Thanks you for the answer. Calculating the values themselves was not problematic. Trying to obtain the values from Simulink, as the lab suggestion was... So, I will just estimate them, or measure them with a different tool than simulink.
Thanks!
Birdman
Birdman 2017년 10월 24일
편집: Birdman 2017년 10월 24일
Maybe you can write a MATLAB Function for it in Simulink. If you have time, I will write and send to you later.
There is a function for time constant for first order systems.
function [tau, TFunc]=TimeConstant(TF)
%%time constant for first order continuous transfer functions.
den=cell2mat(TF.Denominator);
num=cell2mat(TF.Numerator);
len=length(den);
if(den(len)~=1)
den=den/den(len);
num=num/den(len);
end
tau=den(len-1);
TFunc=tf(num,den);
end

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Power and Energy Systems에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by