From 82225d6b06ce057d58a5a73088639143f5276818 Mon Sep 17 00:00:00 2001 From: RevathiJambunathan Date: Wed, 24 Jan 2024 09:28:47 -0800 Subject: [PATCH] simplified_list and no need for assert in coarse, but if fine works, coarse should --- Source/BoundaryConditions/PML.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Source/BoundaryConditions/PML.cpp b/Source/BoundaryConditions/PML.cpp index 449e4ba2c84..2fddce5a406 100644 --- a/Source/BoundaryConditions/PML.cpp +++ b/Source/BoundaryConditions/PML.cpp @@ -568,7 +568,7 @@ PML::PML (const int lev, const BoxArray& grid_ba, const DistributionMapping& gri BoxArray grid_ba_reduced = grid_ba; if (do_pml_in_domain) { - BoxList bl = grid_ba.boxList(); + BoxList bl = grid_ba.simplified_list(); for (auto& b : bl) { for (int idim = 0; idim < AMREX_SPACEDIM; ++idim) { if (do_pml_Lo[idim]) { @@ -770,20 +770,18 @@ PML::PML (const int lev, const BoxArray& grid_ba, const DistributionMapping& gri BoxArray grid_cba_reduced = grid_cba; if (do_pml_in_domain) { - BoxList bl = grid_cba.boxList(); + BoxList bl = grid_cba.simplified_list(); for (auto& b : bl) { for (int idim = 0; idim < AMREX_SPACEDIM; ++idim) { if (do_pml_Lo[idim]) { Box const& bb = amrex::adjCellLo(b, idim); if ( ! grid_cba.intersects(bb) ) { - WARPX_ALWAYS_ASSERT_WITH_MESSAGE(b.length(idim) > ncell/ref_ratio[idim], " box length must be greater that pml size"); b.growLo(idim, -ncell/ref_ratio[idim]); } } if (do_pml_Hi[idim]) { Box const& bb = amrex::adjCellHi(b, idim); if ( ! grid_cba.intersects(bb) ) { - WARPX_ALWAYS_ASSERT_WITH_MESSAGE(b.length(idim) > ncell/ref_ratio[idim], " box length must be greater that pml size"); b.growHi(idim, -ncell/ref_ratio[idim]); } }