University of technology and education Ho Chi Minh cityFaculty of international education Automatic control Matlab exam Teacher: Vu Van Phong Student: Tran Ngoc Xuan Thanh Student id: 20
Trang 1University of technology and education Ho Chi Minh city
Faculty of international education
Automatic control
Matlab exam
Teacher: Vu Van Phong
Student: Tran Ngoc Xuan Thanh Student id: 20146280
TP HCM, Month 12 Year 2023
Trang 2Question 1:
Student id: 20146280
a=8 and b=1
-Code:
a) Define a function on Matlab
I have a=8 and b=1
After that using G(fuction of system)=tf([1],[1,2*a+b,(a+b)/2,0]) to enter a and
b and find G(s)
Trang 3b) Draw a Numerical solution trajectory on Matlap
After that, I use rlocus to find a Numerical solution trajectory for a system on Matlab I have the graph:
Trang 4c) Find Kgh?
d) Choose any K such that the system is stable then simulate the system in Simulink with the obtained value of K and an input signal as a step function
With K=0.3 the system is stable I simulate the system in Simulink I have a block diagram and the graph
Trang 5+Block diagram
+The graph with K=0,3 and input step is 500 The system is stable:
Question 2:
Student id:20146280
=>a=8 and b=1
Trang 6a)Draw a bode graph on Matlab
First, we I a G2=tf([100, 1800],conv([1 8],[1 11 1])) to enter a function(G2) on Matlab
I use a bode(G2) to draw a bode graph on Matlab and we have a graph:
Trang 7b)Find a Phase and Magnitude
We can see a picture when I draw a bode graph on Matlab:
Trang 8We have Phase(dự trữ Pha)=Pm and Magnitude(dự trữ biên)=Gm, so I have magnitude=infinity and phase=24,3degree(about 10,5 rad/s)
c)Comment on the stability of the system based on the Bode theory
-The system is stable When:
+with Gm(Magnitude): Gm>1(db) the system is stable
+with Pm(Phase margin): 30(degree)<Pm<60(degree) is the best Pm for the system stable
-I have Pm=24,3 degree and Gm=infinity
+With Gm=infinity the system is stable because Gm>1
+With Pm=24,3degree, Pm<30(degree) the system may be stable but the system will become sluggish with disturbances and the system may be have a risk of overshoot\
Trang 9-Based on the given information, the system will be stable, but there is a possibility of overshoot
Question 3:
Student id: 20146280 so a=8 and b=1
-Code:
Trang 10a)Draw a Nyquist graph on Matlab
I use G3=tf([8], conv([1 8], [1 11 1])) to enter the function on matlab
After that I use Nyquist(G3) to draw a Nyquist graph on Matlab:
Trang 11b) Comment on the stability of the system based on the Nyquist theory -According to Nyquist, a system is stable if there is a loop on the Nyquist plot, but no point of the loop crosses the point -1 (1 + 0j); the system can still be stable
-We can see in picture, the circle don’t include the point(-1;0) so the system is stable(Nyquist theory)
Question 4:
-Code:
a) and b) Find a pole and zero of the system and draw on complex plane -We have a function G(s)=s2 1
+s+ 9 because the numerator of function is
=>we don’t have zero point
Trang 12I use a pole(T4) and zero(T4) on Matlab to find a poles points and zero points
I use a pzplot(T4) to draw a pole point and zero point on complex plane