Let me first show you what I have done so far.

img1 = RemoveAlphaChannel[
   ColorConvert[ExampleData[{"TestImage", "Lena"}], "Grayscale"]];
data = ImageData[img];
{nRow, nCol} = Dimensions[data];
 d = data;
d = d*(-1)^Table[i + j, {i, nRow}, {j, nCol}];
ft = Fourier[d];
ftAbs = Abs[ft];
ftArg = Arg[ft];

This will give me the information about the image in the Fourier domain. Now let's make a copy of this information.

tempAbs = ftAbs;
tempArg = ftArg;

To look at the contribution for each row in the Fourier domain to the image

 tempAbs[[All, All]] = 0;
 tempArg[[All, All]] = 0;
 tempAbs[[All, n]] = ftAbs[[All, n]];
 tempArg[[All, n]] = ftArg[[All, n]];
 ImageAdjust[Image[Abs[InverseFourier[(tempAbs E^(I tempArg))]]]],
 {n, 1, nCol, 1}

And to check the cumulative contribution

 tempAbs[[All, All]] = 0;
 tempArg[[All, All]] = 0;
 Table[{tempAbs[[All, i]] = ftAbs[[All, i]];
 tempArg[[All, i]] = ftArg[[All, i]];}, {i, 1, n}];
 ImageAdjust[Image[Abs[InverseFourier[(tempAbs E^(I tempArg))]]]],
 {n, 1, nCol, 1}

If I take the individual contributions for the first m rows (say, 5), I will get 5 different images (say, I1,I2,I3,I4andI5). And if I take the cumulative contribution up to the fifth row, I will get another image (say, I15).

My question is what is the relation between I15 and I1,I2,I3,I4andI5? To be more precise, how can I combine these five images to get I15?

  • $\begingroup$ You probably want Re[InverseFourier[... instead of Abs[InverseFourier[.... Then I15 should be the sum of I1..I5. Fourier transform is linear, so Fourier[I1]+Fourier[I2]+Fourier[I3] = Fourier[I1+I2+I3] $\endgroup$ – Niki Estner Dec 6 '17 at 16:52
  • $\begingroup$ @nikie I want to use Abs instead of Re. I know Fourier Transform is linear but I am not sure whether they contribute linearly or not. Are you saying that the relation should be I15=I1+I2+I3+I4+I5? $\endgroup$ – Majis Dec 6 '17 at 17:00
  • $\begingroup$ Not if you use Abs. Abs[Exp[I*x]+Exp[I*y]] != Abs[Exp[I*x]]+Abs[Exp[I*y]] $\endgroup$ – Niki Estner Dec 6 '17 at 17:02
  • $\begingroup$ @nikie Then what would be the relationship between the images? $\endgroup$ – Majis Dec 6 '17 at 17:07
  • $\begingroup$ It's not noise, so there is a relationship, but it's not invertible and I don't see how you can gain any insight from it. Look at it this way: If you take a 1d Fourier transform, and delete every frequency except one, take the inverse Fourier transform, then you get the time domain of that frequency. If you take the absolute in the time domain, you get a constant signal. If you delete all but two frequencies, you get some interference, but you still can't say much about the original signal. $\endgroup$ – Niki Estner Dec 7 '17 at 11:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.