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

ComputeVariableEigenstrain computes an Eigenstrain that is a function of variables defined by a base tensor and a scalar function defined in a Derivative Material. More...

#include <ComputeVariableEigenstrain.h>

Inheritance diagram for ComputeVariableEigenstrain:
[legend]

Public Member Functions

 ComputeVariableEigenstrain (const InputParameters &parameters)
 

Protected Member Functions

virtual void computeQpEigenstrain ()
 

Protected Attributes

const unsigned int _num_args
 number of variables the prefactor depends on More...
 
std::vector< const MaterialProperty< Real > * > _dprefactor
 first derivatives of the prefactor w.r.t. to the args More...
 
std::vector< std::vector< const MaterialProperty< Real > * > > _d2prefactor
 second derivatives of the prefactor w.r.t. to the args More...
 
std::vector< MaterialProperty< RankTwoTensor > * > _delastic_strain
 first derivatives of the elastic strain w.r.t. to the args More...
 
std::vector< std::vector< MaterialProperty< RankTwoTensor > * > > _d2elastic_strain
 second derivatives of the elastic strain w.r.t. to the args More...
 

Detailed Description

ComputeVariableEigenstrain computes an Eigenstrain that is a function of variables defined by a base tensor and a scalar function defined in a Derivative Material.

Definition at line 25 of file ComputeVariableEigenstrain.h.

Constructor & Destructor Documentation

◆ ComputeVariableEigenstrain()

ComputeVariableEigenstrain::ComputeVariableEigenstrain ( const InputParameters &  parameters)

Definition at line 26 of file ComputeVariableEigenstrain.C.

27  : DerivativeMaterialInterface<ComputeEigenstrain>(parameters),
28  _num_args(coupledComponents("args")),
33 {
34  // fetch prerequisite derivatives and build elastic_strain derivatives and cross-derivatives
35  for (unsigned int i = 0; i < _num_args; ++i)
36  {
37  const VariableName & iname = getVar("args", i)->name();
38  _dprefactor[i] = &getMaterialPropertyDerivative<Real>("prefactor", iname);
39  _delastic_strain[i] =
40  &declarePropertyDerivative<RankTwoTensor>(_base_name + "elastic_strain", iname);
41 
42  _d2prefactor[i].resize(_num_args);
43  _d2elastic_strain[i].resize(_num_args);
44 
45  for (unsigned int j = i; j < _num_args; ++j)
46  {
47  const VariableName & jname = getVar("args", j)->name();
48  _d2prefactor[i][j] = &getMaterialPropertyDerivative<Real>("prefactor", iname, jname);
49  _d2elastic_strain[i][j] =
50  &declarePropertyDerivative<RankTwoTensor>(_base_name + "elastic_strain", iname, jname);
51  }
52  }
53 }
const unsigned int _num_args
number of variables the prefactor depends on
std::vector< std::vector< MaterialProperty< RankTwoTensor > * > > _d2elastic_strain
second derivatives of the elastic strain w.r.t. to the args
std::vector< std::vector< const MaterialProperty< Real > * > > _d2prefactor
second derivatives of the prefactor w.r.t. to the args
std::vector< MaterialProperty< RankTwoTensor > * > _delastic_strain
first derivatives of the elastic strain w.r.t. to the args
std::vector< const MaterialProperty< Real > * > _dprefactor
first derivatives of the prefactor w.r.t. to the args

Member Function Documentation

◆ computeQpEigenstrain()

void ComputeVariableEigenstrain::computeQpEigenstrain ( )
protectedvirtual

Definition at line 56 of file ComputeVariableEigenstrain.C.

57 {
59 
60  // Define derivatives of the elastic strain
61  for (unsigned int i = 0; i < _num_args; ++i)
62  {
63  (*_delastic_strain[i])[_qp] = -_eigen_base_tensor * (*_dprefactor[i])[_qp];
64  for (unsigned int j = i; j < _num_args; ++j)
65  (*_d2elastic_strain[i][j])[_qp] = -_eigen_base_tensor * (*_d2prefactor[i][j])[_qp];
66  }
67 }
const unsigned int _num_args
number of variables the prefactor depends on
std::vector< std::vector< MaterialProperty< RankTwoTensor > * > > _d2elastic_strain
second derivatives of the elastic strain w.r.t. to the args
virtual void computeQpEigenstrain()
Compute the eigenstrain and store in _eigenstrain.
std::vector< std::vector< const MaterialProperty< Real > * > > _d2prefactor
second derivatives of the prefactor w.r.t. to the args
std::vector< MaterialProperty< RankTwoTensor > * > _delastic_strain
first derivatives of the elastic strain w.r.t. to the args
std::vector< const MaterialProperty< Real > * > _dprefactor
first derivatives of the prefactor w.r.t. to the args

Member Data Documentation

◆ _d2elastic_strain

std::vector<std::vector<MaterialProperty<RankTwoTensor> *> > ComputeVariableEigenstrain::_d2elastic_strain
protected

second derivatives of the elastic strain w.r.t. to the args

Definition at line 44 of file ComputeVariableEigenstrain.h.

Referenced by computeQpEigenstrain(), and ComputeVariableEigenstrain().

◆ _d2prefactor

std::vector<std::vector<const MaterialProperty<Real> *> > ComputeVariableEigenstrain::_d2prefactor
protected

second derivatives of the prefactor w.r.t. to the args

Definition at line 39 of file ComputeVariableEigenstrain.h.

Referenced by computeQpEigenstrain(), and ComputeVariableEigenstrain().

◆ _delastic_strain

std::vector<MaterialProperty<RankTwoTensor> *> ComputeVariableEigenstrain::_delastic_strain
protected

first derivatives of the elastic strain w.r.t. to the args

Definition at line 42 of file ComputeVariableEigenstrain.h.

Referenced by computeQpEigenstrain(), and ComputeVariableEigenstrain().

◆ _dprefactor

std::vector<const MaterialProperty<Real> *> ComputeVariableEigenstrain::_dprefactor
protected

first derivatives of the prefactor w.r.t. to the args

Definition at line 37 of file ComputeVariableEigenstrain.h.

Referenced by computeQpEigenstrain(), and ComputeVariableEigenstrain().

◆ _num_args

const unsigned int ComputeVariableEigenstrain::_num_args
protected

number of variables the prefactor depends on

Definition at line 34 of file ComputeVariableEigenstrain.h.

Referenced by computeQpEigenstrain(), and ComputeVariableEigenstrain().


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