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

StressBasedChemicalPotential computes chemical potential based on stress and a direction tensor Forest et. More...

#include <StressBasedChemicalPotential.h>

Inheritance diagram for StressBasedChemicalPotential:
[legend]

Public Member Functions

 StressBasedChemicalPotential (const InputParameters &parameters)
 

Protected Member Functions

virtual void initQpStatefulProperties ()
 
virtual void computeQpProperties ()
 

Protected Attributes

MaterialProperty< Real > & _chemical_potential
 
MaterialProperty< Real > * _dchemical_potential
 
const MaterialProperty< RankTwoTensor > & _stress_old
 
const MaterialProperty< RealTensorValue > & _direction_tensor
 
const MaterialProperty< Real > & _prefactor
 
const MaterialProperty< Real > * _dprefactor_dc
 
bool _has_coupled_c
 

Detailed Description

StressBasedChemicalPotential computes chemical potential based on stress and a direction tensor Forest et.

al. MSMSE 2015

Definition at line 27 of file StressBasedChemicalPotential.h.

Constructor & Destructor Documentation

◆ StressBasedChemicalPotential()

StressBasedChemicalPotential::StressBasedChemicalPotential ( const InputParameters &  parameters)

Definition at line 30 of file StressBasedChemicalPotential.C.

31  : DerivativeMaterialInterface<Material>(parameters),
32  _chemical_potential(declareProperty<Real>(getParam<MaterialPropertyName>("property_name"))),
33  _stress_old(getMaterialPropertyOld<RankTwoTensor>("stress_name")),
34  _direction_tensor(getMaterialProperty<RealTensorValue>("direction_tensor_name")),
35  _prefactor(getMaterialProperty<Real>("prefactor_name")),
36  _has_coupled_c(isCoupled("c"))
37 {
38  if (_has_coupled_c)
39  {
40  _dchemical_potential = &declarePropertyDerivative<Real>(
41  getParam<MaterialPropertyName>("property_name"), getVar("c", 0)->name());
42  _dprefactor_dc = &getMaterialPropertyDerivative<Real>("prefactor_name", getVar("c", 0)->name());
43  }
44 }
const MaterialProperty< Real > * _dprefactor_dc
MaterialProperty< Real > * _dchemical_potential
const MaterialProperty< RealTensorValue > & _direction_tensor
const MaterialProperty< RankTwoTensor > & _stress_old
MaterialProperty< Real > & _chemical_potential
const MaterialProperty< Real > & _prefactor

Member Function Documentation

◆ computeQpProperties()

void StressBasedChemicalPotential::computeQpProperties ( )
protectedvirtual

Definition at line 56 of file StressBasedChemicalPotential.C.

57 {
58  RankTwoTensor direction_tensor_rank_two = _direction_tensor[_qp];
59  _chemical_potential[_qp] =
60  -_stress_old[_qp].doubleContraction(direction_tensor_rank_two) * _prefactor[_qp];
61 
62  if (_has_coupled_c)
63  (*_dchemical_potential)[_qp] =
64  -_stress_old[_qp].doubleContraction(direction_tensor_rank_two) * (*_dprefactor_dc)[_qp];
65 }
const MaterialProperty< RealTensorValue > & _direction_tensor
const MaterialProperty< RankTwoTensor > & _stress_old
MaterialProperty< Real > & _chemical_potential
const MaterialProperty< Real > & _prefactor

◆ initQpStatefulProperties()

void StressBasedChemicalPotential::initQpStatefulProperties ( )
protectedvirtual

Definition at line 47 of file StressBasedChemicalPotential.C.

48 {
49  _chemical_potential[_qp] = 0.0;
50 
51  if (_has_coupled_c)
52  (*_dchemical_potential)[_qp] = 0.0;
53 }
MaterialProperty< Real > & _chemical_potential

Member Data Documentation

◆ _chemical_potential

MaterialProperty<Real>& StressBasedChemicalPotential::_chemical_potential
protected

Definition at line 36 of file StressBasedChemicalPotential.h.

Referenced by computeQpProperties(), and initQpStatefulProperties().

◆ _dchemical_potential

MaterialProperty<Real>* StressBasedChemicalPotential::_dchemical_potential
protected

Definition at line 37 of file StressBasedChemicalPotential.h.

Referenced by StressBasedChemicalPotential().

◆ _direction_tensor

const MaterialProperty<RealTensorValue>& StressBasedChemicalPotential::_direction_tensor
protected

Definition at line 40 of file StressBasedChemicalPotential.h.

Referenced by computeQpProperties().

◆ _dprefactor_dc

const MaterialProperty<Real>* StressBasedChemicalPotential::_dprefactor_dc
protected

Definition at line 42 of file StressBasedChemicalPotential.h.

Referenced by StressBasedChemicalPotential().

◆ _has_coupled_c

bool StressBasedChemicalPotential::_has_coupled_c
protected

◆ _prefactor

const MaterialProperty<Real>& StressBasedChemicalPotential::_prefactor
protected

Definition at line 41 of file StressBasedChemicalPotential.h.

Referenced by computeQpProperties().

◆ _stress_old

const MaterialProperty<RankTwoTensor>& StressBasedChemicalPotential::_stress_old
protected

Definition at line 39 of file StressBasedChemicalPotential.h.

Referenced by computeQpProperties().


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