From 3ef89c687399c2724ceba1841e35bb6acbca9b00 Mon Sep 17 00:00:00 2001 From: Andrew Myers Date: Mon, 25 Oct 2021 14:20:15 -0700 Subject: Bugfixes for ref_ratio = 4 in the moving window direction. (#2452) * Bugfixes for ref_ratio = 4 in the moving window direction. * == should be <= * only adjust guard cells for moving window by ref_ratio if nlevs > 1 * restore logic to always have at least 2 grow cells if moving window is on * remove comment about this not being needed on level 0 - it does. --- Source/Utils/WarpXMovingWindow.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Source/Utils/WarpXMovingWindow.cpp') diff --git a/Source/Utils/WarpXMovingWindow.cpp b/Source/Utils/WarpXMovingWindow.cpp index a95b58a41..d4fa74683 100644 --- a/Source/Utils/WarpXMovingWindow.cpp +++ b/Source/Utils/WarpXMovingWindow.cpp @@ -286,7 +286,7 @@ WarpX::shiftMF (MultiFab& mf, const Geometry& geom, int num_shift, int dir, const int nc = mf.nComp(); const IntVect& ng = mf.nGrowVect(); - AMREX_ALWAYS_ASSERT(ng.min() >= num_shift); + AMREX_ALWAYS_ASSERT(ng[dir] >= num_shift); MultiFab tmpmf(ba, dm, nc, ng); MultiFab::Copy(tmpmf, mf, 0, 0, nc, ng); -- cgit v1.2.3