cannam@167: cannam@167: cannam@167: cannam@167: cannam@167:
cannam@167:cannam@167: Previous: Overview of Fortran interface, Up: Overview of Fortran interface [Contents][Index]
cannam@167:If FFTW is compiled in long double
(extended) precision
cannam@167: (see Installation and Customization), you may be able to call the
cannam@167: resulting fftwl_
routines (see Precision) from Fortran if
cannam@167: your compiler supports the C_LONG_DOUBLE_COMPLEX
type code.
cannam@167:
Because some Fortran compilers do not support
cannam@167: C_LONG_DOUBLE_COMPLEX
, the fftwl_
declarations are
cannam@167: segregated into a separate interface file fftw3l.f03
, which you
cannam@167: should include in addition to fftw3.f03
(which declares
cannam@167: precision-independent ‘FFTW_’ constants):
cannam@167:
use, intrinsic :: iso_c_binding cannam@167: include 'fftw3.f03' cannam@167: include 'fftw3l.f03' cannam@167:
We also support using the nonstandard __float128
cannam@167: quadruple-precision type provided by recent versions of gcc
on
cannam@167: 32- and 64-bit x86 hardware (see Installation and Customization),
cannam@167: using the corresponding real(16)
and complex(16)
types
cannam@167: supported by gfortran
. The quadruple-precision ‘fftwq_’
cannam@167: functions (see Precision) are declared in a fftw3q.f03
cannam@167: interface file, which should be included in addition to
cannam@167: fftw3l.f03
, as above. You should also link with
cannam@167: -lfftw3q -lquadmath -lm
as in C.
cannam@167: