Friday, 8 May 2009

Mathematica bug afflicting our product

Our Mathematica library for wavelet-based time-frequency analysis does not work with the first release of Mathematica 7 due to a bug in Mathematica's FFT routines that silently corrupts data. Any customers using this product are advised to avoid Mathematica version 7.0.0.

Specifically, the Fourier function and all related functions drop the imaginary parts of complex numbers in the result. For example, Mathematica 7.0.0 gives the wrong result here:

In[1]:= Fourier[{0.007 + 0.01 I, -0.002 - 0.0024 I}]
Out[1]= {0.00353553, 0.00636396}

The correct answer in this case is:

In[1]:= Fourier[{0.007 + 0.01 I, -0.002 - 0.0024 I}]
Out[1]= {0.00353553 + 0.00537401 I, 0.00636396 + 0.00876812 I}

If anyone would be interested in us porting this software to other environments, such as Matlab or F#, please let us know.


Scott Robert Ladd said...

I'm working on a signal processing library in F# for an accelerometer applications.

Contact me through my web site at

vJD said...

Do you know if this problem is now being fixed? And btw what kind of problem is that after all?

Flying Frog Consultancy Ltd. said...


An example of the bug is here. The problem is that MMA 7's Fourier routine often drops the imaginary parts, producing garbage answers. We had a similar problem where ListConvolve would corrupts its input on MMA 4.

jay paul said...
This comment has been removed by a blog administrator.