From 89325c316d4439ec325c4c3e36396b10a1653639 Mon Sep 17 00:00:00 2001 From: Zhi Date: Mon, 7 Oct 2024 15:21:40 -0400 Subject: [PATCH] fix logic --- Source/driver/Castro.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/driver/Castro.cpp b/Source/driver/Castro.cpp index a76ed50c78..750d7f0c8a 100644 --- a/Source/driver/Castro.cpp +++ b/Source/driver/Castro.cpp @@ -306,12 +306,12 @@ Castro::read_params () #elif (AMREX_SPACEDIM == 2) if ( dgeom.IsSPHERICAL() ) { - if ( (dgeom.ProbLo(1) >= 0.0_rt) && (dgeom.ProbHi(1) <= 3.14159265359_rt) ) + if ( (dgeom.ProbLo(1) < 0.0_rt) && (dgeom.ProbHi(1) > 3.14159265359_rt) ) { amrex::Abort("Theta must be within [0, Pi] for spherical coordinate system in 2D"); } - if ( dgeom.ProbLo(0) > static_cast(NUM_GROW) * dgeom.CellSize(0) ) + if ( dgeom.ProbLo(0) < static_cast(NUM_GROW) * dgeom.CellSize(0) ) { amrex::Abort("R-min must be large enough so ghost cells doesn't extend to negative R"); }