28 use,
intrinsic :: iso_fortran_env
56 real(real64),
allocatable :: dop(:, :, :)
57 complex(real64),
allocatable :: zop(:, :, :)
61 real(real32),
allocatable :: sop(:, :, :)
62 complex(real32),
allocatable :: cop(:, :, :)
63 type(accel_mem_t) :: op_buffer
65 logical :: in_device_memory = .false.
68 real(real64),
allocatable,
public :: qq(:)
69 real(real64),
public :: singularity =
m_zero
70 real(real64),
public :: mu =
m_zero
71 real(real64),
public :: alpha =
m_zero
72 real(real64),
public :: beta =
m_zero
82 real(real64),
parameter,
public :: VANISHING_Q = 1.0e-5_real64
83 real(real64),
parameter :: TOL_VANISHING_Q = 1e-6_real64
95 class(fourier_space_op_t),
intent(inout) :: this
96 class(space_t),
intent(in) :: space
97 real(real64),
intent(in) :: qvector(:)
98 type(xc_cam_t),
intent(in) :: cam
99 real(real64),
optional,
intent(in) :: singularity
103 safe_allocate(this%qq(1:space%dim))
104 this%qq(1:space%periodic_dim) = qvector(1:space%periodic_dim)
105 this%qq(space%periodic_dim+1:space%dim) = vanishing_q
110 this%alpha = cam%alpha
119 class(fourier_space_op_t),
intent(inout) :: this
123 if (this%in_device_memory)
then
125 this%in_device_memory = .false.
127 safe_deallocate_a(this%dop)
128 safe_deallocate_a(this%zop)
129 safe_deallocate_a(this%sop)
130 safe_deallocate_a(this%cop)
131 safe_deallocate_a(this%qq)
138#include "fourier_space_inc.F90"
141#include "complex.F90"
142#include "fourier_space_inc.F90"
146#include "fourier_space_inc.F90"
149#include "complex32.F90"
150#include "fourier_space_inc.F90"
subroutine, public accel_free_buffer(this, async)
Fast Fourier Transform module. This module provides a single interface that works with different FFT ...
subroutine, public zfourier_space_op_apply(this, cube, cf)
Applies a multiplication factor to the Fourier space grid. This is a local function.
subroutine, public dfourier_space_op_apply(this, cube, cf)
Applies a multiplication factor to the Fourier space grid. This is a local function.
subroutine fourier_space_op_end(this)
Finalize an instance of fourier_space_op_t.
subroutine zfourier_space_op_set_op(this, cube, op, in_device, op_move)
Set the op buffer, which defines the kernel on the cube, in Fourier space.
subroutine, public sfourier_space_op_apply(this, cube, cf)
Applies a multiplication factor to the Fourier space grid. This is a local function.
subroutine fourier_space_op_init(this, space, qvector, cam, singularity)
Initialise a Fourier space Op instance.
subroutine dfourier_space_op_set_op(this, cube, op, in_device, op_move)
Set the op buffer, which defines the kernel on the cube, in Fourier space.
subroutine, public cfourier_space_op_apply(this, cube, cf)
Applies a multiplication factor to the Fourier space grid. This is a local function.
real(real64), parameter, public m_zero
This module is intended to contain "only mathematical" functions and procedures.
The low level module to work with the PFFT library. http:
Definition of a Fourier Space Coulomb Kernel.