impulse
Impulse response of LTI system. If no output arguments are given, the response is printed on the screen.
Inputs
LTI model.
Time vector. Should be evenly spaced. If not specified, it is calculated by the poles of the system to reflect adequately the response transients.
Optional simulation horizon. If not specified, it is calculated by the poles of the system to reflect adequately the response transients.
Optional sampling time. Be sure to choose it small enough to capture transient phenomena. If not specified, it is calculated by the poles of the system.
Line style and color, e.g. ’r’ for a solid red line or ’-.k’ for a dash-dotted
black line. See help plot
for details.
Outputs
Output response array. Has as many rows as time samples (length of t) and as many columns as outputs.
Time row vector.
State trajectories array. Has length (t)
rows and as many columns as states.
Remark
For the impulse response of a discrete-time system, the input sequence {1/T,0,0,0,...} and not the unit impulse is considered.
Source Code: impulse
clf; s = tf('s'); g = 1/(2*s^2+3*s+4); impulse(g); title ("Impulse response of a PT2 transfer function"); |
clf; s = tf('s'); g = 1/(2*s^2+3*s+4); h = c2d(g,0.1); impulse(h); title ("Impulse response of a discretized PT2 transfer function"); |