Skip to content

Commit

Permalink
allow for constant efield with Gaussian envelop (cp2k#3429)
Browse files Browse the repository at this point in the history
  • Loading branch information
marci73 authored May 24, 2024
1 parent 4da8881 commit e3f64b7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/efield_utils.F
Original file line number Diff line number Diff line change
Expand Up @@ -127,10 +127,11 @@ SUBROUTINE make_field(dft_control, field, sim_step, sim_time)

c = 137.03599962875_dp
field = 0._dp
nu = 0.0_dp
nfield = SIZE(dft_control%efield_fields)
DO i = 1, nfield
efield => dft_control%efield_fields(i)%efield
IF (.NOT. efield%envelop_id == custom_env) nu = c/(efield%wavelength) !in case of a custom efield we do not need nu
IF (.NOT. efield%envelop_id == custom_env .AND. efield%wavelength > EPSILON(0.0_dp)) nu = c/(efield%wavelength) !in case of a custom efield we do not need nu
strength = SQRT(efield%strength/(3.50944_dp*10.0_dp**16))
IF (DOT_PRODUCT(efield%polarisation, efield%polarisation) == 0) THEN
pol(:) = 1.0_dp/3.0_dp
Expand Down
2 changes: 1 addition & 1 deletion src/motion/gopt_f_methods.F
Original file line number Diff line number Diff line change
Expand Up @@ -621,7 +621,7 @@ SUBROUTINE check_converg(ndf, dr, g, output_unit, conv, gopt_param, max_memory,

ELSE
WRITE (UNIT=output_unit, FMT="(T2,2A)") &
" Conv. for gradients = ", &
" Conv. for RMS gradients = ", &
" NO"
END IF
IF (PRESENT(pres_diff) .AND. PRESENT(pres_tol)) THEN
Expand Down

0 comments on commit e3f64b7

Please sign in to comment.