Quantcast
Channel: Intel® Integrated Performance Primitives
Viewing all articles
Browse latest Browse all 1294

Wrong fft values when comapred with Matlab results

$
0
0

Hi, I am trying to calculate the MTF (modulation transfer function) of a radiograph. Multiple lines are drawn over a region that goes from high attenuation values to low attenuation values. These lines are sampled at the rate of 0.01mm. The following graph shows the attenuation value distribution of each of these lines:

Each of these lines are the differentiated and the last value is repeated in order to maintain the length. The following graph shows the differentiated graph of each of these lines:
 

 

X axis in both these graphs is the number of samples. The lowest value at each point on the x axis is taken so that there is no offset and so we get the following graph:

 

 

The FFT of this is taken and half of the values are used as the other half are complex conjugate. Before passing to the FFT function the array with the differentiated values is padded with the last value in the array so that the size of the array is a power of 2. From the FFT we get the following result.

Here the result is as expected. Now the same procedure is repeated with just one difference. The sampling rate is now 0.02 mm instead of 0.01 mm as before. The MTF from this look like:

Here the result is as expected. Now the same procedure is repeated with just one difference. The sampling rate is now 0.02 mm instead of 0.01 mm as before. The MTF from this look like:

 

Similar results are seen with sampling rates of 0.03,0.04. Sampling rate of 0.05 works fine. X axis in case of MTF is represented in line pairs/mm. The FFT is carried out using the Intel library IPP. When using Matlab all MTF graphs show same form as here shown in the graph with sampling rate 0.01 mm.

I wanted to ask if this is due to the misalignment with DFT bins or is there something happening in the FFT function. If this is the case then why does it work fine with Matlab? I also tried increasing the sampling rate to 0.001 mm and 0.002 mm and the results seem fine in that case but I am ruling out aliasing because the results with 0.05 mm are fine as mentioned before.


Viewing all articles
Browse latest Browse all 1294

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>