From 27aaef9ee84edd0318ea8ac0b884565c392064db Mon Sep 17 00:00:00 2001 From: Michael B Kuhn <31661049+mbkuhn@users.noreply.github.com> Date: Fri, 18 Aug 2023 12:31:39 -0600 Subject: [PATCH] more general form for the sloshing tank case (#899) * center the disturbance regardless of domain bounds * better for testing with nalu-wind overset --- amr-wind/physics/multiphase/SloshingTank.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/amr-wind/physics/multiphase/SloshingTank.cpp b/amr-wind/physics/multiphase/SloshingTank.cpp index a4e4b92eb4..7558141c7c 100644 --- a/amr-wind/physics/multiphase/SloshingTank.cpp +++ b/amr-wind/physics/multiphase/SloshingTank.cpp @@ -47,8 +47,8 @@ void SloshingTank::initialize_fields(int level, const amrex::Geometry& geom) const amrex::Real z0 = water_level + Amp * std::exp( - -kappa * (std::pow(x - 0.5 * Lx, 2) + - std::pow(y - 0.5 * Ly, 2))); + -kappa * (std::pow(x - problo[0] - 0.5 * Lx, 2) + + std::pow(y - problo[1] - 0.5 * Ly, 2))); phi(i, j, k) = z0 - z; }); }