CP bug: namelist &ions must be read in all cases

Write charge density (if required) only at last step
Documentation updated


git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@211 c92efa57-630b-4861-b058-cf58834340f0
This commit is contained in:
giannozz 2003-05-14 16:09:14 +00:00
parent 02042117e2
commit 8f7900d5c9
3 changed files with 9 additions and 11 deletions

View File

@ -6752,12 +6752,6 @@
if (tpre) call drhov(irb,eigrb,rhovan,rhog,rhor)
!
call rhov(irb,eigrb,rhovan,rhog,rhor)
!
#ifdef __PARA
if(trhow) call write_rho(47,nspin,rhor)
#else
if(trhow) write(47) ((rhor(ir,iss),ir=1,nnr),iss=1,nspin)
#endif
endif
! ======================================endif for trhor=============
!

View File

@ -233,6 +233,7 @@
! general variables
!
tfirst=.true.
tlast =.false.
nacc=5
!
gausp=delt*sqrt(tempw/factem)
@ -722,6 +723,12 @@
!
call rhoofr (nfi,c0,irb,eigrb,bec,rhovan,rhor,rhog,rhos)
!
#ifdef __PARA
if(trhow .and. tlast) call write_rho(47,nspin,rhor)
#else
if(trhow .and. tlast) write(47) ((rhor(i,is),i=1,nnr),is=1,nspin)
#endif
!
! put core charge (if present) in rhoc(r)
!
if (nlcc.gt.0) call set_cc(irb,eigrb,rhoc)

View File

@ -352,11 +352,8 @@
if (ios /= 0) call errore ('reading','namelist &system',2)
READ (unit, electrons, iostat = ios )
if (ios /= 0) call errore ('reading','namelist &electrons',3)
if ( TRIM(calculation) == 'relax' .or. TRIM(calculation) == 'vc-relax' &
.or. TRIM(calculation) == 'cp' .or. TRIM(calculation) == 'vc-cp' ) then
READ (unit, ions, iostat = ios )
if (ios /= 0) call errore ('reading','namelist &ions',4)
end if
READ (unit, ions, iostat = ios )
if (ios /= 0) call errore ('reading','namelist &ions',4)
if ( TRIM(calculation) == 'vc-cp' .or. &
TRIM(calculation) == 'vc-relax' ) then
READ (unit, cell, iostat = ios )