ERF
Energy Research and Forecasting: An Atmospheric Modeling Code
ShocImplicit Class Reference

#include <ERF_ShocImplicit.H>

Static Public Member Functions

static void cache_baseline_state (ShocColumnData &col)
 
static void compute_tmpi (const ShocColumnData &col, int ic, double dt, const amrex::Vector< amrex::Real > &rho_zi, amrex::Vector< amrex::Real > &tmpi)
 
static void compute_dp_inverse (const ShocColumnData &col, int ic, amrex::Vector< amrex::Real > &rdp_zt)
 
static AMREX_GPU_HOST_DEVICE amrex::Real compute_temperature (amrex::Real thetal, amrex::Real ql, amrex::Real exner)
 
static AMREX_GPU_HOST_DEVICE amrex::Real compute_vapor (amrex::Real qw, amrex::Real ql)
 
static void advance_implicit_state (ShocColumnData &col, const ShocRuntimeOptions &opts, double dt)
 
static void finalize_from_pdf (ShocColumnData &col, const ShocRuntimeOptions &opts, double dt)
 
static void update_prognostics (ShocColumnData &col, const ShocRuntimeOptions &opts, double dt)
 

Member Function Documentation

◆ advance_implicit_state()

void ShocImplicit::advance_implicit_state ( ShocColumnData col,
const ShocRuntimeOptions opts,
double  dt 
)
static
169 {
170  static_cast<void>(opts);
171 
172  Real dt = static_cast<Real>(dt_d);
173 
175 
176  const int nlev = col.layout.nlev;
177  if (nlev == 0) {
178  return;
179  }
180 
181  const Box iface_box(IntVect(0,0,0), IntVect(col.layout.ncell - 1, nlev, 0));
182  const Box tri_box(IntVect(0,0,0), IntVect(col.layout.ncell - 1, 0, nlev - 1));
183  FArrayBox rho_zi_fab(iface_box, 1, The_Async_Arena());
184  FArrayBox tk_zi_fab(iface_box, 1, The_Async_Arena());
185  FArrayBox tkh_zi_fab(iface_box, 1, The_Async_Arena());
186  FArrayBox tmpi_fab(iface_box, 1, The_Async_Arena());
187  FArrayBox rdp_zt_fab(Box(IntVect(0,0,0), IntVect(col.layout.ncell - 1, nlev - 1, 0)), 1, The_Async_Arena());
188  FArrayBox rhs_fab(tri_box, 1, The_Async_Arena());
189  FArrayBox soln_fab(tri_box, 1, The_Async_Arena());
190  FArrayBox coeffA_fab(tri_box, 1, The_Async_Arena());
191  FArrayBox coeffB_fab(tri_box, 1, The_Async_Arena());
192  FArrayBox inv_coeffB_fab(tri_box, 1, The_Async_Arena());
193  FArrayBox coeffC_fab(tri_box, 1, The_Async_Arena());
194 
195  interpolate_cc_to_iface(col, col.rho, rho_zi_fab);
196  interpolate_cc_to_iface(col, col.tk, tk_zi_fab);
197  interpolate_cc_to_iface(col, col.tkh, tkh_zi_fab);
198 
199  auto thetal = col.thetal.array();
200  auto qw = col.qw.array();
201  auto tke = col.tke.array();
202  auto u = col.u.array();
203  auto v = col.v.array();
204 
205  const auto surf_tau_u = col.surf_tau_u.const_array();
206  const auto surf_tau_v = col.surf_tau_v.const_array();
207  const auto surf_sens_flux = col.surf_sens_flux.const_array();
208  const auto surf_lat_flux = col.surf_lat_flux.const_array();
209  const auto rho = col.rho.const_array();
210  const auto dz = col.dz.const_array();
211  const auto zt = col.zt.const_array();
212  const auto zi = col.zi.const_array();
213  const auto rho_zi = rho_zi_fab.const_array();
214  const auto tk_zi = tk_zi_fab.const_array();
215  const auto tkh_zi = tkh_zi_fab.const_array();
216  const auto layout = col.layout;
217  auto tmpi = tmpi_fab.array();
218  auto rdp_zt = rdp_zt_fab.array();
219  auto rhs = rhs_fab.array();
220  auto soln = soln_fab.array();
221  auto coeffA = coeffA_fab.array();
222  auto coeffB = coeffB_fab.array();
223  auto inv_coeffB = inv_coeffB_fab.array();
224  auto coeffC = coeffC_fab.array();
225 
226  const Box col_box(IntVect(0,0,0), IntVect(layout.ncell - 1, 0, 0));
227  ParallelFor(col_box, [=] AMREX_GPU_DEVICE (int ic, int, int) noexcept
228  {
229  for (int k = 0; k <= nlev; ++k) {
230  tmpi(ic,k,0) = dt * CONST_GRAV * amrex::max(rho_zi(ic,k,0), 1.0e-12_rt) /
231  interface_spacing(zt, zi, layout, ic, k);
232  if (k < nlev) {
233  rdp_zt(ic,k,0) = 1.0_rt / amrex::max(CONST_GRAV * rho(ic,k,0) * dz(ic,k,0), 1.0e-12_rt);
234  }
235  }
236 
237  // E3SM: cmnfac = dtime * g * rho_zi(nlevi-1) * rdp_zt(nlev-1)
238  // The tmpi array includes a 1/dz_zi interface-spacing factor that
239  // belongs only in the tridiagonal diffusion matrix, NOT in the
240  // explicit surface-flux injection.
241  const Real cmnfac = dt * CONST_GRAV * amrex::max(rho_zi(ic,0,0), 1.0e-12_rt) * rdp_zt(ic,0,0);
242 
243  const Real uw_sfc = surf_tau_u(ic,0,0);
244  const Real vw_sfc = surf_tau_v(ic,0,0);
245  const Real stress_mag = std::sqrt(uw_sfc * uw_sfc + vw_sfc * vw_sfc);
246  Real ksrf = 0.0_rt;
247  Real wtke_sfc = 0.0_rt;
248  if (stress_mag > 1.0e-12_rt) {
249  const Real ws = amrex::max(std::sqrt(u(ic,0,0) * u(ic,0,0) + v(ic,0,0) * v(ic,0,0)), shoc_u_ws_min());
250  const Real rho_zi_sfc = amrex::max(rho_zi(ic,0,0), 1.0e-12_rt);
251  const Real tau_u = rho_zi_sfc * uw_sfc;
252  const Real tau_v = rho_zi_sfc * vw_sfc;
253  const Real tau = std::sqrt(tau_u * tau_u + tau_v * tau_v);
254  ksrf = amrex::max(tau / ws, shoc_ksrf_min());
255  const Real ustar = amrex::max(std::sqrt(stress_mag), shoc_ustar_min());
256  wtke_sfc = ustar * ustar * ustar;
257  }
258 
259  for (int k = 0; k < nlev; ++k) {
260  rhs(ic,0,k) = u(ic,k,0);
261  coeffA(ic,0,k) = (k > 0) ? -tk_zi(ic,k,0) * tmpi(ic,k,0) * rdp_zt(ic,k,0) : 0.0_rt;
262  coeffC(ic,0,k) = (k < nlev - 1) ? -tk_zi(ic,k+1,0) * tmpi(ic,k+1,0) * rdp_zt(ic,k,0) : 0.0_rt;
263  coeffB(ic,0,k) = 1.0_rt - coeffA(ic,0,k) - coeffC(ic,0,k);
264  }
265  coeffB(ic,0,0) += ksrf * dt * CONST_GRAV * rdp_zt(ic,0,0);
266  SolveTridiag(ic, 0, 0, nlev - 1, soln, coeffA, coeffB, inv_coeffB, coeffC, rhs);
267  for (int k = 0; k < nlev; ++k) {
268  u(ic,k,0) = soln(ic,0,k);
269  }
270 
271  for (int k = 0; k < nlev; ++k) {
272  rhs(ic,0,k) = v(ic,k,0);
273  coeffA(ic,0,k) = (k > 0) ? -tk_zi(ic,k,0) * tmpi(ic,k,0) * rdp_zt(ic,k,0) : 0.0_rt;
274  coeffC(ic,0,k) = (k < nlev - 1) ? -tk_zi(ic,k+1,0) * tmpi(ic,k+1,0) * rdp_zt(ic,k,0) : 0.0_rt;
275  coeffB(ic,0,k) = 1.0_rt - coeffA(ic,0,k) - coeffC(ic,0,k);
276  }
277  coeffB(ic,0,0) += ksrf * dt * CONST_GRAV * rdp_zt(ic,0,0);
278  SolveTridiag(ic, 0, 0, nlev - 1, soln, coeffA, coeffB, inv_coeffB, coeffC, rhs);
279  for (int k = 0; k < nlev; ++k) {
280  v(ic,k,0) = soln(ic,0,k);
281  }
282 
283  for (int k = 0; k < nlev; ++k) {
284  rhs(ic,0,k) = thetal(ic,k,0);
285  coeffA(ic,0,k) = (k > 0) ? -tkh_zi(ic,k,0) * tmpi(ic,k,0) * rdp_zt(ic,k,0) : 0.0_rt;
286  coeffC(ic,0,k) = (k < nlev - 1) ? -tkh_zi(ic,k+1,0) * tmpi(ic,k+1,0) * rdp_zt(ic,k,0) : 0.0_rt;
287  coeffB(ic,0,k) = 1.0_rt - coeffA(ic,0,k) - coeffC(ic,0,k);
288  }
289  rhs(ic,0,0) += cmnfac * surf_sens_flux(ic,0,0);
290  SolveTridiag(ic, 0, 0, nlev - 1, soln, coeffA, coeffB, inv_coeffB, coeffC, rhs);
291  for (int k = 0; k < nlev; ++k) {
292  thetal(ic,k,0) = soln(ic,0,k);
293  }
294 
295  for (int k = 0; k < nlev; ++k) {
296  rhs(ic,0,k) = qw(ic,k,0);
297  coeffA(ic,0,k) = (k > 0) ? -tkh_zi(ic,k,0) * tmpi(ic,k,0) * rdp_zt(ic,k,0) : 0.0_rt;
298  coeffC(ic,0,k) = (k < nlev - 1) ? -tkh_zi(ic,k+1,0) * tmpi(ic,k+1,0) * rdp_zt(ic,k,0) : 0.0_rt;
299  coeffB(ic,0,k) = 1.0_rt - coeffA(ic,0,k) - coeffC(ic,0,k);
300  }
301  rhs(ic,0,0) += cmnfac * surf_lat_flux(ic,0,0);
302  SolveTridiag(ic, 0, 0, nlev - 1, soln, coeffA, coeffB, inv_coeffB, coeffC, rhs);
303  for (int k = 0; k < nlev; ++k) {
304  qw(ic,k,0) = amrex::max(soln(ic,0,k), shoc_min_qw());
305  }
306 
307  for (int k = 0; k < nlev; ++k) {
308  rhs(ic,0,k) = shoc_clamp(tke(ic,k,0), shoc_min_tke(), shoc_max_tke());
309  coeffA(ic,0,k) = (k > 0) ? -tkh_zi(ic,k,0) * tmpi(ic,k,0) * rdp_zt(ic,k,0) : 0.0_rt;
310  coeffC(ic,0,k) = (k < nlev - 1) ? -tkh_zi(ic,k+1,0) * tmpi(ic,k+1,0) * rdp_zt(ic,k,0) : 0.0_rt;
311  coeffB(ic,0,k) = 1.0_rt - coeffA(ic,0,k) - coeffC(ic,0,k);
312  }
313  rhs(ic,0,0) += cmnfac * wtke_sfc;
314  SolveTridiag(ic, 0, 0, nlev - 1, soln, coeffA, coeffB, inv_coeffB, coeffC, rhs);
315  for (int k = 0; k < nlev; ++k) {
316  tke(ic,k,0) = shoc_clamp(soln(ic,0,k), shoc_min_tke(), shoc_max_tke());
317  }
318  });
319 }
constexpr amrex::Real zero
Definition: ERF_Constants.H:8
constexpr amrex::Real CONST_GRAV
Definition: ERF_Constants.H:64
AMREX_ALWAYS_ASSERT(bx.length()[2]==khi+1)
rho
Definition: ERF_InitCustomPert_Bubble.H:107
ParallelFor(grown_box, [=] AMREX_GPU_DEVICE(int i, int j, int k) { qrcuten_arr(i, j, k)=Real(0);qscuten_arr(i, j, k)=Real(0);qicuten_arr(i, j, k)=Real(0);})
amrex::Real Real
Definition: ERF_ShocInterface.H:19
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE T shoc_clamp(T value, T lo, T hi)
Definition: ERF_ShocTypes.H:382
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void SolveTridiag(int i, int j, int klo, int khi, const amrex::Array4< amrex::Real > &soln_a, const amrex::Array4< const amrex::Real > &coeffA_a, const amrex::Array4< amrex::Real > &coeffB_a, const amrex::Array4< amrex::Real > &inv_coeffB_a, const amrex::Array4< const amrex::Real > &coeffC_a, const amrex::Array4< const amrex::Real > &RHS_a)
Definition: ERF_SolveTridiag.H:6
@ dz
Definition: ERF_AdvanceWSM6.cpp:104
@ zi
Definition: ERF_AdvanceWSM6.cpp:133
amrex::FArrayBox dz
Definition: ERF_ShocTypes.H:210
amrex::FArrayBox tk
Definition: ERF_ShocTypes.H:236
amrex::FArrayBox surf_lat_flux
Definition: ERF_ShocTypes.H:277
amrex::FArrayBox rho
Definition: ERF_ShocTypes.H:213
amrex::FArrayBox surf_tau_v
Definition: ERF_ShocTypes.H:279
amrex::FArrayBox tke
Definition: ERF_ShocTypes.H:223
amrex::FArrayBox tkh
Definition: ERF_ShocTypes.H:237
ShocColumnLayout layout
Definition: ERF_ShocTypes.H:205
amrex::FArrayBox zi
Definition: ERF_ShocTypes.H:209
amrex::FArrayBox surf_sens_flux
Definition: ERF_ShocTypes.H:276
amrex::FArrayBox qw
Definition: ERF_ShocTypes.H:221
amrex::FArrayBox v
Definition: ERF_ShocTypes.H:225
amrex::FArrayBox zt
Definition: ERF_ShocTypes.H:208
amrex::FArrayBox u
Definition: ERF_ShocTypes.H:224
amrex::FArrayBox surf_tau_u
Definition: ERF_ShocTypes.H:278
amrex::FArrayBox thetal
Definition: ERF_ShocTypes.H:217
int nlev
Definition: ERF_ShocTypes.H:196
int ncell
Definition: ERF_ShocTypes.H:195

Referenced by ShocDriver::advance().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ cache_baseline_state()

void ShocImplicit::cache_baseline_state ( ShocColumnData col)
static
85 {
86  auto thetal = col.thetal.const_array();
87  auto theta = col.theta.const_array();
88  auto qv = col.qv.const_array();
89  auto qc = col.qc.const_array();
90  auto qi = col.qi.const_array();
91  auto u = col.u.const_array();
92  auto v = col.v.const_array();
93  auto tke = col.tke.const_array();
94 
95  auto thetal_base = col.thetal_base.array();
96  auto theta_base = col.theta_base.array();
97  auto qv_base = col.qv_base.array();
98  auto qc_base = col.qc_base.array();
99  auto qi_base = col.qi_base.array();
100  auto u_base = col.u_base.array();
101  auto v_base = col.v_base.array();
102  auto tke_base = col.tke_base_state.array();
103 
104  const Box cell_box(IntVect(0,0,0), IntVect(col.layout.ncell - 1, col.layout.nlev - 1, 0));
105  ParallelFor(cell_box, [=] AMREX_GPU_DEVICE (int ic, int k, int) noexcept
106  {
107  thetal_base(ic,k,0) = thetal(ic,k,0);
108  theta_base(ic,k,0) = theta(ic,k,0);
109  qv_base(ic,k,0) = qv(ic,k,0);
110  qc_base(ic,k,0) = qc(ic,k,0);
111  qi_base(ic,k,0) = qi(ic,k,0);
112  u_base(ic,k,0) = u(ic,k,0);
113  v_base(ic,k,0) = v(ic,k,0);
114  tke_base(ic,k,0) = tke(ic,k,0);
115  });
116 }
@ theta
Definition: ERF_MM5.H:20
@ qv
Definition: ERF_Kessler.H:30
@ qc
Definition: ERF_SatAdj.H:40
@ qi
Definition: ERF_WSM6.H:27
amrex::FArrayBox theta
Definition: ERF_ShocTypes.H:214
amrex::FArrayBox theta_base
Definition: ERF_ShocTypes.H:261
amrex::FArrayBox qi
Definition: ERF_ShocTypes.H:220
amrex::FArrayBox v_base
Definition: ERF_ShocTypes.H:266
amrex::FArrayBox tke_base_state
Definition: ERF_ShocTypes.H:267
amrex::FArrayBox qv_base
Definition: ERF_ShocTypes.H:262
amrex::FArrayBox qc
Definition: ERF_ShocTypes.H:219
amrex::FArrayBox qi_base
Definition: ERF_ShocTypes.H:264
amrex::FArrayBox u_base
Definition: ERF_ShocTypes.H:265
amrex::FArrayBox qc_base
Definition: ERF_ShocTypes.H:263
amrex::FArrayBox qv
Definition: ERF_ShocTypes.H:218
amrex::FArrayBox thetal_base
Definition: ERF_ShocTypes.H:260

Referenced by ShocDriver::advance().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ compute_dp_inverse()

void ShocImplicit::compute_dp_inverse ( const ShocColumnData col,
int  ic,
amrex::Vector< amrex::Real > &  rdp_zt 
)
static
139 {
140  rdp_zt.assign(col.layout.nlev, 0.0);
141  const auto rho = col.rho.const_array();
142  const auto dz = col.dz.const_array();
143  for (int k = 0; k < col.layout.nlev; ++k) {
144  rdp_zt[k] = 1.0_rt / amrex::max(CONST_GRAV * rho(ic,k,0) * dz(ic,k,0), 1.0e-12_rt);
145  }
146 }

◆ compute_temperature()

AMREX_GPU_HOST_DEVICE Real ShocImplicit::compute_temperature ( amrex::Real  thetal,
amrex::Real  ql,
amrex::Real  exner 
)
static
153 {
154  return shoc::temperature_from_thetal(thetal, ql, 0.0_rt, exner);
155 }
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::Real temperature_from_thetal(amrex::Real thetal, amrex::Real qc, amrex::Real qi, amrex::Real exner) noexcept
Definition: ERF_ShocThermoUtils.H:40
Here is the call graph for this function:

◆ compute_tmpi()

void ShocImplicit::compute_tmpi ( const ShocColumnData col,
int  ic,
double  dt,
const amrex::Vector< amrex::Real > &  rho_zi,
amrex::Vector< amrex::Real > &  tmpi 
)
static
124 {
125  tmpi.assign(col.layout.nlev + 1, 0.0_rt);
126  const auto zt = col.zt.const_array();
127  const auto zi = col.zi.const_array();
128  const auto layout = col.layout;
129  for (int k = 0; k <= col.layout.nlev; ++k) {
130  tmpi[k] = static_cast<amrex::Real>(dt) * CONST_GRAV * amrex::max(rho_zi[k], 1.0e-12_rt) /
131  interface_spacing(zt, zi, layout, ic, k);
132  }
133 }

◆ compute_vapor()

AMREX_GPU_HOST_DEVICE Real ShocImplicit::compute_vapor ( amrex::Real  qw,
amrex::Real  ql 
)
static
161 {
162  return amrex::max(0.0_rt, qw - amrex::max(0.0_rt, ql));
163 }

◆ finalize_from_pdf()

void ShocImplicit::finalize_from_pdf ( ShocColumnData col,
const ShocRuntimeOptions opts,
double  dt 
)
static
325 {
326  Real dt = static_cast<Real>(dt_d);
327 
329 
330  const int nlev = col.layout.nlev;
331  if (nlev == 0) {
332  return;
333  }
334 
335  auto thetal = col.thetal.array();
336  auto theta = col.theta.array();
337  auto theta_v = col.theta_v.array();
338  auto qv = col.qv.array();
339  auto qc = col.qc.array();
340  auto qi = col.qi.array();
341  auto qw = col.qw.array();
342  auto tabs = col.tabs.array();
343  auto host_dse = col.host_dse.array();
344  auto tke = col.tke.array();
345  auto u = col.u.array();
346  auto v = col.v.array();
347  auto shoc_ql = col.shoc_ql.array();
348  auto theta_tend = col.theta_tend.array();
349  auto qv_tend = col.qv_tend.array();
350  auto qc_tend = col.qc_tend.array();
351  auto qi_tend = col.qi_tend.array();
352  auto u_tend = col.u_tend.array();
353  auto v_tend = col.v_tend.array();
354  auto tke_tend = col.tke_tend.array();
355 
356  const auto zt = col.zt.const_array();
357  const auto exner = col.exner.const_array();
358  const auto shoc_ql_pdf = col.shoc_ql.const_array();
359  const auto theta_base = col.theta_base.const_array();
360  const auto qv_base = col.qv_base.const_array();
361  const auto qc_base = col.qc_base.const_array();
362  const auto qi_base = col.qi_base.const_array();
363  const auto u_base = col.u_base.const_array();
364  const auto v_base = col.v_base.const_array();
365  const auto tke_base = col.tke_base_state.const_array();
366  const auto energy_view = shoc::make_energy_fixer_view(col);
367  const Box col_box(IntVect(0,0,0), IntVect(col.layout.ncell - 1, 0, 0));
368  const Box cell_box(IntVect(0,0,0), IntVect(col.layout.ncell - 1, nlev - 1, 0));
369 
370  {
371  BL_PROFILE("SHOC::advance::finalize::energy_fix");
372  ParallelFor(col_box, [=] AMREX_GPU_DEVICE (int ic, int, int) noexcept
373  {
374  shoc::apply_energy_fix_column(energy_view, ic, dt);
375  });
376  }
377 
378  {
379  BL_PROFILE("SHOC::advance::finalize::reconstruct");
380  ParallelFor(cell_box, [=] AMREX_GPU_DEVICE (int ic, int k, int) noexcept
381  {
382  const Real qw_new_loc = amrex::max(qw(ic,k,0), shoc_min_qw());
383  const Real ql_base = amrex::max(0.0_rt, qc_base(ic,k,0) + qi_base(ic,k,0));
384  const Real pdf_ql_raw = shoc_clamp(shoc_ql_pdf(ic,k,0), 0.0_rt, qw_new_loc);
385  const Real pdf_ql = opts.debug_disable_pdf_cloud_increment
386  ? shoc_clamp(ql_base, 0.0_rt, qw_new_loc)
387  : pdf_ql_raw;
388  Real tabs_new = 0.0_rt;
389  Real qv_new_loc = 0.0_rt;
390  Real qc_new_loc = 0.0_rt;
391  Real qi_new_loc = 0.0_rt;
392  shoc::reconstruct_pdf_state(thetal(ic,k,0), qw_new_loc,
393  exner(ic,k,0), qi_base(ic,k,0), pdf_ql,
394  tabs_new, qv_new_loc, qc_new_loc, qi_new_loc);
395 
396  const Real ql_total = qc_new_loc + qi_new_loc;
397  tabs(ic,k,0) = tabs_new;
398  theta(ic,k,0) = tabs_new / amrex::max(exner(ic,k,0), 1.0e-12_rt);
399  qw(ic,k,0) = qw_new_loc;
400  qv(ic,k,0) = qv_new_loc;
401  qc(ic,k,0) = qc_new_loc;
402  qi(ic,k,0) = qi_new_loc;
403  shoc_ql(ic,k,0) = ql_total;
404  theta_v(ic,k,0) = theta(ic,k,0) * (1.0_rt + shoc_zvir() * qv_new_loc - ql_total);
405  host_dse(ic,k,0) = Cp_d * tabs_new + CONST_GRAV * zt(ic,k,0);
406 
407  theta_tend(ic,k,0) = (theta(ic,k,0) - theta_base(ic,k,0)) / dt;
408  qv_tend(ic,k,0) = (qv_new_loc - qv_base(ic,k,0)) / dt;
409  qc_tend(ic,k,0) = (qc_new_loc - qc_base(ic,k,0)) / dt;
410  qi_tend(ic,k,0) = (qi_new_loc - qi_base(ic,k,0)) / dt;
411  u_tend(ic,k,0) = (u(ic,k,0) - u_base(ic,k,0)) / dt;
412  v_tend(ic,k,0) = (v(ic,k,0) - v_base(ic,k,0)) / dt;
413  tke_tend(ic,k,0) = (tke(ic,k,0) - tke_base(ic,k,0)) / dt;
414  });
415  }
416 }
constexpr amrex::Real Cp_d
Definition: ERF_Constants.H:49
@ tabs
Definition: ERF_Kessler.H:26
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void reconstruct_pdf_state(amrex::Real thetal, amrex::Real qw, amrex::Real exner, amrex::Real qi_seed, amrex::Real pdf_ql, amrex::Real &tabs, amrex::Real &qv, amrex::Real &qc, amrex::Real &qi) noexcept
Definition: ERF_ShocThermoUtils.H:86
ShocEnergyFixerView make_energy_fixer_view(ShocColumnData &col)
Definition: ERF_ShocEnergyFixer.H:40
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void apply_energy_fix_column(const ShocEnergyFixerView &v, int ic, double dt_d) noexcept
Definition: ERF_ShocEnergyFixer.H:84
amrex::FArrayBox theta_v
Definition: ERF_ShocTypes.H:216
amrex::FArrayBox qc_tend
Definition: ERF_ShocTypes.H:271
amrex::FArrayBox v_tend
Definition: ERF_ShocTypes.H:274
amrex::FArrayBox shoc_ql
Definition: ERF_ShocTypes.H:243
amrex::FArrayBox host_dse
Definition: ERF_ShocTypes.H:227
amrex::FArrayBox exner
Definition: ERF_ShocTypes.H:215
amrex::FArrayBox tke_tend
Definition: ERF_ShocTypes.H:275
amrex::FArrayBox qi_tend
Definition: ERF_ShocTypes.H:272
amrex::FArrayBox u_tend
Definition: ERF_ShocTypes.H:273
amrex::FArrayBox tabs
Definition: ERF_ShocTypes.H:222
amrex::FArrayBox theta_tend
Definition: ERF_ShocTypes.H:269
amrex::FArrayBox qv_tend
Definition: ERF_ShocTypes.H:270
bool debug_disable_pdf_cloud_increment
Definition: ERF_ShocTypes.H:117

Referenced by ShocDriver::advance().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ update_prognostics()

void ShocImplicit::update_prognostics ( ShocColumnData col,
const ShocRuntimeOptions opts,
double  dt 
)
static
422 {
424  advance_implicit_state(col, opts, dt);
425  finalize_from_pdf(col, opts, dt);
426 }
static void advance_implicit_state(ShocColumnData &col, const ShocRuntimeOptions &opts, double dt)
Definition: ERF_ShocImplicit.cpp:166
static void cache_baseline_state(ShocColumnData &col)
Definition: ERF_ShocImplicit.cpp:84
static void finalize_from_pdf(ShocColumnData &col, const ShocRuntimeOptions &opts, double dt)
Definition: ERF_ShocImplicit.cpp:322

The documentation for this class was generated from the following files: