From 069fd36e36768c40936491f8608f9255fb564697 Mon Sep 17 00:00:00 2001 From: Candace Gilet Date: Wed, 3 Apr 2024 15:25:05 -0400 Subject: [PATCH] Fix fillpatch tracer (#95) for ntrac>1 --- src/boundary_conditions/incflo_fillpatch.cpp | 2 +- src/incflo_apply_corrector.cpp | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/boundary_conditions/incflo_fillpatch.cpp b/src/boundary_conditions/incflo_fillpatch.cpp index aa5f072c..e8c8e858 100644 --- a/src/boundary_conditions/incflo_fillpatch.cpp +++ b/src/boundary_conditions/incflo_fillpatch.cpp @@ -87,7 +87,7 @@ void incflo::fillpatch_tracer (int lev, Real time, MultiFab& tracer, int ng) FillPatchSingleLevel(tracer, IntVect(ng), time, {&(m_leveldata[lev]->tracer_o), &(m_leveldata[lev]->tracer)}, - {m_t_old[lev], m_t_new[lev]}, 0, 0, 1, geom[lev], + {m_t_old[lev], m_t_new[lev]}, 0, 0, m_ntrac, geom[lev], physbc, 0); } else { const auto& bcrec = get_tracer_bcrec(); diff --git a/src/incflo_apply_corrector.cpp b/src/incflo_apply_corrector.cpp index 4b148306..5e1ee384 100644 --- a/src/incflo_apply_corrector.cpp +++ b/src/incflo_apply_corrector.cpp @@ -121,7 +121,7 @@ void incflo::ApplyCorrector() } } - // ********************************************************************************************** + // ************************************************************************************* // Compute the MAC-projected velocities at all levels // ************************************************************************************* bool include_pressure_gradient = !(m_use_mac_phi_in_godunov); @@ -131,9 +131,8 @@ void incflo::ApplyCorrector() compute_MAC_projected_velocities(get_velocity_new_const(), get_density_new_const(), AMREX_D_DECL(GetVecOfPtrs(u_mac), GetVecOfPtrs(v_mac), GetVecOfPtrs(w_mac)), GetVecOfPtrs(vel_forces), new_time); - // ********************************************************************************************** + // ************************************************************************************* // Compute the explicit "new" advective terms R_u^(n+1,*), R_r^(n+1,*) and R_t^(n+1,*) - // Note that "get_conv_tracer_new" returns div(rho u tracer) // ************************************************************************************* compute_convective_term(get_conv_velocity_new(), get_conv_density_new(), get_conv_tracer_new(), get_velocity_new_const(), get_density_new_const(), get_tracer_new_const(),