From de2696a56b158abeefbbb0fa98cafea05e3fca89 Mon Sep 17 00:00:00 2001 From: Michael Zingale Date: Thu, 27 Jun 2024 14:53:16 -0400 Subject: [PATCH] fix some amrex::Real namespace issues (#471) --- Source/Maestro.H | 74 ++++++++++++++++++++++++------------------------ 1 file changed, 37 insertions(+), 37 deletions(-) diff --git a/Source/Maestro.H b/Source/Maestro.H index 8c14503d3..67a765507 100644 --- a/Source/Maestro.H +++ b/Source/Maestro.H @@ -170,10 +170,10 @@ class Maestro : public amrex::AmrCore { void AdvectBaseEnthalpySphr( BaseState& rhoh0_predicted_edge_state); // only need to advect species for test_basetest problem - void UpdateSpecies(const BaseState& rho0, - const BaseState& rho0_predicted_edge, - const BaseState& rhoX0_old, - BaseState& rhoX0_new); + void UpdateSpecies(const BaseState& rho0, + const BaseState& rho0_predicted_edge, + const BaseState& rhoX0_old, + BaseState& rhoX0_new); // end MaestroAdvectBase.cpp functions //////////// @@ -363,12 +363,12 @@ class Maestro : public amrex::AmrCore { #endif void ComputeCutoffCoords(const BaseState& rho0_state) const; - void RestrictBase(BaseState& s0, const bool is_cell_centered) const; - void RestrictBase(const BaseStateArray& s0, + void RestrictBase(BaseState& s0, const bool is_cell_centered) const; + void RestrictBase(const BaseStateArray& s0, const bool is_cell_centered) const; - void FillGhostBase(BaseState& s0, const bool is_cell_centered) const; - void FillGhostBase(const BaseStateArray& s0, + void FillGhostBase(BaseState& s0, const bool is_cell_centered) const; + void FillGhostBase(const BaseStateArray& s0, const bool is_cell_centered) const; // end MaestroBaseStateGeometry.cpp functions @@ -429,7 +429,7 @@ class Maestro : public amrex::AmrCore { /// @param bcs_in boundary conditions /// @param flag determines whether base state is subtracted (true) or added (false) void PutInPertForm(amrex::Vector& scal, - const BaseState& s0, int comp, int bccomp, + const BaseState& s0, int comp, int bccomp, const amrex::Vector& bcs, bool flag); /// If `flag`, subtract the base state, returning the perturbed quantity. @@ -444,7 +444,7 @@ class Maestro : public amrex::AmrCore { /// @param bcs_in boundary conditions /// @param flag determines whether base state is subtracted (true) or added (false) void PutInPertForm(int level, amrex::Vector& scal, - const BaseState& s0, int comp, int bccomp, + const BaseState& s0, int comp, int bccomp, const amrex::Vector& bcs, bool flag); /// If `flag`, returns species mass fraction `X` given the conserved variable `rhoX`. @@ -933,7 +933,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const simhy, const amrex::Box& domainBox, const amrex::Vector& bcs, - const amrex::GpuArray dx, + const amrex::GpuArray dx, int comp, int bccomp, bool is_vel) const; void MakeEdgeScalEdges(const amrex::MFIter& mfi, @@ -953,7 +953,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const simhy, const amrex::Box& domainBox, const amrex::Vector& bcs, - const amrex::GpuArray dx, + const amrex::GpuArray dx, int comp, int bccomp, const bool is_vel, const bool is_conservative) const; #else @@ -962,7 +962,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const umac, amrex::Array4 const vmac, amrex::Array4 const wmac, - const amrex::GpuArray dx); + const amrex::GpuArray dx); void MakeEdgeScalPredictor(const amrex::MFIter& mfi, amrex::Array4 const slx, @@ -983,7 +983,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const simhz, const amrex::Box& domainBox, const amrex::Vector& bcs, - const amrex::GpuArray dx, + const amrex::GpuArray dx, int comp, int bccomp, const bool is_vel) const; void MakeEdgeScalTransverse(const amrex::MFIter& mfi, @@ -1009,7 +1009,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const simhzy, const amrex::Box& domainBox, const amrex::Vector& bcs, - const amrex::GpuArray dx, + const amrex::GpuArray dx, int comp, int bccomp, const bool is_vel, const bool is_conservative) const; @@ -1038,7 +1038,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const simhzy, const amrex::Box& domainBox, const amrex::Vector& bcs, - const amrex::GpuArray dx, + const amrex::GpuArray dx, int comp, int bccomp, const bool is_vel, const bool is_conservative) const; #endif @@ -1242,9 +1242,9 @@ class Maestro : public amrex::AmrCore { const BaseState& p0_minus_peosbar, const amrex::Real dt_in, const amrex::Real dtold_in); - static void Tridiag(const BaseStateArray& a, const BaseStateArray& b, - const BaseStateArray& c, const BaseStateArray& r, - const BaseStateArray& u, const int n); + static void Tridiag(const BaseStateArray& a, const BaseStateArray& b, + const BaseStateArray& c, const BaseStateArray& r, + const BaseStateArray& u, const int n); void ProlongBasetoUniform(const BaseState& base_ml_s, BaseState& base_fine_s) const; @@ -1402,7 +1402,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const Ip, amrex::Array4 const Im, const amrex::Box& domainBox, const amrex::Vector& bcs, - const amrex::GpuArray dx, const bool is_umac, + const amrex::GpuArray dx, const bool is_umac, const int comp, const int bccomp) const; //////////// @@ -1734,7 +1734,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const ury, amrex::Array4 const uimhy, const amrex::Box& domainBox, - const amrex::GpuArray dx); + const amrex::GpuArray dx); void VelPredVelocities(const amrex::MFIter& mfi, amrex::Array4 const utilde, @@ -1755,7 +1755,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const force, amrex::Array4 const w0_cart_in, const amrex::Box& domainBox, - const amrex::GpuArray dx); + const amrex::GpuArray dx); #else void VelPredInterface(const amrex::MFIter& mfi, amrex::Array4 const utilde, @@ -1779,7 +1779,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const urz, amrex::Array4 const uimhz, const amrex::Box& domainBox, - const amrex::GpuArray dx); + const amrex::GpuArray dx); void VelPredTransverse(const amrex::MFIter& mfi, amrex::Array4 const utilde, @@ -1802,7 +1802,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const wimhxy, amrex::Array4 const wimhyx, const amrex::Box& domainBox, - const amrex::GpuArray dx); + const amrex::GpuArray dx); void VelPredVelocities(const amrex::MFIter& mfi, amrex::Array4 const utilde, @@ -1836,7 +1836,7 @@ class Maestro : public amrex::AmrCore { amrex::Array4 const force, amrex::Array4 const w0_cart_in, const amrex::Box& domainBox, - const amrex::GpuArray dx); + const amrex::GpuArray dx); #endif //////////////////////// @@ -1990,29 +1990,29 @@ class Maestro : public amrex::AmrCore { amrex::Vector diagfile3_data; // problem information - amrex::GpuArray center; + amrex::GpuArray center; // rotation #ifdef ROTATION - Real sin_theta; - Real cos_theta; - Real omega; + amrex::Real sin_theta; + amrex::Real cos_theta; + amrex::Real omega; #endif // sponge - Real r_sp; - Real r_md; - Real r_tp; + amrex::Real r_sp; + amrex::Real r_md; + amrex::Real r_tp; // outer sponge parameters used for spherical problems - Real r_sp_outer; - Real r_tp_outer; + amrex::Real r_sp_outer; + amrex::Real r_tp_outer; /// the sponge_start_density should be the density below which the /// sponge first turns on. Different problems may compute this in /// different ways (i.e. not using sponge_center_density and /// sponge_start_factor), so we provide this public module variable to /// ensure that the rest of the code always knows at what density the /// sponge begins. - Real sponge_start_density; + amrex::Real sponge_start_density; /// Stores fluxes at coarse-fine interface for synchronization. /// This will be sized `max_level+1` @@ -2025,8 +2025,8 @@ class Maestro : public amrex::AmrCore { /// Rate of change of pressure at the lower boundary. Used to modify w0 /// and p0 in the case of a closed upper boundary (planar). - Real p0bdot; - Real p0b; + amrex::Real p0bdot; + amrex::Real p0b; /// flag for writing plotfiles enum plotfile_flag {