From: huda nawaf on
hi,
please , can anybody help me to write code and plot this signal?
Define the discrete-time signal x(n) = n u(n) in a vector in the range 0 ≤ n ≤ 10 and plot the signal.

thanks in advance
From: Rune Allnor on
On 20 Mar, 13:29, "huda nawaf" <halmam...(a)yahoo.com> wrote:
> hi,
> please , can anybody help me to write code and plot this signal?
> Define the discrete-time signal x(n) = n u(n) in a vector in the range 0 ≤ n ≤ 10 and plot the signal.
>
> thanks in advance

doc plot
doc stem

Rune
From: RIKA fazi on
Rune Allnor <allnor(a)tele.ntnu.no> wrote in message <50582939-bbdb-40e2-a07a-2e6e0a4053d2(a)t23g2000yqt.googlegroups.com>...
> On 20 Mar, 13:29, "huda nawaf" <halmam...(a)yahoo.com> wrote:
> > hi,
> > please , can anybody help me to write code and plot this signal?
> > Define the discrete-time signal x(n) = n u(n) in a vector in the range 0 &#8804; n &#8804; 10 and plot the signal.
> >
> > thanks in advance
>
> doc plot
> doc stem
>
> Rune
if you signal is step unity we can define it by u=ones(1,10)
n=[1 :10]
u=ones(1,10)
for n=1:10
uu(n)=n*u(n)
end
size(uu)
stem(uu)
From: huda nawaf on
Rune Allnor <allnor(a)tele.ntnu.no> wrote in message <50582939-bbdb-40e2-a07a-2e6e0a4053d2(a)t23g2000yqt.googlegroups.com>...
> On 20 Mar, 13:29, "huda nawaf" <halmam...(a)yahoo.com> wrote:
> > hi,
> > please , can anybody help me to write code and plot this signal?
> > Define the discrete-time signal x(n) = n u(n) in a vector in the range 0 &#8804; n &#8804; 10 and plot the signal.
> >
> > thanks in advance
>
> doc plot
> doc stem
>
> Rune

thanks, are you meaning , after I have got x , just plot(x)?
From: huda nawaf on
"RIKA fazi" <fazirika(a)yahoo.fr> wrote in message <ho2h28$knj$1(a)fred.mathworks.com>...
> Rune Allnor <allnor(a)tele.ntnu.no> wrote in message <50582939-bbdb-40e2-a07a-2e6e0a4053d2(a)t23g2000yqt.googlegroups.com>...
> > On 20 Mar, 13:29, "huda nawaf" <halmam...(a)yahoo.com> wrote:
> > > hi,
> > > please , can anybody help me to write code and plot this signal?
> > > Define the discrete-time signal x(n) = n u(n) in a vector in the range 0 &#8804; n &#8804; 10 and plot the signal.
> > >
> > > thanks in advance
> >
> > doc plot
> > doc stem
> >
> > Rune
> if you signal is step unity we can define it by u=ones(1,10)
> n=[1 :10]
> u=ones(1,10)
> for n=1:10
> uu(n)=n*u(n)
> end
> size(uu)
> stem(uu)
thank you very much , but, i think that unit step be 1 from any value =>0.