From a781b39dab69d3f63362cb026ab4ce5fcb5eff15 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ji=C5=99=C3=AD=20Jano=C5=A1?= <88504448+JanosJiri@users.noreply.github.com> Date: Tue, 10 Dec 2024 12:58:42 +0100 Subject: [PATCH] Ignoring BA sigma for ignor_state (#197) --- src/surfacehop.F90 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/surfacehop.F90 b/src/surfacehop.F90 index a268d77e..da4aa731 100644 --- a/src/surfacehop.F90 +++ b/src/surfacehop.F90 @@ -609,6 +609,8 @@ subroutine calc_baeckan(dt) do ist1 = 1, nstate do ist2 = ist1 + 1, nstate + ! If ignore_state is set, we do not calculate sigma (dotproduct) for this state + if (ignore_state == ist1 .or. ignore_state == ist2) cycle de = en_hist_array(ist2, :) - en_hist_array(ist1, :) ! Second derivative (de2dt2) comes from Eq. 16 from https://doi.org/10.12688/openreseurope.13624.2 de2dt2 = (2.0D0 * de(1) - 5.0D0 * de(2) + 4.0D0 * de(3) - de(4)) / dt**2