Evaluating Z transform numericaly and explicite

16 views (last 30 days)
I have to evaluate Z transform of function (u(n) is equal 1 if n>=0 and 0 if n<0)
numericaly and then compare it to known equation.
I made A matrix which is kind of transition matrix between z and n domain, so z transform is just xz=A*x, and inverse is xx=pinv(A)*xz. I obtain strange results, because numerical evaluation differs from analytical by 1. Is there someone who can explain or guide me how to fix this? Here is definition of Z transform if needed https://en.wikipedia.org/wiki/Z-transform.
EDIT: I noticed that problem appears only if i transfrom function with cosine. for a^n or sine works good.

Answers (0)

Community Treasure Hunt

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

Start Hunting!