# Thread: how to plot this unit step functions

1. ## how to plot this unit step functions

this is condition after inverse Z transform
I want to plot it

y[n]= u[n-1]-u[n-2]-u[n-3]+u[n-4]

2. ## Re: how to plot this unit step functions

The base step function, u(x), is 0 for x< 0, 1 for x> 0 (the definition of the value at 0 varies- most often 1, sometimes 0, occasionally 1/2). So u(n-1) is 0 for n< 1, 1 for n>1, u(n- 2)= 0 for n< 2, 1 for n> 2, and so on.

So, for n< 1, y[n]= u[n-1]-u[n-2]-u[n-3]+u[n-4] =0- 0- 0+ 0= 0.
For 1<n< 2, y[n]= u[n-1]-u[n-2]-u[n-3]+u[n-4]= 1- 0- 0+ 0= 1.
Get the idea? It's just adding integers!

,
,

,

,

,

,

# plot u(n-1)

Click on a term to search for related topics.