compute the impulse-response of a system
ImpulseResponse( sys, opts )
System; linear system
(optional) equation(s) of the form option = value; specify options for the ImpulseResponse command
format = charfcn or piecewise
Used with a discrete system and the matrix method to select the format of the output. If charfcn, then use the charfcn procedure to represent an impulse. If piecewise, then, if required, the return value is a piecewise expression. The default is charfcn.
method = function or matrix
Select the method used to compute the impulse response. If function, then the impulse response is computed from a transfer-function model of the system using an inverse transformation. If matrix, then the impulse response is computed from a state-space model of the system. The function method is the default for frequency-domain based models (TF, Coeff, and ZPK), the matrix method is the default for time-domain based models (DE and SS).
The ImpulseResponse command computes the impulse response of sys, a System object.
The ImpulseResponse command returns an algebraic Matrix, except in the case when the option format=piecewise is selected, as described under Options, and the output may be a piecewise expression of Matrices.
Two methods are provided for computing the impulse response of a system.
The function method generates a transfer-function model of sys, then computes the inverse Laplace transformation or the inverse z-transformation, for continuous and discrete system, respectively.
The matrix method generates a state-space model of sys, then computes the impulse response from the state-transition matrix.
For a continuous system the impulse response is C . exp(A*t) . B + D*Dirac(t).
For a discrete system the impulse response is (C . A^(q-1) . B)(1 - charfcn(q)) + D*charfcn(q).
sys ≔ NewSystem⁡ss2+ω2,s+1s2+3:
imp ≔ ImpulseResponse⁡sys
Use inttrans[laplace] to compute the transfer-functions from the impulse response.
The impulse response of a discrete system consists of expressions in terms of the discrete time variable (generally q).
sys ≔ NewSystem⁡1z+1,z−az+b,discrete:
Use ztrans to compute the transfer-functions from the impulse response.
Use the matrix method with the piecewise format.
Download Help Document
What kind of issue would you like to report? (Optional)