www.mooseframework.org
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
NSEntropyError Class Reference

#include <NSEntropyError.h>

Inheritance diagram for NSEntropyError:
[legend]

Public Member Functions

 NSEntropyError (const InputParameters &parameters)
 
virtual Real getValue ()
 

Protected Member Functions

virtual Real computeQpIntegral ()
 

Protected Attributes

Real _rho_infty
 
Real _p_infty
 
const VariableValue & _rho
 
const VariableValue & _pressure
 
const IdealGasFluidProperties_fp
 

Detailed Description

Definition at line 22 of file NSEntropyError.h.

Constructor & Destructor Documentation

◆ NSEntropyError()

NSEntropyError::NSEntropyError ( const InputParameters &  parameters)

Definition at line 34 of file NSEntropyError.C.

35  : ElementIntegralPostprocessor(parameters),
36  _rho_infty(getParam<Real>("rho_infty")),
37  _p_infty(getParam<Real>("p_infty")),
38  _rho(coupledValue(NS::density)),
39  _pressure(coupledValue(NS::pressure)),
40  _fp(getUserObject<IdealGasFluidProperties>("fluid_properties"))
41 {
42 }
const std::string density
Definition: NS.h:17
const VariableValue & _pressure
const VariableValue & _rho
const IdealGasFluidProperties & _fp
const std::string pressure
Definition: NS.h:26

Member Function Documentation

◆ computeQpIntegral()

Real NSEntropyError::computeQpIntegral ( )
protectedvirtual

Definition at line 51 of file NSEntropyError.C.

52 {
53  Real integrand = (_pressure[_qp] / _p_infty) * std::pow(_rho_infty / _rho[_qp], _fp.gamma()) - 1.;
54  return integrand * integrand;
55 }
const VariableValue & _pressure
const VariableValue & _rho
ExpressionBuilder::EBTerm pow(const ExpressionBuilder::EBTerm &left, T exponent)
const IdealGasFluidProperties & _fp

◆ getValue()

Real NSEntropyError::getValue ( )
virtual

Definition at line 45 of file NSEntropyError.C.

46 {
47  return std::sqrt(ElementIntegralPostprocessor::getValue());
48 }

Member Data Documentation

◆ _fp

const IdealGasFluidProperties& NSEntropyError::_fp
protected

Definition at line 38 of file NSEntropyError.h.

Referenced by computeQpIntegral().

◆ _p_infty

Real NSEntropyError::_p_infty
protected

Definition at line 32 of file NSEntropyError.h.

Referenced by computeQpIntegral().

◆ _pressure

const VariableValue& NSEntropyError::_pressure
protected

Definition at line 35 of file NSEntropyError.h.

Referenced by computeQpIntegral().

◆ _rho

const VariableValue& NSEntropyError::_rho
protected

Definition at line 34 of file NSEntropyError.h.

Referenced by computeQpIntegral().

◆ _rho_infty

Real NSEntropyError::_rho_infty
protected

Definition at line 31 of file NSEntropyError.h.

Referenced by computeQpIntegral().


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