GRINS-0.7.0
List of all members | Public Member Functions | Protected Attributes
GRINSTesting::TurbBoundFuncBase Class Referenceabstract
Inheritance diagram for GRINSTesting::TurbBoundFuncBase:
Inheritance graph
[legend]
Collaboration diagram for GRINSTesting::TurbBoundFuncBase:
Collaboration graph
[legend]

Public Member Functions

 TurbBoundFuncBase (libMesh::MeshFunction *turbulent_bc_values)
 
virtual libMesh::Number operator() (const libMesh::Point &, const libMesh::Real=0)
 
virtual libMesh::Number compute_final_value (const libMesh::DenseVector< libMesh::Number > &u_nu_values)=0
 
virtual void operator() (const libMesh::Point &p, const libMesh::Real t, libMesh::DenseVector< libMesh::Number > &output)
 

Protected Attributes

libMesh::MeshFunction * _turbulent_bc_values
 

Detailed Description

Definition at line 74 of file test_turbulent_channel.C.

Constructor & Destructor Documentation

GRINSTesting::TurbBoundFuncBase::TurbBoundFuncBase ( libMesh::MeshFunction *  turbulent_bc_values)
inline

Definition at line 77 of file test_turbulent_channel.C.

78  : _turbulent_bc_values(turbulent_bc_values)
79  { this->_initialized = true; }
libMesh::MeshFunction * _turbulent_bc_values

Member Function Documentation

virtual libMesh::Number GRINSTesting::TurbBoundFuncBase::compute_final_value ( const libMesh::DenseVector< libMesh::Number > &  u_nu_values)
pure virtual
virtual libMesh::Number GRINSTesting::TurbBoundFuncBase::operator() ( const libMesh::Point &  ,
const libMesh::Real  = 0 
)
inlinevirtual

Definition at line 81 of file test_turbulent_channel.C.

82  { libmesh_not_implemented(); }
virtual void GRINSTesting::TurbBoundFuncBase::operator() ( const libMesh::Point &  p,
const libMesh::Real  t,
libMesh::DenseVector< libMesh::Number > &  output 
)
inlinevirtual

Definition at line 86 of file test_turbulent_channel.C.

References _turbulent_bc_values, and compute_final_value().

89  {
90  output.resize(1);
91  output.zero();
92 
93  // Since the turbulent_bc_values object has a solution from a 1-d problem, we have to zero out the y coordinate of p
94  libMesh::Point p_copy(p);
95  // Also, the 1-d solution provided is on the domain [0, 1] on the x axis and we need to map this to the corresponding point on the y axis
96  p_copy(0) = p_copy(1);
97  p_copy(1)= 0.0;
98  // Also, the 1-d solution provided is actually a symmetry solution, so we have to make the following map
99  // x_GRINS < 0.5 => x_meshfunction = 2*x_GRINS , x_GRINS >= 0.5 => x_GRINS = 1 - x_GRINS, x_meshfunction = 2*x_GRINS
100  if(p_copy(0) > 0.5)
101  {
102  p_copy(0) = 1 - p_copy(0);
103  }
104  p_copy(0) = 2*p_copy(0);
105 
106  libMesh::DenseVector<libMesh::Number> u_nu_values;
107  _turbulent_bc_values->operator()(p_copy, t, u_nu_values);
108 
109  output(0) = this->compute_final_value(u_nu_values);
110  }
libMesh::MeshFunction * _turbulent_bc_values
virtual libMesh::Number compute_final_value(const libMesh::DenseVector< libMesh::Number > &u_nu_values)=0

Member Data Documentation

libMesh::MeshFunction* GRINSTesting::TurbBoundFuncBase::_turbulent_bc_values
protected

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

Generated on Thu Jun 2 2016 21:52:33 for GRINS-0.7.0 by  doxygen 1.8.10