GRINS-0.7.0
List of all members | Public Member Functions
GRINS::MultiVarSingleFETypeVariable Class Reference

Base class for variables with multiple components that all have the same FEType. More...

#include <multi_var_single_fe_type_variable.h>

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

Public Member Functions

 MultiVarSingleFETypeVariable (const GetPot &input, const std::string &physics_name, const std::string &old_var_prefix, const std::vector< std::string > &old_var_names, const std::vector< std::string > &default_names, const std::string &subsection, const std::string &default_family, const std::string &default_order, bool is_constraint_var)
 Deprecated, old style constructor. More...
 
 MultiVarSingleFETypeVariable (const GetPot &input, const std::string &subsection, const std::vector< std::string > &default_names, bool is_constraint_var)
 Primary constructor. More...
 
 ~MultiVarSingleFETypeVariable ()
 
- Public Member Functions inherited from GRINS::SingleFETypeVariable
 SingleFETypeVariable (const GetPot &input, const std::string &physics_name, const std::string &old_var_prefix, const std::string &subsection, const std::string &default_family, const std::string &default_order, bool is_constraint_var)
 Deprecated, old style constructor. More...
 
 SingleFETypeVariable (const GetPot &input, const std::string &subsection, bool is_constraint_var)
 Primary constructor. More...
 
 ~SingleFETypeVariable ()
 
virtual void init (libMesh::FEMSystem *system)
 Add variables to the system. More...
 
- Public Member Functions inherited from GRINS::FEVariablesBase
 FEVariablesBase (bool is_constraint_var)
 
 ~FEVariablesBase ()
 
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
 

Additional Inherited Members

- Protected Member Functions inherited from GRINS::SingleFETypeVariable
void parse_family_and_order (const GetPot &input, const std::string &physics_name, const std::string &old_var_prefix, const std::string &subsection, std::vector< GRINSEnums::FEFamily > &family, std::vector< GRINSEnums::Order > &order, const std::string &default_family, const std::string &default_order)
 Helper function to parse FEFamily and Order. More...
 
void dup_family_order_check (const GetPot &input, const std::string &physics_name, const std::string &old_var_prefix) const
 Check (and error if true) for old and new style FEFamily/Order input. More...
 
bool have_family_or_order (const GetPot &input, const std::string &physics_name, const std::string &old_var_prefix, const std::string &subsection) const
 Check for no presence of FEFamily/Order input. More...
 
void parse_old_style_with_warning (const GetPot &input, const std::string &physics_name, const std::string &old_var_prefix, const std::string &default_family, const std::string &default_order, const std::string &subsection, GRINSEnums::FEFamily &family, GRINSEnums::Order &order)
 
void parse_new_style (const GetPot &input, const std::string &subsection, GRINSEnums::FEFamily &family, GRINSEnums::Order &order)
 
- Protected Member Functions inherited from GRINS::FEVariablesBase
void parse_names_from_input (const GetPot &input, const std::string &subsection, std::vector< std::string > &var_names, const std::vector< std::string > &default_names)
 Method to parse variable names from input. More...
 
void duplicate_name_section_check (const GetPot &input) const
 Check for old name style and new name style. If both present, error. More...
 
bool check_dep_name_input (const GetPot &input, const std::string &new_subsection) const
 Check for deprecated variable name input style. More...
 
- Protected Attributes inherited from GRINS::FEVariablesBase
std::vector< VariableIndex_vars
 
std::vector< std::string > _var_names
 
std::vector< GRINSEnums::FEFamily > _family
 
std::vector< GRINSEnums::Order > _order
 
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...
 

Detailed Description

Base class for variables with multiple components that all have the same FEType.

Definition at line 34 of file multi_var_single_fe_type_variable.h.

Constructor & Destructor Documentation

GRINS::MultiVarSingleFETypeVariable::MultiVarSingleFETypeVariable ( const GetPot &  input,
const std::string &  physics_name,
const std::string &  old_var_prefix,
const std::vector< std::string > &  old_var_names,
const std::vector< std::string > &  default_names,
const std::string &  subsection,
const std::string &  default_family,
const std::string &  default_order,
bool  is_constraint_var 
)

Deprecated, old style constructor.

This constructor is used for when there is possibly old deprecated styles of input for which we do additional checks/warnings. Otherwise, you should use the new constructor.

Definition at line 33 of file multi_var_single_fe_type_variable.C.

References GRINS::FEVariablesBase::_var_names, GRINS::FEVariablesBase::check_dep_name_input(), and GRINS::FEVariablesBase::parse_names_from_input().

42  : SingleFETypeVariable(input,physics_name,old_var_prefix,subsection,default_family,
43  default_order,is_constraint_var)
44  {
45  libmesh_assert_equal_to( default_names.size(), old_var_names.size() );
46 
47  _var_names.resize(default_names.size());
48 
49  if( this->check_dep_name_input(input,subsection) )
50  for( unsigned int n = 0; n < default_names.size(); n++ )
51  _var_names[n] = input("Physics/VariableNames/"+old_var_names[n], default_names[n] );
52  else
53  this->parse_names_from_input(input,subsection,_var_names,default_names);
54  }
SingleFETypeVariable(const GetPot &input, const std::string &physics_name, const std::string &old_var_prefix, const std::string &subsection, const std::string &default_family, const std::string &default_order, bool is_constraint_var)
Deprecated, old style constructor.
void parse_names_from_input(const GetPot &input, const std::string &subsection, std::vector< std::string > &var_names, const std::vector< std::string > &default_names)
Method to parse variable names from input.
std::vector< std::string > _var_names
bool is_constraint_var() const
bool check_dep_name_input(const GetPot &input, const std::string &new_subsection) const
Check for deprecated variable name input style.
GRINS::MultiVarSingleFETypeVariable::MultiVarSingleFETypeVariable ( const GetPot &  input,
const std::string &  subsection,
const std::vector< std::string > &  default_names,
bool  is_constraint_var 
)

Primary constructor.

Will parse from input section [Variables/<subsection>].

Definition at line 56 of file multi_var_single_fe_type_variable.C.

References GRINS::FEVariablesBase::_var_names, and GRINS::FEVariablesBase::parse_names_from_input().

60  : SingleFETypeVariable(input,subsection,is_constraint_var)
61  {
62  _var_names.resize(default_names.size());
63  this->parse_names_from_input(input,subsection,_var_names,default_names);
64  }
SingleFETypeVariable(const GetPot &input, const std::string &physics_name, const std::string &old_var_prefix, const std::string &subsection, const std::string &default_family, const std::string &default_order, bool is_constraint_var)
Deprecated, old style constructor.
void parse_names_from_input(const GetPot &input, const std::string &subsection, std::vector< std::string > &var_names, const std::vector< std::string > &default_names)
Method to parse variable names from input.
std::vector< std::string > _var_names
bool is_constraint_var() const
GRINS::MultiVarSingleFETypeVariable::~MultiVarSingleFETypeVariable ( )
inline

Definition at line 59 of file multi_var_single_fe_type_variable.h.

59 {};

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

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