Skip to content

Commit

Permalink
Update src/DynamicsMethods/SurfaceHoppingMethods/surface_hopping.jl
Browse files Browse the repository at this point in the history
Co-authored-by: James Gardner <38594562+jamesgardner1421@users.noreply.github.com>
  • Loading branch information
reinimaurer1 and jamesgardner1421 authored Dec 11, 2023
1 parent d0a1dcd commit 3bf00ff
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ Measures the component of velocity along the nonadiabatic coupling vector and in
function frustrated_hop_invert_velocity!(
sim::AbstractSimulation{<:SurfaceHopping}, velocity, d
)
dn = d/norm(d)
dn = LinearAlgebra.normalize(d)
γ = dot(velocity,dn)
for I in CartesianIndices(dn)
velocity[I] -= 2γ * dn[I]
Expand Down

0 comments on commit 3bf00ff

Please sign in to comment.