17 fft_alloc => fftw_alloc, fft_dealloc => fftw_dealloc,
fftw31dm,
fftw33d, &
20 #include "../../base/base_uses.f90"
25 CHARACTER(len=*),
PARAMETER,
PRIVATE :: moduleN =
'fft_lib'
29 PUBLIC :: fft_alloc, fft_dealloc
43 CHARACTER(len=*),
INTENT(IN) :: fftlib
63 INTEGER,
INTENT(IN) :: fft_type
64 CHARACTER(LEN=*),
INTENT(IN) :: wisdom_file
66 SELECT CASE (fft_type)
68 cpabort(
"fft_do_init")
84 INTEGER,
INTENT(IN) :: fft_type
85 CHARACTER(LEN=*),
INTENT(IN) :: wisdom_file
86 LOGICAL,
INTENT(IN) :: ionode
88 SELECT CASE (fft_type)
90 cpabort(
"fft_do_cleanup")
107 INTEGER,
INTENT(IN) :: fft_type
108 INTEGER,
DIMENSION(*) :: data
109 INTEGER,
INTENT(INOUT) :: max_length
111 SELECT CASE (fft_type)
113 cpabort(
"fft_get_lengths")
137 TYPE(fft_plan_type),
INTENT(INOUT) :: plan
138 INTEGER,
INTENT(IN) :: fft_type
139 LOGICAL,
INTENT(IN) :: fft_in_place
140 INTEGER,
INTENT(IN) :: fsign
141 INTEGER,
DIMENSION(3),
INTENT(IN) :: n
142 COMPLEX(KIND=dp),
DIMENSION(*),
INTENT(INOUT) :: zin, zout
143 INTEGER,
INTENT(IN) :: plan_style
145 plan%fft_type = fft_type
147 plan%fft_in_place = fft_in_place
152 IF (fft_type .EQ. 3)
THEN
171 SUBROUTINE fft_3d(plan, scale, zin, zout, stat)
172 TYPE(fft_plan_type),
INTENT(IN) :: plan
173 REAL(kind=
dp),
INTENT(IN) :: scale
174 COMPLEX(KIND=dp),
DIMENSION(*),
INTENT(INOUT) :: zin, zout
175 INTEGER,
INTENT(OUT) :: stat
178 IF (plan%n_3d(1)*plan%n_3d(2)*plan%n_3d(3) > 0)
THEN
179 SELECT CASE (plan%fft_type)
183 CALL fftsg3d(plan%fft_in_place, stat, scale, plan%n_3d, zin, zout)
185 CALL fftw33d(plan, scale, zin, zout, stat)
189 IF (stat .EQ. 0)
THEN
212 TYPE(fft_plan_type),
INTENT(INOUT) :: plan
213 INTEGER,
INTENT(IN) :: fft_type, fsign
214 LOGICAL,
INTENT(IN) :: trans
215 INTEGER,
INTENT(IN) :: n, m
216 COMPLEX(KIND=dp),
DIMENSION(*),
INTENT(IN) :: zin, zout
217 INTEGER,
INTENT(IN) :: plan_style
219 plan%fft_type = fft_type
227 IF ((fft_type .EQ. 3) .AND. (n*m .NE. 0))
THEN
241 TYPE(fft_plan_type),
INTENT(INOUT) :: plan
245 IF (plan%valid .AND. plan%fft_type .EQ. 3)
THEN
260 SUBROUTINE fft_1dm(plan, zin, zout, scale, stat)
261 TYPE(fft_plan_type),
INTENT(IN) :: plan
262 COMPLEX(KIND=dp),
DIMENSION(*),
INTENT(INOUT) :: zin, zout
263 REAL(kind=
dp),
INTENT(IN) :: scale
264 INTEGER,
INTENT(OUT) :: stat
267 IF (plan%n*plan%m > 0)
THEN
268 SELECT CASE (plan%fft_type)
272 CALL fftsg1dm(stat, plan%trans, plan%n, plan%m, zin, zout, scale)
274 CALL fftw31dm(plan, zin, zout, scale, stat)
278 IF (stat .EQ. 0)
THEN
Defines the basic variable types.
integer, parameter, public dp
subroutine, public fft_do_init(fft_type, wisdom_file)
...
subroutine, public fft_3d(plan, scale, zin, zout, stat)
...
subroutine, public fft_create_plan_1dm(plan, fft_type, fsign, trans, n, m, zin, zout, plan_style)
...
subroutine, public fft_destroy_plan(plan)
...
subroutine, public fft_get_lengths(fft_type, DATA, max_length)
...
integer function, public fft_library(fftlib)
Interface to FFT libraries.
subroutine, public fft_1dm(plan, zin, zout, scale, stat)
...
subroutine, public fft_create_plan_3d(plan, fft_type, fft_in_place, fsign, n, zin, zout, plan_style)
...
subroutine, public fft_do_cleanup(fft_type, wisdom_file, ionode)
...
Type to store data about a (1D or 3D) FFT, including FFTW plan.
subroutine, public fftsg1dm(fsign, trans, n, m, zin, zout, scale)
...
subroutine, public fftsg_do_init()
...
subroutine, public fftsg_get_lengths(DATA, max_length)
...
subroutine, public fftsg_do_cleanup()
...
subroutine, public fftsg3d(fft_in_place, fsign, scale, n, zin, zout)
...
subroutine, public fftw3_do_cleanup(wisdom_file, ionode)
...
subroutine, public fftw3_destroy_plan(plan)
...
subroutine, public fftw3_create_plan_3d(plan, zin, zout, plan_style)
...
subroutine, public fftw3_get_lengths(DATA, max_length)
...
subroutine, public fftw33d(plan, scale, zin, zout, stat)
...
subroutine, public fftw31dm(plan, zin, zout, scale, stat)
...
subroutine, public fftw3_do_init(wisdom_file)
...
subroutine, public fftw3_create_plan_1dm(plan, zin, zout, plan_style)
...