The ques is to plot the equation on z-plane: x(n)=-a^n*u(-n-1). But in my code,the ROC is plotting outside the circle which should be inside the circle actually. And the stem of the equation should be start from 0 to - scale .Whats's wrong in code?

3 views (last 30 days)
clear all; close all; clc; n=-10:-1; a=2; y =-a.^n.*heaviside(-n-1); figure(1) zplane(y) figure(2) stem(y)
function:function y = heaviside(n) % We assume a vector input
% Our default output value is 0 y = 0 * n; % Now, we find values in n greater than or equal to 0 y(find(n >= 0)) = 1;

Answers (0)

Community Treasure Hunt

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

Start Hunting!