MATLAB system simulation and modeling (5)-transient response analysis-impulse response

Pre-reading: MATLAB System Simulation and Modeling (4)-Transient Response Analysis-Step Response

About what is impulse input, readers can go to understand the principle of automatic control and signal and system

2 Impulse response

2.1 The first method to obtain the impulse response

impulse(num,den)  % 在屏幕上绘制冲激响应    
% impulse(sys)   
impulse(A,B,C,D)  % 在屏幕上绘制状态空间方程系统的冲激响应
% 剩下的与上一篇关于阶跃响应是同一个道理
impulse(num,den,t)  % t 为仿真终止时间     
% impulse(sys,t)
y = impulse(num,den)     
% y = impulse(sys)
[y,t]   = impulse(num,den,t)    
% [y,t) = impulse(sys,t) 
[y,x,t) = impulse(num,den)
[y,x,t] = impulse(num,den,t)
[y,x,t] = impulse(A,B,C,D)
[y,x,t] = impulse(A,B,C,D,iu)
[y,x,t] = impulse(A,B,C,D,iu,t)

For example, in the following system
C (s) R (s) = G (s) = 1 s 2 + 0.2 s + 1 {\frac{C(s)}{R(s)})=G(s )={\frac 1{s^2+0.2s+1}}R(s)C(s)=G(s)=s2+0.2s+11
The code is as follows:

num = [1];
den = [1 0.2 1];
impulse(num,den); 
grid
title('Unit-lmpulse Response of G(s) = 1/(s^2 + 0.2s + 1)')

We can see that the MATLAB output is:

Insert picture description here

2.2 The second method to obtain the impulse response

We know that when the initial condition is 0 0At 0 ,G (s) G (s)G ( S ) of the unit impulse responses G (s) sG (sThe unit step response of s G ( s ) is the same.

Guess you like

Origin blog.csdn.net/weixin_43229030/article/details/110817093