You are on page 1of 1

n=-12:12;

>> u=[zeros(1,12), ones(1,1),zeros(1,12)]

> ylim([-2,2])

>> u=[zeros(1,10), ones(1,11)];

>> clear

>> clear

>> n=-10:10;

>> u=[zeros(1,10), ones(1,11)];

>> stem(n,u,'g','LineWidth',2);

error: get: invalid handle (= -1.3124)

execution error in graphics callback function

>> grid on

>> ylim([-2,2])

>> stem(n,u,'g','LineWidth',2);

>> u

u=

0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1

>> u=[zeros(1,14), ones(1,1),zeros(1,6)];

>> stem(n,u,'g','LineWidth',2);

You might also like