WARPXM v1.10.0
Loading...
Searching...
No Matches
5-moment_base.h File Reference
#include "warpxm/warpxm_config.h"
#include "apps/wmapplication.h"
#include "apps/general_functions/geometry.h"
#include "apps/general_functions/functions.h"
#include <cmath>

Go to the source code of this file.

Classes

struct  constants_5moment_t
 Structure for holding constants used in the 5moment solvers. More...
 

Namespaces

namespace  wxm
 Base namespace for everything not included in the global namespace.
 
namespace  wxm::apps
 
namespace  wxm::apps::five_moment
 
namespace  wxm::apps::five_moment::bc
 

Functions

real wxm::apps::five_moment::getRhoFloored (const real *q, const real rho_min=std::numeric_limits< real >::epsilon())
 Get the floored mass density.
 
real wxm::apps::five_moment::getPressureFloored (const real *q, const real gas_gamma, const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Get the pressure from Euler (5-moment) variables using floors for pressure and density.
 
real wxm::apps::five_moment::getTemperatureFloored (const real *q, const real gas_gamma, const real A=1.0, const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Get the temperature from Euler (5-moment) variables using floors for pressure and density.
 
void wxm::apps::five_moment::NCtoC (const constants_5moment_t *pC, const real QNC[5], real QC[5])
 Converts nonconserved (primitive) variables to conserved variables.
 
void wxm::apps::five_moment::CtoNC (const constants_5moment_t *pC, const real QC[5], real QNC[5], const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Converts conserved variables to nonconserved (primitive) variables.
 
void wxm::apps::five_moment::NCtoCDifferential (const constants_5moment_t *pC, const real QNC_center[5], const real dQNC[5], const real QC_center[5], real dQC[5])
 This currently isn't used anywhere.
 
void wxm::apps::five_moment::rotateVector (const real v[5], const solverVariables_t *pSV, real Rv[5])
 Rotates a 5-moment variable set from world frame to local frame.
 
void wxm::apps::five_moment::antirotateVector (const real Rv[5], const solverVariables_t *pSV, real v[5])
 Rotates a 5-moment variable set from local frame to world frame.
 
void wxm::apps::five_moment::eulerFlux (const constants_5moment_t *pC, const real QC[5], real flux[5], const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Flux along x-axis for Euler fluid equations using conserved variables.
 
void wxm::apps::five_moment::eulerRoeFluxSolver (const constants_5moment_t *pC, const real QC_l[5], const real QC_r[5], real *s, real amdq[5], real apdq[5], const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Solves the full Roe decomposition for the euler fluid problem using conserved variables - assumes an entropy fix - function is stolen from WARPX.
 
void wxm::apps::five_moment::eulerRoeAverages (const constants_5moment_t *pC, const real ql[5], const real qr[5], const real &pl, const real &pr, real &rho, real &u, real &v, real &w, real &enth, real &a, const real rho_min=std::numeric_limits< real >::epsilon())
 
void wxm::apps::five_moment::hartenHymanEntropyFix (const constants_5moment_t *pC, const real ql[5], const real qr[5], const real s[3], const real wave[][3], real amdq[5], real apdq[5], const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 
real wxm::apps::five_moment::eulerNumericalFlux_x (const constants_5moment_t *pC, const real QC_l[5], const real QC_r[5], void(*numerical_flux_scheme)(const constants_5moment_t *pC, const real QC_l[5], const real QC_r[5], real *s, real amdq[5], real apdq[5], const real rho_min, const real press_min), real flux[5], const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Calculates the Euler Numerical flux given a scheme along the x-axis which is to be used as a numerical flux.
 
real wxm::apps::five_moment::eulerNumericalFlux (const constants_5moment_t *pC, const solverVariables_t *pSV, const real QC_l[5], const real QC_r[5], void(*numerical_flux_scheme)(const constants_5moment_t *pC, const real QC_l[5], const real QC_r[5], real *s, real amdq[5], real apdq[5], const real rho_min, const real press_min), real numericalFlux[5], const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Calculates the Numerical Flux for the Euler fluid equations using Roe's Method as given by Leveque in "Finite Volume Methods for Hyperbolic Problems" equation 15.40 for a given numerical Flux scheme (Roe, HLLE, etc.)
 
void wxm::apps::five_moment::eulerHLLEFluxSolver (const constants_5moment_t *pC, const real QC_l[5], const real QC_r[5], real *s, real amdq[5], real apdq[5], const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Calculates the HLLE flux for the Euler fluid equations.
 
void wxm::apps::five_moment::eulerHLLECFluxSolver (const constants_5moment_t *pC, const real QC_l[5], const real QC_r[5], real *s, real amdq[5], real apdq[5], const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 
real wxm::apps::five_moment::eulerRusanovFlux (const constants_5moment_t *pC, const solverVariables_t *pSV, const real QC_l[5], const real QC_r[5], real numericalFlux[5], const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Calculates the Rusanov flux for the Euler fluid equations directly.
 
real wxm::apps::five_moment::eulerInternalFlux (const constants_5moment_t *pC, const solverVariables_t *pSV, const real QC[5], std::vector< std::vector< real > > &internalFlux, const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Calculates the internal euler flux at a given point.
 
void wxm::apps::five_moment::navier_stokes_anisotropic_pressure_tensor (const real viscosity, const real *q, const real *grad_rho, const real *grad_p[3], real pi[3][3])
 
void wxm::apps::five_moment::navier_stokes_viscous_flux_tensor (const real *q, const solverVariables_t *pSV, const real pi[][3], const real h[3], std::vector< std::vector< real > > &flux_tensor)
 
void wxm::apps::five_moment::navier_stokes_internal_flux (const constants_5moment_t *pC, const solverVariables_t *pSV, const real mu, const real k, const real *q, const real u[3], const real *grad_u[3], const real div_u, const real grad_T[3], std::vector< std::vector< real > > &internal_flux, const real rho_min=std::numeric_limits< real >::epsilon())
 
real wxm::apps::five_moment::navier_stokes_numerical_flux (constants_5moment_t *pC, const solverVariables_t *pSV, const real viscosity, const real thermal_conductivity, const real *q_l, const real *q_r, const real *aux_l, const real *aux_r, real *numerical_flux, const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 
real wxm::apps::five_moment::interspeciesCollisions (const real nu_ab, const constants_5moment_t *pC_a, const constants_5moment_t *pC_b, const real *q_a, const real *q_b, real *source, const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 
void wxm::apps::five_moment::calcGradT (const constants_5moment_t *pC, const real *q, const real *aux, const real *grad_u, real *grad_T, const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 Computes temperature gradients from 5 moment conserved variable gradients/values.
 
real wxm::apps::five_moment::calcDivU (const real *q, const real *aux, const real rho_min=std::numeric_limits< real >::epsilon())
 
void wxm::apps::five_moment::calcGradU (const real *q, const real *aux, real *grad_u[3], const real rho_min=std::numeric_limits< real >::epsilon())
 
void wxm::apps::five_moment::get_mu_and_k (const constants_5moment_t *pC, const real *q, const bool is_neutral, const real collision_coefficient, const real minimum_frequency, const real diffusivity_min, const real diffusivity_max, const bool is_const_mu, const real const_mu, const bool is_const_k, const real const_k, real &mu, real &k, const real rho_min=std::numeric_limits< real >::epsilon(), const real press_min=std::numeric_limits< real >::epsilon())
 
real wxm::apps::five_moment::positivity_preserving_source_dt (const real *q, const real *dqdt, real lambda, const real rho_min=std::numeric_limits< real >::epsilon())
 Computes the maximum allowable dt for a source term to preserve positivity for the positivity-preserving DG scheme.
 
void wxm::apps::five_moment::bc::noslipWallCondition (const constants_5moment_t *pC, const solverVariables_t *pSV, const real *QC, const real vx_w, const real vy_w, const real vz_w, real *QC_w)
 
void wxm::apps::five_moment::bc::noslipWallCondition_gradients (const constants_5moment_t *pC, const solverVariables_t *pSV, const real *QC, real *QC_w)
 
void wxm::apps::five_moment::bc::freeslipWallCondition (const solverVariables_t *pSV, const real *QC, real *QC_w)
 
void wxm::apps::five_moment::bc::freeslipWallCondition_yu (const constants_5moment_t *pC, const solverVariables_t *pSV, const real *QC, real *QC_w)
 
void wxm::apps::five_moment::bc::freeslipWallCondition_gradients_yu (const constants_5moment_t *pC, const solverVariables_t *pSV, const real *QC, real *QC_w)
 
void wxm::apps::five_moment::bc::copyoutBoundaryCondition (const real *QC, real *QC_w)
 
void wxm::apps::five_moment::bc::axisBoundaryCondition (const constants_5moment_t *pC, const solverVariables_t *pSV, const real *QC, real *QC_w)
 
void wxm::apps::five_moment::bc::axisBoundaryCondition_gradients (const constants_5moment_t *pC, const solverVariables_t *pSV, const real *QC, real *QC_w, const real rho_min=std::numeric_limits< real >::epsilon())
 
void wxm::apps::five_moment::bc::imhd_to_twofluid_bc (const real *QC, const solverVariables_t *pSV, real Aa, real Ab, real Za, real Zb, real ztheta_ba, real skin_depth_norm, real *QC_w)
 
void wxm::apps::five_moment::bc::imhd_to_twofluid_consistent_assumption (const real *QC, const solverVariables_t *pSV, real Ai, real Ae, real Zi, real Ze, real ztheta_ba, real skin_depth_norm, real *QC_w)
 
real pressure_5moment (const constants_5moment_t *pC, const real QC[5])
 Soon to be deprecated.
 

Function Documentation

◆ pressure_5moment()

real pressure_5moment ( const constants_5moment_t pC,
const real  QC[5] 
)

Soon to be deprecated.