From c01b5831d4d58e09eb721cf453cc52df9acad555 Mon Sep 17 00:00:00 2001 From: Andy Nonaka Date: Mon, 18 Nov 2024 11:31:25 -0800 Subject: [PATCH 1/2] fix bug when hi-x wall moves in the y-direction --- src_common/MultiFabPhysBC.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src_common/MultiFabPhysBC.cpp b/src_common/MultiFabPhysBC.cpp index 529efaf5..06948555 100644 --- a/src_common/MultiFabPhysBC.cpp +++ b/src_common/MultiFabPhysBC.cpp @@ -390,7 +390,7 @@ void MultiFabPhysBCMacVel(MultiFab& vel, const Geometry& geom, int dim, int is_i } } - if ((dim != 0) && (bc_vel_lo[0] == 1 || bc_vel_hi[0] == 2) && (bx.bigEnd(0) > dom.bigEnd(0))) { + if ((dim != 0) && (bc_vel_hi[0] == 1 || bc_vel_hi[0] == 2) && (bx.bigEnd(0) > dom.bigEnd(0))) { if (bc_vel_hi[0] == 1) { // slip amrex::ParallelFor(bx,[=] AMREX_GPU_DEVICE (int i, int j, int k) noexcept { From 6041c07a165cd28ea992c436347af05a286e4ad6 Mon Sep 17 00:00:00 2001 From: Andy Nonaka Date: Mon, 18 Nov 2024 11:47:47 -0800 Subject: [PATCH 2/2] fix moving wall solver in delta form --- exec/multispec/AdvanceTimestepBousq.cpp | 4 ++-- exec/multispec/AdvanceTimestepInertial.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/exec/multispec/AdvanceTimestepBousq.cpp b/exec/multispec/AdvanceTimestepBousq.cpp index 8d9f3931..bed33cd1 100644 --- a/exec/multispec/AdvanceTimestepBousq.cpp +++ b/exec/multispec/AdvanceTimestepBousq.cpp @@ -273,7 +273,7 @@ void AdvanceTimestepBousq(std::array< MultiFab, AMREX_SPACEDIM >& umac, // set normal velocity of physical domain boundaries MultiFabPhysBCDomainVel(umac[i],geom,i); // set transverse velocity behind physical boundaries - int is_inhomogeneous = 1; + int is_inhomogeneous = 0; MultiFabPhysBCMacVel(umac[i],geom,i,is_inhomogeneous); // fill periodic and interior ghost cells umac[i].FillBoundary(geom.periodicity()); @@ -707,7 +707,7 @@ void AdvanceTimestepBousq(std::array< MultiFab, AMREX_SPACEDIM >& umac, // set normal velocity of physical domain boundaries MultiFabPhysBCDomainVel(umac[i],geom,i); // set transverse velocity behind physical boundaries - int is_inhomogeneous = 1; + int is_inhomogeneous = 0; MultiFabPhysBCMacVel(umac[i],geom,i,is_inhomogeneous); // fill periodic and interior ghost cells umac[i].FillBoundary(geom.periodicity()); diff --git a/exec/multispec/AdvanceTimestepInertial.cpp b/exec/multispec/AdvanceTimestepInertial.cpp index bbfbc263..b89d1373 100644 --- a/exec/multispec/AdvanceTimestepInertial.cpp +++ b/exec/multispec/AdvanceTimestepInertial.cpp @@ -309,7 +309,7 @@ void AdvanceTimestepInertial(std::array< MultiFab, AMREX_SPACEDIM >& umac, // set normal velocity of physical domain boundaries MultiFabPhysBCDomainVel(umac[i],geom,i); // set transverse velocity behind physical boundaries - int is_inhomogeneous = 1; + int is_inhomogeneous = 0; MultiFabPhysBCMacVel(umac[i],geom,i,is_inhomogeneous); // fill periodic and interior ghost cells umac[i].FillBoundary(geom.periodicity()); @@ -598,7 +598,7 @@ void AdvanceTimestepInertial(std::array< MultiFab, AMREX_SPACEDIM >& umac, // set normal velocity of physical domain boundaries MultiFabPhysBCDomainVel(umac[i],geom,i); // set transverse velocity behind physical boundaries - int is_inhomogeneous = 1; + int is_inhomogeneous = 0; MultiFabPhysBCMacVel(umac[i],geom,i,is_inhomogeneous); // fill periodic and interior ghost cells umac[i].FillBoundary(geom.periodicity());