GRINS-0.8.0
List of all members | Public Member Functions | Private Member Functions
GRINS::SingleVariable Class Reference

Variables with a single component. More...

#include <single_variable.h>

Inheritance diagram for GRINS::SingleVariable:
Inheritance graph
[legend]
Collaboration diagram for GRINS::SingleVariable:
Collaboration graph
[legend]

Public Member Functions

 SingleVariable (const std::vector< std::string > &var_names, const std::vector< VariableIndex > &var_indices, const std::set< libMesh::subdomain_id_type > &subdomain_ids)
 
 ~SingleVariable ()
 
VariableIndex var () const
 
- Public Member Functions inherited from GRINS::FEVariablesBase
 FEVariablesBase (const std::vector< std::string > &var_names, const std::vector< VariableIndex > &var_indices, const std::set< libMesh::subdomain_id_type > &subdomain_ids)
 
virtual ~FEVariablesBase ()
 
void set_is_constraint_var (bool is_constraint_var)
 Set whether or not this is a "constraint" variable. More...
 
bool is_constraint_var () const
 
void set_neumann_bc_is_positive (bool is_positive)
 Reset whetever Neumann bc is postive or not. More...
 
libMesh::Real neumann_bc_sign () const
 
const std::vector< std::string > & active_var_names () const
 Return the var names that are active from this class. More...
 
const std::vector< VariableIndex > & var_indices () const
 
const std::set< libMesh::subdomain_id_type > & subdomain_ids () const
 

Private Member Functions

 SingleVariable ()
 

Additional Inherited Members

- Protected Attributes inherited from GRINS::FEVariablesBase
std::vector< VariableIndex_vars
 
std::vector< std::string > _var_names
 
bool _is_constraint_var
 Tracks whether this is a constraint variable. More...
 
libMesh::Real _neumann_bc_sign
 Track the sign of the Neumann BC term. Defaults to 1.0. More...
 
std::set< libMesh::subdomain_id_type > _subdomain_ids
 

Detailed Description

Variables with a single component.

Subclasses can add syntatic sugar, but this class can provide the sanity check on there actually being one component.

Definition at line 37 of file single_variable.h.

Constructor & Destructor Documentation

GRINS::SingleVariable::SingleVariable ( const std::vector< std::string > &  var_names,
const std::vector< VariableIndex > &  var_indices,
const std::set< libMesh::subdomain_id_type > &  subdomain_ids 
)
inline

Definition at line 41 of file single_variable.h.

45  {
46  if( var_names.size() != 1 )
47  libmesh_error_msg("ERROR: SingleVariable must only have a single name!");
48 
49  if(var_indices.size() != 1)
50  libmesh_error_msg("ERROR: SingleVariable must only have a single index!");
51  }
const std::set< libMesh::subdomain_id_type > & subdomain_ids() const
FEVariablesBase(const std::vector< std::string > &var_names, const std::vector< VariableIndex > &var_indices, const std::set< libMesh::subdomain_id_type > &subdomain_ids)
const std::vector< VariableIndex > & var_indices() const
GRINS::SingleVariable::~SingleVariable ( )
inline

Definition at line 53 of file single_variable.h.

53 {}
GRINS::SingleVariable::SingleVariable ( )
private

Member Function Documentation

VariableIndex GRINS::SingleVariable::var ( ) const
inline

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

Generated on Tue Dec 19 2017 12:47:32 for GRINS-0.8.0 by  doxygen 1.8.9.1