6subroutine rfpts(np,vpl,rfmt,rfir,fp)
11integer,
intent(in) :: np
12real(8),
intent(in) :: vpl(3,np),rfmt(npmtmax,natmtot),rfir(ngtot)
13real(8),
intent(out) :: fp(np)
17complex(8),
allocatable :: zfft(:)
20zfft(1:ngtot)=rfir(1:ngtot)
40integer,
intent(in) :: ip
47real(8) ya(4,lmmaxo),rlm(lmmaxo)
57 else if (ir > nr-2)
then
75 i0=
lmmaxi*nri+lmmaxo*(ir-nri-1)
77 ya(j,1:lmmax)=rfmt(i0+1:i0+lmmax,ias)
88 v(1:3)=vpl(1,ip)*
avec(1:3,1)+vpl(2,ip)*
avec(1:3,2)+vpl(3,ip)*
avec(1:3,3)
92 t1=
vgc(1,ig)*v(1)+
vgc(2,ig)*v(2)+
vgc(3,ig)*v(3)
93 sm=sm+dble(zfft(
igfft(ig))*cmplx(cos(t1),sin(t1),8))
99pure real(8) function poly4(xa,ya,x)
102real(8),
intent(in) :: xa(4),ya(4),x
104real(8) x0,x1,x2,x3,y0,y1,y2,y3
105real(8) c1,c2,c3,t0,t1,t2,t3,t4,t5,t6
108x1=xa(2)-x0; x2=xa(3)-x0; x3=xa(4)-x0
110y1=ya(2)-y0; y2=ya(3)-y0; y3=ya(4)-y0
111t4=x1-x2; t5=x1-x3; t6=x2-x3
112t1=x1*x2*y3; t2=x2*x3*y1; t3=x1*x3
113t0=1.d0/(x2*t3*t4*t5*t6)
116t4=x1**2; t5=x2**2; t6=x3**2
117c2=t1*(t5-t4)+t2*(t6-t5)+t3*(t4-t6)
118c1=t1*(x2*t4-x1*t5)+t2*(x3*t5-x2*t6)+t3*(x1*t6-x3*t4)
121poly4=y0+t0*t1*(c1+t1*(c2+c3*t1))
subroutine findmtpt(vrl, ias, ir, v, r)
subroutine genrlmv(lmax, v, rlm)
integer, dimension(maxspecies) nrmti
integer, dimension(3) ngridg
integer, dimension(maxspecies) nrmt
real(8), dimension(:,:), allocatable rsp
integer, dimension(maxatoms *maxspecies) idxis
real(8), dimension(3, 3) avec
integer, dimension(:), allocatable igfft
real(8), dimension(:,:), allocatable vgc
subroutine holdthd(nloop, nthd)
subroutine rfpts(np, vpl, rfmt, rfir, fp)
pure real(8) function poly4(xa, ya, x)
subroutine zfftifc(nd, n, sgn, z)