ERF
Energy Research and Forecasting: An Atmospheric Modeling Code
surface_flux_diagnostics Namespace Reference

Functions

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::Real sensible_heat_flux_wm2_from_rhotheta_flux (amrex::Real rhotheta_flux) noexcept
 
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::Real latent_heat_flux_wm2_from_rhoqv_flux (amrex::Real rhoqv_flux) noexcept
 

Function Documentation

◆ latent_heat_flux_wm2_from_rhoqv_flux()

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::Real surface_flux_diagnostics::latent_heat_flux_wm2_from_rhoqv_flux ( amrex::Real  rhoqv_flux)
noexcept
37 {
38  return L_v * rhoqv_flux;
39 }
constexpr amrex::Real L_v
Definition: ERF_Constants.H:48

Referenced by plotfile2d::fill_latent_heat_flux_from_klevel_or_missing().

Here is the caller graph for this function:

◆ sensible_heat_flux_wm2_from_rhotheta_flux()

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::Real surface_flux_diagnostics::sensible_heat_flux_wm2_from_rhotheta_flux ( amrex::Real  rhotheta_flux)
noexcept

Convert applied conservative surface fluxes to W m^-2 for 2D plotfile output.

SFS_hfx3 and SFS_q1fx3 are already conservative applied fluxes. Noah-MP LSM kinematic fluxes are converted to conservative fluxes in SurfaceLayer::compute_SurfaceLayer_bcs, so this layer must not multiply by density. The output sign convention follows ERF's lower-boundary flux convention. These helpers exist so the 2D writer does not duplicate unit semantics.

Maintenance note: Do not add source-specific Noah-MP/MOST branches here. If this helper ever appears to need a density factor, the applied SurfaceLayer flux contract has likely been broken upstream.

30 {
31  return Cp_d * rhotheta_flux;
32 }
constexpr amrex::Real Cp_d
Definition: ERF_Constants.H:44

Referenced by plotfile2d::fill_sensible_heat_flux_from_klevel_or_missing().

Here is the caller graph for this function: