6 amrex::Real
T_inf = amrex::Real(300.0);
pp.query(
"T_inf",
T_inf);
7 amrex::Real
M_inf = amrex::Real(0.2);
pp.query(
"M_inf",
M_inf);
10 amrex::Real
beta = amrex::Real(0.01);
pp.query(
"beta",
beta);
16 const amrex::Real*
prob_lo = geomdata.ProbLo();
17 const amrex::Real*
prob_hi = geomdata.ProbHi();
50 const amrex::Real
rdOcp = sc.rdOcp;
52 ParallelFor(bx, [=] AMREX_GPU_DEVICE(
int i,
int j,
int k) noexcept
54 const Real*
dx = geomdata.CellSize();
65 const Real rho_norm = std::pow(
one + deltaT,
inv_gm1);
66 state_pert(i, j, k,
Rho_comp) = rho_norm *
rho_0 - r_hse(i,j,k);
74 const Real rho_theta =
rho_0 * rho_norm * (
T * std::pow(
p_0 /
p,
rdOcp));
77 const Real r2d_xy = std::sqrt((
x-
xc)*(
x-
xc) + (
y-
yc)*(
y-
yc));
GpuArray< Real, AMREX_SPACEDIM > dx
Definition: ERF_ActuatorSpreading.cpp:131
constexpr amrex::Real p_0
Definition: ERF_Constants.H:69
constexpr amrex::Real R_d
Definition: ERF_Constants.H:49
constexpr amrex::Real Gamma
Definition: ERF_Constants.H:70
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::Real getRhoThetagivenP(const amrex::Real p, const amrex::Real qv=amrex::Real(0))
Definition: ERF_EOS.H:172
#define RhoScalar_comp
Definition: ERF_IndexDefines.H:65
#define Rho_comp
Definition: ERF_IndexDefines.H:61
#define RhoTheta_comp
Definition: ERF_IndexDefines.H:62
static AMREX_GPU_DEVICE amrex::Real erf_vortex_Gaussian(amrex::Real x, amrex::Real y, amrex::Real xc, amrex::Real yc, amrex::Real R, amrex::Real beta, amrex::Real sigma)
Definition: ERF_InitCustomPert.H:33
amrex::Real gamma
Definition: ERF_InitCustomPert_IsentropicVortex.H:9
const amrex::Real * prob_lo
Definition: ERF_InitCustomPert_IsentropicVortex.H:16
amrex::Real R
Definition: ERF_InitCustomPert_IsentropicVortex.H:12
amrex::Real yc
Definition: ERF_InitCustomPert_IsentropicVortex.H:20
amrex::Real a_inf
Definition: ERF_InitCustomPert_IsentropicVortex.H:38
amrex::Real p_inf
Definition: ERF_InitCustomPert_IsentropicVortex.H:5
amrex::Real rho_0
Definition: ERF_InitCustomPert_IsentropicVortex.H:33
amrex::Real sigma
Definition: ERF_InitCustomPert_IsentropicVortex.H:11
const amrex::Real rdOcp
Definition: ERF_InitCustomPert_IsentropicVortex.H:50
ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept { const Real *dx=geomdata.CellSize();const Real x=(i+myhalf) *dx[0];const Real y=(j+myhalf) *dx[1];const Real Omg=erf_vortex_Gaussian(x, y, xc, yc, R, beta, sigma);const Real deltaT=-(gamma - one)/(two *sigma *sigma) *Omg *Omg;const Real rho_norm=std::pow(one+deltaT, inv_gm1);state_pert(i, j, k, Rho_comp)=rho_norm *rho_0 - r_hse(i, j, k);const Real T=(one+deltaT) *T_inf;const Real p=std::pow(rho_norm, gamma)/gamma *rho_0 *a_inf *a_inf;const Real rho_theta=rho_0 *rho_norm *(T *std::pow(p_0/p, rdOcp));state_pert(i, j, k, RhoTheta_comp)=rho_theta - getRhoThetagivenP(p_hse(i, j, k));const Real r2d_xy=std::sqrt((x-xc) *(x-xc)+(y-yc) *(y-yc));state_pert(i, j, k, RhoScalar_comp)=fourth *(one+std::cos(PI *std::min(r2d_xy, R)/R));})
amrex::Real alpha
Definition: ERF_InitCustomPert_IsentropicVortex.H:8
amrex::Real xc_frac
Definition: ERF_InitCustomPert_IsentropicVortex.H:13
const amrex::Real * prob_hi
Definition: ERF_InitCustomPert_IsentropicVortex.H:17
amrex::Real beta
Definition: ERF_InitCustomPert_IsentropicVortex.H:10
amrex::Real M_inf
Definition: ERF_InitCustomPert_IsentropicVortex.H:7
amrex::Real inv_gm1
Definition: ERF_InitCustomPert_IsentropicVortex.H:27
amrex::Real yc_frac
Definition: ERF_InitCustomPert_IsentropicVortex.H:14
amrex::Real T_inf
Definition: ERF_InitCustomPert_IsentropicVortex.H:6
amrex::Real xc
Definition: ERF_InitCustomPert_IsentropicVortex.H:19
constexpr amrex::Real two
Definition: ERF_NumericalConstants.H:38
constexpr amrex::Real one
Definition: ERF_NumericalConstants.H:37
constexpr amrex::Real fourth
Definition: ERF_NumericalConstants.H:42
constexpr amrex::Real zero
Definition: ERF_NumericalConstants.H:36
constexpr amrex::Real myhalf
Definition: ERF_NumericalConstants.H:41
constexpr amrex::Real PI
Definition: ERF_NumericalConstants.H:46
@ T
Definition: ERF_IndexDefines.H:180
@ p
Definition: ERF_WSM6.H:303