Path: news.mathworks.com!newsfeed-00.mathworks.com!newsfeed2.dallas1.level3.net!news.level3.com!postnews.google.com!w9g2000pro.googlegroups.com!not-for-mail
From: dbd <dbd@ieee.org>
Newsgroups: comp.soft-sys.matlab,comp.dsp,sci.math.num-analysis
Subject: Re: WARNING: Is there a use for ifft(X,M)?
Date: Fri, 12 Jun 2009 22:22:09 -0700 (PDT)
Organization: http://groups.google.com
Lines: 113
Message-ID: <f0075e8f-e691-4280-9736-8c3a4fb644a9@w9g2000pro.googlegroups.com>
References: <8c3ffec9-42f0-4ba1-ac3c-f826d56dd963@y7g2000yqa.googlegroups.com> 
	<c751a7c4-04ea-4891-82fd-e538fad25826@c19g2000prh.googlegroups.com> 
	<3605952f-7b12-40e2-a651-863b88f9ae65@z16g2000prd.googlegroups.com>
NNTP-Posting-Host: 75.3.203.41
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
X-Trace: posting.google.com 1244870530 5520 127.0.0.1 (13 Jun 2009 05:22:10 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Sat, 13 Jun 2009 05:22:10 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: w9g2000pro.googlegroups.com; posting-host=75.3.203.41; 
	posting-account=E_gaFgoAAACfAhF2MzvkivNAUVGQbrBP
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.20) 
	Gecko/20081217 Firefox/2.0.0.20 (.NET CLR 3.5.30729),gzip(gfe),gzip(gfe)
Xref: news.mathworks.com comp.soft-sys.matlab:547112 comp.dsp:258709 sci.math.num-analysis:108375



On Jun 12, 12:30 pm, Greg <he...@alumni.brown.edu> wrote:
> On Jun 12, 3:55 am, dbd <d...@ieee.org> wrote:
>
>
>
> > On Jun 11, 9:21 pm, Greg Heath <he...@alumni.brown.edu> wrote:
>
> > > This is a followup to the thread "Why is fft(x,M) useful?
>
> > >http://groups.google.com/group/comp.soft-sys.matlab/
> > > msg/2bacfcce9454065e
>
> > > As long as the N components of the time sampled row
> > > vector function x are presented in chronological order,
> > > the use of fft(x,M) as shorthand for the zeropadding
> > > operation fft([x,zeros(1,M-N)]) is relatively
> > > straightforward.
>
> > > In contrast, it has been show in recent posts, e.g.,
>
> > >http://groups.google.com/group/comp.soft-sys.matlab/
> > > msg/a76d7837e3d84bcf?hl=en
>
> > > that when zero padding in the spectral domain, it is
> > > essential to add the zeros so that both the real and
> > > imaginary parts of the result are conjugate symmetric.
> > > When N is even, this results in the insertion of the
> > > zeros within a two part decomposition of the Nyquist
> > > component. However, workarounds are available when
> > > the zeros are placed on either side of the Nyquist
> > > component.
>
> > > The purpose of this thread is to warn potential users
> > > that none of the three techniques in the above reference
> > > involves appending the zeros at the end of the spectrum
> > > obtained from fft(x).
>
> > ,> Therefore, I can find no use for ifft(X,M).
> > ,>
> > ,> Hope this helps.
> > ,>
> > ,> Greg
>
> > I can find no use for mayonnaise, but I don't post a warning to
> > comp.dsp about it.
>
> > Since you have included comp.dsp in this post and I've read the basis
> > of your concern, why do you think those in comp.dsp need to be
> > concerned about maintaining non-zero Nyquist components when
> > interpolating via spectrum zero fill and ifft? Why are you?
>
> > How does this help?
>
.> I want all of the experts and nonexperts who read
.> comp.dsp to understand that
.>
.> 1.Using MATLABs dual input option of ifft will not
.> return a reasonable interpolation of the time
.> function obtained when using the single input version.

Since you seem to think that the single input option of Matlab's ifft
can produce an appropriate interpolation and all outputs of the single
input option can be produced with the dual input option with the
correct value of the second input, your statement cannot be true. If
it was your intent to make a true statement, perhaps you meant to say
something like "The default zero-fill behavior of the dual input
option of ifft does not correctly place zeros to support zero-fill
interpolation."

> 2. This has nothing to do with Nyquist components.

You referenced it as an area motivating your concern, but you're
right, it probably isn't relevant to a correct version of the
statement you made in 1.

Then you seem to take it up again in:
On Jun 12, 8:36 pm, Greg <he...@alumni.brown.edu> wrote:
> 1234567890123456789012345678901234567890123456789012345
Why?

.> 3. I can't think of any scenario where the dual input
.> version is of any use at all.

There are others who post on comp.dsp who chose to show no
imagination. Please don't encourage them.

3a. I have a vector  V of length n > m. I want to know the ifft of the
first m elements of V. "ifft(V,m)" requires fewer characters to type
than "ifft(V(1:m))".
3b.While using ifft I want to make the code more readable for the
maintenance programmer (me in 6 months). Using the dual input ifft
allows my to explicitly place the size of ifft I am intending to
perform in the second input to allow me to check the correctness of
the size of the vector defined by the complex expression in the first
input.

Scenarios, great or not.

.> 4. I think this is serious enough to issue a WARNING.
.>
.> Hope this helps.
.>
.> Greg

You have found an application where you choose not to use ifft(X,m).
This is not logically equivalent to "There is no use for ifft(X,m)."

Perhaps if we tried: "The default zero-fill capability of the dual
input form of ifft() may not be useful for some purposes", we could
get by with just a "Warning".

Dale B. Dalrymple