Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 6

CONTROLS SYSTEMS LAB #6 STEADY STATE ERROR

PREPARED BY Nicholas Miller In partial fulfillment of the requirements for ECET 4610 Date: November 6, 2006

PREPARED BY:

Part 1: numG = [1,5]; denG = [1,3,6,0]; G = tf(numG,denG) Transfer function: s+5 ----------------s^3 + 3 s^2 + 6 s numG1 = [10]; denG1 = [1,10]; G1 = tf(numG1,denG1) Transfer function: 10 -----s + 10 Geq1 = G*G1 Transfer function: 10 s + 50 ---------------------------s^4 + 13 s^3 + 36 s^2 + 60 s

Geq2 = Geq1*2 Transfer function: 20 s + 100 ---------------------------s^4 + 13 s^3 + 36 s^2 + 60 s Geq3 = feedback(Geq2,1) Transfer function: 20 s + 100 ---------------------------------s^4 + 13 s^3 + 36 s^2 + 80 s + 100

a = 0.5*pi/180; t = (0:0.1:10); u = a*t; [y,x] = lsim(Geq3,u,t); plot(t,y*180/pi,t,u*180/pi,'--')

The graph above shows the actual altitude vs. the theoretical altitude from zero to ten seconds for a constant gain control system. Thus, providing the ability to figure the error between the two for the system and hopefully help us make a decision as to whether this error is acceptable or not. Which looking at the error resulting from the system I would consider it not acceptable. t5= interp1(t',y,5); t5*180/pi ans = 2.2072 Actual altitude at t=5sec t5= interp1(t',u,5); t5*180/pi ans = 2.5000 Theoretical altitude at t=5sec error = ((2.5 - 2.2072)/(2.5))*100 error = 11.7120%

Part 2: G1 = Geq1 Transfer function: 10 s + 50 ---------------------------s^4 + 13 s^3 + 36 s^2 + 60 s numG2 = [2,1]; denG2 = [1,0]; G2 = tf(numG2,denG2) Transfer function: 2s+1 ------s G = G1*G2 Transfer function: 20 s^2 + 110 s + 50 -----------------------------s^5 + 13 s^4 + 36 s^3 + 60 s^2

G = feedback(G,1) Transfer function: 20 s^2 + 110 s + 50 ------------------------------------------s^5 + 13 s^4 + 36 s^3 + 80 s^2 + 110 s + 50

[y,x] = lsim(G,u,t); plot(t,y*180/pi,t,u*180/pi,'--') title('Miller: Response of AutoPilot with a PI Controller vs. Theoretical')

The graph above shows the actual altitude vs. the theoretical altitude from zero to ten seconds when implementing a Proportional + Integral control system. Thus, providing the ability to figure the error between the two for the system and hopefully help us make a decision as to whether this error is acceptable or not. Which looking at the error resulting from the system I would consider it quite acceptable. t5= interp1(t',y,5); t5*180/pi ans = 2.4767 Actual altitude at t=5sec t5= interp1(t',u,5); t5*180/pi ans = 2.5000 Theoretical altitude at t=5sec error = ((2.5 - 2.4767)/(2.5))*100 error =0.9320%

Conclusion: This lab taught us how to implement both a constant gain controller and an Proportional + Integral controller. The second proved to be a much more accurate controller with little implementation difference. The error was much smaller with the second as well being less than 1% while being more than 11% with the constant gain controller. Therefore, I would recommend implementing the Proportional + Integral controller for the autopilot control system between the two in this lab.

You might also like