# P3DFFT++ C++ examplesΒΆ

`test1D_cos.C` |
This program exemplifies the use of 1D transforms in P3DFFT++, using cosine 1D transform (DCT-1), for real-valued arrays. 1D transforms are performed on 3D arrays, in the dimension specified as an argument. This could be an isolated 1D transform or a stage in a multidimensional transform. This function can do local transposition, i.e. arbitrary input and output memory ordering. However it does not do an inter-processor transpose (see test_transMPI for that). |

`test1D_cos_complex.C` |
This program exemplifies the use of 1D transforms in P3DFFT++, using cosine 1D transform (DCT-1), for complex-valued arrays. 1D transforms are performed on 3D arrays, in the dimension specified as an argument. This could be an isolated 1D transform or a stage in a multidimensional transform. This function can do local transposition, i.e. arbitrary input and output memory ordering. However it does not do an inter-processor transpose (see test_transMPI for that). |

`test1D_sin.C` |
This program exemplifies the use of 1D transforms in P3DFFT++, using cosine 1D transform (DST-1), for real-valued arrays. 1D transforms are performed on 3D arrays, in the dimension specified as an argument. This could be an isolated 1D transform or a stage in a multidimensional transform. This function can do local transposition, i.e. arbitrary input and output memory ordering. However it does not do an inter-processor transpose (see test_transMPI for that). |

`test3D_c2c.C` |
This program exemplifies the use of P3DFFT++ for 3D complex-to-complex FFT using 2D domain decomposition (1D is a specific case). |

`test3D_c2c_inplace.C` |
This program exemplifies the use of P3DFFT++ for 3D complex-to-complex using 2D domain decomposition (1D is a specific case). This is an in-place transform example (output overwrites input, which is in the same array). |

`test3D_r2c.C` |
This program exemplifies the use of P3DFFT++ for 3D real-to-complex and complex-to-real FFT using 2D domain decomposition (1D is a specific case). |

`test3D_r2c_single.C` |
This program exemplifies the use of P3DFFT++ for 3D real-to-complex and complex-to-real FFT using 2D domain decomposition (1D is a specific case). This is a single precision version of test3D_r2c.C example. |

`test_deriv.C` |
This program exemplifies using P3DFFT++ library for taking a spectral derivative of a 3D array in a given dimension. |

`test_deriv2.C` |
This program exemplifies using P3DFFT++ library for taking a spectral derivative of a 3D array in a given dimension. Derivative is computed in this test program based on 3D FFT from P3DFFT++. |

`test_transplan.C` |
This program exemplifies the use of 1D transforms in P3DFFT++, using real-to-complex (R2C) 1D transform. 1D transforms are performed on 3D arrays, in the dimension specified as an argument. This could be an isolated 1D transform or a stage in a multidimensional transform. This function can do local transposition, i.e. arbitrary input and output memory ordering. However it does not do an inter-processor transpose (see test_transMPI for that). |