Skip to content

Commit

Permalink
approximate away the hessian for rodft calculations and functionals t…
Browse files Browse the repository at this point in the history
…hat do not have second derivatives
  • Loading branch information
Niri Govind committed Jan 27, 2012
1 parent 289dc8a commit 4bbf3c1
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/nwdft/scf_dft_cg/dft_roks_hessv_2e.F
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ subroutine dft_roks_hessv_2e( basis, geom, nbf, nmo, nclosed,
c
double precision Exc(2)
integer nExc
logical xc_gotxc,xc_got2nd
logical xc_gotxc,xc_got2nd,rodft
double precision xc_hfexch
external xc_gotxc,xc_hfexch,xc_got2nd
c
Expand Down Expand Up @@ -276,7 +276,12 @@ subroutine dft_roks_hessv_2e( basis, geom, nbf, nmo, nclosed,
endif
c
c include hessian contribution only if second derivatives are available
if(xc_got2nd()) then
c and if the calculation is not a rodft calculation
c
if (.not. rtdb_get(rtdb, 'dft:rodft', mt_log, 1, rodft))
& rodft = .false. ! query the rtdb for the type of calculation

if(xc_got2nd().and. (.not. rodft)) then
call fock_xc(geom, nbf, basis, jfock, g_dd, g_ff,
+ Exc, nExc, .true.)
end if
Expand Down

0 comments on commit 4bbf3c1

Please sign in to comment.