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

Base class Material designed to provide the tortuosity and diffusion coefficents. More...

#include <PorousFlowDiffusivityBase.h>

Inheritance diagram for PorousFlowDiffusivityBase:
[legend]

Public Member Functions

 PorousFlowDiffusivityBase (const InputParameters &parameters)
 

Protected Member Functions

virtual void computeQpProperties () override
 

Protected Attributes

MaterialProperty< std::vector< Real > > & _tortuosity
 Tortuosity tau_0 * tau_{alpha} for fluid phase alpha. More...
 
MaterialProperty< std::vector< std::vector< Real > > > & _dtortuosity_dvar
 Derivative of tortuosity wrt PorousFlow variables. More...
 
MaterialProperty< std::vector< std::vector< Real > > > & _diffusion_coeff
 Diffusion coefficients of component k in fluid phase alpha. More...
 
MaterialProperty< std::vector< std::vector< std::vector< Real > > > > & _ddiffusion_coeff_dvar
 Derivative of the diffusion coefficients wrt PorousFlow variables. More...
 
const std::vector< Real > _input_diffusion_coeff
 Input diffusion coefficients. More...
 
const unsigned int _num_phases
 Number of phases. More...
 
const unsigned int _num_components
 Number of fluid components. More...
 
const unsigned int _num_var
 Number of PorousFlow variables. More...
 

Detailed Description

Base class Material designed to provide the tortuosity and diffusion coefficents.

Definition at line 19 of file PorousFlowDiffusivityBase.h.

Constructor & Destructor Documentation

PorousFlowDiffusivityBase::PorousFlowDiffusivityBase ( const InputParameters &  parameters)

Definition at line 25 of file PorousFlowDiffusivityBase.C.

26  : PorousFlowMaterialVectorBase(parameters),
27 
28  _tortuosity(declareProperty<std::vector<Real>>("PorousFlow_tortuosity_qp")),
30  declareProperty<std::vector<std::vector<Real>>>("dPorousFlow_tortuosity_qp_dvar")),
32  declareProperty<std::vector<std::vector<Real>>>("PorousFlow_diffusion_coeff_qp")),
33  _ddiffusion_coeff_dvar(declareProperty<std::vector<std::vector<std::vector<Real>>>>(
34  "dPorousFlow_diffusion_coeff_qp_dvar")),
35  _input_diffusion_coeff(getParam<std::vector<Real>>("diffusion_coeff"))
36 {
37  // Also, the number of diffusion coefficients must be equal to the num_phases * num_components
39  mooseError("The number of diffusion coefficients entered is not equal to the number of phases "
40  "multiplied by the number of fluid components");
41  if (_nodal_material == true)
42  mooseError("PorousFlowRelativeDiffusivity classes are only defined for at_nodes = false");
43 }
const unsigned int _num_phases
Number of phases.
const unsigned int _num_components
Number of fluid components.
MaterialProperty< std::vector< std::vector< Real > > > & _diffusion_coeff
Diffusion coefficients of component k in fluid phase alpha.
PorousFlowMaterialVectorBase(const InputParameters &parameters)
MaterialProperty< std::vector< std::vector< std::vector< Real > > > > & _ddiffusion_coeff_dvar
Derivative of the diffusion coefficients wrt PorousFlow variables.
MaterialProperty< std::vector< std::vector< Real > > > & _dtortuosity_dvar
Derivative of tortuosity wrt PorousFlow variables.
MaterialProperty< std::vector< Real > > & _tortuosity
Tortuosity tau_0 * tau_{alpha} for fluid phase alpha.
const std::vector< Real > _input_diffusion_coeff
Input diffusion coefficients.

Member Function Documentation

void PorousFlowDiffusivityBase::computeQpProperties ( )
overrideprotectedvirtual

Reimplemented in PorousFlowDiffusivityMillingtonQuirk, and PorousFlowDiffusivityConst.

Definition at line 46 of file PorousFlowDiffusivityBase.C.

Referenced by PorousFlowDiffusivityConst::computeQpProperties(), and PorousFlowDiffusivityMillingtonQuirk::computeQpProperties().

47 {
48  _diffusion_coeff[_qp].resize(_num_phases);
50  _dtortuosity_dvar[_qp].resize(_num_phases);
51 
52  for (unsigned int ph = 0; ph < _num_phases; ++ph)
53  {
54  _diffusion_coeff[_qp][ph].resize(_num_components);
55  _ddiffusion_coeff_dvar[_qp][ph].resize(_num_components);
56  _dtortuosity_dvar[_qp][ph].assign(_num_var, 0.0);
57 
58  for (unsigned int comp = 0; comp < _num_components; ++comp)
59  {
60  _diffusion_coeff[_qp][ph][comp] = _input_diffusion_coeff[ph + comp];
61  _ddiffusion_coeff_dvar[_qp][ph][comp].assign(_num_var, 0.0);
62  }
63  }
64 }
const unsigned int _num_phases
Number of phases.
const unsigned int _num_components
Number of fluid components.
MaterialProperty< std::vector< std::vector< Real > > > & _diffusion_coeff
Diffusion coefficients of component k in fluid phase alpha.
const unsigned int _num_var
Number of PorousFlow variables.
MaterialProperty< std::vector< std::vector< std::vector< Real > > > > & _ddiffusion_coeff_dvar
Derivative of the diffusion coefficients wrt PorousFlow variables.
MaterialProperty< std::vector< std::vector< Real > > > & _dtortuosity_dvar
Derivative of tortuosity wrt PorousFlow variables.
const std::vector< Real > _input_diffusion_coeff
Input diffusion coefficients.

Member Data Documentation

MaterialProperty<std::vector<std::vector<std::vector<Real> > > >& PorousFlowDiffusivityBase::_ddiffusion_coeff_dvar
protected

Derivative of the diffusion coefficients wrt PorousFlow variables.

Definition at line 37 of file PorousFlowDiffusivityBase.h.

Referenced by computeQpProperties().

MaterialProperty<std::vector<std::vector<Real> > >& PorousFlowDiffusivityBase::_diffusion_coeff
protected

Diffusion coefficients of component k in fluid phase alpha.

Definition at line 34 of file PorousFlowDiffusivityBase.h.

Referenced by computeQpProperties().

MaterialProperty<std::vector<std::vector<Real> > >& PorousFlowDiffusivityBase::_dtortuosity_dvar
protected

Derivative of tortuosity wrt PorousFlow variables.

Definition at line 31 of file PorousFlowDiffusivityBase.h.

Referenced by computeQpProperties(), and PorousFlowDiffusivityMillingtonQuirk::computeQpProperties().

const std::vector<Real> PorousFlowDiffusivityBase::_input_diffusion_coeff
protected

Input diffusion coefficients.

Definition at line 40 of file PorousFlowDiffusivityBase.h.

Referenced by computeQpProperties(), and PorousFlowDiffusivityBase().

const unsigned int PorousFlowMaterialVectorBase::_num_components
protectedinherited
const unsigned int PorousFlowMaterialVectorBase::_num_phases
protectedinherited
const unsigned int PorousFlowMaterialVectorBase::_num_var
protectedinherited
MaterialProperty<std::vector<Real> >& PorousFlowDiffusivityBase::_tortuosity
protected

Tortuosity tau_0 * tau_{alpha} for fluid phase alpha.

Definition at line 28 of file PorousFlowDiffusivityBase.h.

Referenced by PorousFlowDiffusivityConst::computeQpProperties(), and PorousFlowDiffusivityMillingtonQuirk::computeQpProperties().


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