The Elk Code
cfcmtwr.f90
Go to the documentation of this file.
1 
2 ! Copyright (C) 2022 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 pure subroutine cfcmtwr(nr,nri,wr,cfmt)
7 use modmain
8 implicit none
9 ! arguments
10 integer, intent(in) :: nr,nri
11 real(8), intent(in) :: wr(nr)
12 complex(4), intent(inout) :: cfmt(*)
13 ! local variables
14 integer n,ir,i
15 real(8) t1
16 i=1
17 if (lmaxi == 1) then
18  do ir=1,nri
19  cfmt(i:i+3)=(pi*wr(ir))*cfmt(i:i+3)
20  i=i+4
21  end do
22 else
23  t1=fourpi/dble(lmmaxi)
24  n=lmmaxi-1
25  do ir=1,nri
26  cfmt(i:i+n)=(t1*wr(ir))*cfmt(i:i+n)
27  i=i+lmmaxi
28  end do
29 end if
30 t1=fourpi/dble(lmmaxo)
31 n=lmmaxo-1
32 do ir=nri+1,nr
33  cfmt(i:i+n)=(t1*wr(ir))*cfmt(i:i+n)
34  i=i+lmmaxo
35 end do
36 end subroutine
37 
integer lmmaxo
Definition: modmain.f90:203
real(8), parameter pi
Definition: modmain.f90:1232
integer lmmaxi
Definition: modmain.f90:207
real(8), parameter fourpi
Definition: modmain.f90:1234
pure subroutine cfcmtwr(nr, nri, wr, cfmt)
Definition: cfcmtwr.f90:7
integer lmaxi
Definition: modmain.f90:205