10
1
mirror of https://gitlab.com/scemama/qmcchem.git synced 2024-11-07 06:33:38 +01:00

Trapped max is 20, corrected bug in wDMC weights (+1)

This commit is contained in:
Anthony Scemama 2016-01-12 22:05:22 +01:00
parent 837435f646
commit 76d2e4a491
2 changed files with 5 additions and 6 deletions

View File

@ -87,7 +87,7 @@ END_SHELL
cpu2 = cpu0
do while (loop)
! Move to the next projection step
dmc_projection_step = mod(dmc_projection_step+1,dmc_projection)+1
dmc_projection_step = mod(dmc_projection_step,dmc_projection)+1
! Remove contribution of the old value of the weight at the new
! projection step
@ -255,7 +255,7 @@ BEGIN_PROVIDER [ double precision, pop_weight_mult ]
BEGIN_DOC
! Population weight of DMC
END_DOC
pop_weight_mult = 1.d0
pop_weight_mult = pop_weight(dmc_projection)
END_PROVIDER
BEGIN_PROVIDER [ integer, dmc_projection ]
@ -274,5 +274,6 @@ BEGIN_PROVIDER [ double precision, pop_weight, (dmc_projection) ]
! Population weight of DMC
END_DOC
pop_weight = 1.d0
pop_weight(dmc_projection) = 1.d0/dble(dmc_projection)
END_PROVIDER

View File

@ -178,9 +178,7 @@ END_SHELL
enddo
if (qmc_method == t_DMC) then
! if ( (trapped_walk(i_walk) < trapped_walk_max).and. &
! (psi_value * psi_value_save(i_walk) > 0.d0).and. &
! (dabs(E_ref-E_loc)*time_step_sq < -.2d0*E_ref) ) then
if ( (trapped_walk(i_walk) < trapped_walk_max).and. &
(psi_value * psi_value_save(i_walk) >= 0.d0) ) then
dmc_weight(i_walk) = dexp(dtime_step*(E_ref - E_loc))
@ -263,6 +261,6 @@ BEGIN_PROVIDER [ integer, trapped_walk_max ]
BEGIN_DOC
! Max number of trapped MC steps before killing walker
END_DOC
trapped_walk_max = 5
trapped_walk_max = 20
END_PROVIDER