<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=iso-8859-1"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
h1
        {mso-style-priority:9;
        mso-style-link:"Título 1 Car";
        margin-top:24.0pt;
        margin-right:0cm;
        margin-bottom:0cm;
        margin-left:0cm;
        margin-bottom:.0001pt;
        line-height:115%;
        page-break-after:avoid;
        font-size:16.0pt;
        font-family:"Calibri","sans-serif";
        color:#365F91;
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EstiloCorreo17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.Ttulo1Car
        {mso-style-name:"Título 1 Car";
        mso-style-priority:9;
        mso-style-link:"Título 1";
        font-family:"Times New Roman","serif";
        color:#365F91;
        font-weight:bold;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 3.0cm 70.85pt 3.0cm;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=ES link=blue vlink=purple><div class=WordSection1><h1 align=center style='text-align:center'><span lang=EN-US>Inaccuracy in <i>fftw</i> calculation<o:p></o:p></span></h1><p class=MsoNormal><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span lang=EN-US>I am calculating the <i>fft</i> of an image which pixels are double with the FFTW library, for that purpose i am using the library fftw(</span><a href="http://www.fftw.org/"><span lang=EN-US>http://www.fftw.org/</span></a><span lang=EN-US>) library in Visual Studio 2008 and using ITK.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span lang=EN-US>When I calculate the fft from a double pointer, with the method  &#8216;<i>fftw_plan_dft_c2r_</i>2d&#8217;, it makes the calculation but introducing inaccuracy, it is around +- 0.5&#8230;<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span lang=EN-US>I don&#8217;t really know what is wrong, maybe the spacing between pixels? The type of the data used? Did someone have this problem or something similar before?<o:p></o:p></span></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>Many thanks in advanced.<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>Antonio Gómez Barquero<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal><span lang=ES-TRAD style='font-size:8.0pt;mso-fareast-language:ES'>Ingeniero de Telecomunicaciones -Becario Investigador asociado a Actividades de I+D+I <o:p></o:p></span></p><p class=MsoNormal><span lang=ES-TRAD style='font-size:8.0pt;mso-fareast-language:ES'>GTTS ( Grupo de Tratamiento y Teoría de la Señal)[ </span><span style='font-size:8.0pt;mso-fareast-language:ES'><a href="http://gtts.upct.es/"><span style='color:blue'>http://gtts.upct.es/</span></a></span><span lang=ES-TRAD style='font-size:8.0pt;mso-fareast-language:ES'>]<o:p></o:p></span></p><p class=MsoNormal><span lang=ES-TRAD style='font-size:8.0pt;mso-fareast-language:ES'>UPCT (Universidad Politécnica de Cartagena)[ </span><span style='font-size:8.0pt;mso-fareast-language:ES'><a href="http://www.upct.es/"><span style='color:blue'>http://www.upct.es/</span></a>]</span><span lang=ES-TRAD style='font-size:8.0pt;mso-fareast-language:ES'><o:p></o:p></span></p><p class=MsoNormal><o:p>&nbsp;</o:p></p></div></body></html>