plot inverse z transform

조회 수: 11 (최근 30일)
Francisco Araujo
Francisco Araujo 2016년 5월 1일
답변: Priyadharsini B 2022년 12월 1일
I want to plot the sequence described by the inverse transform of the following Pulse Transfer Function
G(z) = (0.6321*z^-1)/(1-1.3679*z^-1+0.3679*z^-2)
writing the code
syms z k
G = (0.6321*z^-1)/(1-1.3679*z^-1+0.3679*z^-2)
g = iztrans(G, z, k)
k = linspace(0,14,15);
stem(g,k)
or even
syms z k
G = (0.6321*z^-1)/(1-1.3679*z^-1+0.3679*z^-2)
g = iztrans(G, z, k)
stem(g)
But there is the following error:
DOUBLE cannot convert the input expression into a double array.
If the input expression contains a symbolic variable, use VPA.
Error in
stem(g)
What is the problem?

답변 (2개)

Walter Roberson
Walter Roberson 2016년 5월 1일
stem() does not understand symbolic expressions. You need to evaluate to get numeric expressions.
gn = double( subs(g, sym('k'), k) );
stem(gn, k)

Priyadharsini B
Priyadharsini B 2022년 12월 1일
syms z
f=z/((z-1)^2)*((z+2)^2)
iztrans(f)

카테고리

Help CenterFile Exchange에서 Symbolic Math Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by