#include "petscmat.h" #include "petscvec.h" PetscErrorCode VecScatterPetscToFFTW(Mat A,Vec x,Vec y)Collective on Mat
| A | - FFTW matrix | |
| x | - the PETSc vector |
| y | - the FFTW vector |
| -mat_fftw_plannerflags | - set FFTW planner flags |
Note: For real parallel FFT, FFTW requires insertion of extra space at the end of last dimension. This required even when one is not doing in-place transform. The last dimension size must be changed to 2*(dim[last]/2+1) to accommodate these extra zeros. This routine does that job by scattering operation.