2d Functions and their 2d Fourier coefficients

Created with ❤️ by Machine Learning & Simulation.

Follow @felix_m_koehler

Using the conventions of numpy.fft: Normalization by 1/N on the inverse transform, ordering starts at zero mode, then positive modes in ascending order, then negative modes in ascending order (starting at the "most negative") N is always the number of dof

Function Fourier Coefficients
Example for N=5×5 on Ω=[0,2π)2
spatial grid x=[[00][0152π][0252π][0352π][0452π][152π0][152π152π][152π252π][152π352π][152π452π][252π0][252π152π][252π252π][252π352π][252π452π][352π0][352π152π][352π252π][352π352π][352π452π][452π0][452π152π][452π252π][452π352π][452π452π]]
wavenumber grid using "ij" convention k=[[00][01][02][02][01][10][11][12][12][11][20][21][22][22][21][20][21][22][22][21][10][11][12][12][11]]
u(x)=a u^h=[[a520][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00]][0i]
u(x)=ai u^h=[[0a52][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00]][0i]
u(x)=asin(1x0) u^h=[[00][00][00][00][00][0a522][00][00][00][00][00][00][00][00][00][00][00][00][00][00][0a522][00][00][00][00]][0i]
u(x)=acos(1x0) u^h=[[00][00][00][00][00][a5220][00][00][00][00][00][00][00][00][00][00][00][00][00][00][a5220][00][00][00][00]][0i]
u(x)=aisin(1x0) u^h=[[00][00][00][00][00][a5220][00][00][00][00][00][00][00][00][00][00][00][00][00][00][a5220][00][00][00][00]][0i]
u(x)=aicos(1x0) u^h=[[00][00][00][00][00][0a522][00][00][00][00][00][00][00][00][00][00][00][00][00][00][0a522][00][00][00][00]][0i]
u(x)=asin(1x1) u^h=[[00][0a522][00][00][0a522][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00]][0i]
u(x)=acos(1x1) u^h=[[00][a5220][00][00][a5220][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00]][0i]
u(x)=aisin(1x1) u^h=[[00][a5220][00][00][a5220][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00]][0i]
u(x)=aicos(1x1) u^h=[[00][0a522][00][00][0a522][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00]][0i]
u(x)=asin(1x0)sin(1x1) u^h=[[00][00][00][00][00][00][a5240][00][00][a5240][00][00][00][00][00][00][00][00][00][00][00][a5240][00][00][a5240]][0i]
template u(x)= u^h=[[00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00][00]][0i]