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

The couple, SplitCHMath and SplitCHWRes, splits the CH equation by replacing chemical potential with 'w'. More...

#include <SplitCHMath.h>

Inheritance diagram for SplitCHMath:
[legend]

Public Member Functions

 SplitCHMath (const InputParameters &parameters)
 

Protected Types

enum  PFFunctionType { Jacobian, Residual }
 

Protected Member Functions

virtual Real computeDFDC (PFFunctionType type)
 
virtual Real computeQpResidual ()
 
virtual Real computeQpJacobian ()
 
virtual Real computeQpOffDiagJacobian (unsigned int jvar)
 
virtual Real computeDEDC (PFFunctionType type)
 

Protected Attributes

const MaterialProperty< Real > & _kappa
 
unsigned int _w_var
 
const VariableValue & _w
 

Detailed Description

The couple, SplitCHMath and SplitCHWRes, splits the CH equation by replacing chemical potential with 'w'.

Definition at line 22 of file SplitCHMath.h.

Member Enumeration Documentation

◆ PFFunctionType

enum SplitCHBase::PFFunctionType
protectedinherited
Enumerator
Jacobian 
Residual 

Definition at line 28 of file SplitCHBase.h.

Constructor & Destructor Documentation

◆ SplitCHMath()

SplitCHMath::SplitCHMath ( const InputParameters &  parameters)

Definition at line 24 of file SplitCHMath.C.

24 : SplitCHCRes(parameters) {}
SplitCHCRes(const InputParameters &parameters)
Definition: SplitCHCRes.C:23

Member Function Documentation

◆ computeDEDC()

Real SplitCHBase::computeDEDC ( PFFunctionType  type)
protectedvirtualinherited

Definition at line 69 of file SplitCHBase.C.

Referenced by SplitCHBase::computeQpJacobian(), and SplitCHBase::computeQpResidual().

69 { return 0.0; }

◆ computeDFDC()

Real SplitCHMath::computeDFDC ( PFFunctionType  type)
protectedvirtual

Reimplemented from SplitCHBase.

Definition at line 27 of file SplitCHMath.C.

28 {
29  switch (type)
30  {
31  case Residual:
32  return _u[_qp] * _u[_qp] * _u[_qp] - _u[_qp]; // return Residual value
33 
34  case Jacobian:
35  return (3.0 * _u[_qp] * _u[_qp] - 1.0) * _phi[_j][_qp]; // return Jacobian value
36  }
37 
38  mooseError("Invalid type passed in");
39 }

◆ computeQpJacobian()

Real SplitCHCRes::computeQpJacobian ( )
protectedvirtualinherited

Reimplemented from SplitCHBase.

Definition at line 60 of file SplitCHCRes.C.

61 {
62  Real jacobian = SplitCHBase::computeQpJacobian(); //(df_prime_zero_dc+de_prime_dc)*_test[_i][_qp];
63  // from SplitCHBase
64 
65  jacobian += _kappa[_qp] * _grad_phi[_j][_qp] * _grad_test[_i][_qp];
66 
67  return jacobian;
68 }
const MaterialProperty< Real > & _kappa
Definition: SplitCHCRes.h:32
virtual Real computeQpJacobian()
Definition: SplitCHBase.C:51

◆ computeQpOffDiagJacobian()

Real SplitCHCRes::computeQpOffDiagJacobian ( unsigned int  jvar)
protectedvirtualinherited

Reimplemented from SplitCHBase.

Definition at line 71 of file SplitCHCRes.C.

Referenced by SplitCHParsed::computeQpOffDiagJacobian().

72 {
73  if (jvar == _w_var)
74  {
75  return -_phi[_j][_qp] * _test[_i][_qp];
76  }
77 
78  return 0.0;
79 }
unsigned int _w_var
Definition: SplitCHCRes.h:33

◆ computeQpResidual()

Real SplitCHCRes::computeQpResidual ( )
protectedvirtualinherited

Reimplemented from SplitCHBase.

Definition at line 48 of file SplitCHCRes.C.

49 {
50  Real residual =
51  SplitCHBase::computeQpResidual(); //(f_prime_zero+e_prime)*_test[_i][_qp] from SplitCHBase
52 
53  residual += -_w[_qp] * _test[_i][_qp];
54  residual += _kappa[_qp] * _grad_u[_qp] * _grad_test[_i][_qp];
55 
56  return residual;
57 }
virtual Real computeQpResidual()
Definition: SplitCHBase.C:40
const MaterialProperty< Real > & _kappa
Definition: SplitCHCRes.h:32
const VariableValue & _w
Definition: SplitCHCRes.h:34

Member Data Documentation

◆ _kappa

const MaterialProperty<Real>& SplitCHCRes::_kappa
protectedinherited

Definition at line 32 of file SplitCHCRes.h.

Referenced by SplitCHCRes::computeQpJacobian(), and SplitCHCRes::computeQpResidual().

◆ _w

const VariableValue& SplitCHCRes::_w
protectedinherited

Definition at line 34 of file SplitCHCRes.h.

Referenced by SplitCHCRes::computeQpResidual().

◆ _w_var

unsigned int SplitCHCRes::_w_var
protectedinherited

Definition at line 33 of file SplitCHCRes.h.

Referenced by SplitCHCRes::computeQpOffDiagJacobian().


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