From 6058ff439a207d6aecefb3a8cd18c8928bbd57fd Mon Sep 17 00:00:00 2001 From: Michael Kuhn Date: Fri, 20 Sep 2024 11:48:14 -0600 Subject: [PATCH] body-node tweak to iblank_to_mask_vof --- amr-wind/overset/overset_ops_routines.cpp | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/amr-wind/overset/overset_ops_routines.cpp b/amr-wind/overset/overset_ops_routines.cpp index 6447342d99..f8a4466262 100644 --- a/amr-wind/overset/overset_ops_routines.cpp +++ b/amr-wind/overset/overset_ops_routines.cpp @@ -33,8 +33,20 @@ void iblank_to_mask_vof( } } } + // Check nodes neighboring node for being near solid + bool near_solid = false; + for (int ii = i - 1; ii < i + 2; ii++) { + for (int jj = j - 1; jj < j + 2; jj++) { + for (int kk = k - 1; kk < k + 2; kk++) { + near_solid = ibarrs[nbx](ii, jj, kk) == 0 + ? true + : near_solid; + } + } + } // Do mask -1 cells near interface - if (ibarrs[nbx](i, j, k) == -1 && near_interface) { + if (ibarrs[nbx](i, j, k) == -1 && + (near_interface && !near_solid)) { marrs[nbx](i, j, k) = 1; } });