comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » IDL and PV-Wave
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: idl and pv-wave [message #7919 is a reply to message #412] Sat, 25 January 1997 00:00 Go to previous messageGo to previous message
Big Brother is currently offline  Big Brother
Messages: 1
Registered: January 1997
Junior Member
Achim Hein wrote:
> Try the following:
> wave>test=findgen(4097)
> wave>print,max(test-fft(test,-1),1))

Shurely it should be max(test-fft(fft(test,-1),1)) :-)

> wave>(31.3898,0.350983)

fairly close, my HP gives
(29.4698,0.247685)

> In IDL you will get as result:
> IDL>test=findgen(4097)
> IDL>print,max(test-fft(test,-1),1))
> IDL>(0.000244141,1.39110e-05)
> If you try to evaluate this FFT with a 4096-length, the results in > > > both programs are quite equal.

test=findgen(4095)
print, max( test-fft(fft(test,-1), 1))
( 0.00219727, -0.000417931)

> There was a discussion some month ago with Sergei Senin...:
> In his opinion:

IMHO :-)

>> <There seems to be no mistake, but simply no check in the procedure > > <for the number of elements in the array being 2^X.

> But I think:
>> It seems so, but I think a Fourier-Transform-Algorithm has to
>> run for every array length

I do agree with you now - WAVE fft is weird.
I'm using it to plot amplitude and phase spectral densities, which
requires a certain precision, and to avoid this problem, I run a
"power-of-two check" routine and zero padding before doing fft.

Sergei Senin
UoP, UK
ss@ee.port.ac.uk
WAVE mailing list archive:
http://www.ee.port.ac.uk:80/~ss-www/WAVE/wave-maillist/maill ist.html

PS: Sorry about this "Big Brother" stuff - I'm tired of getting junk
e-mail. My real address is in the signature.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: color buttons
Next Topic: Re: Shaded circles request.

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sat Oct 11 07:12:32 PDT 2025

Total time taken to generate the page: 1.36017 seconds