<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic FFTW3 normalization Question in Intel® oneAPI Math Kernel Library</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/FFTW3-normalization-Question/m-p/1717723#M37346</link>
    <description>&lt;P&gt;I cannot not figure out FFTW3 normalization process when going from spectral space to grid point space back to spectral space. The transforms on both sides consist of all real data.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;In a nutshell is do I need to normalize BOTH going from spectral to grid and grid to spectral or just going from spectral to grid?&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;I am integrating a dynamic system which has nonlinear terms. So every time step I need to transform from spectral to grid, perform some computations on the grid, and then transform back.&lt;/P&gt;&lt;P&gt;I need to calculate the following&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;J(A,B) = dA/dx * dB/dy - dA/dy * dB/dx 
where A(k,l) = (ac(k,l)cosknx + as(k,l)sinknx)sinly + az(l)cosly                                               and   B(k,l) = (bc(k,l)cosknx + bs(k,l)sinknx)sinly + bz(l)cosly&lt;/LI-CODE&gt;&lt;P&gt;So I have set up plans for each of these transform structures:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;cosknxsinly
sinknxsinly
cosknxcosly
sinknxcosly
sinly&lt;/LI-CODE&gt;&lt;P&gt;I compute the derivatives in spectral space but to do the multiplications I transform the spectral components to a data grid. Now I normalize each of the input spectral components by&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;cosknxsinly: Normalization factor is 1/(2*(Nx - 1)* 2*(Ny + 1))
sinknxsinly: Normalization factor is 1/(2*(Nx + 1)* 2*(Ny + 1))
cosknxcosly: Normalization factor is 1/(2*(Nx - 1)* 2*(Ny - 1))
sinknxcosly: Normalization factor is 1/(2*(Nx + 1)* 2*(Ny - 1))&lt;/LI-CODE&gt;&lt;P&gt;and do the transform.&lt;/P&gt;&lt;P&gt;I am assuming that the grid points I get are now what I want. Okay, now I have created a few of these grid arrays, do the necessary multiplications and have a final 2-d grid array of dimension G3(Nx, Ny).&amp;nbsp; Now I have transform back to spectral space. This will require several transforms.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;But my question is&lt;/STRONG&gt;, on the transform back do I need to normalize again? My understanding is that normalization is only needed going from spectral to grid. Going from grid to spectral normalization is not needed.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 18 Sep 2025 20:35:33 GMT</pubDate>
    <dc:creator>brianreinhold</dc:creator>
    <dc:date>2025-09-18T20:35:33Z</dc:date>
    <item>
      <title>FFTW3 normalization Question</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/FFTW3-normalization-Question/m-p/1717723#M37346</link>
      <description>&lt;P&gt;I cannot not figure out FFTW3 normalization process when going from spectral space to grid point space back to spectral space. The transforms on both sides consist of all real data.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;In a nutshell is do I need to normalize BOTH going from spectral to grid and grid to spectral or just going from spectral to grid?&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;I am integrating a dynamic system which has nonlinear terms. So every time step I need to transform from spectral to grid, perform some computations on the grid, and then transform back.&lt;/P&gt;&lt;P&gt;I need to calculate the following&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;J(A,B) = dA/dx * dB/dy - dA/dy * dB/dx 
where A(k,l) = (ac(k,l)cosknx + as(k,l)sinknx)sinly + az(l)cosly                                               and   B(k,l) = (bc(k,l)cosknx + bs(k,l)sinknx)sinly + bz(l)cosly&lt;/LI-CODE&gt;&lt;P&gt;So I have set up plans for each of these transform structures:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;cosknxsinly
sinknxsinly
cosknxcosly
sinknxcosly
sinly&lt;/LI-CODE&gt;&lt;P&gt;I compute the derivatives in spectral space but to do the multiplications I transform the spectral components to a data grid. Now I normalize each of the input spectral components by&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;cosknxsinly: Normalization factor is 1/(2*(Nx - 1)* 2*(Ny + 1))
sinknxsinly: Normalization factor is 1/(2*(Nx + 1)* 2*(Ny + 1))
cosknxcosly: Normalization factor is 1/(2*(Nx - 1)* 2*(Ny - 1))
sinknxcosly: Normalization factor is 1/(2*(Nx + 1)* 2*(Ny - 1))&lt;/LI-CODE&gt;&lt;P&gt;and do the transform.&lt;/P&gt;&lt;P&gt;I am assuming that the grid points I get are now what I want. Okay, now I have created a few of these grid arrays, do the necessary multiplications and have a final 2-d grid array of dimension G3(Nx, Ny).&amp;nbsp; Now I have transform back to spectral space. This will require several transforms.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;But my question is&lt;/STRONG&gt;, on the transform back do I need to normalize again? My understanding is that normalization is only needed going from spectral to grid. Going from grid to spectral normalization is not needed.&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 18 Sep 2025 20:35:33 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/FFTW3-normalization-Question/m-p/1717723#M37346</guid>
      <dc:creator>brianreinhold</dc:creator>
      <dc:date>2025-09-18T20:35:33Z</dc:date>
    </item>
  </channel>
</rss>

