The Elk Code
zfirftoc.f90
Go to the documentation of this file.
1 
2 ! Copyright (C) 2024 J. K. Dewhurst and S. Sharma.
3 ! This file is distributed under the terms of the GNU General Public License.
4 ! See the file COPYING for license details.
5 
6 subroutine zfirftoc(zfir,zfirc)
7 use modmain
8 implicit none
9 ! arguments
10 complex(8), intent(in) :: zfir(ngtot)
11 complex(8), intent(out) :: zfirc(ngtc)
12 ! automatic arrays
13 complex(8) zfft(ngtot)
14 ! multiply by characteristic function and Fourier transform on fine grid
15 zfft(1:ngtot)=zfir(1:ngtot)*cfunir(1:ngtot)
16 call zfftifc(3,ngridg,-1,zfft)
17 zfirc(1:ngtc)=0.d0
18 zfirc(igfc(1:ngvc))=zfft(igfft(1:ngvc))
19 ! Fourier transform to real-space coarse grid
20 call zfftifc(3,ngdgc,1,zfirc)
21 end subroutine
22 
integer, dimension(3) ngridg
Definition: modmain.f90:386
subroutine zfirftoc(zfir, zfirc)
Definition: zfirftoc.f90:7
integer ngvc
Definition: modmain.f90:398
subroutine zfftifc(nd, n, sgn, z)
Definition: zfftifc_fftw.f90:7
integer, dimension(:), allocatable igfft
Definition: modmain.f90:406
integer, dimension(:), allocatable igfc
Definition: modmain.f90:410
real(8), dimension(:), allocatable cfunir
Definition: modmain.f90:436
integer, dimension(3) ngdgc
Definition: modmain.f90:388