Mathematica Stack Exchange is a question and answer site for users of Mathematica. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have the following code

Image[img, ImageSize -> 300]
data = ImageData[img];
fdct = Fourier[data]
tdata = InverseFourier[fdct];

but it seems to fail when doing the inverseFourier function. The error I get is:

Image::imgarray: The specified argument {{{1. -2.0236*10^-17 I,1. -9.36654*10^-17 I,1. -3.45228*10^-17 I},<<49>>,<<330>>},{<<1>>},<<47>>,{{1. +4.61893*10^-17 I,<<19>> +<<24>> I,1. +7.44929*10^-17 I},<<49>>,<<330>>},<<330>>} should be an array of rank 2 or 3 with machine-sized numbers. >>

I'm actually not sure what I'm doing wrong as I've checked the "discrete fourier transforms" ( and the output of fourier was just used in the inverseFourier to get the inverse...

Any ideas what is wrong here?

share|improve this question
Seems like you're right... Chopping values of solved the issue. – markovuksanovic Jul 27 '13 at 7:26
up vote 2 down vote accepted

tdata acquired small imaginary parts. Try



share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.