Add scaling parameter to input for pseudopotential optimization

svn-origin-rev: 18418
This commit is contained in:
Jürg Hutter 2018-05-09 08:35:52 +00:00
parent d71a0c0f80
commit e2eae28d33
2 changed files with 11 additions and 3 deletions

View file

@ -495,8 +495,8 @@ CONTAINS
INTEGER, DIMENSION(0:lmat) :: ncore
LOGICAL :: explicit
REAL(KIND=dp) :: afun, charge, de, deig, drho, dx, eig, fopt, oc, pchg, peig, pv, rcm, rcov, &
rmax, semicore_level, t_ener, t_psir0, t_semi, t_valence, t_virt, w_ener, w_node, &
w_psir0, w_semi, w_valence, w_virt, wtot
rmax, semicore_level, step_size_scaling, t_ener, t_psir0, t_semi, t_valence, t_virt, &
w_ener, w_node, w_psir0, w_semi, w_valence, w_virt, wtot
REAL(KIND=dp), ALLOCATABLE, DIMENSION(:) :: x, xi
REAL(KIND=dp), ALLOCATABLE, DIMENSION(:, :) :: wem
REAL(KIND=dp), ALLOCATABLE, &
@ -511,6 +511,7 @@ CONTAINS
CALL section_vals_val_get(powell_section, "STEP_SIZE", r_val=ostate%rhobeg)
CALL section_vals_val_get(powell_section, "MAX_FUN", i_val=ostate%maxfun)
CALL section_vals_val_get(powell_section, "MAX_INIT", i_val=nreinit)
CALL section_vals_val_get(powell_section, "STEP_SIZE_SCALING", r_val=step_size_scaling)
CALL section_vals_val_get(powell_section, "WEIGHT_POT_VALENCE", r_val=w_valence)
CALL section_vals_val_get(powell_section, "WEIGHT_POT_VIRTUAL", r_val=w_virt)
@ -938,7 +939,7 @@ CONTAINS
CALL atom_write_pseudo_param(ppot%gth_pot)
! dx < SQRT(ostate%rhoend)
IF ((dx*dx) < ostate%rhoend) EXIT
ostate%rhobeg = 0.75_dp*ostate%rhobeg
ostate%rhobeg = step_size_scaling*ostate%rhobeg
END DO
DEALLOCATE (xi)

View file

@ -1110,6 +1110,13 @@ CONTAINS
CALL section_add_keyword(section, keyword)
CALL keyword_release(keyword)
CALL keyword_create(keyword, name="STEP_SIZE_SCALING", &
description="Scaling of Step Size on re-initialization of Powell method", &
usage="STEP_SIZE_SCALING 0.80", &
default_r_val=0.75_dp)
CALL section_add_keyword(section, keyword)
CALL keyword_release(keyword)
CALL keyword_create(keyword, name="WEIGHT_POT_VIRTUAL", &
description="Weight for virtual states in pseudopotential optimization", &
usage="WEIGHT_POT_VIRTUAL 1.0", &