4
$\begingroup$

I've stuck in one problem. I need to perform Fourier Slice Theorem on sinogram of medical image.

I read a lot about this theorem. I write a matlab code but results are always non-sense after inverse fourier transform. But Fourier Space seems alright.

I fill Fourier space with converting polar coordinates to cartesian coordinates. I apply 1 Dimensional Fast Fourier Transform with ftt command on every sinogram lines. After for each angle (I used 180 rotation angle) and radius value I convert it to cartesian coordinates and for each corresponding values G(theta, radius) ==> F(x,y) I filled up Fourier Space. It seems logical but results is not. How can I correct my code to run this algorithm?

Circular shape is Fourier Space, other nonsenseless image is ifft. Original image is binary liver but I can't add it.

Thank you!

Plus, my matlab code!

enter image description here

enter image description here

[![I=imread('binaryliver.png');

% I = im2bw(I, 0.1);
%Sinogram was calculated before for 180 angle!
\[w,h\] = size(I); 

theta = 0:1:179;][1]][1]

xorg = floor(h/2);
yorg = floor(w/2);  %for find origin of matrix

F = zeros(w,h);     %fourier space assigment

for i = 1:length(theta)

    E(:,:,i) = fft(sinogram(i,:));  %calculate FFT for each line of sinogram

end

for i = 1:length(theta)

    for r = 1: length(E(:,:,1)) %Convert polar coordinates to cartesian coordinates



        x = xorg + (r-h/2+1)*cosd(-theta(i));
        y = yorg + (r-w/2+1)*sind(-theta(i));

        if x == 0 && y == 0   %                               

        else
            yy = round(y); xx = round(x);

            if yy <= 0

                yy = 1;

            elseif yy > h
                yy = h;

            end

            if xx <= 0

                xx = 1;

            elseif xx > w


                xx = w;

            end
        value = E(1,r,i);
        F(xx, yy) = value;
        end
    end 

end

Im2=abs(ifft2(F));
figure; imshow(log(1+abs(F)),[]);

figure; imshow(Im2, []);
$\endgroup$
2
  • $\begingroup$ Welcome to SE.DSP! Please edit your question and add the actual image. You will need to delete one of the others, but one of the higher-rep users can then edit it and allow three images in the question. Ping me once you're done. $\endgroup$
    – Peter K.
    Commented May 26, 2017 at 20:47
  • $\begingroup$ Ok, sir. I did it. $\endgroup$
    – muygun
    Commented May 26, 2017 at 21:20

1 Answer 1

3
$\begingroup$

Fourier slice theorem states that Fourier Transform of your projections are equal to slices of 2D Fourier transform.

When you sample the projections over discrete angles the FT of projections become samples of 2D Fourier transform.

So you have to use your obtained samples to interpolate the remaining points.(The interpolation must be a certain type of interpolation which is a periodic and 2D version of Lanczos interpolation)

in your code you put the samples in their position but the remaining points remain zero.

$\endgroup$
3
  • $\begingroup$ You can find the Cartesian coordinate of your obtained samples then use it to interpolate the Fourier transform over its Cartesian grid. $\endgroup$
    – Mohammad M
    Commented May 26, 2017 at 21:39
  • $\begingroup$ ı understant. actually I tried before all over process that I took 2D fourier transform and I deleted other angles and points except 180 rotation degree. and I get meaningful data, I could see borders of liver. But now, I see image like an interference pattern. So, I'll try interpolate. Could you recommend method in matlab for this process? $\endgroup$
    – muygun
    Commented May 26, 2017 at 21:41
  • $\begingroup$ Sorry sir, it's not work on my situation. I used this solution at link. now, I'll try back two dimensional fft because of verification of interpolation $\endgroup$
    – muygun
    Commented May 26, 2017 at 22:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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