diff --git a/sources/statistics.F90 b/sources/statistics.F90 index 50cbbbc..c3e9556 100644 --- a/sources/statistics.F90 +++ b/sources/statistics.F90 @@ -1199,13 +1199,6 @@ module statistics end if ! track conservation -! sum up the injected energy and injection rate -! - if (forcing_enabled) then - lint(29) = einj - lint(30) = rinj - end if - gint = gint + lint gavg = gavg + lavg gmin = min(gmin, lmin) @@ -1217,6 +1210,13 @@ module statistics work_in_use(nt) = .false. !$omp end parallel +! sum up the injected energy and injection rate +! + if (forcing_enabled) then + gint(29) = gint(29) + einj + gint(30) = gint(30) + rinj + end if + #ifdef MPI ! sum the integral array from all processes !