Calculating steadystate errors
System type and steadystate error
Example: Meeting steadystate error requirements
Steadystate error is defined as the difference between the input and output of a system in the limit as time goes to infinity (i.e. when the response has reached the steady state). The steadystate error will depend on the type of input (step, ramp, etc) as well as the system type (0, I, or II).
Note: Steadystate error analysis is only useful for stable systems. It is your responsibility to check the system for stability before performing a steadystate error analysis. Many of the techniques that we present will give an answer even if the system is unstable; obviously this answer is meaningless for an unstable system.
Before talking about the relationships between steadystate error and system type, we will show how to calculate error regardless of system type or input. Then, we will start deriving formulas we will apply when we perform a steady stateerror analysis. Steadystate error can be calculated from the open or closedloop transfer function for unity feedback systems. For example, let's say that we have the following system:
which is equivalent to the following system:
We can calculate the steady state error for this system from either the open or closedloop transfer function using the final value theorem (remember that this theorem can only be applied if the denominator has no poles in the righthalf plane):
Now, let's plug in the Laplace transforms for different inputs and find equations to calculate steadystate errors from openloop transfer functions given different inputs:
When we design a controller, we usually want to compensate for disturbances to a system. Let's say that we have the following system with a disturbance:
we can find the steadystate error for a step disturbance input with the following equation:
Lastly, we can calculate steadystate error for nonunity feedback systems:
By manipulating the blocks, we can model the system as follows:
Now, simply apply the equations we talked about above.
If you refer back to the equations for calculating steadystate errors for unity feedback systems, you will find that we have defined certain constants ( known as the static error constants). These constants are the position constant (Kp), the velocity constant (Kv), and the acceleration constant (Ka). Knowing the value of these constants as well as the system type, we can predict if our system is going to have a finite steadystate error.
First, let's talk about system type. The system type is defined as the number of pure integrators in a system. That is, the system type is equal to the value of n when the system is represented as in the following figure:
Therefore, a system can be type 0, type 1, etc. Now, let's see how steady state error relates to system types:
Steady State Error Formula  


Static Error Constant  


Error  


Steady State Error Formula  


Static Error Constant  


Error  


Steady State Error Formula  


Static Error Constant  


Error  


Click on the System Type to see examples
Given the following system,
where G(s) is:
find the value of K so that there is 10% steady state error in open loop. Since this system is type 1, there will be no steadystate error for a step input and an infinite error for a parabolic input. The only input that will yield a finite steadystate error in this system is a ramp input. Let's look at the ramp input response for a gain of 1:K*(s + 3)(s + 5)  s (s + 7)(s + 8)
num = conv( [1 5], [1 3]); den = conv([1,7],[1 8]); den = conv(den,[1 0]); [clnum,clden] = cloop(num,den); t = 0:0.1:50; u = t; [y,x] = lsim(clnum,clden,u,t); plot(t,y,t,u) xlabel('Time(secs)') ylabel('Amplitude') title('Inputpurple, Outputyellow')
The steadystate error for this system is very large, since we can see that an input of time = 20 gives us an output with amplitude of approximately 16. We will talk about this in further detail in a few moments.
We know from our problem statement that the steady state error must be 0.1. Therefore, we can solve the problem following these steps:
Let's see the ramp input response for K = 37.33:
k =37.33 ; num =k*conv( [1 5], [1 3]); den =conv([1,7],[1 8]); den = conv(den,[1 0]); [clnum,clden] = cloop(num,den); t = 0:0.1:50; u = t; [y,x] = lsim(clnum,clden,u,t); plot(t,y,t,u) xlabel('Time(secs)') ylabel('Amplitude') title('Inputpurple, Outputyellow')
In order to get a better view, we must zoom in on the response. We choose to zoom in between 40 and 41 because we will be sure that the system has reached steady state by then and we will also be able to get a good view of the input and the output.
axis([40,41,40,41])
The amplitude = 40 at t = 40 for our input, and time = 40.1 for our output. However, since these are parallel lines in steady state, we can also say that when time = 40 our output has an amplitude of 39.9, giving us a steadystate error of 10%. Let's zoom in further on this plot and confirm our statement:
axis([39.9,40.1,39.9,40.1])
Now let's modify the problem a little bit and say that our system looks as follows:
Our G(s) is the same, but now we want zero steadystate error for a ramp input.
From our tables, we know that a system of type 2 gives us zero steadystate error for a ramp input. Therefore, we can get zero steadystate error by simply adding an integrator (a pole at the origin) Let's view the ramp input response for a step input if we add an integrator and use a gain of one:
num =conv( [1 5], [1 3]); den =conv([1,7],[1 8]); den = conv(den,[1 0]); den = conv(den,[1,0]); [clnum,clden] = cloop(num,den); t = 0:0.1:250; u = t; [y,x] = lsim(clnum,clden,u,t); plot(t,y,t,u) xlabel('Time(secs)') ylabel('Amplitude') title('Inputpurple, Outputyellow')
As you can see, the response is not the most desirable one (we can see oscillations at 100secs, but you may have to zoom in to see them). However, at steady state we have zero steadystate error. Let's zoom in at 240 secs. (trust me, it doesn't reach steady state until then):
axis([239.9,240.1,239.9,240.1])
As you can see, the steadystate error is zero. Feel free to zoom in at different areas on the diagram and observe how the response approaches steady state.