Path: news.mathworks.com!newsfeed-00.mathworks.com!newsfeed2.dallas1.level3.net!news.level3.com!postnews.google.com!o36g2000vbl.googlegroups.com!not-for-mail
From: ImageAnalyst <imageanalyst@mailinator.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: BOX CAR
Date: Tue, 21 Jul 2009 20:17:33 -0700 (PDT)
Organization: http://groups.google.com
Lines: 68
Message-ID: <2121bfee-538d-4585-8c87-6d14651e416c@o36g2000vbl.googlegroups.com>
References: <h3u671$n0p$1@fred.mathworks.com> <h3un4t$d21$1@fred.mathworks.com> 
	<c0146ddf-ae3f-4264-946b-2b85e4ff4c43@s31g2000yqs.googlegroups.com> 
	<h4502e$7no$1@fred.mathworks.com>
NNTP-Posting-Host: 75.186.70.56
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
X-Trace: posting.google.com 1248232654 16091 127.0.0.1 (22 Jul 2009 03:17:34 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Wed, 22 Jul 2009 03:17:34 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: o36g2000vbl.googlegroups.com; posting-host=75.186.70.56; 
	posting-account=0rLUzAkAAABojYSRC64DkTbtiSCX77HH
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; 
	GTB6; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 
	3.5.21022),gzip(gfe),gzip(gfe)
Xref: news.mathworks.com comp.soft-sys.matlab:557377


On Jul 21, 2:06 pm, "guj " <gulatiaks...@gmail.com> wrote:
> ImageAnalyst <imageanal...@mailinator.com> wrote in message <c0146ddf-ae3f-4264-946b-2b85e4ff4...@s31g2000yqs.googlegroups.com>...
> > On Jul 19, 4:57?am, "Sprinceana " <mihai...@yahoo.com> wrote:
> > > "guj " <gulatiaks...@gmail.com> wrote in message <h3u671$n0...@fred.mathworks.com>...
> > > > can any one tell me how can i apply window on my signal which is 296 sample long, i want to see only 64 samples..how can i apply rectangular window...
>
> > > > and how to plot it with my funtion
>
> > > > I tired RECTWIN(64) but is giving me straight line, and how can i multiply with 296 point signal.
>
> > > > I am new to DSP ..:) still learning the things
>
> > > You store your 296 sample long on your signal in a variable isn't it?
>
> > > So you multiply:
>
> > > reactwin(64) *name_of_variable (which consist of your 296 point signal).
>
> > > You gave little details a little code and message of errors can guide us to help you quicker!
>
> > > Michael
>
> > ------------------------------------------------------------------
> > Yeah, you think that's going to work???  The only way to do the
> > multiplication is if the arrays are the same size, Or multiply just
> > part of the longer one like this:
> > a=1:64
> > b=1:296
> > c=a .* b(1:length(a))
>
> > Or possibly they're thinking about a sliding window sort of thing,
> > like convolution, conv().
>
> > But you're right in that they really haven't given enough information
> > to give a decent answer.
> > Regards,
> > ImageAnalyst
>
> Lets  see it like that
>
> I have s which is a spectra signal length a, w another signal spectra of length b when i convolve spectra of both of them i get y=s*w..Now y has length a+b-1.......So for getting s back i need to apply low pass filter...say a rectangular function.....RECTWIN (in matlab)....
>
> If i apply some thing like
> y.*RECTWIN(length(s)) it wont work as they r of not equal size...so how will i apply it..am i clear now ...this question seem to trivial but i dont understand- Hide quoted text -
>
-----------------------------------------------------------------------
Don't use rectwin, and you certainly don't use a low pass filter to
extract a part of a signal (that would just mess up your convolution -
change it's shape).  You just use regular indexing.
For example if you signal is 100 long and your kernel is 11 long, the
convolution will be 111 long.  If you want the central 100 out of it,
just say
sameSizeSignal = convolutionResult(6:105);
Good luck,
ImageAnalyst