6 subroutine wfmtsv_sp(tsh,is,ias,nst,idx,ngp,apwalm,evecfv,evecsv,ld,wfmt)
11 logical,
intent(in) :: tsh
12 integer,
intent(in) :: is,ias,nst,idx(*),ngp(nspnfv)
13 complex(8),
intent(in) :: apwalm(ngkmax,apwordmax,lmmaxapw,natmtot,nspnfv)
14 complex(8),
intent(in) :: evecfv(nmatmax,nstfv,nspnfv),evecsv(nstsv,nstsv)
15 integer,
intent(in) :: ld
16 complex(4),
intent(out) :: wfmt(ld,nspinor,nst)
19 integer io,ilo,ispn,jspn
20 integer nrc,nrci,nrco,irco,npc,npci
21 integer l,lm,lma,lmb,nm
22 integer n,p,i,j,k,nthd
25 complex(8) x(nstfv,nspnfv),y(nlmwf(is),nspinor,nst)
26 complex(4) c(2*lmaxo+1)
28 complex(8),
external :: zdotu
52 lma=l**2+1; lmb=lma+2*l
61 x(j,jspn)=zdotu(n,evecfv(:,j,jspn),1,apwalm(:,io,lm,ias,jspn),1)
69 k=merge(j,idx(j),tasv)
70 y(p,1,j)=zdotu(nstfv,evecsv(1,k),1,x,1)
73 y(p,2,j)=zdotu(nstfv,evecsv(nstfv+1,k),1,x(1,jspn),1)
80 k=merge(j,idx(j),tasv)
81 y(p,1,j)=zdotu(ngp(1),evecfv(:,k,1),1,apwalm(:,io,lm,ias,1),1)
90 wfmt(1:npc,1:nspinor,j)=0.e0
101 if (
ssdph) c(1:nm)=c(1:nm)*zq(ispn)
103 call cfcrf(nm,nrci,
apwfr_sp(1,io,l,ias),c,
lmmaxi,wfmt(lma,ispn,j))
106 wfmt(npci+lma,ispn,j))
118 do lm=l**2+1,(l+1)**2
124 x(1:nstfv,jspn)=evecfv(n+i,1:nstfv,jspn)
128 k=merge(j,idx(j),tasv)
129 y(p,1,j)=zdotu(nstfv,evecsv(1,k),1,x,1)
132 y(p,2,j)=zdotu(nstfv,evecsv(nstfv+1,k),1,x(1,jspn),1)
138 k=merge(j,idx(j),tasv)
139 y(p,1,j)=evecfv(ngp(1)+i,k,1)
156 if (
ssdph) c(1:nm)=c(1:nm)*zq(ispn)
163 if (.not.tsh)
call cbshtip(nrc,nrci,wfmt(:,ispn,j))
172 pure subroutine cfcrf(m,n,rf,c,ld,cf)
175 integer,
intent(in) :: m,n
176 real(4),
intent(in) :: rf(n)
177 complex(4),
intent(in) :: c(m)
178 integer,
intent(in) :: ld
179 complex(4),
intent(inout) :: cf(ld,n)
183 cf(i,1:n)=cf(i,1:n)+c(i)*rf(1:n)
integer, dimension(maxspecies) npcmt
integer, dimension(maxspecies) nlorb
integer, dimension(:,:,:), allocatable idxlo
real(4), dimension(:,:,:), allocatable lofr_sp
complex(8), dimension(:), allocatable zqss
integer, dimension(0:maxlapw, maxspecies) apword
subroutine cbshtip(nr, nri, cfmt)
integer, dimension(maxspecies) npcmti
real(4), dimension(:,:,:,:), allocatable apwfr_sp
subroutine wfmtsv_sp(tsh, is, ias, nst, idx, ngp, apwalm, evecfv, evecsv, ld, wfmt)
subroutine holdthd(nloop, nthd)
integer, dimension(maxspecies) nrcmt
integer, dimension(maxspecies) nrcmti
integer, dimension(maxlorb, maxspecies) lorbl
pure subroutine cfcrf(m, n, rf, c, ld, cf)
integer, dimension(2) jspnfv