https://mooseframework.inl.gov
Public Types | Public Member Functions | Static Public Member Functions | Protected Attributes | List of all members
CoupledSwitchingTimeDerivativeTempl< is_ad > Class Template Reference

#include <CoupledSwitchingTimeDerivative.h>

Inheritance diagram for CoupledSwitchingTimeDerivativeTempl< is_ad >:
[legend]

Public Types

typedef DerivativeMaterialPropertyNameInterface::SymbolName SymbolName
 

Public Member Functions

 CoupledSwitchingTimeDerivativeTempl (const InputParameters &parameters)
 
virtual void initialSetup () override
 
const GenericMaterialProperty< U, is_ad > & getDefaultMaterialProperty (const std::string &name)
 
const GenericMaterialProperty< U, is_ad > & getDefaultMaterialPropertyByName (const std::string &name)
 
void validateDerivativeMaterialPropertyBase (const std::string &base)
 
const MaterialPropertyName derivativePropertyName (const MaterialPropertyName &base, const std::vector< SymbolName > &c) const
 
const MaterialPropertyName derivativePropertyNameFirst (const MaterialPropertyName &base, const SymbolName &c1) const
 
const MaterialPropertyName derivativePropertyNameSecond (const MaterialPropertyName &base, const SymbolName &c1, const SymbolName &c2) const
 
const MaterialPropertyName derivativePropertyNameThird (const MaterialPropertyName &base, const SymbolName &c1, const SymbolName &c2, const SymbolName &c3) const
 
GenericMaterialProperty< U, is_ad > & declarePropertyDerivative (const std::string &base, const std::vector< VariableName > &c)
 
GenericMaterialProperty< U, is_ad > & declarePropertyDerivative (const std::string &base, const std::vector< SymbolName > &c)
 
GenericMaterialProperty< U, is_ad > & declarePropertyDerivative (const std::string &base, const SymbolName &c1, const SymbolName &c2="", const SymbolName &c3="")
 
GenericMaterialProperty< U, is_ad > & declarePropertyDerivative (const std::string &base, const std::vector< VariableName > &c)
 
GenericMaterialProperty< U, is_ad > & declarePropertyDerivative (const std::string &base, const std::vector< SymbolName > &c)
 
GenericMaterialProperty< U, is_ad > & declarePropertyDerivative (const std::string &base, const SymbolName &c1, const SymbolName &c2="", const SymbolName &c3="")
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivative (const std::string &base, const std::vector< VariableName > &c)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivative (const std::string &base, const std::vector< SymbolName > &c)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivative (const std::string &base, const SymbolName &c1, const SymbolName &c2="", const SymbolName &c3="")
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivative (const std::string &base, const SymbolName &c1, unsigned int v2, unsigned int v3=libMesh::invalid_uint)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivative (const std::string &base, unsigned int v1, unsigned int v2=libMesh::invalid_uint, unsigned int v3=libMesh::invalid_uint)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivative (const std::string &base, const std::vector< VariableName > &c)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivative (const std::string &base, const std::vector< SymbolName > &c)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivative (const std::string &base, const SymbolName &c1, const SymbolName &c2="", const SymbolName &c3="")
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivative (const std::string &base, const SymbolName &c1, unsigned int v2, unsigned int v3=libMesh::invalid_uint)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivative (const std::string &base, unsigned int v1, unsigned int v2=libMesh::invalid_uint, unsigned int v3=libMesh::invalid_uint)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivativeByName (const MaterialPropertyName &base, const std::vector< VariableName > &c)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivativeByName (const MaterialPropertyName &base, const std::vector< SymbolName > &c)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivativeByName (const MaterialPropertyName &base, const SymbolName &c1, const SymbolName &c2="", const SymbolName &c3="")
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivativeByName (const MaterialPropertyName &base, const std::vector< VariableName > &c)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivativeByName (const MaterialPropertyName &base, const std::vector< SymbolName > &c)
 
const GenericMaterialProperty< U, is_ad > & getMaterialPropertyDerivativeByName (const MaterialPropertyName &base, const SymbolName &c1, const SymbolName &c2="", const SymbolName &c3="")
 
void validateCoupling (const MaterialPropertyName &base, const std::vector< VariableName > &c, bool validate_aux=true)
 
void validateCoupling (const MaterialPropertyName &base, const VariableName &c1="", const VariableName &c2="", const VariableName &c3="")
 
void validateCoupling (const MaterialPropertyName &base, const std::vector< VariableName > &c, bool validate_aux=true)
 
void validateCoupling (const MaterialPropertyName &base, const VariableName &c1="", const VariableName &c2="", const VariableName &c3="")
 
void validateNonlinearCoupling (const MaterialPropertyName &base, const VariableName &c1="", const VariableName &c2="", const VariableName &c3="")
 
void validateNonlinearCoupling (const MaterialPropertyName &base, const VariableName &c1="", const VariableName &c2="", const VariableName &c3="")
 
const MaterialPropertyName propertyName (const MaterialPropertyName &base, const std::vector< SymbolName > &c) const
 
const MaterialPropertyName propertyName (const MaterialPropertyName &base, const std::vector< SymbolName > &c) const
 
const MaterialPropertyName propertyNameFirst (const MaterialPropertyName &base, const SymbolName &c1) const
 
const MaterialPropertyName propertyNameFirst (const MaterialPropertyName &base, const SymbolName &c1) const
 
const MaterialPropertyName propertyNameSecond (const MaterialPropertyName &base, const SymbolName &c1, const SymbolName &c2) const
 
const MaterialPropertyName propertyNameSecond (const MaterialPropertyName &base, const SymbolName &c1, const SymbolName &c2) const
 
const MaterialPropertyName propertyNameThird (const MaterialPropertyName &base, const SymbolName &c1, const SymbolName &c2, const SymbolName &c3) const
 
const MaterialPropertyName propertyNameThird (const MaterialPropertyName &base, const SymbolName &c1, const SymbolName &c2, const SymbolName &c3) const
 

Static Public Member Functions

static InputParameters validParams ()
 

Protected Attributes

const VariableName _v_name
 name of order parameter that derivatives are taken wrt (needed to retrieve the derivative material properties) More...
 
std::vector< MaterialPropertyName > _Fj_names
 Names of functions for each phase \( F_j \). More...
 
const unsigned int _num_j
 Number of phases. More...
 
std::vector< const GenericMaterialProperty< Real, is_ad > * > _prop_Fj
 Values of the functions for each phase \( F_j \). More...
 
std::vector< MaterialPropertyName > _hj_names
 switching function names More...
 
std::vector< const GenericMaterialProperty< Real, is_ad > * > _prop_dhjdetai
 Derivatives of the switching functions wrt the order parameter for this kernel. More...
 

Detailed Description

template<bool is_ad>
class CoupledSwitchingTimeDerivativeTempl< is_ad >

Definition at line 35 of file CoupledSwitchingTimeDerivative.h.

Constructor & Destructor Documentation

◆ CoupledSwitchingTimeDerivativeTempl()

template<bool is_ad>
CoupledSwitchingTimeDerivativeTempl< is_ad >::CoupledSwitchingTimeDerivativeTempl ( const InputParameters parameters)

Definition at line 32 of file CoupledSwitchingTimeDerivative.C.

35  parameters),
36  _v_name(this->coupledName("v", 0)),
37  _Fj_names(this->template getParam<std::vector<MaterialPropertyName>>("Fj_names")),
38  _num_j(_Fj_names.size()),
40  _hj_names(this->template getParam<std::vector<MaterialPropertyName>>("hj_names")),
42 {
43  // check passed in parameter vectors
44  if (_num_j != _hj_names.size())
45  this->paramError("hj_names", "Need to pass in as many hj_names as Fj_names");
46 
47  // reserve space and set phase material properties
48  for (unsigned int n = 0; n < _num_j; ++n)
49  {
50  // get phase free energy
51  _prop_Fj[n] = &this->template getGenericMaterialProperty<Real, is_ad>(_Fj_names[n]);
52 
53  // get switching function derivatives wrt eta_i, the nonlinear variable
54  _prop_dhjdetai[n] =
55  &this->template getMaterialPropertyDerivative<Real, is_ad>(_hj_names[n], _v_name);
56  }
57 }
std::vector< MaterialPropertyName > _hj_names
switching function names
std::vector< MaterialPropertyName > _Fj_names
Names of functions for each phase .
std::vector< const GenericMaterialProperty< Real, is_ad > * > _prop_dhjdetai
Derivatives of the switching functions wrt the order parameter for this kernel.
std::vector< const GenericMaterialProperty< Real, is_ad > * > _prop_Fj
Values of the functions for each phase .
const unsigned int _num_j
Number of phases.
const VariableName _v_name
name of order parameter that derivatives are taken wrt (needed to retrieve the derivative material pr...

Member Function Documentation

◆ initialSetup()

template<bool is_ad>
void CoupledSwitchingTimeDerivativeTempl< is_ad >::initialSetup ( )
overridevirtual

Reimplemented in CoupledSwitchingTimeDerivative.

Definition at line 90 of file CoupledSwitchingTimeDerivative.C.

Referenced by CoupledSwitchingTimeDerivative::initialSetup().

91 {
92  for (unsigned int n = 0; n < _num_j; ++n)
94 }
Moose::GenericType< Real, is_ad > GenericReal
void validateNonlinearCoupling(const MaterialPropertyName &base, const VariableName &c1="", const VariableName &c2="", const VariableName &c3="")
std::vector< MaterialPropertyName > _hj_names
switching function names
const unsigned int _num_j
Number of phases.

◆ validParams()

template<bool is_ad>
InputParameters CoupledSwitchingTimeDerivativeTempl< is_ad >::validParams ( )
static

Definition at line 17 of file CoupledSwitchingTimeDerivative.C.

18 {
20  params.addClassDescription(
21  "Coupled time derivative Kernel that multiplies the time derivative by "
22  "$\\frac{dh_\\alpha}{d\\eta_i} F_\\alpha + \\frac{dh_\\beta}{d\\eta_i} F_\\beta + \\dots$");
23  params.addRequiredParam<std::vector<MaterialPropertyName>>(
24  "Fj_names", "List of functions for each phase. Place in same order as hj_names!");
25  params.addRequiredParam<std::vector<MaterialPropertyName>>(
26  "hj_names", "Switching Function Materials that provide h. Place in same order as Fj_names!");
27  params.addCoupledVar("args", "Vector of variable arguments of Fj and hj");
28  params.deprecateCoupledVar("args", "coupled_variables", "02/27/2024");
29  return params;
30 }
void addRequiredParam(const std::string &name, const std::string &doc_string)
InputParameters validParams()
void deprecateCoupledVar(const std::string &old_name, const std::string &new_name, const std::string &removal_date)
void addCoupledVar(const std::string &name, const std::string &doc_string)
void addClassDescription(const std::string &doc_string)

Member Data Documentation

◆ _Fj_names

template<bool is_ad>
std::vector<MaterialPropertyName> CoupledSwitchingTimeDerivativeTempl< is_ad >::_Fj_names
protected

Names of functions for each phase \( F_j \).

Definition at line 51 of file CoupledSwitchingTimeDerivative.h.

Referenced by CoupledSwitchingTimeDerivativeTempl< true >::CoupledSwitchingTimeDerivativeTempl().

◆ _hj_names

template<bool is_ad>
std::vector<MaterialPropertyName> CoupledSwitchingTimeDerivativeTempl< is_ad >::_hj_names
protected

◆ _num_j

template<bool is_ad>
const unsigned int CoupledSwitchingTimeDerivativeTempl< is_ad >::_num_j
protected

◆ _prop_dhjdetai

template<bool is_ad>
std::vector<const GenericMaterialProperty<Real, is_ad> *> CoupledSwitchingTimeDerivativeTempl< is_ad >::_prop_dhjdetai
protected

Derivatives of the switching functions wrt the order parameter for this kernel.

Definition at line 63 of file CoupledSwitchingTimeDerivative.h.

Referenced by CoupledSwitchingTimeDerivativeTempl< true >::CoupledSwitchingTimeDerivativeTempl().

◆ _prop_Fj

template<bool is_ad>
std::vector<const GenericMaterialProperty<Real, is_ad> *> CoupledSwitchingTimeDerivativeTempl< is_ad >::_prop_Fj
protected

Values of the functions for each phase \( F_j \).

Definition at line 57 of file CoupledSwitchingTimeDerivative.h.

Referenced by CoupledSwitchingTimeDerivativeTempl< true >::CoupledSwitchingTimeDerivativeTempl().

◆ _v_name

template<bool is_ad>
const VariableName CoupledSwitchingTimeDerivativeTempl< is_ad >::_v_name
protected

name of order parameter that derivatives are taken wrt (needed to retrieve the derivative material properties)

Definition at line 48 of file CoupledSwitchingTimeDerivative.h.

Referenced by CoupledSwitchingTimeDerivativeTempl< true >::CoupledSwitchingTimeDerivativeTempl().


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