From c1c52b2b639a4bedf69be1c67ffea69204d82d40 Mon Sep 17 00:00:00 2001 From: "Navid C. Constantinou" Date: Mon, 1 Apr 2024 19:02:44 +0300 Subject: [PATCH] =?UTF-8?q?=CE=94z=E1=B6=9C=E1=B6=9C=E1=B6=9C(...=20,=20ib?= =?UTF-8?q?g::PCBIBG)=20works=20for=20grids=20with=20flat=20dims?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/ImmersedBoundaries/partial_cell_bottom.jl | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/ImmersedBoundaries/partial_cell_bottom.jl b/src/ImmersedBoundaries/partial_cell_bottom.jl index f00771e834..cce15e6e06 100644 --- a/src/ImmersedBoundaries/partial_cell_bottom.jl +++ b/src/ImmersedBoundaries/partial_cell_bottom.jl @@ -91,14 +91,14 @@ on_architecture(to, ib::PartialCellBottom) = PartialCellBottom(on_architecture(t ∘ k | Δz k --x-- ↓ -Criterion is h >= z - ϵ Δz +Criterion is h ≥ z - ϵ Δz """ @inline function _immersed_cell(i, j, k, underlying_grid, ib::PartialCellBottom) # Face node above current cell z = znode(i, j, k+1, underlying_grid, c, c, f) h = @inbounds ib.bottom_height[i, j, 1] - return z <= h + return z ≤ h end @inline bottom_cell(i, j, k, ibg::PCBIBG) = !immersed_cell(i, j, k, ibg.underlying_grid, ibg.immersed_boundary) & @@ -107,8 +107,9 @@ end @inline function Δzᶜᶜᶜ(i, j, k, ibg::PCBIBG) underlying_grid = ibg.underlying_grid ib = ibg.immersed_boundary + # Get node at face above and defining nodes on c,c,f - x, y, z = node(i, j, k+1, underlying_grid, c, c, f) + z = znode(i, j, k+1, underlying_grid, c, c, f) # Get bottom height and fractional Δz parameter h = @inbounds ib.bottom_height[i, j, 1]