ERF
Energy Research and Forecasting: An Atmospheric Modeling Code
ERF_Wstar.H File Reference
#include <ERF_Constants.H>
Include dependency graph for ERF_Wstar.H:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

AMREX_GPU_DEVICE AMREX_FORCE_INLINE amrex::Real calc_wstar (const amrex::Real &ust, const amrex::Real &tst, const amrex::Real &qst, const amrex::Real &pblh, const amrex::Real &th, const amrex::Real &thv, const amrex::Real &qv=0.0)
 
AMREX_GPU_DEVICE AMREX_FORCE_INLINE amrex::Real calc_wstar (const amrex::Real &hfx, const amrex::Real &pblh, const amrex::Real &thv)
 

Function Documentation

◆ calc_wstar() [1/2]

AMREX_GPU_DEVICE AMREX_FORCE_INLINE amrex::Real calc_wstar ( const amrex::Real &  hfx,
const amrex::Real &  pblh,
const amrex::Real &  thv 
)
38 {
39  if (hfx <= 0) {
40  return 0.0;
41  } else {
42  return std::cbrt(CONST_GRAV / thv * pblh * hfx);
43  }
44 }
constexpr amrex::Real CONST_GRAV
Definition: ERF_Constants.H:21

◆ calc_wstar() [2/2]

AMREX_GPU_DEVICE AMREX_FORCE_INLINE amrex::Real calc_wstar ( const amrex::Real &  ust,
const amrex::Real &  tst,
const amrex::Real &  qst,
const amrex::Real &  pblh,
const amrex::Real &  th,
const amrex::Real &  thv,
const amrex::Real &  qv = 0.0 
)
20 {
21  amrex::Real hfx = -ust*tst; // <theta'w'>
22  if (hfx <= 0) {
23  return 0.0;
24  }
25  if (qv > 0) {
26  // have moisture -- estimate buoyancy flux, <thetav'w'> (Stull 4.4.5d)
27  hfx = hfx*(1 + 0.61*qv) + 0.61*th*(-ust*qst);
28  }
29  return std::cbrt(CONST_GRAV / thv * pblh * hfx);
30 }
@ qv
Definition: ERF_Kessler.H:36

Referenced by surface_flux_charnock::iterate_flux(), surface_flux_mod_charnock::iterate_flux(), surface_flux_donelan::iterate_flux(), surface_temp_charnock::iterate_flux(), surface_temp_mod_charnock::iterate_flux(), surface_temp_donelan::iterate_flux(), surface_flux_wave_coupled::iterate_flux(), surface_temp_wave_coupled::iterate_flux(), surface_flux::iterate_flux(), and surface_temp::iterate_flux().

Here is the caller graph for this function: