The Elk Code
 
Loading...
Searching...
No Matches
gendvsig.f90
Go to the documentation of this file.
1
2! Copyright (C) 2013 J. K. Dewhurst, S. Sharma and E. K. U. Gross.
3! This file is distributed under the terms of the GNU General Public License.
4! See the file COPYING for license details.
5
6subroutine gendvsig
7use modmain
8use modphonon
9implicit none
10! allocatable arrays
11complex(8), allocatable :: zfft(:)
12allocate(zfft(ngtot))
13zfft(1:ngtot)=dvsir(1:ngtot)*cfunir(1:ngtot)
14zfft(1:ngtot)=zfft(1:ngtot)+vsir(1:ngtot)*dcfunir(1:ngtot)
15! Fourier transform to G+q-space
16call zfftifc(3,ngridg,-1,zfft)
17! store in global array
18dvsig(1:ngvc)=zfft(igfft(1:ngvc))
19deallocate(zfft)
20end subroutine
21
subroutine gendvsig
Definition gendvsig.f90:7
integer ngtot
Definition modmain.f90:390
integer, dimension(3) ngridg
Definition modmain.f90:386
real(8), dimension(:), allocatable cfunir
Definition modmain.f90:436
integer, dimension(:), allocatable igfft
Definition modmain.f90:406
real(8), dimension(:), allocatable vsir
Definition modmain.f90:651
integer ngvc
Definition modmain.f90:398
complex(8), dimension(:), allocatable dcfunir
Definition modphonon.f90:78
complex(8), dimension(:), allocatable dvsir
complex(8), dimension(:), pointer, contiguous dvsig
subroutine zfftifc(nd, n, sgn, z)