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

Simple material with constant properties. More...

#include <AnisoHeatConductionMaterial.h>

Inheritance diagram for AnisoHeatConductionMaterial:
[legend]

Public Member Functions

 AnisoHeatConductionMaterial (const InputParameters &parameters)
 

Protected Member Functions

virtual void computeProperties ()
 

Protected Attributes

const bool _has_temp
 
const VariableValue & _temperature
 
const Real _my_thermal_conductivity_x
 
const Real _my_thermal_conductivity_y
 
const Real _my_thermal_conductivity_z
 
const PostprocessorValue *const _thermal_conductivity_x_pp
 
const PostprocessorValue *const _thermal_conductivity_y_pp
 
const PostprocessorValue *const _thermal_conductivity_z_pp
 
const Real _my_specific_heat
 
MaterialProperty< Real > *const _thermal_conductivity_x
 
MaterialProperty< Real > *const _thermal_conductivity_x_dT
 
MaterialProperty< Real > *const _thermal_conductivity_y
 
MaterialProperty< Real > *const _thermal_conductivity_y_dT
 
MaterialProperty< Real > *const _thermal_conductivity_z
 
MaterialProperty< Real > *const _thermal_conductivity_z_dT
 
MaterialProperty< Real > & _specific_heat
 
Function *const _specific_heat_temperature_function
 

Detailed Description

Simple material with constant properties.

Definition at line 18 of file AnisoHeatConductionMaterial.h.

Constructor & Destructor Documentation

AnisoHeatConductionMaterial::AnisoHeatConductionMaterial ( const InputParameters &  parameters)

Definition at line 39 of file AnisoHeatConductionMaterial.C.

40  : Material(parameters),
41 
42  _has_temp(isCoupled("temp")),
43  _temperature(_has_temp ? coupledValue("temp") : _zero),
44 
46  isParamValid("thermal_conductivity_x") ? getParam<Real>("thermal_conductivity_x") : -1),
48  isParamValid("thermal_conductivity_y") ? getParam<Real>("thermal_conductivity_y") : -1),
50  isParamValid("thermal_conductivity_z") ? getParam<Real>("thermal_conductivity_z") : -1),
51 
52  _thermal_conductivity_x_pp(isParamValid("thermal_conductivity_x_pp")
53  ? &getPostprocessorValue("thermal_conductivity_x_pp")
54  : NULL),
55  _thermal_conductivity_y_pp(isParamValid("thermal_conductivity_y_pp")
56  ? &getPostprocessorValue("thermal_conductivity_y_pp")
57  : NULL),
58  _thermal_conductivity_z_pp(isParamValid("thermal_conductivity_z_pp")
59  ? &getPostprocessorValue("thermal_conductivity_z_pp")
60  : NULL),
61 
62  _my_specific_heat(isParamValid("specific_heat") ? getParam<Real>("specific_heat") : 0),
63 
64  _thermal_conductivity_x(&declareProperty<Real>("thermal_conductivity_x")),
65  _thermal_conductivity_x_dT(&declareProperty<Real>("thermal_conductivity_x_dT")),
66  _thermal_conductivity_y(isParamValid("thermal_conductivity_y") ||
67  isParamValid("thermal_conductivity_y_pp")
68  ? &declareProperty<Real>("thermal_conductivity_y")
69  : NULL),
71  _thermal_conductivity_y ? &declareProperty<Real>("thermal_conductivity_y_dT") : NULL),
72  _thermal_conductivity_z(isParamValid("thermal_conductivity_z") ||
73  isParamValid("thermal_conductivity_z_pp")
74  ? &declareProperty<Real>("thermal_conductivity_z")
75  : NULL),
77  _thermal_conductivity_z ? &declareProperty<Real>("thermal_conductivity_z_dT") : NULL),
78 
79  _specific_heat(declareProperty<Real>("specific_heat")),
81  getParam<FunctionName>("specific_heat_temperature_function") != ""
82  ? &getFunction("specific_heat_temperature_function")
83  : NULL)
84 {
85  bool k_x = isParamValid("thermal_conductivity_x") || (NULL != _thermal_conductivity_x_pp);
86  bool k_y = isParamValid("thermal_conductivity_y") || (NULL != _thermal_conductivity_y_pp);
87  bool k_z = isParamValid("thermal_conductivity_z") || (NULL != _thermal_conductivity_z_pp);
88 
89  if (!k_x || (_subproblem.mesh().dimension() > 1 && !k_y) ||
90  (_subproblem.mesh().dimension() > 2 && !k_z))
91  {
92  mooseError("Incomplete set of orthotropic thermal conductivity parameters");
93  }
95  {
96  mooseError("Must couple with temperature if using specific heat function");
97  }
98  if (isParamValid("specific_heat") && _specific_heat_temperature_function)
99  {
100  mooseError("Cannot define both specific heat and specific heat temperature function");
101  }
102 
103  k_x = isParamValid("thermal_conductivity_x") && (NULL != _thermal_conductivity_x_pp);
104  k_y = isParamValid("thermal_conductivity_y") && (NULL != _thermal_conductivity_y_pp);
105  k_z = isParamValid("thermal_conductivity_z") && (NULL != _thermal_conductivity_z_pp);
106  if (k_x || k_y || k_z)
107  {
108  mooseError("Cannot define thermal conductivity value and Postprocessor");
109  }
110 }
MaterialProperty< Real > *const _thermal_conductivity_x_dT
const PostprocessorValue *const _thermal_conductivity_z_pp
MaterialProperty< Real > *const _thermal_conductivity_z
MaterialProperty< Real > *const _thermal_conductivity_x
const PostprocessorValue *const _thermal_conductivity_y_pp
MaterialProperty< Real > & _specific_heat
MaterialProperty< Real > *const _thermal_conductivity_z_dT
const PostprocessorValue *const _thermal_conductivity_x_pp
MaterialProperty< Real > *const _thermal_conductivity_y
MaterialProperty< Real > *const _thermal_conductivity_y_dT

Member Function Documentation

void AnisoHeatConductionMaterial::computeProperties ( )
protectedvirtual

Definition at line 113 of file AnisoHeatConductionMaterial.C.

114 {
115  for (unsigned int qp(0); qp < _qrule->n_points(); ++qp)
116  {
117  (*_thermal_conductivity_x)[qp] =
119  (*_thermal_conductivity_x_dT)[qp] = 0;
121  {
122  (*_thermal_conductivity_y)[qp] =
124  (*_thermal_conductivity_y_dT)[qp] = 0;
125  }
127  {
128  (*_thermal_conductivity_z)[qp] =
130  (*_thermal_conductivity_z_dT)[qp] = 0;
131  }
132 
134  {
135  Point p;
137  }
138  else
139  {
141  }
142  }
143 }
const PostprocessorValue *const _thermal_conductivity_z_pp
MaterialProperty< Real > *const _thermal_conductivity_z
const PostprocessorValue *const _thermal_conductivity_y_pp
MaterialProperty< Real > & _specific_heat
const PostprocessorValue *const _thermal_conductivity_x_pp
MaterialProperty< Real > *const _thermal_conductivity_y

Member Data Documentation

const bool AnisoHeatConductionMaterial::_has_temp
protected

Definition at line 26 of file AnisoHeatConductionMaterial.h.

Referenced by AnisoHeatConductionMaterial().

const Real AnisoHeatConductionMaterial::_my_specific_heat
protected

Definition at line 35 of file AnisoHeatConductionMaterial.h.

Referenced by computeProperties().

const Real AnisoHeatConductionMaterial::_my_thermal_conductivity_x
protected

Definition at line 29 of file AnisoHeatConductionMaterial.h.

Referenced by computeProperties().

const Real AnisoHeatConductionMaterial::_my_thermal_conductivity_y
protected

Definition at line 30 of file AnisoHeatConductionMaterial.h.

Referenced by computeProperties().

const Real AnisoHeatConductionMaterial::_my_thermal_conductivity_z
protected

Definition at line 31 of file AnisoHeatConductionMaterial.h.

Referenced by computeProperties().

MaterialProperty<Real>& AnisoHeatConductionMaterial::_specific_heat
protected

Definition at line 44 of file AnisoHeatConductionMaterial.h.

Referenced by computeProperties().

Function* const AnisoHeatConductionMaterial::_specific_heat_temperature_function
protected

Definition at line 45 of file AnisoHeatConductionMaterial.h.

Referenced by AnisoHeatConductionMaterial(), and computeProperties().

const VariableValue& AnisoHeatConductionMaterial::_temperature
protected

Definition at line 27 of file AnisoHeatConductionMaterial.h.

Referenced by computeProperties().

MaterialProperty<Real>* const AnisoHeatConductionMaterial::_thermal_conductivity_x
protected

Definition at line 37 of file AnisoHeatConductionMaterial.h.

MaterialProperty<Real>* const AnisoHeatConductionMaterial::_thermal_conductivity_x_dT
protected

Definition at line 38 of file AnisoHeatConductionMaterial.h.

const PostprocessorValue* const AnisoHeatConductionMaterial::_thermal_conductivity_x_pp
protected

Definition at line 32 of file AnisoHeatConductionMaterial.h.

Referenced by AnisoHeatConductionMaterial(), and computeProperties().

MaterialProperty<Real>* const AnisoHeatConductionMaterial::_thermal_conductivity_y
protected

Definition at line 39 of file AnisoHeatConductionMaterial.h.

Referenced by computeProperties().

MaterialProperty<Real>* const AnisoHeatConductionMaterial::_thermal_conductivity_y_dT
protected

Definition at line 40 of file AnisoHeatConductionMaterial.h.

const PostprocessorValue* const AnisoHeatConductionMaterial::_thermal_conductivity_y_pp
protected

Definition at line 33 of file AnisoHeatConductionMaterial.h.

Referenced by AnisoHeatConductionMaterial(), and computeProperties().

MaterialProperty<Real>* const AnisoHeatConductionMaterial::_thermal_conductivity_z
protected

Definition at line 41 of file AnisoHeatConductionMaterial.h.

Referenced by computeProperties().

MaterialProperty<Real>* const AnisoHeatConductionMaterial::_thermal_conductivity_z_dT
protected

Definition at line 42 of file AnisoHeatConductionMaterial.h.

const PostprocessorValue* const AnisoHeatConductionMaterial::_thermal_conductivity_z_pp
protected

Definition at line 34 of file AnisoHeatConductionMaterial.h.

Referenced by AnisoHeatConductionMaterial(), and computeProperties().


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