In the normalization of the MTF, you normalize on the second element:
tmp = ft_fit[1];
for (i=0; i<ft_len; i++) {
ft_fit[i]= ft_fit[i]/tmp;
}
Why not ft_fit[0]?
I suppose your comment has something to do with it, but I don't really see what you mean...
// imagej FT is squared sum of positive negative spatial frequencies, except for FT(0)