9 subroutine getevecfv(fext,ikp,vpl,vgpl,evecfv)
32 character(*),
intent(in) :: fext
33 integer,
intent(in) :: ikp
34 real(8),
intent(in) :: vpl(3),vgpl(3,ngkmax,nspnfv)
35 complex(8),
intent(out) :: evecfv(nmatmax,nstfv,nspnfv)
38 integer isym,lspl,ilspl
39 integer jspn,ilo,l,lm,i,j
40 integer ik,ngk_,igp,igk,ig
41 integer is,ia,ja,ias,jas
42 integer recl,nmatmax_,nstfv_,nspnfv_
43 real(8) vkl_(3),v(3),si(3,3),t1
53 fname=trim(
scrpath)//
'EVECFV'//trim(fext)
57 call getrd(fname,ik,tgs,v1=vkl_,n1=nmatmax_,n2=nstfv_,n3=nspnfv_, &
58 nzv=nmatmax*nstfv*nspnfv,zva=evecfv)
62 inquire(iolength=recl) vkl_,nmatmax_,nstfv_,nspnfv_,evecfv
63 open(202,
file=fname,form=
'UNFORMATTED',access=
'DIRECT',recl=recl)
64 read(202,rec=ik) vkl_,nmatmax_,nstfv_,nspnfv_,evecfv
68 t1=abs(
vkl(1,ik)-vkl_(1))+abs(
vkl(2,ik)-vkl_(2))+abs(
vkl(3,ik)-vkl_(3))
71 write(*,
'("Error(getevecfv): differing vectors for k-point ",I0)') ik
72 write(*,
'(" current : ",3G18.10)')
vkl(:,ik)
73 write(*,
'(" EVECFV.OUT : ",3G18.10)') vkl_
77 if (nmatmax /= nmatmax_)
then 79 write(*,
'("Error(getevecfv): differing nmatmax for k-point ",I0)') ik
80 write(*,
'(" current : ",I0)') nmatmax
81 write(*,
'(" EVECFV.OUT : ",I0)') nmatmax_
85 if (nstfv /= nstfv_)
then 87 write(*,
'("Error(getevecfv): differing nstfv for k-point ",I0)') ik
88 write(*,
'(" current : ",I0)') nstfv
89 write(*,
'(" EVECFV.OUT : ",I0)') nstfv_
93 if (nspnfv /= nspnfv_)
then 95 write(*,
'("Error(getevecfv): differing nspnfv for k-point ",I0)') ik
96 write(*,
'(" current : ",I0)') nspnfv
97 write(*,
'(" EVECFV.OUT : ",I0)') nspnfv_
103 t1=abs(vpl(1)-
vkl(1,ik))+abs(vpl(2)-
vkl(2,ik))+abs(vpl(3)-
vkl(3,ik))
107 complex(8) evecfv_(nmatmax,nstfv)
112 si(1:3,1:3)=dble(
symlat(1:3,1:3,ilspl))
121 evecfv_(1:ngk_,1:nstfv)=evecfv(1:ngk_,1:nstfv,jspn)
126 ig=
igkig(igk,jspn,ik)
127 t1=
vgc(1,ig)*v(1)+
vgc(2,ig)*v(2)+
vgc(3,ig)*v(3)
128 z1=cmplx(cos(t1),-sin(t1),8)
129 evecfv_(igk,1:nstfv)=z1*evecfv(igk,1:nstfv,jspn)
141 t1=abs(v(1)-vgpl(1,igp,jspn)) &
142 +abs(v(2)-vgpl(2,igp,jspn)) &
143 +abs(v(3)-vgpl(3,igp,jspn))
145 evecfv(igp,1:nstfv,jspn)=evecfv_(igk,1:nstfv)
164 do i=ngk_+1,
nmat(jspn,ik)
165 evecfv_(i,1:nstfv)=evecfv(i,1:nstfv,jspn)
175 z1=cmplx(cos(t1),sin(t1),8)
177 z1=z1*cmplx(cos(t1),sin(t1),8)
182 i=ngk_+
idxlo(lm,ilo,ias)
183 j=ngk_+
idxlo(lm,ilo,jas)
185 evecfv_(j,1),evecfv(i,1,jspn))
186 evecfv(i:i+2*l,1:nstfv,jspn)=z1*evecfv(i:i+2*l,1:nstfv,jspn)
pure subroutine r3mtv(a, x, y)
integer, dimension(maxspecies) nlorb
integer, dimension(:,:,:), allocatable idxlo
integer, dimension(maxatoms, maxspecies) idxas
subroutine getevecfv(fext, ikp, vpl, vgpl, evecfv)
integer, dimension(48) isymlat
type(file_t), dimension(:), allocatable, private file
integer, dimension(3, 3, 48) symlat
integer, dimension(:,:,:), allocatable ieqatom
logical, dimension(maxsymcrys) tv0symc
subroutine getrd(fname, irec, tgs, n1, n2, n3, v1, v2, nrv, rva, nzv, zva)
real(8), dimension(:,:), allocatable vgc
integer, dimension(:,:), allocatable nmat
integer, dimension(:,:), allocatable ngk
real(8), dimension(3, maxatoms, maxspecies) atposl
integer, dimension(maxsymcrys) lsplsymc
real(8), dimension(:,:,:,:), allocatable vgkl
real(8), dimension(3, 3, 48) symlatc
real(8), dimension(:,:), allocatable vkl
integer, dimension(maxspecies) natoms
subroutine findkpt(vpl, isym, ik)
integer, dimension(maxlorb, maxspecies) lorbl
integer, dimension(:,:,:), allocatable igkig
subroutine rotzflm(rot, lmin, lmax, lmmax, n, ld, zflm1, zflm2)
real(8), dimension(3, maxsymcrys) vtcsymc