Parallel Three-Dimensional Fast Fourier Transforms, dubbed P3DFFT, is a library for large-scale computer simulations on parallel platforms. 3D FFT is an important algorithm for simulations in a wide range of fields, including studies of turbulence, climatology, astrophysics and material science. This project was initiated at San Diego Supercomputer Center (SDSC) at UC San Diego by its main author Dmitry Pekurovsky, Ph.D.

P3DFFT uses 2D, or pencil, decomposition. This overcomes an important limitation to scalability inherent in FFT libraries implementing 1D (or slab) decomposition: the number of processors/tasks used to run this problem in parallel can be as large as N2, where N is the linear problem size. This approach has shown good scalability up to 524,288 cores.

P3DFFT is written in Fortran90 and is optimized for parallel performance. It uses Message Passing Interface (MPI) for interprocessor communication, and starting from v.2.7.5 there is a multithreading option for hybrid MPI/OpenMP implementation. C interface is available, as are detailed documentation and examples in both Fortran and C. A configure script is supplied for ease of installation. This package depends on a serial FFT library such as Fastest Fourier Transform in the West (FFTW) or IBM's ESSL.

In the forward transform, given an input of an array of 3D real values, an output of 3D complex array of Fourier coefficients is returned. Current features include:

  • real-to-complex/complex-to-real FFT in 3D
  • real-to-complex FFT in 2D followed by sine/cosine/Chebyshev/empty transform, and the reverse for backward transform.
  • pruned transforms (less than full input or output)
  • in-place or out-of-place transforms
  • multi-variable transforms
  • multithreaded version (MPI/OpenMP)

For more information see the User Guide. For installation instructions click here.

Citation information

Please acknowledge/cite use of P3DFFT as follows: D. Pekurovsky, P3DFFT: a framework for parallel computations of Fourier transforms in three dimensions, SIAM Journal on Scientific Computing 2012, Vol. 34, No. 4, pp. C192-C209. This paper can be obtained here.

Version History

2.7.2 - 2.7.5 - Added multithreaded capability (MPI/openMP); additional example programs; bug fixes

2.7.1 - Added multi-variable transforms (p3dfft_ftran_r2c_many, p3dfft_btran_c2r_many)

2.6.1 - Added pruned transforms

Added user-defined communicator

2.5.1 - Added cosine/sine/Chebyshev/empty transform in addition to Fourier


Be sure to subscribe to the project mailing list where you can discuss topics of interest with other users and developers and get timely news regarding this library. Click on Issues tab above to see the list of outstanding problems or report a new problem or suggestion. You can also reach the main author Dmitry Pekurovsky here.

We are interested to hear your experiences, and suggestions for future releases. Please let us know if you are interested in contributing to future development of the library. The author is also interested in collaborating on computational science projects where 3D FFT and related transforms are applied.

Future work

  • One-sided communication
  • Generalized data layout options
This project is supported by National Science Foundation grant ACI-1339884.