diff --git a/amr-wind/CFDSim.H b/amr-wind/CFDSim.H index c9ce4ab364..e343e48191 100644 --- a/amr-wind/CFDSim.H +++ b/amr-wind/CFDSim.H @@ -20,6 +20,10 @@ class OversetManager; class ExtSolverMgr; class HelicsStorage; +namespace transport { +class TransportModel; +} + namespace turbulence { class TurbulenceModel; } @@ -74,6 +78,12 @@ public: return m_physics_mgr.objects(); } + transport::TransportModel& transport_model() { return *m_transport; } + const transport::TransportModel& transport_model() const + { + return *m_transport; + } + turbulence::TurbulenceModel& turbulence_model() { return *m_turbulence; } const turbulence::TurbulenceModel& turbulence_model() const { @@ -103,6 +113,9 @@ public: bool has_overset() const; + //! Instantiate the transport model based on user inputs + void create_transport_model(); + //! Instantiate the turbulence model based on user inputs void create_turbulence_model(); @@ -137,6 +150,8 @@ private: PhysicsMgr m_physics_mgr; + std::unique_ptr m_transport; + std::unique_ptr m_turbulence; std::unique_ptr m_io_mgr; diff --git a/amr-wind/CFDSim.cpp b/amr-wind/CFDSim.cpp index 0ef2b113f4..1d46cbe870 100644 --- a/amr-wind/CFDSim.cpp +++ b/amr-wind/CFDSim.cpp @@ -1,4 +1,5 @@ #include "amr-wind/CFDSim.H" +#include "amr-wind/transport_models/TransportModel.H" #include "amr-wind/turbulence/TurbulenceModel.H" #include "amr-wind/utilities/IOManager.H" #include "amr-wind/utilities/PostProcessing.H" @@ -22,6 +23,17 @@ CFDSim::CFDSim(amrex::AmrCore& mesh) CFDSim::~CFDSim() = default; +void CFDSim::create_transport_model() +{ + std::string transport_model_name = "ConstTransport"; + { + amrex::ParmParse pp("transport"); + pp.query("model", transport_model_name); + } + m_transport = + transport::TransportModel::create(transport_model_name, *this); +} + void CFDSim::create_turbulence_model() { std::string transport_model_name = "ConstTransport"; diff --git a/amr-wind/equation_systems/icns/source_terms/ABLMeanBoussinesq.H b/amr-wind/equation_systems/icns/source_terms/ABLMeanBoussinesq.H index f1ef28fcc1..d4da314be0 100644 --- a/amr-wind/equation_systems/icns/source_terms/ABLMeanBoussinesq.H +++ b/amr-wind/equation_systems/icns/source_terms/ABLMeanBoussinesq.H @@ -2,6 +2,7 @@ #define ABLMEANBOUSSINESQ_H #include "amr-wind/core/FieldRepo.H" +#include "amr-wind/transport_models/TransportModel.H" #include "amr-wind/equation_systems/icns/MomentumSource.H" #include "amr-wind/utilities/FieldPlaneAveraging.H" @@ -42,11 +43,11 @@ private: amrex::Gpu::DeviceVector m_theta_ht; amrex::Gpu::DeviceVector m_theta_vals; - //! Reference temperature (Kelvin) - amrex::Real m_ref_theta{300.0}; + //! Transport model + const transport::TransportModel& m_transport; - //! Thermal expansion coefficient - amrex::Real m_beta{0.0}; + //! Reference temperature + std::unique_ptr m_ref_theta; int m_axis{2}; diff --git a/amr-wind/equation_systems/icns/source_terms/ABLMeanBoussinesq.cpp b/amr-wind/equation_systems/icns/source_terms/ABLMeanBoussinesq.cpp index 9aeb3dfe40..9d6d4031b7 100644 --- a/amr-wind/equation_systems/icns/source_terms/ABLMeanBoussinesq.cpp +++ b/amr-wind/equation_systems/icns/source_terms/ABLMeanBoussinesq.cpp @@ -8,50 +8,74 @@ namespace amr_wind::pde::icns { /** Boussinesq buoyancy source term for ABL simulations - * - * Reads in the following parameters from `ABLMeanBoussinesq` namespace: - * - * - `reference_temperature` (Mandatory) temperature (`T0`) in Kelvin - * - `thermal_expansion_coeff` Optional, default = `1.0 / T0` - * - `gravity` acceleration due to gravity (m/s) - * - `read_temperature_profile` - * - `tprofile_filename` */ -ABLMeanBoussinesq::ABLMeanBoussinesq(const CFDSim& sim) : m_mesh(sim.mesh()) -{ +ABLMeanBoussinesq::ABLMeanBoussinesq(const CFDSim& sim) + : m_mesh(sim.mesh()), m_transport(sim.transport_model()) +{ const auto& abl = sim.physics_manager().get(); abl.register_mean_boussinesq_term(this); - amrex::ParmParse pp_boussinesq_buoyancy("BoussinesqBuoyancy"); - pp_boussinesq_buoyancy.get("reference_temperature", m_ref_theta); - - if (pp_boussinesq_buoyancy.contains("thermal_expansion_coeff")) { - pp_boussinesq_buoyancy.get("thermal_expansion_coeff", m_beta); - } else { - m_beta = 1.0 / m_ref_theta; - } + m_ref_theta = m_transport.ref_theta(); // gravity in `incflo` namespace amrex::ParmParse pp_incflo("incflo"); pp_incflo.queryarr("gravity", m_gravity); - bool read_temp_prof = false; - pp_boussinesq_buoyancy.query("read_temperature_profile", read_temp_prof); - - if ((!pp_boussinesq_buoyancy.contains("read_temperature_profile") && - pp_boussinesq_buoyancy.contains("tprofile_filename")) || - read_temp_prof) { + // Backwards compatibility + amrex::ParmParse pp_boussinesq_buoyancy("BoussinesqBuoyancy"); + amrex::ParmParse pp_abl("ABLMeanBoussinesq"); - m_const_profile = true; + bool read_temp_prof = false; + if (pp_abl.contains("read_temperature_profile")) { + pp_abl.get("read_temperature_profile", read_temp_prof); + if (pp_boussinesq_buoyancy.contains("read_temperature_profile")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.read_temperature_profile " + "option has been deprecated in favor of " + "ABLMeanBoussinesq.read_temperature_profile. Ignoring the" + "BoussinesqBuoyancy option in favor of the " + "ABLMeanBoussinesq " + "option." + << std::endl; + } + } else if (pp_boussinesq_buoyancy.contains("read_temperature_profile")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.read_temperature_profile option " + "has been deprecated in favor of " + "ABLMeanBoussinesq.read_temperature_profile. Please replace " + "this option." + << std::endl; + pp_boussinesq_buoyancy.get("read_temperature_profile", read_temp_prof); + } - std::string tprofile_filename; + std::string tprofile_filename; + if (pp_abl.contains("temperature_profile_filename")) { + pp_abl.get("temperature_profile_filename", tprofile_filename); + if (pp_boussinesq_buoyancy.contains("tprofile_filename")) { + amrex::Print() << "WARNING: BoussinesqBuoyancy.tprofile_filename " + "option has been deprecated in favor of " + "ABLMeanBoussinesq.temperature_profile_filename. " + "Ignoring the" + "BoussinesqBuoyancy option in favor of the " + "ABLMeanBoussinesq " + "option." + << std::endl; + } + } else if (pp_boussinesq_buoyancy.contains("tprofile_filename")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.tprofile_filename option " + "has been deprecated in favor of " + "ABLMeanBoussinesq.temperature_profile_filename. Please replace " + "this option." + << std::endl; pp_boussinesq_buoyancy.get("tprofile_filename", tprofile_filename); + } + if ((read_temp_prof) && (tprofile_filename.empty())) { + m_const_profile = true; read_temperature_profile(tprofile_filename); - } else { - mean_temperature_init(abl.abl_statistics().theta_profile()); } } @@ -60,15 +84,19 @@ ABLMeanBoussinesq::~ABLMeanBoussinesq() = default; void ABLMeanBoussinesq::operator()( const int lev, - const amrex::MFIter& /*mfi*/, + const amrex::MFIter& mfi, const amrex::Box& bx, const FieldState /*fstate*/, const amrex::Array4& src_term) const { const auto& problo = m_mesh.Geom(lev).ProbLoArray(); const auto& dx = m_mesh.Geom(lev).CellSizeArray(); - const amrex::Real T0 = m_ref_theta; - const amrex::Real beta = m_beta; + + amrex::FArrayBox beta_fab(bx, 1, amrex::The_Async_Arena()); + amrex::Array4 const& beta_arr = beta_fab.array(); + m_transport.beta_impl(lev, mfi, bx, beta_arr); + + const auto& ref_theta = (*m_ref_theta)(lev).const_array(mfi); const amrex::GpuArray gravity{ m_gravity[0], m_gravity[1], m_gravity[2]}; @@ -82,9 +110,10 @@ void ABLMeanBoussinesq::operator()( amrex::ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept { amrex::IntVect iv(i, j, k); const amrex::Real ht = problo[idir] + (iv[idir] + 0.5) * dx[idir]; + const amrex::Real T0 = ref_theta(i, j, k); const amrex::Real temp = amr_wind::interp::linear(theights, theights_end, tvals, ht); - const amrex::Real fac = beta * (temp - T0); + const amrex::Real fac = beta_arr(i, j, k) * (temp - T0); src_term(i, j, k, 0) += gravity[0] * fac; src_term(i, j, k, 1) += gravity[1] * fac; src_term(i, j, k, 2) += gravity[2] * fac; diff --git a/amr-wind/equation_systems/icns/source_terms/BoussinesqBuoyancy.H b/amr-wind/equation_systems/icns/source_terms/BoussinesqBuoyancy.H index 341a9a8c5f..4774fd79ed 100644 --- a/amr-wind/equation_systems/icns/source_terms/BoussinesqBuoyancy.H +++ b/amr-wind/equation_systems/icns/source_terms/BoussinesqBuoyancy.H @@ -2,6 +2,7 @@ #define BOUSSINESQBUOYANCY_H #include "amr-wind/core/FieldRepo.H" +#include "amr-wind/transport_models/TransportModel.H" #include "amr-wind/equation_systems/icns/MomentumSource.H" namespace amr_wind::pde::icns { @@ -31,18 +32,14 @@ public: private: const Field& m_temperature; - const Field* m_vof; amrex::Vector m_gravity{0.0, 0.0, -9.81}; - //! Reference temperature (Kelvin) - amrex::Real m_ref_theta{300.0}; + //! Transport model + const transport::TransportModel& m_transport; - //! Thermal expansion coefficient - amrex::Real m_beta{0.0}; - - //! Check for VOF - bool m_is_vof{false}; + //! Reference temperature + std::unique_ptr m_ref_theta; }; } // namespace amr_wind::pde::icns diff --git a/amr-wind/equation_systems/icns/source_terms/BoussinesqBuoyancy.cpp b/amr-wind/equation_systems/icns/source_terms/BoussinesqBuoyancy.cpp index babd89de58..ab46706467 100644 --- a/amr-wind/equation_systems/icns/source_terms/BoussinesqBuoyancy.cpp +++ b/amr-wind/equation_systems/icns/source_terms/BoussinesqBuoyancy.cpp @@ -8,32 +8,12 @@ namespace amr_wind::pde::icns { /** Boussinesq buoyancy source term for ABL simulations * - * Reads in the following parameters from `BoussinesqBuoyancy` namespace: - * - * - `reference_temperature` (Mandatory) temperature (`T0`) in Kelvin - * - `thermal_expansion_coeff` Optional, default = `1.0 / T0` - * - `gravity` acceleration due to gravity (m/s) */ BoussinesqBuoyancy::BoussinesqBuoyancy(const CFDSim& sim) : m_temperature(sim.repo().get_field("temperature")) + , m_transport(sim.transport_model()) { - amrex::ParmParse pp_boussinesq_buoyancy( - amr_wind::pde::icns::BoussinesqBuoyancy::identifier()); - pp_boussinesq_buoyancy.get("reference_temperature", m_ref_theta); - - if (pp_boussinesq_buoyancy.contains("thermal_expansion_coeff")) { - pp_boussinesq_buoyancy.get("thermal_expansion_coeff", m_beta); - } else { - m_beta = 1.0 / m_ref_theta; - } - - m_is_vof = sim.repo().field_exists("vof"); - if (m_is_vof) { - m_vof = &sim.repo().get_field("vof"); - } else { - // Point to something, will not be used - m_vof = &m_temperature; - } + m_ref_theta = m_transport.ref_theta(); // gravity in `incflo` namespace amrex::ParmParse pp_incflo("incflo"); @@ -49,25 +29,20 @@ void BoussinesqBuoyancy::operator()( const FieldState fstate, const amrex::Array4& src_term) const { - const amrex::Real T0 = m_ref_theta; - const amrex::Real beta = m_beta; const amrex::GpuArray gravity{ m_gravity[0], m_gravity[1], m_gravity[2]}; - const bool ivf = m_is_vof; - const auto& vof_arr = (*m_vof)(lev).const_array(mfi); - constexpr amrex::Real tol = 1e-12; - const auto& temp = m_temperature.state(field_impl::phi_state(fstate))(lev).const_array( mfi); + amrex::FArrayBox beta_fab(bx, 1, amrex::The_Async_Arena()); + amrex::Array4 const& beta_arr = beta_fab.array(); + m_transport.beta_impl(lev, mfi, bx, beta_arr); + const auto& ref_theta = (*m_ref_theta)(lev).const_array(mfi); amrex::ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept { const amrex::Real T = temp(i, j, k, 0); - const amrex::Real fac_air = beta * (T0 - T); - // If vof exists, ignore Boussinesq term in cells with liquid - // If no vof, assume single phase and use the term for air everywhere - const amrex::Real fac = - ivf ? (vof_arr(i, j, k) > tol ? 0.0 : fac_air) : fac_air; + const amrex::Real T0 = ref_theta(i, j, k); + const amrex::Real fac = beta_arr(i, j, k) * (T0 - T); src_term(i, j, k, 0) += gravity[0] * fac; src_term(i, j, k, 1) += gravity[1] * fac; diff --git a/amr-wind/equation_systems/temperature/source_terms/DragTempForcing.H b/amr-wind/equation_systems/temperature/source_terms/DragTempForcing.H index 8c504d0ffb..6c2c27aafd 100644 --- a/amr-wind/equation_systems/temperature/source_terms/DragTempForcing.H +++ b/amr-wind/equation_systems/temperature/source_terms/DragTempForcing.H @@ -4,6 +4,7 @@ #include "amr-wind/equation_systems/temperature/TemperatureSource.H" #include "amr-wind/core/SimTime.H" #include "amr-wind/CFDSim.H" +#include "amr-wind/transport_models/TransportModel.H" namespace amr_wind::pde::temperature { @@ -29,7 +30,12 @@ private: const Field& m_velocity; const Field& m_temperature; amrex::Real m_drag_coefficient{1.0}; - amrex::Real m_reference_temperature{300.0}; + + //! Transport model + const transport::TransportModel& m_transport; + + //! Reference temperature + std::unique_ptr m_ref_theta; }; } // namespace amr_wind::pde::temperature diff --git a/amr-wind/equation_systems/temperature/source_terms/DragTempForcing.cpp b/amr-wind/equation_systems/temperature/source_terms/DragTempForcing.cpp index 098e806cc0..f699820d0c 100644 --- a/amr-wind/equation_systems/temperature/source_terms/DragTempForcing.cpp +++ b/amr-wind/equation_systems/temperature/source_terms/DragTempForcing.cpp @@ -13,10 +13,16 @@ DragTempForcing::DragTempForcing(const CFDSim& sim) , m_mesh(sim.mesh()) , m_velocity(sim.repo().get_field("velocity")) , m_temperature(sim.repo().get_field("temperature")) + , m_transport(sim.transport_model()) { amrex::ParmParse pp("DragTempForcing"); pp.query("drag_coefficient", m_drag_coefficient); - pp.query("reference_temperature", m_reference_temperature); + m_ref_theta = m_transport.ref_theta(); + if (pp.contains("reference_temperature")) { + amrex::Abort( + "DragTempForcing.reference_temperature has been deprecated. Please " + "replace with transport.reference_temperature."); + } } DragTempForcing::~DragTempForcing() = default; @@ -44,7 +50,7 @@ void DragTempForcing::operator()( const auto& geom = m_mesh.Geom(lev); const auto& dx = geom.CellSizeArray(); const amrex::Real drag_coefficient = m_drag_coefficient / dx[2]; - const amrex::Real reference_temperature = m_reference_temperature; + const auto& ref_theta = (*m_ref_theta)(lev).const_array(mfi); const auto tiny = std::numeric_limits::epsilon(); const amrex::Real cd_max = 10.0; amrex::ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept { @@ -54,9 +60,9 @@ void DragTempForcing::operator()( const amrex::Real m = std::sqrt(ux1 * ux1 + uy1 * uy1 + uz1 * uz1); const amrex::Real Cd = std::min(drag_coefficient / (m + tiny), cd_max / dx[2]); + const amrex::Real T0 = ref_theta(i, j, k); src_term(i, j, k, 0) -= - (Cd * (temperature(i, j, k, 0) - reference_temperature) * - blank(i, j, k, 0)); + (Cd * (temperature(i, j, k, 0) - T0) * blank(i, j, k, 0)); }); } diff --git a/amr-wind/equation_systems/tke/source_terms/KransAxell.H b/amr-wind/equation_systems/tke/source_terms/KransAxell.H index dc4bbe2066..a8e0f0d80a 100644 --- a/amr-wind/equation_systems/tke/source_terms/KransAxell.H +++ b/amr-wind/equation_systems/tke/source_terms/KransAxell.H @@ -1,6 +1,7 @@ #ifndef KRANSAXELL_H #define KRANSAXELL_H +#include "amr-wind/transport_models/TransportModel.H" #include "amr-wind/equation_systems/tke/TKESource.H" namespace amr_wind::pde::tke { @@ -35,7 +36,6 @@ private: Field& m_tke; amrex::Real m_Cmu{0.556}; amrex::Real m_heat_flux{0.0}; - amrex::Real m_ref_temp{300.0}; amrex::Real m_z0{0.1}; amrex::Real m_kappa{0.41}; amrex::Real m_sponge_start{600}; @@ -45,6 +45,12 @@ private: const CFDSim& m_sim; const amrex::AmrCore& m_mesh; const Field& m_velocity; + + //! Transport model + const transport::TransportModel& m_transport; + + //! Reference temperature + std::unique_ptr m_ref_theta; }; } // namespace amr_wind::pde::tke diff --git a/amr-wind/equation_systems/tke/source_terms/KransAxell.cpp b/amr-wind/equation_systems/tke/source_terms/KransAxell.cpp index 66808678af..df24297bbe 100644 --- a/amr-wind/equation_systems/tke/source_terms/KransAxell.cpp +++ b/amr-wind/equation_systems/tke/source_terms/KransAxell.cpp @@ -16,6 +16,7 @@ KransAxell::KransAxell(const CFDSim& sim) , m_sim(sim) , m_mesh(sim.mesh()) , m_velocity(sim.repo().get_field("velocity")) + , m_transport(sim.transport_model()) { AMREX_ALWAYS_ASSERT(sim.turbulence_model().model_name() == "KLAxell"); auto coeffs = sim.turbulence_model().model_coeffs(); @@ -23,13 +24,13 @@ KransAxell::KransAxell(const CFDSim& sim) pp.query("Cmu", m_Cmu); pp.query("kappa", m_kappa); pp.query("surface_roughness_z0", m_z0); - pp.query("reference_temperature", m_ref_temp); pp.query("surface_temp_flux", m_heat_flux); pp.query("meso_sponge_start", m_sponge_start); { amrex::ParmParse pp_incflow("incflo"); pp_incflow.queryarr("gravity", m_gravity); } + m_ref_theta = m_transport.ref_theta(); } KransAxell::~KransAxell() = default; @@ -48,20 +49,21 @@ void KransAxell::operator()( const auto& buoy_prod_arr = (this->m_buoy_prod)(lev).array(mfi); const auto& dissip_arr = (this->m_dissip)(lev).array(mfi); const auto& tke_arr = m_tke(lev).array(mfi); + const auto& ref_theta_arr = (*m_ref_theta)(lev).const_array(mfi); const auto& geom = m_mesh.Geom(lev); const auto& problo = m_mesh.Geom(lev).ProbLoArray(); const auto& probhi = m_mesh.Geom(lev).ProbHiArray(); const auto& dx = geom.CellSizeArray(); const auto& dt = m_time.delta_t(); - const amrex::Real ref_temp = m_ref_temp; - const amrex::Real heat_flux = - std::abs(m_gravity[2]) / ref_temp * m_heat_flux; + const amrex::Real heat_flux = m_heat_flux; const amrex::Real Cmu = m_Cmu; const amrex::Real sponge_start = m_sponge_start; const amrex::Real ref_tke = m_ref_tke; const auto tiny = std::numeric_limits::epsilon(); const amrex::Real kappa = m_kappa; const amrex::Real z0 = m_z0; + const amrex::GpuArray gravity{ + m_gravity[0], m_gravity[1], m_gravity[2]}; amrex::ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept { amrex::Real bcforcing = 0; const amrex::Real ux = vel(i, j, k, 0); @@ -70,9 +72,10 @@ void KransAxell::operator()( if (k == 0) { const amrex::Real m = std::sqrt(ux * ux + uy * uy); const amrex::Real ustar = m * kappa / std::log(z / z0); + const amrex::Real T0 = ref_theta_arr(i, j, k); + const amrex::Real hf = std::abs(gravity[2]) / T0 * heat_flux; const amrex::Real rans_b = std::pow( - std::max(heat_flux, 0.0) * kappa * z / std::pow(Cmu, 3), - (2.0 / 3.0)); + std::max(hf, 0.0) * kappa * z / std::pow(Cmu, 3), (2.0 / 3.0)); bcforcing = (ustar * ustar / (Cmu * Cmu) + rans_b - tke_arr(i, j, k)) / dt; } @@ -105,8 +108,10 @@ void KransAxell::operator()( const amrex::Real z = 0.5 * dx[2]; amrex::Real m = std::sqrt(ux * ux + uy * uy); const amrex::Real ustar = m * kappa / std::log(z / z0); + const amrex::Real T0 = ref_theta_arr(i, j, k); + const amrex::Real hf = std::abs(gravity[2]) / T0 * heat_flux; const amrex::Real rans_b = std::pow( - std::max(heat_flux, 0.0) * kappa * z / std::pow(Cmu, 3), + std::max(hf, 0.0) * kappa * z / std::pow(Cmu, 3), (2.0 / 3.0)); terrainforcing = (ustar * ustar / (Cmu * Cmu) + rans_b - tke_arr(i, j, k)) / diff --git a/amr-wind/incflo.cpp b/amr-wind/incflo.cpp index 335c4c18ef..5480a6e2f3 100644 --- a/amr-wind/incflo.cpp +++ b/amr-wind/incflo.cpp @@ -430,6 +430,7 @@ void incflo::init_physics_and_pde() amrex::ParmParse pp("incflo"); pp.query("prescribe_velocity", m_prescribe_vel); } + m_sim.create_transport_model(); m_sim.create_turbulence_model(); // Initialize the refinement criteria diff --git a/amr-wind/physics/TerrainDrag.H b/amr-wind/physics/TerrainDrag.H index 585c95f19e..2009bb0346 100644 --- a/amr-wind/physics/TerrainDrag.H +++ b/amr-wind/physics/TerrainDrag.H @@ -7,8 +7,6 @@ namespace amr_wind::terraindrag { -namespace {} // namespace - /** Terraindrag Flow physics * \ingroup physics */ diff --git a/amr-wind/physics/multiphase/MultiPhase.H b/amr-wind/physics/multiphase/MultiPhase.H index 194a866399..2b612a305d 100644 --- a/amr-wind/physics/multiphase/MultiPhase.H +++ b/amr-wind/physics/multiphase/MultiPhase.H @@ -63,7 +63,7 @@ public: amrex::Real momentum_sum(int n); - InterfaceCapturingMethod interface_capturing_method(); + InterfaceCapturingMethod interface_capturing_method() const; amrex::Real rho1() const { return m_rho1; } diff --git a/amr-wind/physics/multiphase/MultiPhase.cpp b/amr-wind/physics/multiphase/MultiPhase.cpp index 2336a7f1e2..4e939fb826 100644 --- a/amr-wind/physics/multiphase/MultiPhase.cpp +++ b/amr-wind/physics/multiphase/MultiPhase.cpp @@ -77,7 +77,7 @@ MultiPhase::MultiPhase(CFDSim& sim) pp_incflo.queryarr("gravity", m_gravity); } -InterfaceCapturingMethod MultiPhase::interface_capturing_method() +InterfaceCapturingMethod MultiPhase::interface_capturing_method() const { return m_interface_capturing_method; } diff --git a/amr-wind/transport_models/ConstTransport.H b/amr-wind/transport_models/ConstTransport.H index 2ec1790334..f7d8780906 100644 --- a/amr-wind/transport_models/ConstTransport.H +++ b/amr-wind/transport_models/ConstTransport.H @@ -2,6 +2,7 @@ #define CONSTTRANSPORT_H #include "amr-wind/transport_models/TransportModel.H" +#include "amr-wind/utilities/constants.H" #include "AMReX_ParmParse.H" namespace amr_wind::transport { @@ -9,19 +10,82 @@ namespace amr_wind::transport { /** Fluid transport model with constant properties * \ingroup transport */ -class ConstTransport : public TransportModel +class ConstTransport : public TransportModel::Register { public: static constexpr bool constant_properties = true; static std::string identifier() { return "ConstTransport"; } - explicit ConstTransport(CFDSim& sim) : m_repo(sim.repo()) + explicit ConstTransport(const CFDSim& sim) + : m_repo(sim.repo()), m_phy_mgr(sim.physics_manager()) { amrex::ParmParse pp("transport"); pp.query("viscosity", m_mu); pp.query("laminar_prandtl", m_Pr); pp.query("turbulent_prandtl", m_Prt); + + // Backwards compatibility + amrex::ParmParse pp_boussinesq_buoyancy("BoussinesqBuoyancy"); + amrex::ParmParse pp_abl("ABL"); + if (pp.contains("thermal_expansion_coefficient")) { + pp.get("thermal_expansion_coefficient", m_constant_beta); + if (pp_boussinesq_buoyancy.contains("thermal_expansion_coeff")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.thermal_expansion_coeff " + "option has been deprecated in favor of " + "transport.thermal_expansion_coefficient. Ignoring the " + "BoussinesqBuoyancy option in favor of the transport " + "option." + << std::endl; + } + } else if (pp_boussinesq_buoyancy.contains("thermal_expansion_coeff")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.thermal_expansion_coeff option " + "has been deprecated in favor of " + "transport.thermal_expansion_coefficient. Please replace " + "this option." + << std::endl; + pp_boussinesq_buoyancy.get( + "thermal_expansion_coeff", m_constant_beta); + } + + if (pp.contains("reference_temperature")) { + pp.get("reference_temperature", m_reference_temperature); + if (pp_boussinesq_buoyancy.contains("reference_temperature")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.reference_temperature " + "option has been deprecated in favor of " + "transport.reference_temperature. Ignoring the " + "BoussinesqBuoyancy option in favor of the transport " + "option." + << std::endl; + } else if (pp_abl.contains("reference_temperature")) { + amrex::Print() + << "WARNING: ABL.reference_temperature " + "option has been deprecated in favor of " + "transport.reference_temperature. Ignoring the " + "ABL option in favor of the transport " + "option." + << std::endl; + } + } else if (pp_boussinesq_buoyancy.contains("reference_temperature")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.reference_temperature option " + "has been deprecated in favor of " + "transport.reference_temperature. Please replace " + "this option." + << std::endl; + pp_boussinesq_buoyancy.get( + "reference_temperature", m_reference_temperature); + } else if (pp_abl.contains("reference_temperature")) { + amrex::Print() << "WARNING: ABL.reference_temperature option " + "has been deprecated in favor of " + "transport.reference_temperature. Please replace " + "this option." + << std::endl; + pp_abl.get("reference_temperature", m_reference_temperature); + } } ~ConstTransport() override = default; @@ -55,7 +119,7 @@ public: //! Return the dynamic visocity field inline std::unique_ptr mu() override { - auto mu = m_repo.create_scratch_field(1, 1); + auto mu = m_repo.create_scratch_field(1, m_ngrow); for (int lev = 0; lev < m_repo.num_active_levels(); ++lev) { (*mu)(lev).setVal(m_mu); } @@ -87,10 +151,78 @@ public: return diff; } + //! Return the thermal expansion coefficient + inline std::unique_ptr beta() const override + { + auto beta = m_repo.create_scratch_field(1, m_ngrow); + for (int lev = 0; lev < m_repo.num_active_levels(); ++lev) { +#ifdef AMREX_USE_OMP +#pragma omp parallel if (amrex::Gpu::notInLaunchRegion()) +#endif + for (amrex::MFIter mfi((*beta)(lev)); mfi.isValid(); ++mfi) { + const auto& bx = mfi.tilebox(); + const auto& beta_arr = (*beta)(lev).array(mfi); + beta_impl(lev, mfi, bx, beta_arr); + } + } + return beta; + } + + //! Compute the thermal expansion coefficient + inline void beta_impl( + const int lev, + const amrex::MFIter& mfi, + const amrex::Box& bx, + const amrex::Array4& beta) const override + { + + const amrex::Real beta_val = (m_constant_beta > 0.0) + ? m_constant_beta + : 1.0 / m_reference_temperature; + + amrex::ParallelFor( + bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept { + beta(i, j, k) = beta_val; + }); + + if (m_repo.field_exists("vof")) { + const auto& vof = m_repo.get_field("vof"); + const auto& vof_arr = vof(lev).const_array(mfi); + amrex::ParallelFor( + bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept { + if (vof_arr(i, j, k) > constants::TIGHT_TOL) { + beta(i, j, k) = 0.0; + } + }); + } + } + + inline amrex::Real reference_temperature() const override + { + return m_reference_temperature; + } + + //! Return the reference temperature + inline std::unique_ptr ref_theta() const override + { + if (m_reference_temperature < 0.0) { + amrex::Abort("Reference temperature was not set"); + } + + auto ref_theta = m_repo.create_scratch_field(1, m_ngrow); + for (int lev = 0; lev < m_repo.num_active_levels(); ++lev) { + (*ref_theta)(lev).setVal(m_reference_temperature); + } + return ref_theta; + } + private: //! Reference to the field repository (for creating scratch fields) FieldRepo& m_repo; + //! Reference to the physics manager + const PhysicsMgr& m_phy_mgr; + //! (Laminar) dynamic viscosity amrex::Real m_mu{1.0e-5}; @@ -99,6 +231,12 @@ private: //! Turbulent Prandtl number amrex::Real m_Prt{1.0}; + + //! Constant thermal expansion coefficient + amrex::Real m_constant_beta{0.0}; + + //! Reference temperature + amrex::Real m_reference_temperature{-1.0}; }; } // namespace amr_wind::transport diff --git a/amr-wind/transport_models/TransportModel.H b/amr-wind/transport_models/TransportModel.H index ba2ea96f5b..2a93636b78 100644 --- a/amr-wind/transport_models/TransportModel.H +++ b/amr-wind/transport_models/TransportModel.H @@ -2,6 +2,7 @@ #define TRANSPORTMODEL_H #include "amr-wind/core/Factory.H" +#include "amr-wind/CFDSim.H" #include "amr-wind/core/FieldRepo.H" namespace amr_wind::transport { @@ -25,10 +26,12 @@ namespace amr_wind::transport { /** Abstract representation of a transport model * \ingroup transport */ -class TransportModel +class TransportModel : public Factory { public: - virtual ~TransportModel() = default; + static std::string base_identifier() { return "TransportModel"; } + + ~TransportModel() override = default; //! Dynamic laminar viscosity (kg/m/s) virtual std::unique_ptr mu() = 0; @@ -39,6 +42,25 @@ public: //! Scalar diffusivity based on Schmidt number virtual std::unique_ptr scalar_diffusivity(const std::string& scalar_name) = 0; + + //! Thermal expansion coefficient + virtual std::unique_ptr beta() const = 0; + + //! Thermal expansion coefficient + virtual void beta_impl( + const int lev, + const amrex::MFIter& mfi, + const amrex::Box& bx, + const amrex::Array4& beta) const = 0; + + //! Reference temperature + virtual amrex::Real reference_temperature() const = 0; + + //! Reference temperature + virtual std::unique_ptr ref_theta() const = 0; + +protected: + const int m_ngrow{1}; }; } // namespace amr_wind::transport diff --git a/amr-wind/transport_models/TwoPhaseTransport.H b/amr-wind/transport_models/TwoPhaseTransport.H index 28ee096e9d..6e1a390d04 100644 --- a/amr-wind/transport_models/TwoPhaseTransport.H +++ b/amr-wind/transport_models/TwoPhaseTransport.H @@ -3,6 +3,7 @@ #include "amr-wind/physics/multiphase/MultiPhase.H" #include "amr-wind/transport_models/TransportModel.H" +#include "amr-wind/utilities/constants.H" #include "AMReX_ParmParse.H" namespace amr_wind::transport { @@ -10,20 +11,21 @@ namespace amr_wind::transport { /** Two-phase fluid transport model with piece-wise constant properties * \ingroup transport */ -class TwoPhaseTransport : public TransportModel +class TwoPhaseTransport : public TransportModel::Register { public: static constexpr bool constant_properties = false; static std::string identifier() { return "TwoPhaseTransport"; } - explicit TwoPhaseTransport(CFDSim& sim) : m_sim(sim), m_repo(sim.repo()) + explicit TwoPhaseTransport(const CFDSim& sim) + : m_sim(sim), m_repo(sim.repo()) { - auto& physics_mgr = m_sim.physics_manager(); + const auto& physics_mgr = m_sim.physics_manager(); if (!physics_mgr.contains("MultiPhase")) { amrex::Abort("TwoPhaseTransport requires MultiPhase physics"); } - auto& multiphase = physics_mgr.get(); + const auto& multiphase = physics_mgr.get(); m_ifacetype = multiphase.interface_capturing_method(); amrex::ParmParse pp("transport"); @@ -44,6 +46,68 @@ public: << "WARNING: single-phase laminar_prandtl has been specified " "but will not be used! (TwoPhaseTransport)\n"; } + + // Backwards compatibility + amrex::ParmParse pp_boussinesq_buoyancy("BoussinesqBuoyancy"); + amrex::ParmParse pp_abl("ABL"); + if (pp.contains("thermal_expansion_coefficient")) { + pp.get("thermal_expansion_coefficient", m_constant_beta); + if (pp_boussinesq_buoyancy.contains("thermal_expansion_coeff")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.thermal_expansion_coeff " + "option has been deprecated in favor of " + "transport.thermal_expansion_coefficient. Ignoring the " + "BoussinesqBuoyancy option in favor of the transport " + "option." + << std::endl; + } + } else if (pp_boussinesq_buoyancy.contains("thermal_expansion_coeff")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.thermal_expansion_coeff option " + "has been deprecated in favor of " + "transport.thermal_expansion_coefficient. Please replace " + "this option." + << std::endl; + pp_boussinesq_buoyancy.get( + "thermal_expansion_coeff", m_constant_beta); + } + + if (pp.contains("reference_temperature")) { + pp.get("reference_temperature", m_reference_temperature); + if (pp_boussinesq_buoyancy.contains("reference_temperature")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.reference_temperature " + "option has been deprecated in favor of " + "transport.reference_temperature. Ignoring the " + "BoussinesqBuoyancy option in favor of the transport " + "option." + << std::endl; + } else if (pp_abl.contains("reference_temperature")) { + amrex::Print() + << "WARNING: ABL.reference_temperature " + "option has been deprecated in favor of " + "transport.reference_temperature. Ignoring the " + "ABL option in favor of the transport " + "option." + << std::endl; + } + } else if (pp_boussinesq_buoyancy.contains("reference_temperature")) { + amrex::Print() + << "WARNING: BoussinesqBuoyancy.reference_temperature option " + "has been deprecated in favor of " + "transport.reference_temperature. Please replace " + "this option." + << std::endl; + pp_boussinesq_buoyancy.get( + "reference_temperature", m_reference_temperature); + } else if (pp_abl.contains("reference_temperature")) { + amrex::Print() << "WARNING: ABL.reference_temperature option " + "has been deprecated in favor of " + "transport.reference_temperature. Please replace " + "this option." + << std::endl; + pp_abl.get("reference_temperature", m_reference_temperature); + } } ~TwoPhaseTransport() override = default; @@ -75,7 +139,7 @@ public: inline std::unique_ptr mu() override { // Select the interface capturing method - auto mu = m_repo.create_scratch_field(1, 1); + auto mu = m_repo.create_scratch_field(1, m_ngrow); if (m_ifacetype == InterfaceCapturingMethod::VOF) { @@ -140,7 +204,7 @@ public: inline std::unique_ptr alpha() override { // Select the interface capturing method - auto alpha = m_repo.create_scratch_field(1, 1); + auto alpha = m_repo.create_scratch_field(1, m_ngrow); if (m_ifacetype == InterfaceCapturingMethod::VOF) { @@ -221,9 +285,90 @@ public: return diff; } + //! Return the thermal expansion coefficient + inline std::unique_ptr beta() const override + { + auto beta = m_repo.create_scratch_field(1, m_ngrow); + for (int lev = 0; lev < m_repo.num_active_levels(); ++lev) { +#ifdef AMREX_USE_OMP +#pragma omp parallel if (amrex::Gpu::notInLaunchRegion()) +#endif + for (amrex::MFIter mfi((*beta)(lev)); mfi.isValid(); ++mfi) { + const auto& bx = mfi.tilebox(); + const auto& beta_arr = (*beta)(lev).array(mfi); + beta_impl(lev, mfi, bx, beta_arr); + } + } + return beta; + } + + //! Compute the thermal expansion coefficient + inline void beta_impl( + const int lev, + const amrex::MFIter& mfi, + const amrex::Box& bx, + const amrex::Array4& beta) const override + { + const amrex::Real beta_val = (m_constant_beta > 0.0) + ? m_constant_beta + : 1.0 / m_reference_temperature; + + if (m_ifacetype == InterfaceCapturingMethod::VOF) { + const auto& vof = m_repo.get_field("vof"); + const auto& vof_arr = vof(lev).const_array(mfi); + amrex::ParallelFor( + bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept { + if (vof_arr(i, j, k) > constants::TIGHT_TOL) { + beta(i, j, k) = 0.0; + } else { + beta(i, j, k) = beta_val; + } + }); + } else if (m_ifacetype == InterfaceCapturingMethod::LS) { + const auto& levelset = m_repo.get_field("levelset"); + const auto& dx = m_repo.mesh().Geom(lev).CellSizeArray(); + const auto& phi_arr = levelset(lev).const_array(mfi); + const amrex::Real eps = std::cbrt(2. * dx[0] * dx[1] * dx[2]); + amrex::ParallelFor( + bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept { + amrex::Real smooth_heaviside; + if (phi_arr(i, j, k) > eps) { + smooth_heaviside = 1.0; + } else if (phi_arr(i, j, k) < -eps) { + smooth_heaviside = 0.; + } else { + smooth_heaviside = + 0.5 * (1.0 + phi_arr(i, j, k) / eps + + 1.0 / M_PI * + std::sin(phi_arr(i, j, k) * M_PI / eps)); + } + beta(i, j, k) = beta_val * (1 - smooth_heaviside); + }); + } + } + + inline amrex::Real reference_temperature() const override + { + return m_reference_temperature; + } + + //! Return the reference temperature + inline std::unique_ptr ref_theta() const override + { + if (m_reference_temperature < 0.0) { + amrex::Abort("Reference temperature was not set"); + } + + auto ref_theta = m_repo.create_scratch_field(1, m_ngrow); + for (int lev = 0; lev < m_repo.num_active_levels(); ++lev) { + (*ref_theta)(lev).setVal(m_reference_temperature); + } + return ref_theta; + } + private: //! Reference to the CFD sim - CFDSim& m_sim; + const CFDSim& m_sim; //! Reference to the field repository (for creating scratch fields) FieldRepo& m_repo; @@ -245,6 +390,12 @@ private: //! Turbulent Prandtl number amrex::Real m_Prt{1.0}; + + //! Constant thermal expansion coefficient + amrex::Real m_constant_beta{0.0}; + + //! Reference temperature + amrex::Real m_reference_temperature{-1.0}; }; } // namespace amr_wind::transport diff --git a/amr-wind/turbulence/LES/AMD.H b/amr-wind/turbulence/LES/AMD.H index 69c24b7842..df7e1f6bc3 100644 --- a/amr-wind/turbulence/LES/AMD.H +++ b/amr-wind/turbulence/LES/AMD.H @@ -50,9 +50,6 @@ private: //! discretization) amrex::Real m_C{0.333333333333333}; - //! Reference temperature (Kelvin) - amrex::Real m_ref_theta{300.0}; - //! Wall-normal direction axis int m_normal_dir{2}; @@ -69,7 +66,8 @@ AMREX_GPU_DEVICE AMREX_FORCE_INLINE amrex::Real amd_muvel( int k, const amrex::GpuArray& dx, // Grid spacing const amrex::Real beta, // Thermal expansion coefficient - const amrex::Real C, // Poincare const + const amrex::GpuArray& gravity, + const amrex::Real C, // Poincare const const amrex::Array4& gradVel, const amrex::Array4& gradT, const amrex::Real* gradTbar_coord_begin, @@ -108,7 +106,7 @@ AMREX_GPU_DEVICE AMREX_FORCE_INLINE amrex::Real amd_muvel( } denom = std::max(1e-15, denom); num_shear *= -C; - num_buoy *= C * beta; + num_buoy *= C * beta * std::abs(gravity[normal_dir]); return std::max(1e-15, (num_shear + num_buoy) / denom); } diff --git a/amr-wind/turbulence/LES/AMD.cpp b/amr-wind/turbulence/LES/AMD.cpp index eb1c509ec6..840eab9b57 100644 --- a/amr-wind/turbulence/LES/AMD.cpp +++ b/amr-wind/turbulence/LES/AMD.cpp @@ -23,16 +23,9 @@ AMD::AMD(CFDSim& sim) , m_rho(sim.repo().get_field("density")) , m_pa_temp(m_temperature, sim.time(), m_normal_dir, true) { - auto& phy_mgr = this->m_sim.physics_manager(); - if (phy_mgr.contains("ABL")) { - { - amrex::ParmParse pp("ABL"); - pp.get("reference_temperature", m_ref_theta); - } - { - amrex::ParmParse pp("incflo"); - pp.queryarr("gravity", m_gravity); - } + { + amrex::ParmParse pp("incflo"); + pp.queryarr("gravity", m_gravity); } } @@ -56,13 +49,9 @@ void AMD::update_turbulent_viscosity( const auto& vel = m_vel.state(fstate); const auto& temp = m_temperature.state(fstate); const auto& den = m_rho.state(fstate); + const auto beta = (this->m_transport).beta(); const auto& geom_vec = repo.mesh().Geom(); - amrex::Real beta = 0.0; const int normal_dir = m_normal_dir; - auto& phy_mgr = this->m_sim.physics_manager(); - if (phy_mgr.contains("ABL")) { - beta = -m_gravity[normal_dir] / m_ref_theta; - } const amrex::Real C_poincare = m_C; @@ -88,6 +77,8 @@ void AMD::update_turbulent_viscosity( const amrex::Real* p_tpa_coord_begin = tpa_coord_d.data(); const amrex::Real* p_tpa_coord_end = tpa_coord_d.end(); const amrex::Real* p_tpa_deriv = tpa_deriv_d.data(); + const amrex::GpuArray gravity{ + m_gravity[0], m_gravity[1], m_gravity[2]}; const int nlevels = repo.num_active_levels(); for (int lev = 0; lev < nlevels; ++lev) { const auto& geom = geom_vec[lev]; @@ -98,6 +89,7 @@ void AMD::update_turbulent_viscosity( const auto& gradVel_arrs = (*gradVel)(lev).const_arrays(); const auto& gradT_arrs = (*gradT)(lev).const_arrays(); const auto& rho_arrs = den(lev).const_arrays(); + const auto& beta_arrs = (*beta)(lev).const_arrays(); const auto& mu_arrs = mu_turb(lev).arrays(); const auto& mu_turb_lev = mu_turb(lev); amrex::ParallelFor( @@ -107,10 +99,11 @@ void AMD::update_turbulent_viscosity( const auto rho_arr = rho_arrs[nbx]; const auto gradVel_arr = gradVel_arrs[nbx]; const auto gradT_arr = gradT_arrs[nbx]; + const auto beta_val = beta_arrs[nbx](i, j, k); mu_arr(i, j, k) = rho_arr(i, j, k) * amd_muvel( - i, j, k, dx, beta, C_poincare, - gradVel_arr, gradT_arr, + i, j, k, dx, beta_val, gravity, + C_poincare, gradVel_arr, gradT_arr, p_tpa_coord_begin, p_tpa_coord_end, p_tpa_deriv, normal_dir, nlo); }); diff --git a/amr-wind/turbulence/LES/OneEqKsgs.H b/amr-wind/turbulence/LES/OneEqKsgs.H index 4467470c75..5ce88c053b 100644 --- a/amr-wind/turbulence/LES/OneEqKsgs.H +++ b/amr-wind/turbulence/LES/OneEqKsgs.H @@ -80,9 +80,6 @@ private: //! Gravity vector (m/s^2) amrex::Vector m_gravity{0.0, 0.0, -9.81}; - //! Reference temperature (Kelvin) - amrex::Real m_ref_theta{300.0}; - //! Hybrid RANS-LES with Nalu-wind bool m_hybrid_rl{false}; Field* m_sdr; diff --git a/amr-wind/turbulence/LES/OneEqKsgs.cpp b/amr-wind/turbulence/LES/OneEqKsgs.cpp index da1c6653e4..d7fafbcb60 100644 --- a/amr-wind/turbulence/LES/OneEqKsgs.cpp +++ b/amr-wind/turbulence/LES/OneEqKsgs.cpp @@ -43,7 +43,6 @@ OneEqKsgsM84::OneEqKsgsM84(CFDSim& sim) { amrex::ParmParse pp("ABL"); - pp.get("reference_temperature", m_ref_theta); pp.query("enable_hybrid_rl_mode", m_hybrid_rl); } @@ -101,7 +100,7 @@ void OneEqKsgsM84::update_turbulent_viscosity( const amrex::GpuArray gravity{ m_gravity[0], m_gravity[1], m_gravity[2]}; - const amrex::Real beta = 1.0 / m_ref_theta; + const auto beta = (this->m_transport).beta(); auto& mu_turb = this->mu_turb(); const amrex::Real Ce = this->m_Ce; @@ -127,6 +126,7 @@ void OneEqKsgsM84::update_turbulent_viscosity( const auto& tke_arr = (*this->m_tke)(lev).array(mfi); const auto& buoy_prod_arr = (this->m_buoy_prod)(lev).array(mfi); const auto& shear_prod_arr = (this->m_shear_prod)(lev).array(mfi); + const auto& beta_arr = (*beta)(lev).const_array(mfi); amrex::ParallelFor( bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept { @@ -134,7 +134,7 @@ void OneEqKsgsM84::update_turbulent_viscosity( -(gradT_arr(i, j, k, 0) * gravity[0] + gradT_arr(i, j, k, 1) * gravity[1] + gradT_arr(i, j, k, 2) * gravity[2]) * - beta; + beta_arr(i, j, k); if (stratification > 1e-10) { tlscale_arr(i, j, k) = amrex::min( ds, 0.76 * std::sqrt( diff --git a/amr-wind/turbulence/RANS/KLAxell.H b/amr-wind/turbulence/RANS/KLAxell.H index 1f6175f0b3..af19ae1246 100644 --- a/amr-wind/turbulence/RANS/KLAxell.H +++ b/amr-wind/turbulence/RANS/KLAxell.H @@ -58,8 +58,6 @@ private: Field& m_temperature; //! Gravity vector (m/s^2) amrex::Vector m_gravity{0.0, 0.0, -9.81}; - //! Reference temperature (Kelvin) - amrex::Real m_ref_theta{300.0}; amrex::Real m_surf_flux{0}; amrex::Real m_lengthscale_switch{800}; }; diff --git a/amr-wind/turbulence/RANS/KLAxell.cpp b/amr-wind/turbulence/RANS/KLAxell.cpp index edf25a8ed2..1d2af84972 100644 --- a/amr-wind/turbulence/RANS/KLAxell.cpp +++ b/amr-wind/turbulence/RANS/KLAxell.cpp @@ -31,7 +31,6 @@ KLAxell::KLAxell(CFDSim& sim) } { amrex::ParmParse pp("ABL"); - pp.get("reference_temperature", m_ref_theta); pp.get("surface_temp_flux", m_surf_flux); pp.query("length_scale_switch", m_lengthscale_switch); } @@ -84,7 +83,7 @@ void KLAxell::update_turbulent_viscosity( const amrex::GpuArray gravity{ m_gravity[0], m_gravity[1], m_gravity[2]}; - const amrex::Real beta = 1.0 / m_ref_theta; + const auto beta = (this->m_transport).beta(); const amrex::Real Cmu = m_Cmu; const amrex::Real Cb_stable = m_Cb_stable; const amrex::Real Cb_unstable = m_Cb_unstable; @@ -113,6 +112,8 @@ void KLAxell::update_turbulent_viscosity( const auto& tke_arr = (*this->m_tke)(lev).array(mfi); const auto& buoy_prod_arr = (this->m_buoy_prod)(lev).array(mfi); const auto& shear_prod_arr = (this->m_shear_prod)(lev).array(mfi); + const auto& beta_arr = (*beta)(lev).const_array(mfi); + //! Add terrain components const bool has_terrain = this->m_sim.repo().int_field_exists("terrain_blank"); @@ -130,7 +131,7 @@ void KLAxell::update_turbulent_viscosity( -(gradT_arr(i, j, k, 0) * gravity[0] + gradT_arr(i, j, k, 1) * gravity[1] + gradT_arr(i, j, k, 2) * gravity[2]) * - beta; + beta_arr(i, j, k); const amrex::Real z = std::max( problo[2] + (k + 0.5) * dz - ht_arr(i, j, k), 0.5 * dz); @@ -201,7 +202,7 @@ void KLAxell::update_turbulent_viscosity( -(gradT_arr(i, j, k, 0) * gravity[0] + gradT_arr(i, j, k, 1) * gravity[1] + gradT_arr(i, j, k, 2) * gravity[2]) * - beta; + beta_arr(i, j, k); const amrex::Real z = problo[2] + (k + 0.5) * dz; const amrex::Real lscale_s = (lambda * kappa * z) / (lambda + kappa * z); @@ -280,7 +281,7 @@ void KLAxell::update_alphaeff(Field& alphaeff) fvm::gradient(*gradT, m_temperature); const amrex::GpuArray gravity{ m_gravity[0], m_gravity[1], m_gravity[2]}; - const amrex::Real beta = 1.0 / m_ref_theta; + const auto beta = (this->m_transport).beta(); const amrex::Real Cmu = m_Cmu; const int nlevels = repo.num_active_levels(); for (int lev = 0; lev < nlevels; ++lev) { @@ -292,6 +293,7 @@ void KLAxell::update_alphaeff(Field& alphaeff) const auto& tke_arr = (*this->m_tke)(lev).array(mfi); const auto& gradT_arr = (*gradT)(lev).array(mfi); const auto& tlscale_arr = (this->m_turb_lscale)(lev).array(mfi); + const auto& beta_arr = (*beta)(lev).const_array(mfi); const amrex::Real Rtc = -1.0; const amrex::Real Rtmin = -3.0; amrex::ParallelFor( @@ -300,7 +302,7 @@ void KLAxell::update_alphaeff(Field& alphaeff) -(gradT_arr(i, j, k, 0) * gravity[0] + gradT_arr(i, j, k, 1) * gravity[1] + gradT_arr(i, j, k, 2) * gravity[2]) * - beta; + beta_arr(i, j, k); amrex::Real epsilon = std::pow(Cmu, 3) * std::pow(tke_arr(i, j, k), 1.5) / tlscale_arr(i, j, k); diff --git a/amr-wind/wind_energy/ABLStats.H b/amr-wind/wind_energy/ABLStats.H index 633d811edb..1ba8269e3e 100644 --- a/amr-wind/wind_energy/ABLStats.H +++ b/amr-wind/wind_energy/ABLStats.H @@ -3,6 +3,7 @@ #include "amr-wind/wind_energy/ABLStatsBase.H" #include "amr-wind/CFDSim.H" +#include "amr-wind/transport_models/TransportModel.H" #include "amr-wind/utilities/FieldPlaneAveraging.H" #include "amr-wind/utilities/FieldPlaneAveragingFine.H" #include "amr-wind/utilities/SecondMomentAveraging.H" @@ -176,9 +177,6 @@ private: //! Von-Karman constant amrex::Real m_kappa{0.41}; - //! Reference surface temperature - amrex::Real m_ref_theta{300.0}; - //! Variable to store capping inversion height amrex::Real m_zi{0.0}; diff --git a/amr-wind/wind_energy/ABLStats.cpp b/amr-wind/wind_energy/ABLStats.cpp index 95517285cc..ad0aadea50 100644 --- a/amr-wind/wind_energy/ABLStats.cpp +++ b/amr-wind/wind_energy/ABLStats.cpp @@ -55,7 +55,6 @@ void ABLStats::initialize() pp.query("normal_direction", m_normal_dir); AMREX_ASSERT((0 <= m_normal_dir) && (m_normal_dir < AMREX_SPACEDIM)); pp.query("kappa", m_kappa); - pp.get("reference_temperature", m_ref_theta); pp.query("stats_do_energy_budget", m_do_energy_budget); } @@ -337,9 +336,10 @@ void ABLStats::write_ascii() } double wstar = 0.0; + const auto ref_theta = m_sim.transport_model().reference_temperature(); auto Q = m_abl_wall_func.mo().surf_temp_flux; if (Q > 1e-10) { - wstar = std::cbrt(m_gravity * Q * m_zi / m_ref_theta); + wstar = std::cbrt(m_gravity * Q * m_zi / ref_theta); } auto L = m_abl_wall_func.mo().obukhov_len; @@ -525,11 +525,12 @@ void ABLStats::write_netcdf() ncf.var("ustar").put(&ustar, {nt}, {1}); double wstar = 0.0; auto Q = m_abl_wall_func.mo().surf_temp_flux; + const auto ref_theta = m_sim.transport_model().reference_temperature(); ncf.var("Q").put(&Q, {nt}, {1}); auto Tsurf = m_abl_wall_func.mo().surf_temp; ncf.var("Tsurf").put(&Tsurf, {nt}, {1}); if (Q > 1e-10) { - wstar = std::cbrt(m_gravity * Q * m_zi / m_ref_theta); + wstar = std::cbrt(m_gravity * Q * m_zi / ref_theta); } ncf.var("wstar").put(&wstar, {nt}, {1}); double L = m_abl_wall_func.mo().obukhov_len; diff --git a/amr-wind/wind_energy/ABLWallFunction.cpp b/amr-wind/wind_energy/ABLWallFunction.cpp index d4e101eea0..6be8af6074 100644 --- a/amr-wind/wind_energy/ABLWallFunction.cpp +++ b/amr-wind/wind_energy/ABLWallFunction.cpp @@ -1,3 +1,4 @@ +#include "amr-wind/transport_models/TransportModel.H" #include "amr-wind/wind_energy/ABLWallFunction.H" #include "amr-wind/wind_energy/ABL.H" #include "amr-wind/utilities/tensor_ops.H" @@ -42,8 +43,6 @@ ABLWallFunction::ABLWallFunction(const CFDSim& sim) << std::endl; } - pp.get("reference_temperature", m_mo.ref_temp); - if (pp.contains("surface_temp_flux")) { pp.query("surface_temp_flux", m_mo.surf_temp_flux); } else if (pp.contains("surface_temp_rate")) { @@ -54,9 +53,9 @@ ABLWallFunction::ABLWallFunction(const CFDSim& sim) } else { amrex::Print() << "ABLWallFunction: Initial surface temperature not found for " - "ABL. Assuming to be equal to the reference temperature " - << m_mo.ref_temp << std::endl; - m_surf_temp_init = m_mo.ref_temp; + "ABL. Assuming to be equal to the reference temperature" + << std::endl; + m_surf_temp_init = sim.transport_model().reference_temperature(); } if (pp.contains("surface_temp_rate_tstart")) { pp.get("surface_temp_rate_tstart", m_surf_temp_rate_tstart); diff --git a/amr-wind/wind_energy/MOData.H b/amr-wind/wind_energy/MOData.H index a19024f352..d37dab2fbd 100644 --- a/amr-wind/wind_energy/MOData.H +++ b/amr-wind/wind_energy/MOData.H @@ -39,7 +39,6 @@ struct MOData amrex::Real surf_temp_flux{0.0}; ///< Heat flux amrex::Real surf_temp; ///< Instantaneous surface temperature - amrex::Real ref_temp; ///< Reference temperature amrex::Real gamma_m{5.0}; amrex::Real gamma_h{5.0}; diff --git a/docs/sphinx/user/amr_wind_inputs.txt b/docs/sphinx/user/amr_wind_inputs.txt index 82cf0a644f..9cf9cb3bf9 100644 --- a/docs/sphinx/user/amr_wind_inputs.txt +++ b/docs/sphinx/user/amr_wind_inputs.txt @@ -46,6 +46,7 @@ transport.model = ConstTransport transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 290.0 # turbulence equation parameters turbulence.model = OneEqKsgsM84 @@ -61,7 +62,6 @@ ABL.normal_direction = 2 ABL.perturb_ref_height = 50.0 ABL.perturb_temperature = true ABL.perturb_velocity = true -ABL.reference_temperature = 290.0 ABL.stats_output_format = netcdf ABL.stats_output_frequency = 1 ABL.surface_roughness_z0 = 0.01 @@ -72,8 +72,6 @@ ABL.temperature_values = 290.0 296.0 # momentum source term parameters ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing ABLForcing.abl_forcing_height = 90.0 -BoussinesqBuoyancy.reference_temperature = 300.0 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.003333333333 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.latitude = 41.3 CoriolisForcing.north_vector = 0.0 1.0 0.0 diff --git a/docs/sphinx/user/inputs_Momentum_Sources.rst b/docs/sphinx/user/inputs_Momentum_Sources.rst index 54db6c579b..2e2b98b7bf 100644 --- a/docs/sphinx/user/inputs_Momentum_Sources.rst +++ b/docs/sphinx/user/inputs_Momentum_Sources.rst @@ -15,21 +15,6 @@ Section: Momentum Sources if the corresponding source term (the root name) is listed in :input_param:`ICNS.source_terms`. -.. input_param:: BoussinesqBuoyancy.reference_temperature - - **type:** Real, mandatory - - Reference temperature :math:`\theta_\mathrm{ref}` in Kelvin. - Values of the temperature field that are less than or greater than this value will - cause a buoyancy force in the direction of the gravity vector. - -.. input_param:: BoussinesqBuoyancy.thermal_expansion_coeff - - **type:** Real, optional, default :math:`\beta = 1 / \theta_\mathrm{ref}` - - Thermal expansion coefficient, if not specified this value is set to the inverse of the - :input_param:`BoussinesqBuoyancy.reference_temperature` value. - .. input_param:: CoriolisForcing.latitude **type:** Real, mandatory diff --git a/docs/sphinx/user/inputs_Temperature_Sources.rst b/docs/sphinx/user/inputs_Temperature_Sources.rst index 08b8dcc822..e68f59d891 100644 --- a/docs/sphinx/user/inputs_Temperature_Sources.rst +++ b/docs/sphinx/user/inputs_Temperature_Sources.rst @@ -22,14 +22,3 @@ Section: Temperature Sources This value specifies the coefficient for the forcing term in the immersed boundary forcing method. It is currently recommended to use the default value to avoid initial numerical stability. -.. input_param:: DragTempForcing.reference_temperature - - **type:** Real, optional - - Reference temperature :math:`\theta_\mathrm{ref}` in Kelvin. - Set the term to be equal to BoussinesqBuoyancy.reference_temperature. This term - is currently a placeholder and will be updated in future for considering - stratification effects. The default value is 300.0. - - - diff --git a/docs/sphinx/user/inputs_transport.rst b/docs/sphinx/user/inputs_transport.rst index 51cffe20a2..f202b6b234 100644 --- a/docs/sphinx/user/inputs_transport.rst +++ b/docs/sphinx/user/inputs_transport.rst @@ -29,3 +29,18 @@ This section is for setting thermal and momentum diffusivity coefficients. Sets the turbulent Prandtl number. +.. input_param:: transport.reference_temperature + + **type:** Real, mandatory + + Reference temperature :math:`\theta_\mathrm{ref}` in Kelvin. + Values of the temperature field that are less than or greater than this value will + cause a buoyancy force in the direction of the gravity vector. + +.. input_param:: transport.thermal_expansion_coefficient + + **type:** Real, optional, default :math:`\beta = 1 / \theta_\mathrm{ref}` + + Thermal expansion coefficient, if not specified this value is set to the inverse of the + :input_param:`transport.reference_temperature` value. + diff --git a/docs/sphinx/walkthrough/precursor_inp.txt b/docs/sphinx/walkthrough/precursor_inp.txt index 072d5f5d92..c3b6c2d432 100644 --- a/docs/sphinx/walkthrough/precursor_inp.txt +++ b/docs/sphinx/walkthrough/precursor_inp.txt @@ -23,6 +23,7 @@ incflo.density = 1.225 # Reference density; mak transport.viscosity = 1.0e-5 # Dynamic viscosity [N-s/m^2] transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290 #¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨# # GEOMETRY & BCs # @@ -48,8 +49,6 @@ ABLForcing.forcing_timetable_output_file = abl_forces.txt CoriolisForcing.latitude = 36.607322 # Southern Great Plains CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 -BoussinesqBuoyancy.reference_temperature = 290.0 -ABL.reference_temperature = 290.0 ABL.temperature_heights = 0.0 600.0 700.0 1700.0 # Make sure top height >= the domain height ABL.temperature_values = 290.0 290.0 298.0 301.0 ABL.perturb_temperature = true diff --git a/docs/sphinx/walkthrough/spinup_inp.txt b/docs/sphinx/walkthrough/spinup_inp.txt index 358a3f3808..5944ca1c92 100644 --- a/docs/sphinx/walkthrough/spinup_inp.txt +++ b/docs/sphinx/walkthrough/spinup_inp.txt @@ -17,6 +17,7 @@ incflo.density = 1.225 # Reference density; mak transport.viscosity = 1.0e-5 # Dynamic viscosity [N-s/m^2] transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290 #¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨# # GEOMETRY & BCs # @@ -41,8 +42,6 @@ ABLForcing.abl_forcing_height = 86.5 CoriolisForcing.latitude = 36.607322 # Southern Great Plains CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 -BoussinesqBuoyancy.reference_temperature = 290.0 -ABL.reference_temperature = 290.0 ABL.temperature_heights = 0.0 600.0 700.0 1700.0 # Make sure top height >= the domain height ABL.temperature_values = 290.0 290.0 298.0 301.0 ABL.perturb_temperature = true diff --git a/docs/sphinx/walkthrough/terrain.rst b/docs/sphinx/walkthrough/terrain.rst index 331eebbc0c..8858e969dd 100644 --- a/docs/sphinx/walkthrough/terrain.rst +++ b/docs/sphinx/walkthrough/terrain.rst @@ -34,8 +34,7 @@ and the span. For example, a sponge layer of size 1000 m at the east (+x) bounda we need to include ``DragForcing.sponge_east=1`` and ``DragForcing.sponge_distance_east=1000`` in the input file. The sponge layer is not required for periodic boundary boundary conditions. The only input recommended for the energy equation source term is the specification of the internal temperature of the terrain. This is -set as ``DragTempForcing.reference_temperature=300``. It is recommended that the reference_temperature be set -to the value of the reference temperature used in the Boussinesq term. The current terrain setup can only +set as ``transport.reference_temperature=300``. The current terrain setup can only be used for the simulation of neutral ABL. A future release will update this calculation to automatically use the values from a precursor simulation for both neutral and non-neutral stratification. The terrain can be visualized by including ``io.int_outputs = terrain_blank`` in the input file. diff --git a/docs/sphinx/walkthrough/terrain_inp.txt b/docs/sphinx/walkthrough/terrain_inp.txt index bbd23a88e9..50268ad30f 100644 --- a/docs/sphinx/walkthrough/terrain_inp.txt +++ b/docs/sphinx/walkthrough/terrain_inp.txt @@ -30,13 +30,14 @@ transport.model = ConstTransport transport.viscosity = 1e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300 +transport.thermal_expansion_coefficient = 0.00333333 # turbulence equation parameters turbulence.model = Kosovic Kosovic.refMOL = -1e30 # Atmospheric boundary layer ABL.kappa = .41 ABL.normal_direction = 2 -ABL.reference_temperature = 300 ABL.stats_output_format = netcdf ABL.surface_roughness_z0 = 0.1 ABL.temperature_heights = 0 800 900 1900 @@ -49,8 +50,6 @@ ABL.bndry_var_names = velocity temperature ABL.bndry_output_format = native # Source ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing RayleighDamping NonLinearSGSTerm DragForcing -BoussinesqBuoyancy.reference_temperature = 300 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.00333333 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90 diff --git a/docs/sphinx/walkthrough/terrain_precursor_inp.txt b/docs/sphinx/walkthrough/terrain_precursor_inp.txt index 185dddeadb..a2b304eb2f 100644 --- a/docs/sphinx/walkthrough/terrain_precursor_inp.txt +++ b/docs/sphinx/walkthrough/terrain_precursor_inp.txt @@ -30,6 +30,8 @@ transport.model = ConstTransport transport.viscosity = 1e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300 +transport.thermal_expansion_coefficient = 0.00333333 # turbulence equation parameters turbulence.model = Kosovic Kosovic.refMOL = -1e30 @@ -44,7 +46,6 @@ ABL.perturb_velocity = true ABL.perturb_temperature = false ABL.kappa = .41 ABL.normal_direction = 2 -ABL.reference_temperature = 300 ABL.stats_output_format = netcdf ABL.surface_roughness_z0 = 0.1 ABL.temperature_heights = 0 800 900 1900 @@ -60,8 +61,6 @@ ABL.bndry_var_names = velocity temperature ABL.bndry_output_format = native # Source ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing RayleighDamping NonLinearSGSTerm -BoussinesqBuoyancy.reference_temperature = 300 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.00333333 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90 diff --git a/docs/sphinx/walkthrough/turbines_inp.txt b/docs/sphinx/walkthrough/turbines_inp.txt index df53f06b46..0392211214 100644 --- a/docs/sphinx/walkthrough/turbines_inp.txt +++ b/docs/sphinx/walkthrough/turbines_inp.txt @@ -24,6 +24,7 @@ incflo.density = 1.225 # Reference density; mak transport.viscosity = 1.0e-5 # Dynamic viscosity [N-s/m^2] transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 #¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨# # GEOMETRY & BCs # @@ -59,8 +60,6 @@ ABL.wf_velocity = 7.612874161922772 0.05167978610261268 ABL.wf_vmag = 7.655337919472146 ABL.wf_theta = 291.0187046202964 # BodyForce.magnitude = 0.00034839850789284793 0.0009712494385077595 0.0 -BoussinesqBuoyancy.read_temperature_profile = true -BoussinesqBuoyancy.tprofile_filename = avg_theta.dat ##-----------------------------------------------------# BodyForce.uniform_timetable_file = "../precursor/abl_forces.txt" incflo.velocity = 10.0 0.0 0.0 @@ -68,8 +67,6 @@ ABLForcing.abl_forcing_height = 86.5 CoriolisForcing.latitude = 36.607322 # Southern Great Plains CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 -BoussinesqBuoyancy.reference_temperature = 290.0 -ABL.reference_temperature = 290.0 ABL.temperature_heights = 0.0 600.0 700.0 1700.0 # Make sure top height >= the domain height ABL.temperature_values = 290.0 290.0 298.0 301.0 ABL.perturb_temperature = true @@ -83,6 +80,8 @@ ABL.deltaV = 1.0 ABL.kappa = .40 ABL.surface_roughness_z0 = 0.01 # [m] ABL.surface_temp_flux = 0.05 # Surface temperature flux [K-m/s] +ABLMeanBoussinesq.read_temperature_profile = true +ABLMeanBoussinesq.temperature_profile_filename = avg_theta.dat #¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨¨# # POST-Processing # diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index bcc9bea302..58648d1146 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -48,7 +48,7 @@ macro(setup_test) file(MAKE_DIRECTORY ${CURRENT_TEST_BINARY_DIR}) file(GLOB TEST_FILES "${CURRENT_TEST_SOURCE_DIR}/*") file(COPY ${TEST_FILES} DESTINATION "${CURRENT_TEST_BINARY_DIR}/") - set(RUNTIME_OPTIONS "time.max_step=10 io.plot_file=plt time.plot_interval=10 amrex.the_arena_is_managed=0 amrex.abort_on_out_of_gpu_memory=1 amrex.abort_on_unused_inputs=1") + set(RUNTIME_OPTIONS "time.max_step=10 io.plot_file=plt time.plot_interval=10 amrex.the_arena_is_managed=0 amrex.abort_on_out_of_gpu_memory=1") if(NOT AMR_WIND_TEST_WITH_FCOMPARE) #Avoid all I/O otherwise set(RUNTIME_OPTIONS "${RUNTIME_OPTIONS} time.plot_interval=-1 time.checkpoint_interval=-1") endif() diff --git a/test/test_files/abl_amd_wenoz/abl_amd_wenoz.inp b/test/test_files/abl_amd_wenoz/abl_amd_wenoz.inp index 2f5a00a8a5..3989d4a73b 100644 --- a/test/test_files/abl_amd_wenoz/abl_amd_wenoz.inp +++ b/test/test_files/abl_amd_wenoz/abl_amd_wenoz.inp @@ -28,13 +28,12 @@ incflo.diffusion_type = 1 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = AMD incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_anelastic/abl_anelastic.inp b/test/test_files/abl_anelastic/abl_anelastic.inp index d4f33abadb..91b55ac3f1 100644 --- a/test/test_files/abl_anelastic/abl_anelastic.inp +++ b/test/test_files/abl_anelastic/abl_anelastic.inp @@ -34,6 +34,7 @@ incflo.do_initial_proj = 1 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 @@ -41,7 +42,6 @@ io.outputs = reference_density reference_pressure incflo.physics = ABL ICNS.source_terms = GravityForcing -ABL.reference_temperature = 300.0 ABL.perturb_temperature = false ABL.perturb_velocity = false diff --git a/test/test_files/abl_bds/abl_bds.inp b/test/test_files/abl_bds/abl_bds.inp index 4e28388dea..053e8cb430 100644 --- a/test/test_files/abl_bds/abl_bds.inp +++ b/test/test_files/abl_bds/abl_bds.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_bndry_input/abl_bndry_input.inp b/test/test_files/abl_bndry_input/abl_bndry_input.inp index 90162238e1..3683a9fae8 100644 --- a/test/test_files/abl_bndry_input/abl_bndry_input.inp +++ b/test/test_files/abl_bndry_input/abl_bndry_input.inp @@ -24,11 +24,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_input_amr/abl_bndry_input_amr.inp b/test/test_files/abl_bndry_input_amr/abl_bndry_input_amr.inp index 0eb83ac47c..da1bbf7c02 100644 --- a/test/test_files/abl_bndry_input_amr/abl_bndry_input_amr.inp +++ b/test/test_files/abl_bndry_input_amr/abl_bndry_input_amr.inp @@ -24,11 +24,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_input_amr_inflow/abl_bndry_input_amr_inflow.inp b/test/test_files/abl_bndry_input_amr_inflow/abl_bndry_input_amr_inflow.inp index a41b2bedfb..607f45f7d4 100644 --- a/test/test_files/abl_bndry_input_amr_inflow/abl_bndry_input_amr_inflow.inp +++ b/test/test_files/abl_bndry_input_amr_inflow/abl_bndry_input_amr_inflow.inp @@ -24,11 +24,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_input_amr_native/abl_bndry_input_amr_native.inp b/test/test_files/abl_bndry_input_amr_native/abl_bndry_input_amr_native.inp index 90c545c117..f8cf7bdcf3 100644 --- a/test/test_files/abl_bndry_input_amr_native/abl_bndry_input_amr_native.inp +++ b/test/test_files/abl_bndry_input_amr_native/abl_bndry_input_amr_native.inp @@ -25,10 +25,10 @@ transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 turbulence.model = Smagorinsky +transport.reference_temperature = 290.0 Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_input_amr_native_mlbc/abl_bndry_input_amr_native_mlbc.inp b/test/test_files/abl_bndry_input_amr_native_mlbc/abl_bndry_input_amr_native_mlbc.inp index 82d7932c8d..4600baa14d 100644 --- a/test/test_files/abl_bndry_input_amr_native_mlbc/abl_bndry_input_amr_native_mlbc.inp +++ b/test/test_files/abl_bndry_input_amr_native_mlbc/abl_bndry_input_amr_native_mlbc.inp @@ -24,11 +24,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_input_amr_native_xhi/abl_bndry_input_amr_native_xhi.inp b/test/test_files/abl_bndry_input_amr_native_xhi/abl_bndry_input_amr_native_xhi.inp index 7f52b93b17..5591b74efd 100644 --- a/test/test_files/abl_bndry_input_amr_native_xhi/abl_bndry_input_amr_native_xhi.inp +++ b/test/test_files/abl_bndry_input_amr_native_xhi/abl_bndry_input_amr_native_xhi.inp @@ -24,11 +24,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_input_amr_upper/abl_bndry_input_amr_upper.inp b/test/test_files/abl_bndry_input_amr_upper/abl_bndry_input_amr_upper.inp index 1c5129a5d3..04d03ef9f8 100644 --- a/test/test_files/abl_bndry_input_amr_upper/abl_bndry_input_amr_upper.inp +++ b/test/test_files/abl_bndry_input_amr_upper/abl_bndry_input_amr_upper.inp @@ -24,11 +24,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_input_native/abl_bndry_input_native.inp b/test/test_files/abl_bndry_input_native/abl_bndry_input_native.inp index a5cf9f386d..63038c94ca 100644 --- a/test/test_files/abl_bndry_input_native/abl_bndry_input_native.inp +++ b/test/test_files/abl_bndry_input_native/abl_bndry_input_native.inp @@ -24,11 +24,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_input_native_inout/abl_bndry_input_native_inout.inp b/test/test_files/abl_bndry_input_native_inout/abl_bndry_input_native_inout.inp index 1b9e042adb..d757396871 100644 --- a/test/test_files/abl_bndry_input_native_inout/abl_bndry_input_native_inout.inp +++ b/test/test_files/abl_bndry_input_native_inout/abl_bndry_input_native_inout.inp @@ -24,11 +24,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_output/abl_bndry_output.inp b/test/test_files/abl_bndry_output/abl_bndry_output.inp index a4fbad83db..d78ae85a20 100644 --- a/test/test_files/abl_bndry_output/abl_bndry_output.inp +++ b/test/test_files/abl_bndry_output/abl_bndry_output.inp @@ -23,11 +23,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_output_amr_inflow/abl_bndry_output_amr_inflow.inp b/test/test_files/abl_bndry_output_amr_inflow/abl_bndry_output_amr_inflow.inp index a0fe637b9b..44a17f730e 100644 --- a/test/test_files/abl_bndry_output_amr_inflow/abl_bndry_output_amr_inflow.inp +++ b/test/test_files/abl_bndry_output_amr_inflow/abl_bndry_output_amr_inflow.inp @@ -23,11 +23,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_output_amr_native/abl_bndry_output_amr_native.inp b/test/test_files/abl_bndry_output_amr_native/abl_bndry_output_amr_native.inp index f4ae977a13..9688d71419 100644 --- a/test/test_files/abl_bndry_output_amr_native/abl_bndry_output_amr_native.inp +++ b/test/test_files/abl_bndry_output_amr_native/abl_bndry_output_amr_native.inp @@ -23,11 +23,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_output_amr_upper/abl_bndry_output_amr_upper.inp b/test/test_files/abl_bndry_output_amr_upper/abl_bndry_output_amr_upper.inp index c362d92ef7..e1710f26be 100644 --- a/test/test_files/abl_bndry_output_amr_upper/abl_bndry_output_amr_upper.inp +++ b/test/test_files/abl_bndry_output_amr_upper/abl_bndry_output_amr_upper.inp @@ -23,11 +23,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_bndry_output_native/abl_bndry_output_native.inp b/test/test_files/abl_bndry_output_native/abl_bndry_output_native.inp index 6406a17c03..12ac08433e 100644 --- a/test/test_files/abl_bndry_output_native/abl_bndry_output_native.inp +++ b/test/test_files/abl_bndry_output_native/abl_bndry_output_native.inp @@ -23,11 +23,11 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = CoriolisForcing GeostrophicForcing -ABL.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 diff --git a/test/test_files/abl_godunov/abl_godunov.inp b/test/test_files/abl_godunov/abl_godunov.inp index aae3eb136f..7c0f97bf73 100644 --- a/test/test_files/abl_godunov/abl_godunov.inp +++ b/test/test_files/abl_godunov/abl_godunov.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 1 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_ascent/abl_godunov_ascent.inp b/test/test_files/abl_godunov_ascent/abl_godunov_ascent.inp index 7526b84619..1149196d0a 100644 --- a/test/test_files/abl_godunov_ascent/abl_godunov_ascent.inp +++ b/test/test_files/abl_godunov_ascent/abl_godunov_ascent.inp @@ -27,14 +27,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_cn/abl_godunov_cn.inp b/test/test_files/abl_godunov_cn/abl_godunov_cn.inp index d1c1bb86cf..7018c7e88f 100644 --- a/test/test_files/abl_godunov_cn/abl_godunov_cn.inp +++ b/test/test_files/abl_godunov_cn/abl_godunov_cn.inp @@ -27,13 +27,12 @@ incflo.godunov_type = ppm transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_explicit/abl_godunov_explicit.inp b/test/test_files/abl_godunov_explicit/abl_godunov_explicit.inp index b19900baa0..68fd2d847d 100644 --- a/test/test_files/abl_godunov_explicit/abl_godunov_explicit.inp +++ b/test/test_files/abl_godunov_explicit/abl_godunov_explicit.inp @@ -29,13 +29,12 @@ incflo.diffusion_type = 0 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_forcetimetable/abl_godunov_forcetimetable.inp b/test/test_files/abl_godunov_forcetimetable/abl_godunov_forcetimetable.inp index 4e0383008e..dd1cac2ef2 100644 --- a/test/test_files/abl_godunov_forcetimetable/abl_godunov_forcetimetable.inp +++ b/test/test_files/abl_godunov_forcetimetable/abl_godunov_forcetimetable.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing BodyForce -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 # ABL forcing is not turned on, but ABL Field Init needs velocity values diff --git a/test/test_files/abl_godunov_geostrophic_timetable/abl_godunov_geostrophic_timetable.inp b/test/test_files/abl_godunov_geostrophic_timetable/abl_godunov_geostrophic_timetable.inp index 8060bd806c..0d7a2625c7 100644 --- a/test/test_files/abl_godunov_geostrophic_timetable/abl_godunov_geostrophic_timetable.inp +++ b/test/test_files/abl_godunov_geostrophic_timetable/abl_godunov_geostrophic_timetable.inp @@ -26,14 +26,13 @@ incflo.use_godunov = 1 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 GeostrophicForcing.geostrophic_wind_timetable = "time_table.txt" incflo.velocity = 8.0 0.0 0.0 diff --git a/test/test_files/abl_godunov_hypre/abl_godunov_hypre.inp b/test/test_files/abl_godunov_hypre/abl_godunov_hypre.inp index 428613c489..80ca27dad4 100644 --- a/test/test_files/abl_godunov_hypre/abl_godunov_hypre.inp +++ b/test/test_files/abl_godunov_hypre/abl_godunov_hypre.inp @@ -27,14 +27,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_mpl/abl_godunov_mpl.inp b/test/test_files/abl_godunov_mpl/abl_godunov_mpl.inp index 66264cb359..539cb0dc0a 100644 --- a/test/test_files/abl_godunov_mpl/abl_godunov_mpl.inp +++ b/test/test_files/abl_godunov_mpl/abl_godunov_mpl.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLMeanBoussinesq -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 incflo.velocity = 7.0 7.0 0.0 diff --git a/test/test_files/abl_godunov_mpl_amr/abl_godunov_mpl_amr.inp b/test/test_files/abl_godunov_mpl_amr/abl_godunov_mpl_amr.inp index f473d30886..1475cb6bf0 100644 --- a/test/test_files/abl_godunov_mpl_amr/abl_godunov_mpl_amr.inp +++ b/test/test_files/abl_godunov_mpl_amr/abl_godunov_mpl_amr.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLMeanBoussinesq -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 incflo.velocity = 7.0 7.0 0.0 diff --git a/test/test_files/abl_godunov_nofft/abl_godunov_nofft.inp b/test/test_files/abl_godunov_nofft/abl_godunov_nofft.inp index 7905cb0f68..ad1de36926 100644 --- a/test/test_files/abl_godunov_nofft/abl_godunov_nofft.inp +++ b/test/test_files/abl_godunov_nofft/abl_godunov_nofft.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 1 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_nolim/abl_godunov_nolim.inp b/test/test_files/abl_godunov_nolim/abl_godunov_nolim.inp index aa8c931173..03d7dc103a 100644 --- a/test/test_files/abl_godunov_nolim/abl_godunov_nolim.inp +++ b/test/test_files/abl_godunov_nolim/abl_godunov_nolim.inp @@ -27,14 +27,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_noncons/abl_godunov_noncons.inp b/test/test_files/abl_godunov_noncons/abl_godunov_noncons.inp index e9ba6b6c25..931b6f0da9 100644 --- a/test/test_files/abl_godunov_noncons/abl_godunov_noncons.inp +++ b/test/test_files/abl_godunov_noncons/abl_godunov_noncons.inp @@ -29,14 +29,13 @@ incflo.godunov_type = ppm transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_plm/abl_godunov_plm.inp b/test/test_files/abl_godunov_plm/abl_godunov_plm.inp index 953e075e63..ed49d5aad5 100644 --- a/test/test_files/abl_godunov_plm/abl_godunov_plm.inp +++ b/test/test_files/abl_godunov_plm/abl_godunov_plm.inp @@ -28,13 +28,12 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_ppm/abl_godunov_ppm.inp b/test/test_files/abl_godunov_ppm/abl_godunov_ppm.inp index 4eb01be1e7..319cbecd4d 100644 --- a/test/test_files/abl_godunov_ppm/abl_godunov_ppm.inp +++ b/test/test_files/abl_godunov_ppm/abl_godunov_ppm.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 1 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_rayleigh_damping/abl_godunov_rayleigh_damping.inp b/test/test_files/abl_godunov_rayleigh_damping/abl_godunov_rayleigh_damping.inp index f65a32e551..fe1d845967 100644 --- a/test/test_files/abl_godunov_rayleigh_damping/abl_godunov_rayleigh_damping.inp +++ b/test/test_files/abl_godunov_rayleigh_damping/abl_godunov_rayleigh_damping.inp @@ -27,14 +27,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing RayleighDamping -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_restart/abl_godunov_restart.inp b/test/test_files/abl_godunov_restart/abl_godunov_restart.inp index 9bfe724d40..515256ae99 100644 --- a/test/test_files/abl_godunov_restart/abl_godunov_restart.inp +++ b/test/test_files/abl_godunov_restart/abl_godunov_restart.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_scalar_velocity_solve/abl_godunov_scalar_velocity_solve.inp b/test/test_files/abl_godunov_scalar_velocity_solve/abl_godunov_scalar_velocity_solve.inp index dbbe813395..d26c8b55e2 100644 --- a/test/test_files/abl_godunov_scalar_velocity_solve/abl_godunov_scalar_velocity_solve.inp +++ b/test/test_files/abl_godunov_scalar_velocity_solve/abl_godunov_scalar_velocity_solve.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_segregated_velocity_solve/abl_godunov_segregated_velocity_solve.inp b/test/test_files/abl_godunov_segregated_velocity_solve/abl_godunov_segregated_velocity_solve.inp index 5ad2d8291e..492211a19b 100644 --- a/test/test_files/abl_godunov_segregated_velocity_solve/abl_godunov_segregated_velocity_solve.inp +++ b/test/test_files/abl_godunov_segregated_velocity_solve/abl_godunov_segregated_velocity_solve.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_static_refinement/abl_godunov_static_refinement.inp b/test/test_files/abl_godunov_static_refinement/abl_godunov_static_refinement.inp index 8184a32906..b7ebbf4073 100644 --- a/test/test_files/abl_godunov_static_refinement/abl_godunov_static_refinement.inp +++ b/test/test_files/abl_godunov_static_refinement/abl_godunov_static_refinement.inp @@ -30,14 +30,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_static_refinement_rr4/abl_godunov_static_refinement_rr4.inp b/test/test_files/abl_godunov_static_refinement_rr4/abl_godunov_static_refinement_rr4.inp index 9c5525cc0a..d638736012 100644 --- a/test/test_files/abl_godunov_static_refinement_rr4/abl_godunov_static_refinement_rr4.inp +++ b/test/test_files/abl_godunov_static_refinement_rr4/abl_godunov_static_refinement_rr4.inp @@ -30,14 +30,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_timetable/abl_godunov_timetable.inp b/test/test_files/abl_godunov_timetable/abl_godunov_timetable.inp index c618d7344e..e268bf03fc 100644 --- a/test/test_files/abl_godunov_timetable/abl_godunov_timetable.inp +++ b/test/test_files/abl_godunov_timetable/abl_godunov_timetable.inp @@ -27,14 +27,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_weno/abl_godunov_weno.inp b/test/test_files/abl_godunov_weno/abl_godunov_weno.inp index 7aa8a2f489..dc16610322 100644 --- a/test/test_files/abl_godunov_weno/abl_godunov_weno.inp +++ b/test/test_files/abl_godunov_weno/abl_godunov_weno.inp @@ -27,14 +27,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_godunov_wenoz_fixedpt/abl_godunov_wenoz_fixedpt.inp b/test/test_files/abl_godunov_wenoz_fixedpt/abl_godunov_wenoz_fixedpt.inp index 6e8ab161cf..f6fb421df3 100644 --- a/test/test_files/abl_godunov_wenoz_fixedpt/abl_godunov_wenoz_fixedpt.inp +++ b/test/test_files/abl_godunov_wenoz_fixedpt/abl_godunov_wenoz_fixedpt.inp @@ -29,14 +29,13 @@ incflo.fixed_point_iterations = 10 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_kosovic_neutral/abl_kosovic_neutral.inp b/test/test_files/abl_kosovic_neutral/abl_kosovic_neutral.inp index 968dcec6c1..a92e66dc44 100644 --- a/test/test_files/abl_kosovic_neutral/abl_kosovic_neutral.inp +++ b/test/test_files/abl_kosovic_neutral/abl_kosovic_neutral.inp @@ -32,6 +32,8 @@ transport.model = ConstTransport transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300. +transport.thermal_expansion_coefficient = 0.003333 # turbulence equation parameters turbulence.model = Kosovic # Changes the length scale from filter width to kappa * z /phiM and blends with LES length scale using @@ -60,7 +62,6 @@ ABL.normal_direction = 2 ABL.perturb_ref_height = 50.0 ABL.perturb_velocity = true ABL.perturb_temperature = false -ABL.reference_temperature = 300. ABL.stats_output_format = netcdf ABL.surface_roughness_z0 = 0.1 ABL.temperature_heights = 0 800 900 1800 2700 @@ -69,8 +70,6 @@ ABL.wall_shear_stress_type = local ABL.surface_temp_flux = 0.0 # Source ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing RayleighDamping NonLinearSGSTerm -BoussinesqBuoyancy.reference_temperature = 300.0 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.003333 #CoriolisForcing.east_vector = 1.0 0.0 0.0 #CoriolisForcing.latitude = 45.0 #CoriolisForcing.north_vector = 0.0 1.0 0.0 diff --git a/test/test_files/abl_kosovic_neutral_ib/abl_kosovic_neutral_ib.inp b/test/test_files/abl_kosovic_neutral_ib/abl_kosovic_neutral_ib.inp index 1519c5bcd9..7727a0a09c 100644 --- a/test/test_files/abl_kosovic_neutral_ib/abl_kosovic_neutral_ib.inp +++ b/test/test_files/abl_kosovic_neutral_ib/abl_kosovic_neutral_ib.inp @@ -33,6 +33,8 @@ transport.model = ConstTransport transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300. +transport.thermal_expansion_coefficient = 0.003333 # turbulence equation parameters turbulence.model = Kosovic Kosovic.surfaceRANS = false @@ -49,7 +51,6 @@ ABL.normal_direction = 2 ABL.perturb_ref_height = 50.0 ABL.perturb_velocity = true ABL.perturb_temperature = false -ABL.reference_temperature = 300. ABL.stats_output_format = netcdf ABL.surface_roughness_z0 = 0.1 ABL.temperature_heights = 0 800 900 1800 2700 @@ -61,8 +62,6 @@ ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing Temperature.source_terms = DragTempForcing RayleighDamping.force_coord_directions= 0 0 1 DragForcing.sponge_strength=0 -BoussinesqBuoyancy.reference_temperature = 300.0 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.003333 #CoriolisForcing.east_vector = 1.0 0.0 0.0 #CoriolisForcing.latitude = 45.0 #CoriolisForcing.north_vector = 0.0 1.0 0.0 diff --git a/test/test_files/abl_ksgsm84_godunov/abl_ksgsm84_godunov.inp b/test/test_files/abl_ksgsm84_godunov/abl_ksgsm84_godunov.inp index f39c3b57dd..da065cdb14 100644 --- a/test/test_files/abl_ksgsm84_godunov/abl_ksgsm84_godunov.inp +++ b/test/test_files/abl_ksgsm84_godunov/abl_ksgsm84_godunov.inp @@ -27,12 +27,12 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = OneEqKsgsM84 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing TKE.source_terms = KsgsM84Src -BoussinesqBuoyancy.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 @@ -40,7 +40,6 @@ incflo.velocity = 6.128355544951824 5.142300877492314 0.0 ABL.temperature_heights = 650.0 750.0 1000.0 ABL.temperature_values = 300.0 308.0 308.75 -ABL.reference_temperature = 300.0 ABL.kappa = .41 ABL.surface_roughness_z0 = 0.15 diff --git a/test/test_files/abl_meso_input_dpa/abl_meso_input_dpa.inp b/test/test_files/abl_meso_input_dpa/abl_meso_input_dpa.inp index a7304eb132..7549b3e9b6 100644 --- a/test/test_files/abl_meso_input_dpa/abl_meso_input_dpa.inp +++ b/test/test_files/abl_meso_input_dpa/abl_meso_input_dpa.inp @@ -28,6 +28,7 @@ incflo.diffusion_type = 0 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 @@ -35,8 +36,6 @@ Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL #ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 #CoriolisForcing.latitude = 41.3 #ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_meso_input_ipa/abl_meso_input_ipa.inp b/test/test_files/abl_meso_input_ipa/abl_meso_input_ipa.inp index 77f69ee677..6444f92f0e 100644 --- a/test/test_files/abl_meso_input_ipa/abl_meso_input_ipa.inp +++ b/test/test_files/abl_meso_input_ipa/abl_meso_input_ipa.inp @@ -28,6 +28,7 @@ incflo.diffusion_type = 0 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 @@ -35,8 +36,6 @@ Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL #ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 #CoriolisForcing.latitude = 41.3 #ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_meso_tendency/abl_meso_tendency.inp b/test/test_files/abl_meso_tendency/abl_meso_tendency.inp index f314a513de..a393739775 100644 --- a/test/test_files/abl_meso_tendency/abl_meso_tendency.inp +++ b/test/test_files/abl_meso_tendency/abl_meso_tendency.inp @@ -28,6 +28,7 @@ incflo.diffusion_type = 0 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 @@ -35,8 +36,6 @@ Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL #ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 #CoriolisForcing.latitude = 41.3 #ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_mol/abl_mol.inp b/test/test_files/abl_mol/abl_mol.inp index 8c17935ea9..ada92ba8f5 100644 --- a/test/test_files/abl_mol/abl_mol.inp +++ b/test/test_files/abl_mol/abl_mol.inp @@ -26,13 +26,12 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_mol_cn/abl_mol_cn.inp b/test/test_files/abl_mol_cn/abl_mol_cn.inp index dfc1db2519..968e038981 100644 --- a/test/test_files/abl_mol_cn/abl_mol_cn.inp +++ b/test/test_files/abl_mol_cn/abl_mol_cn.inp @@ -25,14 +25,13 @@ incflo.use_godunov = false transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_mol_explicit/abl_mol_explicit.inp b/test/test_files/abl_mol_explicit/abl_mol_explicit.inp index 67592cd65f..12455a41b9 100644 --- a/test/test_files/abl_mol_explicit/abl_mol_explicit.inp +++ b/test/test_files/abl_mol_explicit/abl_mol_explicit.inp @@ -26,13 +26,12 @@ incflo.diffusion_type = 0 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_multiphase_laminar/abl_multiphase_laminar.inp b/test/test_files/abl_multiphase_laminar/abl_multiphase_laminar.inp index 17f8ab8735..03e7f9c11b 100644 --- a/test/test_files/abl_multiphase_laminar/abl_multiphase_laminar.inp +++ b/test/test_files/abl_multiphase_laminar/abl_multiphase_laminar.inp @@ -28,13 +28,13 @@ transport.viscosity_fluid2 = 1e-5 transport.laminar_prandtl_fluid1 = 7.2 transport.laminar_prandtl_fluid2 = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 263.5 turbulence.model = Laminar incflo.physics = MultiPhase ABL OceanWaves ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing GravityForcing ICNS.use_perturb_pressure = true MultiPhase.density_fluid1=1020. MultiPhase.density_fluid2=1.3223 -BoussinesqBuoyancy.reference_temperature = 263.5 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 @@ -43,7 +43,6 @@ GeostrophicForcing.geostrophic_wind = 8.0 0.0 0.0 GeostrophicForcing.wind_forcing_off_height = 3.0 GeostrophicForcing.wind_forcing_ramp_height = 7.0 incflo.velocity = 8.0 0.0 0.0 -ABL.reference_temperature = 263.5 ABL.temperature_heights = 0.0 100 400.0 ABL.temperature_values = 265.0 265.0 268.0 ABL.perturb_temperature = false diff --git a/test/test_files/abl_multiphase_w2a/abl_multiphase_w2a.inp b/test/test_files/abl_multiphase_w2a/abl_multiphase_w2a.inp index 88351f32f5..f3d89be6d9 100644 --- a/test/test_files/abl_multiphase_w2a/abl_multiphase_w2a.inp +++ b/test/test_files/abl_multiphase_w2a/abl_multiphase_w2a.inp @@ -24,6 +24,7 @@ incflo.mflux_type = minmod transport.model = TwoPhaseTransport transport.viscosity_fluid1=1.0e-3 transport.viscosity_fluid2=1.8e-5 +transport.reference_temperature = 263.5 turbulence.model = Laminar incflo.physics = MultiPhase ABL OceanWaves @@ -35,7 +36,6 @@ ICNS.use_perturb_pressure = true MultiPhase.density_fluid1=1020. MultiPhase.density_fluid2=1.3223 -BoussinesqBuoyancy.reference_temperature = 263.5 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 @@ -46,8 +46,6 @@ ABLForcing.abl_forcing_ramp_height = 10.0 ABLForcing.abl_forcing_band = 1 incflo.velocity = 6.128355544951824 5.142300877492314 0.0 -BoussinesqBuoyancy.reference_temperature = 263.5 -ABL.reference_temperature = 263.5 ABL.temperature_heights = -5.0 0.0 100 400.0 1001.0 ABL.temperature_values = 263.5 265.0 265.0 268.0 270.0 ABL.perturb_temperature = false diff --git a/test/test_files/abl_sampling/abl_sampling.inp b/test/test_files/abl_sampling/abl_sampling.inp index fc21050274..04de7dc6b9 100644 --- a/test/test_files/abl_sampling/abl_sampling.inp +++ b/test/test_files/abl_sampling/abl_sampling.inp @@ -30,14 +30,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_sampling_netcdf/abl_sampling_netcdf.inp b/test/test_files/abl_sampling_netcdf/abl_sampling_netcdf.inp index 70d82e3eae..4b0df21292 100644 --- a/test/test_files/abl_sampling_netcdf/abl_sampling_netcdf.inp +++ b/test/test_files/abl_sampling_netcdf/abl_sampling_netcdf.inp @@ -30,14 +30,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_stable/abl_stable.inp b/test/test_files/abl_stable/abl_stable.inp index ef6115eed3..5b13f7428d 100644 --- a/test/test_files/abl_stable/abl_stable.inp +++ b/test/test_files/abl_stable/abl_stable.inp @@ -23,18 +23,17 @@ incflo.godunov_type = "weno_z" transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 263.5 turbulence.model = OneEqKsgsM84 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing TKE.source_terms = KsgsM84Src -BoussinesqBuoyancy.reference_temperature = 263.5 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 CoriolisForcing.rotational_time_period = 90405.5439881955 GeostrophicForcing.geostrophic_wind = 8.0 0.0 0.0 incflo.velocity = 8.0 0.0 0.0 -ABL.reference_temperature = 263.5 ABL.temperature_heights = 0.0 100 400.0 ABL.temperature_values = 265.0 265.0 268.0 ABL.perturb_temperature = false diff --git a/test/test_files/abl_stable_hdf5/abl_stable_hdf5.inp b/test/test_files/abl_stable_hdf5/abl_stable_hdf5.inp index 5d6b373f98..a75205c903 100644 --- a/test/test_files/abl_stable_hdf5/abl_stable_hdf5.inp +++ b/test/test_files/abl_stable_hdf5/abl_stable_hdf5.inp @@ -23,18 +23,17 @@ incflo.godunov_type = "weno_z" transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 263.5 turbulence.model = OneEqKsgsM84 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing TKE.source_terms = KsgsM84Src -BoussinesqBuoyancy.reference_temperature = 263.5 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 CoriolisForcing.rotational_time_period = 90405.5439881955 GeostrophicForcing.geostrophic_wind = 8.0 0.0 0.0 incflo.velocity = 8.0 0.0 0.0 -ABL.reference_temperature = 263.5 ABL.temperature_heights = 0.0 100 400.0 ABL.temperature_values = 265.0 265.0 268.0 ABL.perturb_temperature = false diff --git a/test/test_files/abl_stable_zfp_hdf5/abl_stable_zfp_hdf5.inp b/test/test_files/abl_stable_zfp_hdf5/abl_stable_zfp_hdf5.inp index 3b39f97bf3..52a3d74509 100644 --- a/test/test_files/abl_stable_zfp_hdf5/abl_stable_zfp_hdf5.inp +++ b/test/test_files/abl_stable_zfp_hdf5/abl_stable_zfp_hdf5.inp @@ -23,18 +23,17 @@ incflo.godunov_type = "weno_z" transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 263.5 turbulence.model = OneEqKsgsM84 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing TKE.source_terms = KsgsM84Src -BoussinesqBuoyancy.reference_temperature = 263.5 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 CoriolisForcing.rotational_time_period = 90405.5439881955 GeostrophicForcing.geostrophic_wind = 8.0 0.0 0.0 incflo.velocity = 8.0 0.0 0.0 -ABL.reference_temperature = 263.5 ABL.temperature_heights = 0.0 100 400.0 ABL.temperature_values = 265.0 265.0 268.0 ABL.perturb_temperature = false diff --git a/test/test_files/abl_unstable/abl_unstable.inp b/test/test_files/abl_unstable/abl_unstable.inp index 61af57552a..6d753ebaa4 100644 --- a/test/test_files/abl_unstable/abl_unstable.inp +++ b/test/test_files/abl_unstable/abl_unstable.inp @@ -23,18 +23,17 @@ incflo.godunov_type = "weno_z" transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = OneEqKsgsM84 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing TKE.source_terms = KsgsM84Src -BoussinesqBuoyancy.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 CoriolisForcing.rotational_time_period = 125663.706143592 GeostrophicForcing.geostrophic_wind = 10.0 0.0 0.0 incflo.velocity = 10.0 0.0 0.0 -ABL.reference_temperature = 290.0 ABL.temperature_heights = 0.0 2000.0 ABL.temperature_values = 290.0 296.0 ABL.perturb_temperature = false diff --git a/test/test_files/abl_unstable_constant_wall_model/abl_unstable_constant_wall_model.inp b/test/test_files/abl_unstable_constant_wall_model/abl_unstable_constant_wall_model.inp index 9c812c191e..3a1a8f67ba 100644 --- a/test/test_files/abl_unstable_constant_wall_model/abl_unstable_constant_wall_model.inp +++ b/test/test_files/abl_unstable_constant_wall_model/abl_unstable_constant_wall_model.inp @@ -23,18 +23,17 @@ incflo.godunov_type = "weno_z" transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = OneEqKsgsM84 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing TKE.source_terms = KsgsM84Src -BoussinesqBuoyancy.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 CoriolisForcing.rotational_time_period = 125663.706143592 GeostrophicForcing.geostrophic_wind = 10.0 0.0 0.0 incflo.velocity = 10.0 0.0 0.0 -ABL.reference_temperature = 290.0 ABL.temperature_heights = 0.0 2000.0 ABL.temperature_values = 290.0 296.0 ABL.perturb_temperature = false diff --git a/test/test_files/abl_unstable_local_wall_model/abl_unstable_local_wall_model.inp b/test/test_files/abl_unstable_local_wall_model/abl_unstable_local_wall_model.inp index 210eebbf90..a180f8feb9 100644 --- a/test/test_files/abl_unstable_local_wall_model/abl_unstable_local_wall_model.inp +++ b/test/test_files/abl_unstable_local_wall_model/abl_unstable_local_wall_model.inp @@ -23,18 +23,17 @@ incflo.godunov_type = "weno_z" transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = OneEqKsgsM84 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing TKE.source_terms = KsgsM84Src -BoussinesqBuoyancy.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 CoriolisForcing.rotational_time_period = 125663.706143592 GeostrophicForcing.geostrophic_wind = 10.0 0.0 0.0 incflo.velocity = 10.0 0.0 0.0 -ABL.reference_temperature = 290.0 ABL.temperature_heights = 0.0 2000.0 ABL.temperature_values = 290.0 296.0 ABL.perturb_temperature = false diff --git a/test/test_files/abl_unstable_schumann_wall_model/abl_unstable_schumann_wall_model.inp b/test/test_files/abl_unstable_schumann_wall_model/abl_unstable_schumann_wall_model.inp index b243e820ae..560b5df541 100644 --- a/test/test_files/abl_unstable_schumann_wall_model/abl_unstable_schumann_wall_model.inp +++ b/test/test_files/abl_unstable_schumann_wall_model/abl_unstable_schumann_wall_model.inp @@ -23,18 +23,17 @@ incflo.godunov_type = "weno_z" transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 290.0 turbulence.model = OneEqKsgsM84 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing TKE.source_terms = KsgsM84Src -BoussinesqBuoyancy.reference_temperature = 290.0 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 90.0 CoriolisForcing.rotational_time_period = 125663.706143592 GeostrophicForcing.geostrophic_wind = 10.0 0.0 0.0 incflo.velocity = 10.0 0.0 0.0 -ABL.reference_temperature = 290.0 ABL.temperature_heights = 0.0 2000.0 ABL.temperature_values = 290.0 296.0 ABL.perturb_temperature = false diff --git a/test/test_files/abl_virtual_lidar/abl_virtual_lidar.inp b/test/test_files/abl_virtual_lidar/abl_virtual_lidar.inp index 49e25da5fe..053250cbb0 100644 --- a/test/test_files/abl_virtual_lidar/abl_virtual_lidar.inp +++ b/test/test_files/abl_virtual_lidar/abl_virtual_lidar.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/abl_wallrans_neutral/abl_wallrans_neutral.inp b/test/test_files/abl_wallrans_neutral/abl_wallrans_neutral.inp index 39f29cb9ea..a4c0d34668 100644 --- a/test/test_files/abl_wallrans_neutral/abl_wallrans_neutral.inp +++ b/test/test_files/abl_wallrans_neutral/abl_wallrans_neutral.inp @@ -35,6 +35,8 @@ transport.model = ConstTransport transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300. +transport.thermal_expansion_coefficient = 0.003333 # turbulence equation parameters turbulence.model = KLAxell TKE.source_terms = KransAxell @@ -49,7 +51,6 @@ ABL.normal_direction = 2 ABL.perturb_ref_height = 50.0 ABL.perturb_velocity = true ABL.perturb_temperature = false -ABL.reference_temperature = 300. ABL.stats_output_format = netcdf ABL.surface_roughness_z0 = 0.1 ABL.initial_wind_profile = true @@ -60,8 +61,6 @@ ABL.wall_shear_stress_type = local ABL.surface_temp_flux = 0.0 # Source ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing RayleighDamping -BoussinesqBuoyancy.reference_temperature = 300.0 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.003333 #CoriolisForcing.east_vector = 1.0 0.0 0.0 #CoriolisForcing.latitude = 45.0 #CoriolisForcing.north_vector = 0.0 1.0 0.0 diff --git a/test/test_files/act_abl_joukowskydisk/act_abl_joukowskydisk.inp b/test/test_files/act_abl_joukowskydisk/act_abl_joukowskydisk.inp index baec552a5c..aaad9189e6 100644 --- a/test/test_files/act_abl_joukowskydisk/act_abl_joukowskydisk.inp +++ b/test/test_files/act_abl_joukowskydisk/act_abl_joukowskydisk.inp @@ -31,13 +31,14 @@ transport.model = ConstTransport transport.viscosity = 1e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300 +transport.thermal_expansion_coefficient = 0.00333333 # turbulence equation parameters turbulence.model = Kosovic Kosovic.refMOL = -1e30 # Atmospheric boundary layer ABL.kappa = .41 ABL.normal_direction = 2 -ABL.reference_temperature = 300 ABL.surface_roughness_z0 = 0.1 ABL.temperature_heights = 0 0 1000 1100 3000 ABL.temperature_values = 300 300 300 305 310.7 @@ -47,8 +48,6 @@ ABL.surface_temp_flux = 0 ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing RayleighDamping NonLinearSGSTerm ActuatorForcing GeostrophicForcing.geostrophic_wind = 10 0 0 RayleighDamping.force_coord_directions= 0 0 1 -BoussinesqBuoyancy.reference_temperature = 300 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.00333333 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 43.5239 diff --git a/test/test_files/act_abl_uniformctdisk/act_abl_uniformctdisk.inp b/test/test_files/act_abl_uniformctdisk/act_abl_uniformctdisk.inp index 8b48e18087..b29763b6e9 100644 --- a/test/test_files/act_abl_uniformctdisk/act_abl_uniformctdisk.inp +++ b/test/test_files/act_abl_uniformctdisk/act_abl_uniformctdisk.inp @@ -31,13 +31,14 @@ transport.model = ConstTransport transport.viscosity = 1e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300 +transport.thermal_expansion_coefficient = 0.00333333 # turbulence equation parameters turbulence.model = Kosovic Kosovic.refMOL = -1e30 # Atmospheric boundary layer ABL.kappa = .41 ABL.normal_direction = 2 -ABL.reference_temperature = 300 ABL.surface_roughness_z0 = 0.1 ABL.temperature_heights = 0 0 1000 1100 3000 ABL.temperature_values = 300 300 300 305 310.7 @@ -47,8 +48,6 @@ ABL.surface_temp_flux = 0 ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing RayleighDamping NonLinearSGSTerm ActuatorForcing GeostrophicForcing.geostrophic_wind = 10 0 0 RayleighDamping.force_coord_directions= 0 0 1 -BoussinesqBuoyancy.reference_temperature = 300 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.00333333 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 43.5239 diff --git a/test/test_files/boussinesq_bubble_godunov/boussinesq_bubble_godunov.inp b/test/test_files/boussinesq_bubble_godunov/boussinesq_bubble_godunov.inp index 2f69f3dc84..997ca08c26 100644 --- a/test/test_files/boussinesq_bubble_godunov/boussinesq_bubble_godunov.inp +++ b/test/test_files/boussinesq_bubble_godunov/boussinesq_bubble_godunov.inp @@ -14,6 +14,8 @@ time.checkpoint_interval = -100 # Steps between checkpoint fi transport.viscosity = 0.00001 transport.laminar_prandtl = 0.33333333333333337 +transport.reference_temperature = 0.0 +transport.thermal_expansion_coefficient = 1.0 turbulence.model = Laminar amr.max_level = 1 @@ -30,8 +32,6 @@ incflo.gravity = 0. 0. 0.5 incflo.physics = BoussinesqBubble ICNS.source_terms = BoussinesqBuoyancy -BoussinesqBuoyancy.thermal_expansion_coeff = 1.0 -BoussinesqBuoyancy.reference_temperature = 0.0 zlo.type = "sw" zhi.type = "sw" diff --git a/test/test_files/boussinesq_bubble_mol/boussinesq_bubble_mol.inp b/test/test_files/boussinesq_bubble_mol/boussinesq_bubble_mol.inp index 3f9eed09b8..3d001f2b29 100644 --- a/test/test_files/boussinesq_bubble_mol/boussinesq_bubble_mol.inp +++ b/test/test_files/boussinesq_bubble_mol/boussinesq_bubble_mol.inp @@ -12,6 +12,8 @@ time.checkpoint_interval = -100 # Steps between checkpoint fi transport.viscosity = 0.00001 transport.laminar_prandtl = 0.33333333333333337 +transport.reference_temperature = 0.0 +transport.thermal_expansion_coefficient = 1.0 turbulence.model = Laminar amr.max_level = 1 @@ -28,8 +30,6 @@ incflo.gravity = 0. 0. 0.5 incflo.physics = BoussinesqBubble ICNS.source_terms = BoussinesqBuoyancy -BoussinesqBuoyancy.thermal_expansion_coeff = 1.0 -BoussinesqBuoyancy.reference_temperature = 0.0 zlo.type = "sw" zhi.type = "sw" diff --git a/test/test_files/box_refinement/box_refinement.inp b/test/test_files/box_refinement/box_refinement.inp index 7c74f59797..d6b38deeb4 100644 --- a/test/test_files/box_refinement/box_refinement.inp +++ b/test/test_files/box_refinement/box_refinement.inp @@ -28,14 +28,13 @@ incflo.diffusion_type = 2 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing ABLForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -ABL.reference_temperature = 300.0 CoriolisForcing.latitude = 41.3 ABLForcing.abl_forcing_height = 90 diff --git a/test/test_files/forest_drag/forest_drag.inp b/test/test_files/forest_drag/forest_drag.inp index 30a50f8dc8..c39a494c74 100644 --- a/test/test_files/forest_drag/forest_drag.inp +++ b/test/test_files/forest_drag/forest_drag.inp @@ -32,6 +32,8 @@ transport.model = ConstTransport transport.viscosity = 0.0 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300. +transport.thermal_expansion_coefficient = 0.003333 # turbulence equation parameters turbulence.model = Kosovic # Changes the length scale from filter width to kappa * z /phiM and blends with LES length scale using @@ -60,7 +62,6 @@ ABL.normal_direction = 2 ABL.perturb_ref_height = 50.0 ABL.perturb_velocity = true ABL.perturb_temperature = false -ABL.reference_temperature = 300. ABL.stats_output_format = native ABL.surface_roughness_z0 = 0.1 ABL.temperature_heights = 0 800 900 1800 2700 @@ -69,8 +70,6 @@ ABL.wall_shear_stress_type = local ABL.surface_temp_flux = 0.0 # Source ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing RayleighDamping NonLinearSGSTerm ForestForcing -BoussinesqBuoyancy.reference_temperature = 300.0 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.003333 #CoriolisForcing.east_vector = 1.0 0.0 0.0 #CoriolisForcing.latitude = 45.0 #CoriolisForcing.north_vector = 0.0 1.0 0.0 diff --git a/test/test_files/hbl_godunov/hbl_godunov.inp b/test/test_files/hbl_godunov/hbl_godunov.inp index a5fa7a07e3..640c88eec8 100644 --- a/test/test_files/hbl_godunov/hbl_godunov.inp +++ b/test/test_files/hbl_godunov/hbl_godunov.inp @@ -38,11 +38,11 @@ incflo.density = 1.17 # Fluid density [ transport.viscosity = 1.853e-05 # Fluid dynamic viscosity [kg/m-s] transport.laminar_prandtl = 0.7 # Laminar prandtl number transport.turbulent_prandtl = 0.3333 # Turbulent prandtl number +transport.reference_temperature = 300.0 incflo.physics = ABL ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing HurricaneForcing -ABL.reference_temperature = 300.0 ABL.surface_roughness_z0=0.0028 ABL.wall_shear_stress_type="donelan" ABL.log_law_height=10. @@ -54,8 +54,6 @@ ABL.linear_profile = 1 ABL.top_velocity = 0.0 33.3 0.0 ABL.bottom_velocity = 0.0 40. 0.0 -BoussinesqBuoyancy.reference_temperature = 300.0 - CoriolisForcing.latitude = 90. CoriolisForcing.rotational_time_period = 86164.0900027328 CoriolisForcing.north_vector = 0.0 1.0 0.0 diff --git a/test/test_files/nrel_precursor/nrel_precursor.inp b/test/test_files/nrel_precursor/nrel_precursor.inp index ac514f85fa..24e2c94527 100644 --- a/test/test_files/nrel_precursor/nrel_precursor.inp +++ b/test/test_files/nrel_precursor/nrel_precursor.inp @@ -32,6 +32,8 @@ transport.model = ConstTransport transport.viscosity = 1e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300 +transport.thermal_expansion_coefficient = 0.00333333 # turbulence equation parameters turbulence.model = Kosovic Kosovic.refMOL = -1e30 @@ -46,7 +48,6 @@ ABL.perturb_velocity = true ABL.perturb_temperature = false ABL.kappa = .41 ABL.normal_direction = 2 -ABL.reference_temperature = 300 ABL.stats_output_format = netcdf ABL.surface_roughness_z0 = 0.1 ABL.temperature_heights = 0 1000 2000 2100 4000 @@ -64,8 +65,6 @@ ABL.bndry_output_format = native ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing GeostrophicForcing RayleighDamping NonLinearSGSTerm GeostrophicForcing.geostrophic_wind = 10 0 0 RayleighDamping.force_coord_directions= 0 0 1 -BoussinesqBuoyancy.reference_temperature = 300 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.00333333 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 39.9061 diff --git a/test/test_files/nrel_terrain/nrel_terrain.inp b/test/test_files/nrel_terrain/nrel_terrain.inp index 42cd9876b7..928377c20e 100644 --- a/test/test_files/nrel_terrain/nrel_terrain.inp +++ b/test/test_files/nrel_terrain/nrel_terrain.inp @@ -32,13 +32,14 @@ transport.model = ConstTransport transport.viscosity = 1e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300 +transport.thermal_expansion_coefficient = 0.00333333 # turbulence equation parameters turbulence.model = Kosovic Kosovic.refMOL = -1e30 # Atmospheric boundary layer ABL.kappa = .41 ABL.normal_direction = 2 -ABL.reference_temperature = 300 ABL.stats_output_format = netcdf ABL.surface_roughness_z0 = 0.1 ABL.temperature_heights = 0 1000 2000 2100 4000 @@ -54,8 +55,6 @@ ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing Ge GeostrophicForcing.geostrophic_wind = 10 0 0 Temperature.source_terms = DragTempForcing RayleighDamping.force_coord_directions= 0 0 1 -BoussinesqBuoyancy.reference_temperature = 300 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.00333333 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 39.9061 diff --git a/test/test_files/nrel_terrain_amr/nrel_terrain_amr.inp b/test/test_files/nrel_terrain_amr/nrel_terrain_amr.inp index 556886ca86..2194220d57 100644 --- a/test/test_files/nrel_terrain_amr/nrel_terrain_amr.inp +++ b/test/test_files/nrel_terrain_amr/nrel_terrain_amr.inp @@ -32,13 +32,14 @@ transport.model = ConstTransport transport.viscosity = 1e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.333 +transport.reference_temperature = 300 +transport.thermal_expansion_coefficient = 0.00333333 # turbulence equation parameters turbulence.model = Kosovic Kosovic.refMOL = -1e30 # Atmospheric boundary layer ABL.kappa = .41 ABL.normal_direction = 2 -ABL.reference_temperature = 300 ABL.stats_output_format = netcdf ABL.surface_roughness_z0 = 0.1 ABL.temperature_heights = 0 1000 2000 2100 4000 @@ -54,8 +55,6 @@ ICNS.source_terms = BoussinesqBuoyancy CoriolisForcing Ge GeostrophicForcing.geostrophic_wind = 10 0 0 Temperature.source_terms = DragTempForcing RayleighDamping.force_coord_directions= 0 0 1 -BoussinesqBuoyancy.reference_temperature = 300 -BoussinesqBuoyancy.thermal_expansion_coeff = 0.00333333 CoriolisForcing.east_vector = 1.0 0.0 0.0 CoriolisForcing.north_vector = 0.0 1.0 0.0 CoriolisForcing.latitude = 39.9061 diff --git a/test/test_files/rankine-sym/rankine-sym.inp b/test/test_files/rankine-sym/rankine-sym.inp index 60ca17bb27..98c836f47f 100644 --- a/test/test_files/rankine-sym/rankine-sym.inp +++ b/test/test_files/rankine-sym/rankine-sym.inp @@ -25,6 +25,7 @@ incflo.initial_iterations = 0 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL @@ -34,7 +35,6 @@ incflo.physics = ABL #CoriolisForcing.latitude = 90.0 #CoriolisForcing.rotational_time_period = 125663.706143592 incflo.velocity = 10.0 0.0 0.0 -ABL.reference_temperature = 300.0 ABL.temperature_heights = 0.0 2000.0 ABL.temperature_values = 300.0 300.0 ABL.perturb_temperature = false diff --git a/test/test_files/rankine/rankine.inp b/test/test_files/rankine/rankine.inp index 12b0c174c5..84be3bb3b4 100644 --- a/test/test_files/rankine/rankine.inp +++ b/test/test_files/rankine/rankine.inp @@ -25,6 +25,7 @@ incflo.initial_iterations = 0 transport.viscosity = 1.0e-5 transport.laminar_prandtl = 0.7 transport.turbulent_prandtl = 0.3333 +transport.reference_temperature = 300.0 turbulence.model = Smagorinsky Smagorinsky_coeffs.Cs = 0.135 incflo.physics = ABL @@ -34,7 +35,6 @@ incflo.physics = ABL #CoriolisForcing.latitude = 90.0 #CoriolisForcing.rotational_time_period = 125663.706143592 incflo.velocity = 10.0 0.0 0.0 -ABL.reference_temperature = 300.0 ABL.temperature_heights = 0.0 2000.0 ABL.temperature_values = 300.0 300.0 ABL.perturb_temperature = false diff --git a/tools/calc_inflowoutflow_stats.py b/tools/calc_inflowoutflow_stats.py index d7352756dd..85bc9d280c 100644 --- a/tools/calc_inflowoutflow_stats.py +++ b/tools/calc_inflowoutflow_stats.py @@ -98,8 +98,8 @@ def check_input_file(self): 'ABL.wf_velocity', 'ABL.wf_vmag', 'ABL.wf_theta', - 'BoussinesqBuoyancy.read_temperature_profile', - 'BoussinesqBuoyancy.tprofile_filename', + 'ABLMeanBoussinesq.read_temperature_profile', + 'ABLMeanBoussinesq.temperature_profile_filename', 'BodyForce.magnitude'] for warn in warning_list: if warn in line: @@ -127,8 +127,8 @@ def update_input_file(self): wf_velmag_line = f"ABL.wf_vmag = {self.hvelmag}\n" wf_theta_line = f"ABL.wf_theta = {self.theta_mean}\n" bodyforce_mag_line = f"BodyForce.magnitude = {self.abl_force_x} {self.abl_force_y} 0.0\n" - bouss_read_line = "BoussinesqBuoyancy.read_temperature_profile = true\n" - bouss_profile_line = "BoussinesqBuoyancy.tprofile_filename = avg_theta.dat\n" + bouss_read_line = "ABLMeanBoussinesq.read_temperature_profile = true\n" + bouss_profile_line = "ABLMeanBoussinesq.temperature_profile_filename = avg_theta.dat\n" outro_line = "#-----------------------------------------------------#\n" ### Modify input file diff --git a/unit_tests/offshore_wind/abloffshore_test_utils.cpp b/unit_tests/offshore_wind/abloffshore_test_utils.cpp index 58b1ef46bd..f3c6283336 100644 --- a/unit_tests/offshore_wind/abloffshore_test_utils.cpp +++ b/unit_tests/offshore_wind/abloffshore_test_utils.cpp @@ -16,7 +16,6 @@ void ABLOffshoreMeshTest::populate_parameters() pp.addarr("temperature_heights", theights); pp.addarr("temperature_values", tvalues); pp.add("perturb_ref_height", 50.0); - pp.add("reference_temperature", 300.0); pp.add("kappa", 0.41); pp.add("surface_roughness_z0", 0.1); } @@ -33,9 +32,9 @@ void ABLOffshoreMeshTest::populate_parameters() pp.addarr("bottom_velocity", bottom_velocity); } - // Boussinesq Buoyancy + // Transport { - amrex::ParmParse pp("BoussinesqBuoyancy"); + amrex::ParmParse pp("transport"); pp.add("reference_temperature", 300.0); } @@ -100,4 +99,4 @@ void ABLOffshoreMeshTest::populate_parameters() } } -} // namespace amr_wind_tests \ No newline at end of file +} // namespace amr_wind_tests diff --git a/unit_tests/offshore_wind/test_abloffshore_src.cpp b/unit_tests/offshore_wind/test_abloffshore_src.cpp index 2fd4a91bf8..28985ac0dc 100644 --- a/unit_tests/offshore_wind/test_abloffshore_src.cpp +++ b/unit_tests/offshore_wind/test_abloffshore_src.cpp @@ -305,12 +305,11 @@ TEST_F(ABLOffshoreMeshTest, boussinesq) pde_mgr.register_icns(); pde_mgr.register_transport_pde("Temperature"); sim().init_physics(); + sim().create_transport_model(); auto& mphase = sim().physics_manager().get(); // Make sure to read water level mphase.post_init_actions(); - amr_wind::pde::icns::BoussinesqBuoyancy bb(sim()); - auto& src_term = pde_mgr.icns().fields().src_term; auto& temperature = @@ -329,6 +328,11 @@ TEST_F(ABLOffshoreMeshTest, boussinesq) init_abl_temperature_field(geom[lev], bx, temp_arr, btm_temp_ht); const auto& vof_arr = volume_fraction(lev).array(mfi); init_vof_field(geom[lev], bx, vof_arr, waterlev); + }); + + amr_wind::pde::icns::BoussinesqBuoyancy bb(sim()); + run_algorithm(temperature, [&](const int lev, const amrex::MFIter& mfi) { + const auto bx = mfi.validbox(); const auto& src_arr = src_term(lev).array(mfi); bb(lev, mfi, bx, amr_wind::FieldState::Old, src_arr); }); diff --git a/unit_tests/turbulence/test_turbulence_LES.cpp b/unit_tests/turbulence/test_turbulence_LES.cpp index 088b9c97fa..d5993dc20f 100644 --- a/unit_tests/turbulence/test_turbulence_LES.cpp +++ b/unit_tests/turbulence/test_turbulence_LES.cpp @@ -263,24 +263,26 @@ TEST_F(TurbLESTest, test_1eqKsgs_setup_calc) } { amrex::ParmParse pp("ABL"); - pp.add("reference_temperature", Tref); pp.add("surface_temp_rate", -0.25); amrex::Vector t_hts{0.0, 100.0, 400.0}; pp.addarr("temperature_heights", t_hts); amrex::Vector t_vals{265.0, 265.0, 268.0}; pp.addarr("temperature_values", t_vals); } + // Transport + { + amrex::ParmParse pp("transport"); + pp.add("reference_temperature", Tref); + } // Initialize necessary parts of solver populate_parameters(); initialize_mesh(); auto& pde_mgr = sim().pde_manager(); pde_mgr.register_icns(); + sim().create_transport_model(); sim().init_physics(); - - // Create turbulence model sim().create_turbulence_model(); - // Get turbulence model auto& tmodel = sim().turbulence_model(); // Get coefficients @@ -365,12 +367,16 @@ TEST_F(TurbLESTest, test_AMD_setup_calc) } { amrex::ParmParse pp("ABL"); - pp.add("reference_temperature", Tref); amrex::Vector t_hts{0.0, 100.0, 400.0}; pp.addarr("temperature_heights", t_hts); amrex::Vector t_vals{200.0, 200.0, 200.0}; pp.addarr("temperature_values", t_vals); } + // Transport + { + amrex::ParmParse pp("transport"); + pp.add("reference_temperature", Tref); + } // Initialize necessary parts of solver populate_parameters(); diff --git a/unit_tests/turbulence/test_turbulence_LES_bc.cpp b/unit_tests/turbulence/test_turbulence_LES_bc.cpp index 7ec3ece9b2..855cbae86f 100644 --- a/unit_tests/turbulence/test_turbulence_LES_bc.cpp +++ b/unit_tests/turbulence/test_turbulence_LES_bc.cpp @@ -145,7 +145,6 @@ class TurbLESTestBC : public MeshTest } { amrex::ParmParse pp("ABL"); - pp.add("reference_temperature", m_Tref); amrex::Vector t_hts{0.0, 100.0, 400.0}; pp.addarr("temperature_heights", t_hts); amrex::Vector t_vals{265.0, 265.0, 268.0}; @@ -154,6 +153,7 @@ class TurbLESTestBC : public MeshTest { amrex::ParmParse pp("transport"); pp.add("viscosity", m_mu); + pp.add("reference_temperature", m_Tref); } } void test_calls_body(bool do_postsolve = false) diff --git a/unit_tests/turbulence/test_turbulence_RANS.cpp b/unit_tests/turbulence/test_turbulence_RANS.cpp index 8afd34310c..16aee0d1df 100644 --- a/unit_tests/turbulence/test_turbulence_RANS.cpp +++ b/unit_tests/turbulence/test_turbulence_RANS.cpp @@ -106,7 +106,6 @@ TEST_F(TurbRANSTest, test_1eqKrans_setup_calc) } { amrex::ParmParse pp("ABL"); - pp.add("reference_temperature", Tref); pp.add("surface_temp_rate", 0.0); pp.add("initial_wind_profile", true); amrex::Vector t_hts{0.0, 100.0, 4000.0}; @@ -122,6 +121,11 @@ TEST_F(TurbRANSTest, test_1eqKrans_setup_calc) pp.addarr("tke_values", tke_vals); pp.add("surface_temp_flux", 0.0); } + // Transport + { + amrex::ParmParse pp("transport"); + pp.add("reference_temperature", Tref); + } // Initialize necessary parts of solver populate_parameters(); diff --git a/unit_tests/wind_energy/abl_test_utils.cpp b/unit_tests/wind_energy/abl_test_utils.cpp index b4571a60cd..f59f122835 100644 --- a/unit_tests/wind_energy/abl_test_utils.cpp +++ b/unit_tests/wind_energy/abl_test_utils.cpp @@ -16,7 +16,6 @@ void ABLMeshTest::populate_parameters() pp.addarr("temperature_heights", theights); pp.addarr("temperature_values", tvalues); pp.add("perturb_ref_height", 50.0); - pp.add("reference_temperature", 300.0); pp.add("kappa", 0.41); pp.add("surface_roughness_z0", 0.1); } @@ -42,9 +41,9 @@ void ABLMeshTest::populate_parameters() pp.add("angular_frequency", 1.0); } - // Boussinesq Buoyancy + // Transport { - amrex::ParmParse pp("BoussinesqBuoyancy"); + amrex::ParmParse pp("transport"); pp.add("reference_temperature", 300.0); } @@ -126,4 +125,4 @@ void ABLMeshTest::populate_parameters() } } -} // namespace amr_wind_tests \ No newline at end of file +} // namespace amr_wind_tests diff --git a/unit_tests/wind_energy/test_abl_src.cpp b/unit_tests/wind_energy/test_abl_src.cpp index 08e4568609..4cd5698fb3 100644 --- a/unit_tests/wind_energy/test_abl_src.cpp +++ b/unit_tests/wind_energy/test_abl_src.cpp @@ -536,6 +536,7 @@ TEST_F(ABLMeshTest, boussinesq) pde_mgr.register_icns(); pde_mgr.register_transport_pde("Temperature"); sim().init_physics(); + sim().create_transport_model(); amr_wind::pde::icns::BoussinesqBuoyancy bb(sim()); @@ -582,6 +583,7 @@ TEST_F(ABLMeshTest, boussinesq_nph) pde_mgr.register_icns(); pde_mgr.register_transport_pde("Temperature"); sim().init_physics(); + sim().create_transport_model(); amr_wind::pde::icns::BoussinesqBuoyancy bb(sim()); diff --git a/unit_tests/wind_energy/test_abl_src_timetable.cpp b/unit_tests/wind_energy/test_abl_src_timetable.cpp index 0e3ff8d6ab..fc6101f71d 100644 --- a/unit_tests/wind_energy/test_abl_src_timetable.cpp +++ b/unit_tests/wind_energy/test_abl_src_timetable.cpp @@ -76,7 +76,6 @@ class ABLSrcTimeTableTest : public MeshTest pp.addarr("temperature_heights", theights); pp.addarr("temperature_values", tvalues); pp.add("perturb_ref_height", 50.0); - pp.add("reference_temperature", 300.0); pp.add("kappa", 0.41); pp.add("surface_roughness_z0", 0.1); } @@ -94,6 +93,12 @@ class ABLSrcTimeTableTest : public MeshTest amrex::ParmParse pp("time"); pp.add("fixed_dt", 0.1); } + + // Transport + { + amrex::ParmParse pp("transport"); + pp.add("reference_temperature", 300.0); + } } std::string m_tvel_fname = "target_velocities.txt"; std::string m_forces_fname = "abl_forces.txt";