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

Define the Kernel for a PrimaryConvection operator that looks like: cond * grad_pressure * grad_u. More...

#include <PrimaryConvection.h>

Inheritance diagram for PrimaryConvection:
[legend]

Public Member Functions

 PrimaryConvection (const InputParameters &parameters)
 

Protected Member Functions

virtual Real computeQpResidual () override
 
virtual Real computeQpJacobian () override
 
virtual Real computeQpOffDiagJacobian (unsigned int jvar) override
 

Protected Attributes

const MaterialProperty< Real > & _cond
 Hydraulic conductivity. More...
 
const RealVectorValue _gravity
 Gravity. More...
 
const MaterialProperty< Real > & _density
 Fluid density. More...
 
const VariableGradient & _grad_p
 Pressure gradient. More...
 
const unsigned int _pvar
 Pressure variable number. More...
 

Detailed Description

Define the Kernel for a PrimaryConvection operator that looks like: cond * grad_pressure * grad_u.

Definition at line 23 of file PrimaryConvection.h.

Constructor & Destructor Documentation

PrimaryConvection::PrimaryConvection ( const InputParameters &  parameters)

Definition at line 21 of file PrimaryConvection.C.

22  : DerivativeMaterialInterface<Kernel>(parameters),
23  _cond(getMaterialProperty<Real>("conductivity")),
24  _gravity(getParam<RealVectorValue>("gravity")),
25  _density(getDefaultMaterialProperty<Real>("density")),
26  _grad_p(coupledGradient("p")),
27  _pvar(coupled("p"))
28 
29 {
30 }
const VariableGradient & _grad_p
Pressure gradient.
const RealVectorValue _gravity
Gravity.
const MaterialProperty< Real > & _cond
Hydraulic conductivity.
const unsigned int _pvar
Pressure variable number.
const MaterialProperty< Real > & _density
Fluid density.

Member Function Documentation

Real PrimaryConvection::computeQpJacobian ( )
overrideprotectedvirtual

Definition at line 41 of file PrimaryConvection.C.

42 {
43  RealVectorValue darcy_vel = -_cond[_qp] * (_grad_p[_qp] - _density[_qp] * _gravity);
44 
45  return _test[_i][_qp] * (darcy_vel * _grad_phi[_j][_qp]);
46 }
const VariableGradient & _grad_p
Pressure gradient.
const RealVectorValue _gravity
Gravity.
const MaterialProperty< Real > & _cond
Hydraulic conductivity.
const MaterialProperty< Real > & _density
Fluid density.
Real PrimaryConvection::computeQpOffDiagJacobian ( unsigned int  jvar)
overrideprotectedvirtual

Definition at line 49 of file PrimaryConvection.C.

50 {
51  if (jvar == _pvar)
52  {
53  RealVectorValue ddarcy_vel_dp = -_cond[_qp] * _grad_phi[_j][_qp];
54  return _test[_i][_qp] * (ddarcy_vel_dp * _grad_u[_qp]);
55  }
56  else
57  return 0.0;
58 }
const MaterialProperty< Real > & _cond
Hydraulic conductivity.
const unsigned int _pvar
Pressure variable number.
Real PrimaryConvection::computeQpResidual ( )
overrideprotectedvirtual

Definition at line 33 of file PrimaryConvection.C.

34 {
35  RealVectorValue darcy_vel = -_cond[_qp] * (_grad_p[_qp] - _density[_qp] * _gravity);
36 
37  return _test[_i][_qp] * (darcy_vel * _grad_u[_qp]);
38 }
const VariableGradient & _grad_p
Pressure gradient.
const RealVectorValue _gravity
Gravity.
const MaterialProperty< Real > & _cond
Hydraulic conductivity.
const MaterialProperty< Real > & _density
Fluid density.

Member Data Documentation

const MaterialProperty<Real>& PrimaryConvection::_cond
protected

Hydraulic conductivity.

Definition at line 34 of file PrimaryConvection.h.

Referenced by computeQpJacobian(), computeQpOffDiagJacobian(), and computeQpResidual().

const MaterialProperty<Real>& PrimaryConvection::_density
protected

Fluid density.

Definition at line 40 of file PrimaryConvection.h.

Referenced by computeQpJacobian(), and computeQpResidual().

const VariableGradient& PrimaryConvection::_grad_p
protected

Pressure gradient.

Definition at line 43 of file PrimaryConvection.h.

Referenced by computeQpJacobian(), and computeQpResidual().

const RealVectorValue PrimaryConvection::_gravity
protected

Gravity.

Definition at line 37 of file PrimaryConvection.h.

Referenced by computeQpJacobian(), and computeQpResidual().

const unsigned int PrimaryConvection::_pvar
protected

Pressure variable number.

Definition at line 46 of file PrimaryConvection.h.

Referenced by computeQpOffDiagJacobian().


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