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

This calculates the time derivative for a variable multiplied by a generalized susceptibility. More...

#include <SusceptibilityTimeDerivative.h>

Inheritance diagram for SusceptibilityTimeDerivative:
[legend]

Public Member Functions

 SusceptibilityTimeDerivative (const InputParameters &parameters)
 
virtual void initialSetup ()
 

Protected Member Functions

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

Protected Attributes

const MaterialProperty< Real > & _Chi
 susceptibility More...
 
const MaterialProperty< Real > & _dChidu
 susceptibility derivative w.r.t. the kernel variable More...
 
std::vector< const MaterialProperty< Real > * > _dChidarg
 susceptibility derivatives w.r.t. coupled variables More...
 

Detailed Description

This calculates the time derivative for a variable multiplied by a generalized susceptibility.

Definition at line 21 of file SusceptibilityTimeDerivative.h.

Constructor & Destructor Documentation

SusceptibilityTimeDerivative::SusceptibilityTimeDerivative ( const InputParameters &  parameters)

Definition at line 23 of file SusceptibilityTimeDerivative.C.

24  : DerivativeMaterialInterface<JvarMapKernelInterface<TimeDerivative>>(parameters),
25  _Chi(getMaterialProperty<Real>("f_name")),
26  _dChidu(getMaterialPropertyDerivative<Real>("f_name", _var.name())),
27  _dChidarg(_coupled_moose_vars.size())
28 {
29  // fetch derivatives
30  for (unsigned int i = 0; i < _dChidarg.size(); ++i)
31  _dChidarg[i] = &getMaterialPropertyDerivative<Real>("f_name", _coupled_moose_vars[i]->name());
32 }
std::vector< const MaterialProperty< Real > * > _dChidarg
susceptibility derivatives w.r.t. coupled variables
const MaterialProperty< Real > & _Chi
susceptibility
const MaterialProperty< Real > & _dChidu
susceptibility derivative w.r.t. the kernel variable

Member Function Documentation

Real SusceptibilityTimeDerivative::computeQpJacobian ( )
protectedvirtual

Definition at line 47 of file SusceptibilityTimeDerivative.C.

48 {
49  return TimeDerivative::computeQpJacobian() * _Chi[_qp] +
50  TimeDerivative::computeQpResidual() * _dChidu[_qp] * _phi[_j][_qp];
51 }
const MaterialProperty< Real > & _Chi
susceptibility
const MaterialProperty< Real > & _dChidu
susceptibility derivative w.r.t. the kernel variable
Real SusceptibilityTimeDerivative::computeQpOffDiagJacobian ( unsigned int  jvar)
protectedvirtual

Definition at line 54 of file SusceptibilityTimeDerivative.C.

55 {
56  // get the coupled variable jvar is referring to
57  const unsigned int cvar = mapJvarToCvar(jvar);
58 
59  return TimeDerivative::computeQpResidual() * (*_dChidarg[cvar])[_qp] * _phi[_j][_qp];
60 }
std::vector< const MaterialProperty< Real > * > _dChidarg
susceptibility derivatives w.r.t. coupled variables
Real SusceptibilityTimeDerivative::computeQpResidual ( )
protectedvirtual

Definition at line 41 of file SusceptibilityTimeDerivative.C.

42 {
43  return TimeDerivative::computeQpResidual() * _Chi[_qp];
44 }
const MaterialProperty< Real > & _Chi
susceptibility
void SusceptibilityTimeDerivative::initialSetup ( )
virtual

Definition at line 35 of file SusceptibilityTimeDerivative.C.

36 {
37  validateNonlinearCoupling<Real>("f_name");
38 }

Member Data Documentation

const MaterialProperty<Real>& SusceptibilityTimeDerivative::_Chi
protected

susceptibility

Definition at line 34 of file SusceptibilityTimeDerivative.h.

Referenced by computeQpJacobian(), and computeQpResidual().

std::vector<const MaterialProperty<Real> *> SusceptibilityTimeDerivative::_dChidarg
protected

susceptibility derivatives w.r.t. coupled variables

Definition at line 40 of file SusceptibilityTimeDerivative.h.

Referenced by computeQpOffDiagJacobian(), and SusceptibilityTimeDerivative().

const MaterialProperty<Real>& SusceptibilityTimeDerivative::_dChidu
protected

susceptibility derivative w.r.t. the kernel variable

Definition at line 37 of file SusceptibilityTimeDerivative.h.

Referenced by computeQpJacobian().


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