USER_PROBLEM: Fix slice selection for the magnetic flux integration.

Signed-off-by: Grzegorz Kowal <grzegorz@amuncode.org>
This commit is contained in:
Grzegorz Kowal 2022-11-04 19:30:13 -03:00
parent 8a66bc5769
commit 0f8aed46a1

View File

@ -671,11 +671,11 @@ module user_problem
x(:) = pmeta%xmin + ax(pmeta%level,:)
i = nb
do while(abs(x(i)) > dh(1))
do while(abs(x(i)) > dh(1) .and. i <= ne)
i = i + 1
end do
if (nb <= i .and. i <= ne) then
if (nb < i .and. i <= ne) then
dyz = ady(pmeta%level) * adz(pmeta%level)
@ -866,7 +866,7 @@ module user_problem
rterms(7) = eta * rterms(6)
rterms(8) = eta * rterms(7)
write(runit,"(9es25.15e3)") time, 5.0d-01 * rterms(1:8)
write(runit,"(9es25.15e3)") time, rterms(1:8)
call flush_and_sync(runit)
100 continue