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

#include <AbaqusUmatMaterial.h>

Inheritance diagram for AbaqusUmatMaterial:
[legend]

Public Types

enum  CRACKING_RELEASE { CR_ABRUPT = 0, CR_EXPONENTIAL, CR_POWER, CR_UNKNOWN }
 

Public Member Functions

 AbaqusUmatMaterial (const InputParameters &parameters)
 
virtual ~AbaqusUmatMaterial ()
 
virtual void initStatefulProperties (unsigned n_points)
 
virtual void applyThermalStrain ()
 
virtual void applyVolumetricStrain ()
 
QBase * qrule ()
 
const Point & q_point (unsigned i) const
 
Real JxW (unsigned i) const
 

Static Public Member Functions

static void rotateSymmetricTensor (const ColumnMajorMatrix &R, const SymmTensor &T, SymmTensor &result)
 

Protected Member Functions

virtual void initQpStatefulProperties ()
 
virtual void computeStress ()
 Compute the stress (sigma += deltaSigma) More...
 
virtual void initialSetup ()
 
virtual void timestepSetup ()
 
virtual void jacobianSetup ()
 
virtual void computeProperties ()
 
void computeElasticityTensor ()
 
virtual bool updateElasticityTensor (SymmElasticityTensor &tensor)
 Return true if the elasticity tensor changed. More...
 
virtual void elementInit ()
 
virtual void modifyStrainIncrement ()
 Modify increment for things like thermal strain. More...
 
virtual void crackingStrainDirections ()
 Determine cracking directions. Rotate elasticity tensor. More...
 
virtual unsigned int getNumKnownCrackDirs () const
 
virtual void computeEshelby ()
 
virtual void computeStrainEnergyDensity ()
 
virtual void computeThermalJvec ()
 
virtual void computeCurrentInstantaneousThermalExpansionCoefficient ()
 
virtual void crackingStressRotation ()
 
virtual Real computeCrackFactor (int i, Real &sigma, Real &flagVal)
 
virtual void finalizeStress ()
 Rotate stress to current configuration. More...
 
virtual void computePreconditioning ()
 
void applyCracksToTensor (SymmTensor &tensor, const RealVectorValue &sigma)
 
void elasticityTensor (SymmElasticityTensor *e)
 
SymmElasticityTensorelasticityTensor () const
 
const SolidMechanics::Elementelement () const
 
int delta (int i, int j) const
 
template<typename T >
MaterialProperty< T > & createProperty (const std::string &prop_name)
 
template<typename T >
const MaterialProperty< T > & getPropertyOld (const std::string &prop_name)
 
virtual void checkElasticConstants ()
 
virtual void createElasticityTensor ()
 
virtual void computeConstitutiveModelStress ()
 Compute the stress (sigma += deltaSigma) More...
 
void createConstitutiveModel (const std::string &cm_name)
 

Protected Attributes

FileName _plugin
 
std::vector< Real > _mechanical_constants
 
std::vector< Real > _thermal_constants
 
unsigned int _num_state_vars
 
unsigned int _num_props
 
void * _handle
 
umat_t _umat
 
Real _SSE
 
Real _SPD
 
Real _SCD
 
Real _DRPLDT
 
Real _RPL
 
Real _PNEWDT
 
Real _DTIME
 
Real _TEMP
 
Real _DTEMP
 
Real _CMNAME
 
Real _CELENT
 
int _NDI
 
int _NSHR
 
int _NTENS
 
int _NSTATV
 
int _NPROPS
 
int _NOEL
 
int _NPT
 
int _LAYER
 
int _KSPT
 
int _KSTEP
 
int _KINC
 
Real * _STATEV
 
Real * _DDSDDT
 
Real * _DRPLDE
 
Real * _STRAN
 
Real _PREDEF [1]
 
Real _DPRED [1]
 
Real _COORDS [3]
 
Real _DROT [3][3]
 
Real * _DFGRD0
 
Real * _DFGRD1
 
Real * _STRESS
 
Real * _DDSDDE
 
Real * _DSTRAN
 
Real _TIME [2]
 
Real * _PROPS
 
const VariableGradient & _grad_disp_x
 
const VariableGradient & _grad_disp_y
 
const VariableGradient & _grad_disp_z
 
const VariableGradient & _grad_disp_x_old
 
const VariableGradient & _grad_disp_y_old
 
const VariableGradient & _grad_disp_z_old
 
MaterialProperty< std::vector< Real > > & _state_var
 
const MaterialProperty< std::vector< Real > > & _state_var_old
 
MaterialProperty< ColumnMajorMatrix > & _Fbar
 
const MaterialProperty< ColumnMajorMatrix > & _Fbar_old
 
MaterialProperty< Real > & _elastic_strain_energy
 
MaterialProperty< Real > & _plastic_dissipation
 
MaterialProperty< Real > & _creep_dissipation
 
Moose::CoordinateSystemType _coord_type
 
const std::string _appended_property_name
 
bool _bulk_modulus_set
 
bool _lambda_set
 
bool _poissons_ratio_set
 
bool _shear_modulus_set
 
bool _youngs_modulus_set
 
Real _bulk_modulus
 
Real _lambda
 
Real _poissons_ratio
 
Real _shear_modulus
 
Real _youngs_modulus
 
Function * _youngs_modulus_function
 
Function * _poissons_ratio_function
 
const CRACKING_RELEASE _cracking_release
 
Real _cracking_stress
 
const Real _cracking_residual_stress
 
const Real _cracking_beta
 
const std::string _compute_method
 
Function *const _cracking_stress_function
 
Real _cracking_alpha
 
std::vector< unsigned int > _active_crack_planes
 
const unsigned int _max_cracks
 
const Real _cracking_neg_fraction
 
const bool _has_temp
 
const VariableValue & _temperature
 
const VariableValue & _temperature_old
 
const VariableGradient & _temp_grad
 
const Real _alpha
 
Function * _alpha_function
 
PiecewiseLinear * _piecewise_linear_alpha_function
 
bool _has_stress_free_temp
 
Real _stress_free_temp
 
bool _mean_alpha_function
 
Real _ref_temp
 
std::map< SubdomainID, std::vector< MooseSharedPointer< VolumetricModel > > > _volumetric_models
 
std::set< std::string > _dep_matl_props
 
MaterialProperty< SymmTensor > & _stress
 
SymmTensor _stress_old
 
MaterialProperty< SymmTensor > & _total_strain
 
const MaterialProperty< SymmTensor > & _total_strain_old
 
MaterialProperty< SymmTensor > & _elastic_strain
 
const MaterialProperty< SymmTensor > & _elastic_strain_old
 
MaterialProperty< RealVectorValue > * _crack_flags
 
const MaterialProperty< RealVectorValue > * _crack_flags_old
 
RealVectorValue _crack_flags_local
 
MaterialProperty< RealVectorValue > * _crack_count
 
const MaterialProperty< RealVectorValue > * _crack_count_old
 
MaterialProperty< ColumnMajorMatrix > * _crack_rotation
 
const MaterialProperty< ColumnMajorMatrix > * _crack_rotation_old
 
MaterialProperty< RealVectorValue > * _crack_strain
 
const MaterialProperty< RealVectorValue > * _crack_strain_old
 
MaterialProperty< RealVectorValue > * _crack_max_strain
 
const MaterialProperty< RealVectorValue > * _crack_max_strain_old
 
ColumnMajorMatrix _principal_strain
 
MaterialProperty< SymmElasticityTensor > & _elasticity_tensor
 
MaterialProperty< SymmElasticityTensor > & _Jacobian_mult
 
SymmTensor _d_strain_dT
 
MaterialProperty< SymmTensor > & _d_stress_dT
 
SymmTensor _total_strain_increment
 
SymmTensor _strain_increment
 
const bool _compute_JIntegral
 
const bool _compute_InteractionIntegral
 
bool _store_stress_older
 
MaterialProperty< Real > * _SED
 
const MaterialProperty< Real > * _SED_old
 
MaterialProperty< RankTwoTensor > * _Eshelby_tensor
 
MaterialProperty< RealVectorValue > * _J_thermal_term_vec
 
MaterialProperty< Real > * _current_instantaneous_thermal_expansion_coef
 
std::vector< SubdomainID > _block_id
 
std::map< SubdomainID, MooseSharedPointer< ConstitutiveModel > > _constitutive_model
 
std::set< MooseSharedPointer< ConstitutiveModel > > _models_to_free
 
bool _constitutive_active
 
bool & _step_zero
 Restartable data to check for the zeroth and first time steps for thermal calculations. More...
 
bool & _step_one
 

Detailed Description

Definition at line 57 of file AbaqusUmatMaterial.h.

Member Enumeration Documentation

Enumerator
CR_ABRUPT 
CR_EXPONENTIAL 
CR_POWER 
CR_UNKNOWN 

Definition at line 45 of file SolidModel.h.

Constructor & Destructor Documentation

AbaqusUmatMaterial::AbaqusUmatMaterial ( const InputParameters &  parameters)

Definition at line 30 of file AbaqusUmatMaterial.C.

31  : SolidModel(parameters),
32  _plugin(getParam<FileName>("plugin")),
33  _mechanical_constants(getParam<std::vector<Real>>("mechanical_constants")),
34  _thermal_constants(getParam<std::vector<Real>>("thermal_constants")),
35  _num_state_vars(getParam<unsigned int>("num_state_vars")),
36  _grad_disp_x(coupledGradient("disp_x")),
37  _grad_disp_y(coupledGradient("disp_y")),
38  _grad_disp_z(coupledGradient("disp_z")),
39  _grad_disp_x_old(coupledGradientOld("disp_x")),
40  _grad_disp_y_old(coupledGradientOld("disp_y")),
41  _grad_disp_z_old(coupledGradientOld("disp_z")),
42  _state_var(declareProperty<std::vector<Real>>("state_var")),
43  _state_var_old(getMaterialPropertyOld<std::vector<Real>>("state_var")),
44  _Fbar(declareProperty<ColumnMajorMatrix>("Fbar")),
45  _Fbar_old(getMaterialPropertyOld<ColumnMajorMatrix>("Fbar")),
46  _elastic_strain_energy(declareProperty<Real>("elastic_strain_energy")),
47  _plastic_dissipation(declareProperty<Real>("plastic_dissipation")),
48  _creep_dissipation(declareProperty<Real>("creep_dissipation"))
49 {
50 #if defined(METHOD)
51  _plugin += std::string("-") + QUOTE(METHOD) + ".plugin";
52 #endif
53 
54  // Size and create full (mechanical+thermal) material property array
56  std::vector<Real> props_array(_num_props);
57  for (unsigned int i = 0; i < _mechanical_constants.size(); ++i)
58  props_array[i] = _mechanical_constants[i];
59  for (unsigned int i = _mechanical_constants.size(); i < _num_props; ++i)
60  props_array[i] = _thermal_constants[i];
61 
62  // Read mesh dimension and size UMAT arrays
63  if (_mesh.dimension() == 3) // 3D case
64  {
65  _NTENS = 6; // Size of the stress or strain component array (NDI+NSHR)
66  _NSHR = 3; // Number of engineering shear stress components
67  _NDI = 3; // Number of direct stress components (always 3)
68  }
69  else if (_mesh.dimension() == 2) // 2D case
70  {
71  _NTENS = 4;
72  _NSHR = 1;
73  _NDI = 3;
74  }
75 
76  _STATEV = new Real[_num_state_vars];
77  _DDSDDT = new Real[_NTENS];
78  _DRPLDE = new Real[_NTENS];
79  _STRAN = new Real[_NTENS];
80  _DFGRD0 = new Real[9];
81  _DFGRD1 = new Real[9];
82  _STRESS = new Real[_NTENS];
83  _DDSDDE = new Real[_NTENS * _NTENS];
84  _DSTRAN = new Real[_NTENS];
85  _PROPS = new Real[_num_props];
86 
87  for (unsigned int i = 0; i < _num_state_vars; ++i)
88  {
89  _STATEV[i] = 0.0;
90  }
91 
92  for (int i = 0; i < _NTENS; ++i)
93  {
94  _DDSDDT[i] = 0.0;
95  _DRPLDE[i] = 0.0;
96  _STRAN[i] = 0.0;
97  _STRESS[i] = 0.0;
98  _DSTRAN[i] = 0.0;
99  }
100 
101  for (unsigned int i = 0; i < 9; ++i)
102  {
103  _DFGRD0[i] = 0.0;
104  _DFGRD1[i] = 0.0;
105  }
106 
107  for (int i = 0; i < _NTENS * _NTENS; ++i)
108  {
109  _DDSDDE[i] = 0.0;
110  }
111 
112  // Assign materials properties from vector form into an array
113  for (unsigned int i = 0; i < _num_props; ++i)
114  {
115  _PROPS[i] = props_array[i];
116  }
117 
118  // Size UMAT state variable (NSTATV) and material constant (NPROPS) arrays
121 
122  // Open the library
123  _handle = dlopen(_plugin.c_str(), RTLD_LAZY);
124 
125  if (!_handle)
126  {
127  std::ostringstream error;
128  error << "Cannot open library: " << dlerror() << '\n';
129  mooseError(error.str());
130  }
131 
132  // Reset errors
133  dlerror();
134 
135  // Snag the function pointer from the library
136  {
137  void * pointer = dlsym(_handle, "umat_");
138  _umat = *reinterpret_cast<umat_t *>(&pointer);
139  }
140 
141  // Catch errors
142  const char * dlsym_error = dlerror();
143  if (dlsym_error)
144  {
145  dlclose(_handle);
146  std::ostringstream error;
147  error << "Cannot load symbol 'umat_': " << dlsym_error << '\n';
148  mooseError(error.str());
149  }
150 }
const VariableGradient & _grad_disp_z
const VariableGradient & _grad_disp_y
const VariableGradient & _grad_disp_x
MaterialProperty< std::vector< Real > > & _state_var
const MaterialProperty< std::vector< Real > > & _state_var_old
MaterialProperty< Real > & _elastic_strain_energy
std::vector< Real > _mechanical_constants
void(* umat_t)(Real STRESS[], Real STATEV[], Real DDSDDE[], Real *SSE, Real *SPD, Real *SCD, Real *RPL, Real DDSDDT[], Real DRPLDE[], Real *DRPLDT, Real STRAN[], Real DSTRAN[], Real TIME[], Real *DTIME, Real *TEMP, Real *DTEMP, Real PREDEF[], Real DPRED[], Real *CMNAME, int *NDI, int *NSHR, int *NTENS, int *NSTATV, Real PROPS[], int *NPROPS, Real COORDS[], Real DROT[][3], Real *PNEWDT, Real *CELENT, Real DFGRD0[], Real DFGRD1[], int *NOEL, int *NPT, int *LAYER, int *KSPT, int *KSTEP, int *KINC)
MaterialProperty< Real > & _plastic_dissipation
const VariableGradient & _grad_disp_x_old
std::vector< Real > _thermal_constants
const VariableGradient & _grad_disp_y_old
MaterialProperty< Real > & _creep_dissipation
unsigned int _num_state_vars
MaterialProperty< ColumnMajorMatrix > & _Fbar
SolidModel(const InputParameters &parameters)
Definition: SolidModel.C:141
const MaterialProperty< ColumnMajorMatrix > & _Fbar_old
const VariableGradient & _grad_disp_z_old
AbaqusUmatMaterial::~AbaqusUmatMaterial ( )
virtual

Definition at line 152 of file AbaqusUmatMaterial.C.

153 {
154  delete _STATEV;
155  delete _DDSDDT;
156  delete _DRPLDE;
157  delete _STRAN;
158  delete _DFGRD0;
159  delete _DFGRD1;
160  delete _STRESS;
161  delete _DDSDDE;
162  delete _DSTRAN;
163  delete _PROPS;
164 
165  dlclose(_handle);
166 }

Member Function Documentation

void SolidModel::applyCracksToTensor ( SymmTensor tensor,
const RealVectorValue &  sigma 
)
protectedinherited

Definition at line 1120 of file SolidModel.C.

Referenced by SolidModel::crackingStressRotation().

1121 {
1122  // Form transformation matrix R*E*R^T
1123  const ColumnMajorMatrix & R((*_crack_rotation)[_qp]);
1124 
1125  // Rotate to crack frame
1126  rotateSymmetricTensor(R.transpose(), tensor, tensor);
1127 
1128  // Reset stress if cracked
1129  if ((*_crack_flags)[_qp](0) < 1)
1130  {
1131  tensor(0, 0) = sigma(0);
1132  }
1133  if ((*_crack_flags)[_qp](1) < 1)
1134  {
1135  tensor(1, 1) = sigma(1);
1136  }
1137  if ((*_crack_flags)[_qp](2) < 1)
1138  {
1139  tensor(2, 2) = sigma(2);
1140  }
1141 
1142  // Rotate back to global frame
1143  rotateSymmetricTensor(R, tensor, tensor);
1144 }
MaterialProperty< ColumnMajorMatrix > * _crack_rotation
Definition: SolidModel.h:125
MaterialProperty< RealVectorValue > * _crack_flags
Definition: SolidModel.h:120
static void rotateSymmetricTensor(const ColumnMajorMatrix &R, const SymmTensor &T, SymmTensor &result)
Definition: SolidModel.C:659
void SolidModel::applyThermalStrain ( )
virtualinherited

Definition at line 587 of file SolidModel.C.

Referenced by SolidModel::modifyStrainIncrement().

588 {
589  if (_has_temp && !_step_zero)
590  {
591  Real inc_thermal_strain;
592  Real d_thermal_strain_d_temp;
593 
594  Real old_temp;
596  old_temp = _stress_free_temp;
597  else
598  old_temp = _temperature_old[_qp];
599 
600  Real current_temp = _temperature[_qp];
601 
602  Real delta_t = current_temp - old_temp;
603 
604  Real alpha = _alpha;
605 
606  if (_alpha_function)
607  {
608  Point p;
609  Real alpha_current_temp = _alpha_function->value(current_temp, p);
610  Real alpha_old_temp = _alpha_function->value(old_temp, p);
611 
613  {
614  Real alpha_stress_free_temperature = _alpha_function->value(_stress_free_temp, p);
615  Real small(1e-6);
616 
617  Real numerator = alpha_current_temp * (current_temp - _ref_temp) -
618  alpha_old_temp * (old_temp - _ref_temp);
619  Real denominator = 1.0 + alpha_stress_free_temperature * (_stress_free_temp - _ref_temp);
620  if (denominator < small)
621  mooseError("Denominator too small in thermal strain calculation");
622  inc_thermal_strain = numerator / denominator;
623  d_thermal_strain_d_temp = alpha_current_temp * (current_temp - _ref_temp);
624  }
625  else
626  {
627  inc_thermal_strain = delta_t * 0.5 * (alpha_current_temp + alpha_old_temp);
628  d_thermal_strain_d_temp = alpha_current_temp;
629  }
630  }
631  else
632  {
633  inc_thermal_strain = delta_t * alpha;
634  d_thermal_strain_d_temp = alpha;
635  }
636 
637  _strain_increment.addDiag(-inc_thermal_strain);
638  _d_strain_dT.addDiag(-d_thermal_strain_d_temp);
639  }
640 }
const Real _alpha
Definition: SolidModel.h:95
const VariableValue & _temperature_old
Definition: SolidModel.h:93
Real _stress_free_temp
Definition: SolidModel.h:99
bool & _step_zero
Restartable data to check for the zeroth and first time steps for thermal calculations.
Definition: SolidModel.h:254
bool & _step_one
Definition: SolidModel.h:255
bool _mean_alpha_function
Definition: SolidModel.h:100
const bool _has_temp
Definition: SolidModel.h:91
SymmTensor _d_strain_dT
Definition: SolidModel.h:137
SymmTensor _strain_increment
Definition: SolidModel.h:143
const VariableValue & _temperature
Definition: SolidModel.h:92
bool _has_stress_free_temp
Definition: SolidModel.h:98
Function * _alpha_function
Definition: SolidModel.h:96
Real _ref_temp
Definition: SolidModel.h:101
void addDiag(Real value)
Definition: SymmTensor.h:279
void SolidModel::applyVolumetricStrain ( )
virtualinherited

Definition at line 645 of file SolidModel.C.

Referenced by SolidModel::modifyStrainIncrement().

646 {
647  const Real V0Vold = 1 / _element->volumeRatioOld(_qp);
648  const SubdomainID current_block = _current_elem->subdomain_id();
649  const std::vector<MooseSharedPointer<VolumetricModel>> & vm(_volumetric_models[current_block]);
650  for (unsigned int i(0); i < vm.size(); ++i)
651  {
652  vm[i]->modifyStrain(_qp, V0Vold, _strain_increment, _d_strain_dT);
653  }
654 }
virtual Real volumeRatioOld(unsigned) const
Definition: Element.h:58
SymmTensor _d_strain_dT
Definition: SolidModel.h:137
SymmTensor _strain_increment
Definition: SolidModel.h:143
SolidMechanics::Element * _element
Definition: SolidModel.h:263
std::map< SubdomainID, std::vector< MooseSharedPointer< VolumetricModel > > > _volumetric_models
Definition: SolidModel.h:103
void SolidModel::checkElasticConstants ( )
protectedvirtualinherited

Reimplemented in MacroElastic.

Definition at line 373 of file SolidModel.C.

Referenced by SolidModel::initialSetup().

374 {
375  int num_elastic_constants = _bulk_modulus_set + _lambda_set + _poissons_ratio_set +
377 
378  if (num_elastic_constants != 2)
379  {
380  std::string err("Exactly two elastic constants must be defined for material '");
381  err += name();
382  err += "'.";
383  mooseError(err);
384  }
385 
386  if (_bulk_modulus_set && _bulk_modulus <= 0)
387  {
388  std::string err("Bulk modulus must be positive in material '");
389  err += name();
390  err += "'.";
391  mooseError(err);
392  }
393  if (_poissons_ratio_set && (_poissons_ratio <= -1.0 || _poissons_ratio >= 0.5))
394  {
395  std::string err("Poissons ratio must be greater than -1 and less than 0.5 in material '");
396  err += name();
397  err += "'.";
398  mooseError(err);
399  }
401  {
402  std::string err("Shear modulus must not be negative in material '");
403  err += name();
404  err += "'.";
405  mooseError(err);
406  }
407  if (_youngs_modulus_set && _youngs_modulus <= 0)
408  {
409  std::string err("Youngs modulus must be positive in material '");
410  err += name();
411  err += "'.";
412  mooseError(err);
413  }
414 
415  // Calculate lambda, the shear modulus, and Young's modulus
416  if (_lambda_set && _shear_modulus_set) // First and second Lame
417  {
421  }
422  else if (_lambda_set && _poissons_ratio_set)
423  {
424  _shear_modulus = (_lambda * (1.0 - 2.0 * _poissons_ratio)) / (2.0 * _poissons_ratio);
427  }
428  else if (_lambda_set && _bulk_modulus_set)
429  {
430  _shear_modulus = 3.0 * (_bulk_modulus - _lambda) / 2.0;
434  }
435  else if (_lambda_set && _youngs_modulus_set)
436  {
438  ((_youngs_modulus - 3.0 * _lambda) / 4.0) +
439  (std::sqrt((_youngs_modulus - 3.0 * _lambda) * (_youngs_modulus - 3.0 * _lambda) +
440  8.0 * _lambda * _youngs_modulus) /
441  4.0);
443  }
445  {
446  _lambda = (2.0 * _shear_modulus * _poissons_ratio) / (1.0 - 2.0 * _poissons_ratio);
449  }
451  {
452  _lambda = _bulk_modulus - 2.0 * _shear_modulus / 3.0;
456  (3 * _bulk_modulus - 2 * _shear_modulus) / (2 * (3 * _bulk_modulus + _shear_modulus));
457  }
458  else if (_shear_modulus_set && _youngs_modulus_set)
459  {
463  }
465  {
468  (3.0 * _bulk_modulus * (1.0 - 2.0 * _poissons_ratio)) / (2.0 * (1.0 + _poissons_ratio));
471  }
472  else if (_youngs_modulus_set && _poissons_ratio_set) // Young's Modulus and Poisson's Ratio
473  {
475  ((1.0 + _poissons_ratio) * (1 - 2.0 * _poissons_ratio));
476  _shear_modulus = _youngs_modulus / (2.0 * (1.0 + _poissons_ratio));
477  }
478  else if (_youngs_modulus_set && _bulk_modulus_set)
479  {
480  _lambda = 3.0 * _bulk_modulus * (3.0 * _bulk_modulus - _youngs_modulus) /
481  (9.0 * _bulk_modulus - _youngs_modulus);
485  }
486 
487  _lambda_set = true;
488  _shear_modulus_set = true;
489  _youngs_modulus_set = true;
490  _poissons_ratio_set = true;
491 }
Real _poissons_ratio
Definition: SolidModel.h:70
Real _bulk_modulus
Definition: SolidModel.h:68
bool _youngs_modulus_set
Definition: SolidModel.h:66
bool _poissons_ratio_set
Definition: SolidModel.h:64
bool _shear_modulus_set
Definition: SolidModel.h:65
bool _bulk_modulus_set
Definition: SolidModel.h:62
Real _youngs_modulus
Definition: SolidModel.h:72
bool _lambda_set
Definition: SolidModel.h:63
Real _lambda
Definition: SolidModel.h:69
Real _shear_modulus
Definition: SolidModel.h:71
void SolidModel::computeConstitutiveModelStress ( )
protectedvirtualinherited

Compute the stress (sigma += deltaSigma)

Definition at line 835 of file SolidModel.C.

Referenced by SolidModel::computeProperties().

836 {
837  // Given the stretching, compute the stress increment and add it to the old stress. Also update
838  // the creep strain
839  // stress = stressOld + stressIncrement
840 
841  if (_step_zero)
842  return;
843 
844  const SubdomainID current_block = _current_elem->subdomain_id();
845  MooseSharedPointer<ConstitutiveModel> cm = _constitutive_model[current_block];
846 
847  mooseAssert(_constitutive_active, "Logic error. ConstitutiveModel not active.");
848 
849  // Let's be a little careful and check for a non-existent
850  // ConstitutiveModel, which could be returned as a default value
851  // from std::map::operator[]
852  if (!cm)
853  mooseError("Logic error. No ConstitutiveModel for current_block=", current_block, ".");
854 
855  cm->setQp(_qp);
856  cm->computeStress(
857  *_current_elem, *elasticityTensor(), _stress_old, _strain_increment, _stress[_qp]);
858 }
SymmElasticityTensor * elasticityTensor() const
Definition: SolidModel.h:217
bool _constitutive_active
Definition: SolidModel.h:246
bool & _step_zero
Restartable data to check for the zeroth and first time steps for thermal calculations.
Definition: SolidModel.h:254
std::map< SubdomainID, MooseSharedPointer< ConstitutiveModel > > _constitutive_model
Definition: SolidModel.h:243
SymmTensor _strain_increment
Definition: SolidModel.h:143
SymmTensor _stress_old
Definition: SolidModel.h:112
MaterialProperty< SymmTensor > & _stress
Definition: SolidModel.h:106
Real SolidModel::computeCrackFactor ( int  i,
Real &  sigma,
Real &  flagVal 
)
protectedvirtualinherited

Definition at line 1405 of file SolidModel.C.

Referenced by SolidModel::crackingStressRotation().

1406 {
1408  {
1409  if ((*_crack_max_strain)[_qp](i) < (*_crack_strain)[_qp](i))
1410  {
1411  std::stringstream err;
1412  err << "Max strain less than crack strain: " << i << " " << sigma << ", "
1413  << (*_crack_max_strain)[_qp](i) << ", " << (*_crack_strain)[_qp](i) << ", "
1414  << _principal_strain(0, 0) << ", " << _principal_strain(1, 0) << ", "
1415  << _principal_strain(2, 0) << _elastic_strain[_qp] << std::endl;
1416  mooseError(err.str());
1417  }
1418  const Real crackMaxStrain((*_crack_max_strain)[_qp](i));
1419  // Compute stress that follows exponental curve
1423  (crackMaxStrain - (*_crack_strain)[_qp](i))));
1424  // Compute ratio of current stiffness to original stiffness
1425  flagVal = sigma * (*_crack_strain)[_qp](i) / (crackMaxStrain * _cracking_stress);
1426  }
1427  else
1428  {
1429  if (_cracking_residual_stress == 0)
1430  {
1431  const Real tiny(1e-16);
1432  flagVal = tiny;
1433  sigma = tiny * (*_crack_strain)[_qp](i) * _youngs_modulus;
1434  }
1435  else
1436  {
1438  flagVal = sigma / ((*_crack_max_strain)[_qp](i) * _youngs_modulus);
1439  }
1440  }
1441  if (flagVal < 0)
1442  {
1443  std::stringstream err;
1444  err << "Negative crack flag found: " << i << " " << flagVal << ", "
1445  << (*_crack_max_strain)[_qp](i) << ", " << (*_crack_strain)[_qp](i) << ", " << std::endl;
1446  mooseError(err.str());
1447  }
1448  return flagVal;
1449 }
const Real _cracking_residual_stress
Definition: SolidModel.h:79
Real _cracking_stress
Definition: SolidModel.h:78
const CRACKING_RELEASE _cracking_release
Definition: SolidModel.h:77
Real _cracking_alpha
Definition: SolidModel.h:84
Real _youngs_modulus
Definition: SolidModel.h:72
MaterialProperty< SymmTensor > & _elastic_strain
Definition: SolidModel.h:117
ColumnMajorMatrix _principal_strain
Definition: SolidModel.h:131
MaterialProperty< RealVectorValue > * _crack_max_strain
Definition: SolidModel.h:129
MaterialProperty< RealVectorValue > * _crack_strain
Definition: SolidModel.h:127
const Real _cracking_beta
Definition: SolidModel.h:80
void SolidModel::computeCurrentInstantaneousThermalExpansionCoefficient ( )
protectedvirtualinherited

Definition at line 1645 of file SolidModel.C.

Referenced by SolidModel::computeProperties(), and SolidModel::computeThermalJvec().

1646 {
1648  "_current_instantaneous_thermal_expansion_coef not initialized");
1649 
1650  (*_current_instantaneous_thermal_expansion_coef)[_qp] = 0.0;
1651 
1652  if (_alpha_function)
1653  {
1654  Point p;
1655  Real current_temp = _temperature[_qp];
1656 
1657  if (!_mean_alpha_function)
1658  {
1659  Real alpha = _alpha_function->value(current_temp, p);
1660  (*_current_instantaneous_thermal_expansion_coef)[_qp] = alpha;
1661  }
1662  else
1663  {
1664  Real small(1e-6);
1665  Real dalphabar_dT = _alpha_function->timeDerivative(current_temp, p);
1666  Real alphabar_Tsf = _alpha_function->value(_stress_free_temp, p);
1667  Real alphabar = _alpha_function->value(current_temp, p);
1668  Real numerator = dalphabar_dT * (current_temp - _ref_temp) + alphabar;
1669  Real denominator = 1.0 + alphabar_Tsf * (_stress_free_temp - _ref_temp);
1670  if (denominator < small)
1671  mooseError("Denominator too small in thermal strain calculation");
1672  (*_current_instantaneous_thermal_expansion_coef)[_qp] = numerator / denominator;
1673  }
1674  }
1675  else
1677 }
const Real _alpha
Definition: SolidModel.h:95
Real _stress_free_temp
Definition: SolidModel.h:99
bool _mean_alpha_function
Definition: SolidModel.h:100
const VariableValue & _temperature
Definition: SolidModel.h:92
MaterialProperty< Real > * _current_instantaneous_thermal_expansion_coef
Definition: SolidModel.h:156
Function * _alpha_function
Definition: SolidModel.h:96
Real _ref_temp
Definition: SolidModel.h:101
void SolidModel::computeElasticityTensor ( )
protectedinherited

Definition at line 862 of file SolidModel.C.

Referenced by SolidModel::computeProperties().

863 {
864  if (_cracking_stress_function != NULL)
865  {
866  _cracking_stress = _cracking_stress_function->value(_t, _q_point[_qp]);
867  }
868 
870 
872 
874 
876 
878 
879  if (changed || _cracking_stress > 0)
880  {
882  }
883 }
Real _cracking_stress
Definition: SolidModel.h:78
SymmElasticityTensor * _local_elasticity_tensor
Definition: SolidModel.h:265
virtual bool updateElasticityTensor(SymmElasticityTensor &tensor)
Return true if the elasticity tensor changed.
Definition: SolidModel.C:888
Function *const _cracking_stress_function
Definition: SolidModel.h:82
const MaterialProperty< SymmTensor > & _stress_old_prop
Definition: SolidModel.h:109
MaterialProperty< SymmElasticityTensor > & _elasticity_tensor
Definition: SolidModel.h:133
void calculate(unsigned int qp)
Public function that will be called whenever the values for this matrix need to be filled in...
SymmTensor _stress_old
Definition: SolidModel.h:112
const MaterialProperty< SymmTensor > & _elastic_strain_old
Definition: SolidModel.h:118
virtual void crackingStrainDirections()
Determine cracking directions. Rotate elasticity tensor.
Definition: SolidModel.C:1045
void SolidModel::computeEshelby ( )
protectedvirtualinherited

Definition at line 786 of file SolidModel.C.

Referenced by SolidModel::computeProperties().

787 {
788  mooseAssert(_SED, "_SED not initialized");
789  mooseAssert(_Eshelby_tensor, "_Eshelby_tensor not initialized");
790  // Cauchy stress (sigma) in a colum major matrix:
791  ColumnMajorMatrix stress_CMM;
792  stress_CMM(0, 0) = _stress[_qp].xx();
793  stress_CMM(0, 1) = _stress[_qp].xy();
794  stress_CMM(0, 2) = _stress[_qp].xz();
795  stress_CMM(1, 0) = _stress[_qp].xy();
796  stress_CMM(1, 1) = _stress[_qp].yy();
797  stress_CMM(1, 2) = _stress[_qp].yz();
798  stress_CMM(2, 0) = _stress[_qp].xz();
799  stress_CMM(2, 1) = _stress[_qp].yz();
800  stress_CMM(2, 2) = _stress[_qp].zz();
801 
802  // Deformation gradient (F):
803  ColumnMajorMatrix F;
805  // Displacement gradient (H):
806  ColumnMajorMatrix H(F);
807  H.addDiag(-1.0);
808  Real detF = _element->detMatrix(F);
809  ColumnMajorMatrix Finv;
810  _element->invertMatrix(F, Finv);
811  ColumnMajorMatrix FinvT;
812  FinvT = Finv.transpose();
813  ColumnMajorMatrix HT;
814  HT = H.transpose();
815 
816  // 1st Piola-Kirchoff Stress (P):
817  ColumnMajorMatrix piola;
818  piola = stress_CMM * FinvT;
819  piola *= detF;
820 
821  // HTP = H^T * P = H^T * detF * sigma * FinvT;
822  ColumnMajorMatrix HTP;
823  HTP = HT * piola;
824 
825  ColumnMajorMatrix WI;
826  WI.identity();
827  WI *= (*_SED)[_qp];
828  WI *= detF;
829  (*_Eshelby_tensor)[_qp] = WI - HTP;
830 }
MaterialProperty< Real > * _SED
Definition: SolidModel.h:150
virtual void computeDeformationGradient(unsigned int, ColumnMajorMatrix &)
Definition: Element.h:48
static Real detMatrix(const ColumnMajorMatrix &A)
Definition: Element.C:28
SolidMechanics::Element * _element
Definition: SolidModel.h:263
MaterialProperty< SymmTensor > & _stress
Definition: SolidModel.h:106
static void invertMatrix(const ColumnMajorMatrix &A, ColumnMajorMatrix &Ainv)
Definition: Element.C:49
MaterialProperty< RankTwoTensor > * _Eshelby_tensor
Definition: SolidModel.h:152
void SolidModel::computePreconditioning ( )
protectedvirtualinherited

Definition at line 941 of file SolidModel.C.

Referenced by SolidModel::computeProperties().

942 {
943  mooseAssert(_local_elasticity_tensor, "null elasticity tensor");
944 
945  // _Jacobian_mult[_qp] = *_local_elasticity_tensor;
946  // _d_stress_dT[_qp] = *_local_elasticity_tensor * _d_strain_dT;
949 }
SymmElasticityTensor * _local_elasticity_tensor
Definition: SolidModel.h:265
MaterialProperty< SymmElasticityTensor > & _Jacobian_mult
Definition: SolidModel.h:134
MaterialProperty< SymmTensor > & _d_stress_dT
Definition: SolidModel.h:140
MaterialProperty< SymmElasticityTensor > & _elasticity_tensor
Definition: SolidModel.h:133
SymmTensor _d_strain_dT
Definition: SolidModel.h:137
void SolidModel::computeProperties ( )
protectedvirtualinherited

Definition at line 725 of file SolidModel.C.

726 {
727  if (_t_step >= 1)
728  _step_zero = false;
729 
730  if (_t_step >= 2)
731  _step_one = false;
732 
733  elementInit();
734  _element->init();
735 
736  for (_qp = 0; _qp < _qrule->n_points(); ++_qp)
737  {
740 
742 
744 
746  computeStress();
747  else
749 
750  if (_compute_JIntegral)
752 
754 
756 
757  finalizeStress();
758 
759  if (_compute_JIntegral)
760  computeEshelby();
761 
764 
767 
769  }
770 }
const bool _compute_JIntegral
Definition: SolidModel.h:145
bool _constitutive_active
Definition: SolidModel.h:246
SymmTensor _total_strain_increment
Definition: SolidModel.h:142
virtual void modifyStrainIncrement()
Modify increment for things like thermal strain.
Definition: SolidModel.C:556
const bool _compute_InteractionIntegral
Definition: SolidModel.h:146
virtual void computeStrain(const unsigned qp, const SymmTensor &total_strain_old, SymmTensor &total_strain_new, SymmTensor &strain_increment)=0
virtual void computeEshelby()
Definition: SolidModel.C:786
virtual void computePreconditioning()
Definition: SolidModel.C:941
MaterialProperty< SymmTensor > & _total_strain
Definition: SolidModel.h:114
const MaterialProperty< SymmTensor > & _total_strain_old
Definition: SolidModel.h:115
virtual void crackingStressRotation()
Definition: SolidModel.C:1234
virtual void computeCurrentInstantaneousThermalExpansionCoefficient()
Definition: SolidModel.C:1645
virtual void elementInit()
Definition: SolidModel.h:172
bool & _step_zero
Restartable data to check for the zeroth and first time steps for thermal calculations.
Definition: SolidModel.h:254
bool & _step_one
Definition: SolidModel.h:255
const bool _has_temp
Definition: SolidModel.h:91
MaterialProperty< SymmTensor > & _elastic_strain
Definition: SolidModel.h:117
virtual void computeConstitutiveModelStress()
Compute the stress (sigma += deltaSigma)
Definition: SolidModel.C:835
SymmTensor _strain_increment
Definition: SolidModel.h:143
const MaterialProperty< SymmTensor > & _elastic_strain_old
Definition: SolidModel.h:118
SolidMechanics::Element * _element
Definition: SolidModel.h:263
virtual void computeStrainEnergyDensity()
Definition: SolidModel.C:775
virtual void finalizeStress()
Rotate stress to current configuration.
Definition: SolidModel.C:929
virtual void computeThermalJvec()
Definition: SolidModel.C:1629
virtual void init()
Definition: Element.h:46
virtual void computeStress()
Compute the stress (sigma += deltaSigma)
Definition: SolidModel.h:183
void computeElasticityTensor()
Definition: SolidModel.C:862
void SolidModel::computeStrainEnergyDensity ( )
protectedvirtualinherited

Definition at line 775 of file SolidModel.C.

Referenced by SolidModel::computeProperties().

776 {
777  mooseAssert(_SED, "_SED not initialized");
778  mooseAssert(_SED_old, "_SED_old not initialized");
779  (*_SED)[_qp] = (*_SED_old)[_qp] + _stress[_qp].doubleContraction(_strain_increment) / 2 +
780  _stress_old_prop[_qp].doubleContraction(_strain_increment) / 2;
781 }
const MaterialProperty< Real > * _SED_old
Definition: SolidModel.h:151
MaterialProperty< Real > * _SED
Definition: SolidModel.h:150
const MaterialProperty< SymmTensor > & _stress_old_prop
Definition: SolidModel.h:109
SymmTensor _strain_increment
Definition: SolidModel.h:143
MaterialProperty< SymmTensor > & _stress
Definition: SolidModel.h:106
void AbaqusUmatMaterial::computeStress ( )
protectedvirtual

Compute the stress (sigma += deltaSigma)

Reimplemented from SolidModel.

Definition at line 178 of file AbaqusUmatMaterial.C.

179 {
180  // Calculate deformation gradient - modeled from "solid_mechanics/src/materials/Nonlinear3D.C"
181  // Fbar = 1 + grad(u(k))
182  ColumnMajorMatrix Fbar;
183 
184  Fbar(0, 0) = _grad_disp_x[_qp](0);
185  Fbar(0, 1) = _grad_disp_x[_qp](1);
186  Fbar(0, 2) = _grad_disp_x[_qp](2);
187  Fbar(1, 0) = _grad_disp_y[_qp](0);
188  Fbar(1, 1) = _grad_disp_y[_qp](1);
189  Fbar(1, 2) = _grad_disp_y[_qp](2);
190  Fbar(2, 0) = _grad_disp_z[_qp](0);
191  Fbar(2, 1) = _grad_disp_z[_qp](1);
192  Fbar(2, 2) = _grad_disp_z[_qp](2);
193 
194  Fbar.addDiag(1);
195  _Fbar[_qp] = Fbar;
196 
197  Real myDFGRD0[9] = {_Fbar_old[_qp](0, 0),
198  _Fbar_old[_qp](1, 0),
199  _Fbar_old[_qp](2, 0),
200  _Fbar_old[_qp](0, 1),
201  _Fbar_old[_qp](1, 1),
202  _Fbar_old[_qp](2, 1),
203  _Fbar_old[_qp](0, 2),
204  _Fbar_old[_qp](1, 2),
205  _Fbar_old[_qp](2, 2)};
206  Real myDFGRD1[9] = {_Fbar[_qp](0, 0),
207  _Fbar[_qp](1, 0),
208  _Fbar[_qp](2, 0),
209  _Fbar[_qp](0, 1),
210  _Fbar[_qp](1, 1),
211  _Fbar[_qp](2, 1),
212  _Fbar[_qp](0, 2),
213  _Fbar[_qp](1, 2),
214  _Fbar[_qp](2, 2)};
215 
216  for (unsigned int i = 0; i < 9; ++i)
217  {
218  _DFGRD0[i] = myDFGRD0[i];
219  _DFGRD1[i] = myDFGRD1[i];
220  }
221 
222  // Recover "old" state variables
223  for (unsigned int i = 0; i < _num_state_vars; ++i)
224  _STATEV[i] = _state_var_old[_qp][i];
225 
226  // Pass through updated stress, total strain, and strain increment arrays
227  for (int i = 0; i < _NTENS; ++i)
228  {
229  _STRESS[i] = _stress_old.component(i);
230  _STRAN[i] = _total_strain[_qp].component(i);
232  }
233 
234  // Pass through step , time, and coordinate system information
235  _KSTEP = _t_step; // Step number
236  _TIME[0] = _t; // Value of step time at the beginning of the current increment - Check
237  _TIME[1] = _t - _dt; // Value of total time at the beginning of the current increment - Check
238  _DTIME = _dt; // Time increment
239  for (unsigned int i = 0; i < 3; ++i) // Loop current coordinates in UMAT COORDS
240  _COORDS[i] = _coord[i];
241 
242  // Connection to extern statement
243  _umat(_STRESS,
244  _STATEV,
245  _DDSDDE,
246  &_SSE,
247  &_SPD,
248  &_SCD,
249  &_RPL,
250  _DDSDDT,
251  _DRPLDE,
252  &_DRPLDT,
253  _STRAN,
254  _DSTRAN,
255  _TIME,
256  &_DTIME,
257  &_TEMP,
258  &_DTEMP,
259  _PREDEF,
260  _DPRED,
261  &_CMNAME,
262  &_NDI,
263  &_NSHR,
264  &_NTENS,
265  &_NSTATV,
266  _PROPS,
267  &_NPROPS,
268  _COORDS,
269  _DROT,
270  &_PNEWDT,
271  &_CELENT,
272  _DFGRD0,
273  _DFGRD1,
274  &_NOEL,
275  &_NPT,
276  &_LAYER,
277  &_KSPT,
278  &_KSTEP,
279  &_KINC);
280 
281  // Energy outputs
283  _plastic_dissipation[_qp] = _SPD;
284  _creep_dissipation[_qp] = _SCD;
285 
286  // Update state variables
287  for (unsigned int i = 0; i < _num_state_vars; ++i)
288  _state_var[_qp][i] = _STATEV[i];
289 
290  // Get new stress tensor - UMAT should update stress
291  SymmTensor stressnew(_STRESS[0], _STRESS[1], _STRESS[2], _STRESS[3], _STRESS[4], _STRESS[5]);
292  _stress[_qp] = stressnew;
293 }
const VariableGradient & _grad_disp_z
const VariableGradient & _grad_disp_y
const VariableGradient & _grad_disp_x
MaterialProperty< SymmTensor > & _total_strain
Definition: SolidModel.h:114
MaterialProperty< std::vector< Real > > & _state_var
const MaterialProperty< std::vector< Real > > & _state_var_old
MaterialProperty< Real > & _elastic_strain_energy
MaterialProperty< Real > & _plastic_dissipation
SymmTensor _strain_increment
Definition: SolidModel.h:143
SymmTensor _stress_old
Definition: SolidModel.h:112
MaterialProperty< Real > & _creep_dissipation
MaterialProperty< SymmTensor > & _stress
Definition: SolidModel.h:106
unsigned int _num_state_vars
MaterialProperty< ColumnMajorMatrix > & _Fbar
const MaterialProperty< ColumnMajorMatrix > & _Fbar_old
Real component(unsigned int i) const
Definition: SymmTensor.h:97
void SolidModel::computeThermalJvec ( )
protectedvirtualinherited

Definition at line 1629 of file SolidModel.C.

Referenced by SolidModel::computeProperties().

1630 {
1631  mooseAssert(_J_thermal_term_vec, "_J_thermal_term_vec not initialized");
1632 
1633  Real stress_trace = _stress[_qp].xx() + _stress[_qp].yy() + _stress[_qp].zz();
1634 
1636  for (unsigned int i = 0; i < LIBMESH_DIM; ++i)
1637  {
1638  Real dthermstrain_dx =
1640  (*_J_thermal_term_vec)[_qp](i) = stress_trace * dthermstrain_dx;
1641  }
1642 }
virtual void computeCurrentInstantaneousThermalExpansionCoefficient()
Definition: SolidModel.C:1645
const VariableGradient & _temp_grad
Definition: SolidModel.h:94
MaterialProperty< RealVectorValue > * _J_thermal_term_vec
Definition: SolidModel.h:153
MaterialProperty< SymmTensor > & _stress
Definition: SolidModel.h:106
MaterialProperty< Real > * _current_instantaneous_thermal_expansion_coef
Definition: SolidModel.h:156
void SolidModel::crackingStrainDirections ( )
protectedvirtualinherited

Determine cracking directions. Rotate elasticity tensor.

Definition at line 1045 of file SolidModel.C.

Referenced by SolidModel::computeElasticityTensor().

1046 {
1047  bool cracking_locally_active(false);
1048  if (_cracking_stress > 0)
1049  {
1050  // Compute whether cracking has occurred
1051  (*_crack_rotation)[_qp] = (*_crack_rotation_old)[_qp];
1052 
1053  ColumnMajorMatrix RT((*_crack_rotation)[_qp].transpose());
1054  SymmTensor ePrime;
1055  rotateSymmetricTensor(RT, _elastic_strain[_qp], ePrime);
1056 
1057  for (unsigned int i(0); i < 3; ++i)
1058  {
1059  (*_crack_max_strain)[_qp](i) = (*_crack_max_strain_old)[_qp](i);
1060 
1061  if (_cracking_neg_fraction == 0 && ePrime(i, i) < 0)
1062  {
1063  _crack_flags_local(i) = 1;
1064  }
1065  else if (_cracking_neg_fraction > 0 &&
1066  (*_crack_strain)[_qp](i) * _cracking_neg_fraction > ePrime(i, i))
1067  {
1068  if (-(*_crack_strain)[_qp](i) * _cracking_neg_fraction > ePrime(i, i))
1069  {
1070  _crack_flags_local(i) = 1;
1071  }
1072  else
1073  {
1074  // s = a*e^2 + b*e + c
1075  // a = (Ec-Eo)/(4etr)
1076  // b = (Ec+Eo)/2
1077  // c = (Ec-Eo)*etr/4
1078  // etr = _cracking_neg_fraction * strain when crack occurred
1079  const Real etr = _cracking_neg_fraction * (*_crack_strain)[_qp](i);
1080  const Real Eo = _cracking_stress / (*_crack_strain)[_qp](i);
1081  const Real Ec = Eo * (*_crack_flags_old)[_qp](i);
1082  const Real a = (Ec - Eo) / (4 * etr);
1083  const Real b = (Ec + Eo) / 2;
1084  // Compute the ratio of the current transition stiffness to the original stiffness
1085  _crack_flags_local(i) = (2 * a * etr + b) / Eo;
1086  cracking_locally_active = true;
1087  }
1088  }
1089  else
1090  {
1091  _crack_flags_local(i) = (*_crack_flags_old)[_qp](i);
1092  if (_crack_flags_local(i) < 1)
1093  {
1094  cracking_locally_active = true;
1095  }
1096  }
1097  }
1098  }
1099  if (cracking_locally_active)
1100  {
1101  // Adjust the elasticity matrix for cracking. This must be used by the
1102  // constitutive law.
1103  if (_compute_method == "ShearRetention")
1105  else
1107 
1108  ColumnMajorMatrix R_9x9(9, 9);
1109  const ColumnMajorMatrix & R((*_crack_rotation)[_qp]);
1112 
1114  }
1115 }
MaterialProperty< ColumnMajorMatrix > * _crack_rotation
Definition: SolidModel.h:125
Real _cracking_stress
Definition: SolidModel.h:78
SymmElasticityTensor * _local_elasticity_tensor
Definition: SolidModel.h:265
virtual void adjustForCrackingWithShearRetention(const RealVectorValue &crack_flags)
virtual void adjustForCracking(const RealVectorValue &crack_flags)
MaterialProperty< SymmElasticityTensor > & _elasticity_tensor
Definition: SolidModel.h:133
const std::string _compute_method
Definition: SolidModel.h:81
const Real _cracking_neg_fraction
Definition: SolidModel.h:87
MaterialProperty< SymmTensor > & _elastic_strain
Definition: SolidModel.h:117
void rotateFromLocalToGlobal(const ColumnMajorMatrix &R)
void form9x9Rotation(const ColumnMajorMatrix &R_3x3, ColumnMajorMatrix &R_9x9) const
const MaterialProperty< RealVectorValue > * _crack_max_strain_old
Definition: SolidModel.h:130
MaterialProperty< RealVectorValue > * _crack_strain
Definition: SolidModel.h:127
RealVectorValue _crack_flags_local
Definition: SolidModel.h:122
static void rotateSymmetricTensor(const ColumnMajorMatrix &R, const SymmTensor &T, SymmTensor &result)
Definition: SolidModel.C:659
void SolidModel::crackingStressRotation ( )
protectedvirtualinherited

Definition at line 1234 of file SolidModel.C.

Referenced by SolidModel::computeProperties().

1235 {
1236  if (_cracking_stress_function != NULL)
1237  {
1238  _cracking_stress = _cracking_stress_function->value(_t, _q_point[_qp]);
1239  }
1240 
1241  if (_cracking_stress > 0)
1242  {
1243 
1245 
1246  for (unsigned i(0); i < 3; ++i)
1247  {
1248  if (_principal_strain(i, 0) > (*_crack_max_strain_old)[_qp](i))
1249  {
1250  (*_crack_max_strain)[_qp](i) = _principal_strain(i, 0);
1251  }
1252  }
1253 
1254  // Check for new cracks.
1255  // This must be done in the crack-local coordinate frame.
1256 
1257  // Rotate stress to cracked orientation.
1258  ColumnMajorMatrix R((*_crack_rotation)[_qp]);
1259  ColumnMajorMatrix RT((*_crack_rotation)[_qp].transpose());
1260  SymmTensor sigmaPrime;
1261  rotateSymmetricTensor(RT, _stress[_qp], sigmaPrime);
1262 
1263  unsigned int num_cracks(0);
1264  for (unsigned i(0); i < 3; ++i)
1265  {
1266  _crack_flags_local(i) = 1;
1267  (*_crack_strain)[_qp](i) = (*_crack_strain_old)[_qp](i);
1268  if ((*_crack_flags_old)[_qp](i) < 1)
1269  {
1270  ++num_cracks;
1271  }
1272  }
1273 
1274  bool new_crack(false);
1275  bool cracked(false);
1276  RealVectorValue sigma;
1277  for (unsigned i(0); i < 3; ++i)
1278  {
1279  sigma(i) = sigmaPrime(i, i);
1280  (*_crack_flags)[_qp](i) = (*_crack_flags_old)[_qp](i);
1281  if (sigma(i) <= 1e-4)
1282  {
1283  if ((*_crack_flags)[_qp](i) == 1)
1284  {
1285  (*_crack_max_strain)[_qp](i) = _principal_strain(i, 0);
1286  }
1287  }
1288 
1289  // _cracked_this_step[_q_point[_qp]] = 0;
1290  Real crackFactor(1);
1291  if (_cracking_release == CR_POWER)
1292  {
1293  (*_crack_count)[_qp](i) = (*_crack_count_old)[_qp](i);
1294  }
1295  if ((_cracking_release == CR_POWER && sigma(i) > _cracking_stress &&
1296  _active_crack_planes[i] == 1
1297  // && (*_crack_count)[_qp](i) == 0
1298  )
1299  // || _cracked_this_step_count[_q_point[_qp]] > 5
1300  )
1301  {
1302  cracked = true;
1303  ++((*_crack_count)[_qp](i));
1304  // _cracked_this_step[_q_point[_qp]] = 1;
1305  // Assume Poisson's ratio drops to zero for this direction. Stiffness is then Young's
1306  // modulus.
1307  const Real stiff = _youngs_modulus_function
1308  ? _youngs_modulus_function->value(_temperature[_qp], Point())
1309  : _youngs_modulus;
1310 
1311  if ((*_crack_count_old)[_qp](i) == 0)
1312  {
1313  new_crack = true;
1314  ++num_cracks;
1315 
1316  (*_crack_strain)[_qp](i) = _cracking_stress / stiff;
1317  }
1318  // Compute stress, factor....
1319  (*_crack_flags)[_qp](i) *= 1. / 3.;
1320 
1321  if ((*_crack_max_strain)[_qp](i) < (*_crack_strain)[_qp](i))
1322  {
1323  (*_crack_max_strain)[_qp](i) = (*_crack_strain)[_qp](i);
1324  }
1325  sigma(i) = (*_crack_flags)[_qp](i) * stiff * _principal_strain(i, 0);
1326  }
1327  else if ((_cracking_release != CR_POWER && (*_crack_flags_old)[_qp](i) == 1 &&
1328  sigma(i) > _cracking_stress && num_cracks < _max_cracks &&
1329  _active_crack_planes[i] == 1)
1330  // || _cracked_this_step_count[_q_point[_qp]] > 5
1331  )
1332  {
1333  // A new crack
1334  // _cracked_this_step[_q_point[_qp]] = 1;
1335 
1336  cracked = true;
1337  new_crack = true;
1338  ++num_cracks;
1339 
1340  // Assume Poisson's ratio drops to zero for this direction. Stiffness is then Young's
1341  // modulus.
1342  const Real stiff = _youngs_modulus_function
1343  ? _youngs_modulus_function->value(_temperature[_qp], Point())
1344  : _youngs_modulus;
1345 
1346  (*_crack_strain)[_qp](i) = _cracking_stress / stiff;
1347  if ((*_crack_max_strain)[_qp](i) < (*_crack_strain)[_qp](i))
1348  {
1349  (*_crack_max_strain)[_qp](i) = (*_crack_strain)[_qp](i);
1350  }
1351 
1352  crackFactor = computeCrackFactor(i, sigma(i), (*_crack_flags)[_qp](i));
1353 
1354  (*_crack_flags)[_qp](i) = crackFactor;
1355  _crack_flags_local(i) = crackFactor;
1356 
1357  // May want to set the old value. This may help with the nonlinear solve
1358  // since the stress cannot bounce between just below the critical stress and
1359  // effectively zero. However, this may set allow cracking prematurely.
1360  // (*_crack_flags_old)[_qp](i) = crackFactor;
1361  // (*_crack_strain_old)[_qp](i) = _principal_strain(i,0);
1362  }
1363  else if (_cracking_release != CR_POWER && (*_crack_flags_old)[_qp](i) < 1 &&
1364  std::abs(_principal_strain(i, 0) - (*_crack_max_strain)[_qp](i)) < 1e-10)
1365  {
1366  // Previously cracked,
1367  // Crack opening
1368  cracked = true;
1369  crackFactor = computeCrackFactor(i, sigma(i), (*_crack_flags)[_qp](i));
1370  (*_crack_flags)[_qp](i) = crackFactor;
1371  _crack_flags_local(i) = crackFactor;
1372  }
1373  else if (_cracking_neg_fraction > 0 &&
1376  {
1377  // s = a*e^2 + b*e + c
1378  // a = (Ec-Eo)/(4etr)
1379  // b = (Ec+Eo)/2
1380  // c = (Ec-Eo)*etr/4
1381  // etr = _cracking_neg_fraction * strain when crack occurred
1382  cracked = true;
1383  const Real etr = _cracking_neg_fraction * (*_crack_strain)[_qp](i);
1384  const Real Eo = _cracking_stress / (*_crack_strain)[_qp](i);
1385  const Real Ec = Eo * (*_crack_flags_old)[_qp](i);
1386  const Real a = (Ec - Eo) / (4 * etr);
1387  const Real b = (Ec + Eo) / 2;
1388  const Real c = (Ec - Eo) * etr / 4;
1389  sigma(i) = (a * _principal_strain(i, 0) + b) * _principal_strain(i, 0) + c;
1390  }
1391  }
1392 
1393  if (!new_crack)
1394  {
1395  (*_crack_rotation)[_qp] = (*_crack_rotation_old)[_qp];
1396  }
1397  if (cracked)
1398  {
1399  applyCracksToTensor(_stress[_qp], sigma);
1400  }
1401  }
1402 }
MaterialProperty< ColumnMajorMatrix > * _crack_rotation
Definition: SolidModel.h:125
const MaterialProperty< RealVectorValue > * _crack_count_old
Definition: SolidModel.h:124
const unsigned int _max_cracks
Definition: SolidModel.h:86
Real _cracking_stress
Definition: SolidModel.h:78
void applyCracksToTensor(SymmTensor &tensor, const RealVectorValue &sigma)
Definition: SolidModel.C:1120
virtual Real computeCrackFactor(int i, Real &sigma, Real &flagVal)
Definition: SolidModel.C:1405
Function * _youngs_modulus_function
Definition: SolidModel.h:74
const CRACKING_RELEASE _cracking_release
Definition: SolidModel.h:77
Function *const _cracking_stress_function
Definition: SolidModel.h:82
const MaterialProperty< RealVectorValue > * _crack_flags_old
Definition: SolidModel.h:121
void computeCrackStrainAndOrientation(ColumnMajorMatrix &principal_strain)
Definition: SolidModel.C:1149
const Real _cracking_neg_fraction
Definition: SolidModel.h:87
Real _youngs_modulus
Definition: SolidModel.h:72
MaterialProperty< RealVectorValue > * _crack_flags
Definition: SolidModel.h:120
ColumnMajorMatrix _principal_strain
Definition: SolidModel.h:131
const MaterialProperty< RealVectorValue > * _crack_max_strain_old
Definition: SolidModel.h:130
const VariableValue & _temperature
Definition: SolidModel.h:92
MaterialProperty< RealVectorValue > * _crack_max_strain
Definition: SolidModel.h:129
const MaterialProperty< RealVectorValue > * _crack_strain_old
Definition: SolidModel.h:128
MaterialProperty< RealVectorValue > * _crack_strain
Definition: SolidModel.h:127
MaterialProperty< SymmTensor > & _stress
Definition: SolidModel.h:106
std::vector< unsigned int > _active_crack_planes
Definition: SolidModel.h:85
RealVectorValue _crack_flags_local
Definition: SolidModel.h:122
static void rotateSymmetricTensor(const ColumnMajorMatrix &R, const SymmTensor &T, SymmTensor &result)
Definition: SolidModel.C:659
void SolidModel::createConstitutiveModel ( const std::string &  cm_name)
protectedinherited

Definition at line 1588 of file SolidModel.C.

Referenced by CLSHPlasticMaterial::CLSHPlasticMaterial(), Elastic::Elastic(), LinearStrainHardening::LinearStrainHardening(), and PowerLawCreep::PowerLawCreep().

1589 {
1590 
1591  Factory & factory = _app.getFactory();
1592  InputParameters params = factory.getValidParams(cm_name);
1593  // These set_attributes calls are to make isParamSetByUser() work correctly on
1594  // these parameters in the ConstitutiveModel class, and are needed only for the
1595  // legacy_return_mapping option.
1596  params.set_attributes("absolute_tolerance", false);
1597  params.set_attributes("relative_tolerance", false);
1598  params.set_attributes("max_its", false);
1599  params += parameters();
1600  MooseSharedPointer<ConstitutiveModel> cm =
1601  factory.create<ConstitutiveModel>(cm_name, name() + "Model", params, _tid);
1602 
1603  _models_to_free.insert(
1604  cm); // Keep track of the dynamic memory that is created internally to this object
1605 
1606  _constitutive_active = true;
1607  for (unsigned i(0); i < _block_id.size(); ++i)
1608  {
1609  _constitutive_model[_block_id[i]] = cm;
1610  }
1611 }
bool _constitutive_active
Definition: SolidModel.h:246
std::vector< SubdomainID > _block_id
Definition: SolidModel.h:241
std::set< MooseSharedPointer< ConstitutiveModel > > _models_to_free
Definition: SolidModel.h:245
std::map< SubdomainID, MooseSharedPointer< ConstitutiveModel > > _constitutive_model
Definition: SolidModel.h:243
void SolidModel::createElasticityTensor ( )
protectedvirtualinherited

Reimplemented in MacroElastic.

Definition at line 496 of file SolidModel.C.

Referenced by SolidModel::initialSetup().

497 {
498  bool constant(true);
499 
502  {
503  constant = false;
504  }
505 
507  mooseAssert(_youngs_modulus_set, "Internal error: Youngs modulus not set");
508  mooseAssert(_poissons_ratio_set, "Internal error: Poissons ratio not set");
511  iso->calculate(0);
512  elasticityTensor(iso);
513 }
SymmElasticityTensor * elasticityTensor() const
Definition: SolidModel.h:217
Real _poissons_ratio
Definition: SolidModel.h:70
Real _cracking_stress
Definition: SolidModel.h:78
bool _youngs_modulus_set
Definition: SolidModel.h:66
bool _poissons_ratio_set
Definition: SolidModel.h:64
Function * _youngs_modulus_function
Definition: SolidModel.h:74
Function *const _cracking_stress_function
Definition: SolidModel.h:82
Function * _poissons_ratio_function
Definition: SolidModel.h:75
void calculate(unsigned int qp)
Public function that will be called whenever the values for this matrix need to be filled in...
Real _youngs_modulus
Definition: SolidModel.h:72
void setYoungsModulus(const Real E)
Set the Young&#39;s Modulus.
Defines an Isotropic Elasticity Tensor.
void setPoissonsRatio(const Real nu)
Set Poissons Ratio.
template<typename T >
MaterialProperty<T>& SolidModel::createProperty ( const std::string &  prop_name)
inlineprotectedinherited

Definition at line 224 of file SolidModel.h.

225  {
226  std::string name(prop_name + _appended_property_name);
227  return declareProperty<T>(name);
228  }
const std::string _appended_property_name
Definition: SolidModel.h:60
int SolidModel::delta ( int  i,
int  j 
) const
inlineprotectedinherited

Definition at line 221 of file SolidModel.h.

221 { return i == j; }
void SolidModel::elasticityTensor ( SymmElasticityTensor e)
protectedinherited

Definition at line 547 of file SolidModel.C.

548 {
551 }
SymmElasticityTensor * _local_elasticity_tensor
Definition: SolidModel.h:265
SymmElasticityTensor* SolidModel::elasticityTensor ( ) const
inlineprotectedinherited
const SolidMechanics::Element* SolidModel::element ( ) const
inlineprotectedinherited

Definition at line 219 of file SolidModel.h.

Referenced by SolidModel::createElement().

219 { return _element; }
SolidMechanics::Element * _element
Definition: SolidModel.h:263
virtual void SolidModel::elementInit ( )
inlineprotectedvirtualinherited

Definition at line 172 of file SolidModel.h.

Referenced by SolidModel::computeProperties().

172 {}
void SolidModel::finalizeStress ( )
protectedvirtualinherited

Rotate stress to current configuration.

Definition at line 929 of file SolidModel.C.

Referenced by SolidModel::computeProperties().

930 {
931  std::vector<SymmTensor *> t(3);
932  t[0] = &_elastic_strain[_qp];
933  t[1] = &_total_strain[_qp];
934  t[2] = &_stress[_qp];
936 }
MaterialProperty< SymmTensor > & _total_strain
Definition: SolidModel.h:114
MaterialProperty< SymmTensor > & _elastic_strain
Definition: SolidModel.h:117
SolidMechanics::Element * _element
Definition: SolidModel.h:263
virtual void finalizeStress(std::vector< SymmTensor * > &)
Rotate stress to current configuration.
Definition: Element.h:61
MaterialProperty< SymmTensor > & _stress
Definition: SolidModel.h:106
unsigned int SolidModel::getNumKnownCrackDirs ( ) const
protectedvirtualinherited

Definition at line 1452 of file SolidModel.C.

Referenced by SolidModel::computeCrackStrainAndOrientation().

1453 {
1454  const unsigned fromElement = _element->getNumKnownCrackDirs();
1455  unsigned int retVal(0);
1456  for (unsigned int i(0); i < 3 - fromElement; ++i)
1457  {
1458  retVal += ((*_crack_flags_old)[_qp](i) < 1);
1459  }
1460  return retVal + fromElement;
1461 }
virtual unsigned int getNumKnownCrackDirs() const
Definition: Element.h:63
SolidMechanics::Element * _element
Definition: SolidModel.h:263
template<typename T >
const MaterialProperty<T>& SolidModel::getPropertyOld ( const std::string &  prop_name)
inlineprotectedinherited

Definition at line 231 of file SolidModel.h.

232  {
233  std::string name(prop_name + _appended_property_name);
234  return getMaterialPropertyOld<T>(name);
235  }
const std::string _appended_property_name
Definition: SolidModel.h:60
void SolidModel::initialSetup ( )
protectedvirtualinherited

Definition at line 954 of file SolidModel.C.

955 {
956 
958 
960 
961  // Load in the volumetric models and constitutive models
962  bool set_constitutive_active = false;
963  for (unsigned i(0); i < _block_id.size(); ++i)
964  {
965 
966  // const std::vector<Material*> * mats_p;
967  std::vector<MooseSharedPointer<Material>> const * mats_p;
968  std::string suffix;
969  if (_bnd)
970  {
971  mats_p = &_fe_problem.getMaterialWarehouse()[Moose::FACE_MATERIAL_DATA].getActiveBlockObjects(
972  _block_id[i], _tid);
973  suffix = "_face";
974  }
975  else
976  mats_p = &_fe_problem.getMaterialWarehouse().getActiveBlockObjects(_block_id[i], _tid);
977 
978  const std::vector<MooseSharedPointer<Material>> & mats = *mats_p;
979 
980  for (unsigned int j = 0; j < mats.size(); ++j)
981  {
982  MooseSharedPointer<VolumetricModel> vm =
983  MooseSharedNamespace::dynamic_pointer_cast<VolumetricModel>(mats[j]);
984  if (vm)
985  {
986  const std::vector<std::string> & dep_matl_props = vm->getDependentMaterialProperties();
987  for (unsigned k = 0; k < dep_matl_props.size(); ++k)
988  {
989  if ("" != dep_matl_props[k] &&
990  _dep_matl_props.find(dep_matl_props[k]) == _dep_matl_props.end())
991  {
992  mooseError("A VolumetricModel depends on " + dep_matl_props[k] +
993  ", but that material property was not given in the dep_matl_props line.");
994  }
995  }
996  _volumetric_models[_block_id[i]].push_back(vm);
997  }
998  }
999 
1000  for (std::map<SubdomainID, MooseSharedPointer<ConstitutiveModel>>::iterator iter =
1001  _constitutive_model.begin();
1002  iter != _constitutive_model.end();
1003  ++iter)
1004  {
1005  iter->second->initialSetup();
1006  }
1007 
1008  if (isParamValid("constitutive_model") && !_constitutive_active)
1009  {
1010  // User-defined name of the constitutive model (a Material object)
1011  std::string constitutive_model = getParam<std::string>("constitutive_model") + suffix;
1012 
1013  for (unsigned int j = 0; j < mats.size(); ++j)
1014  {
1015  MooseSharedPointer<ConstitutiveModel> cm =
1016  MooseSharedNamespace::dynamic_pointer_cast<ConstitutiveModel>(mats[j]);
1017 
1018  if (cm && cm->name() == constitutive_model)
1019  {
1020  _constitutive_model[_block_id[i]] = cm;
1021  set_constitutive_active = true;
1022  break;
1023  }
1024  }
1025 
1026  if (!set_constitutive_active)
1027  mooseError("Unable to find constitutive model " + constitutive_model);
1028  }
1029  }
1030  if (set_constitutive_active)
1031  _constitutive_active = true;
1032 
1034  {
1035  // Make sure that timeDerivative is supported for _alpha_function. If not, it will error out.
1036  Point dummy_point;
1037  Real dummy_temp = 0;
1038  _alpha_function->timeDerivative(dummy_temp, dummy_point);
1039  }
1040 }
virtual std::vector< std::string > getDependentMaterialProperties() const
std::set< std::string > _dep_matl_props
Definition: SolidModel.h:104
const bool _compute_JIntegral
Definition: SolidModel.h:145
bool _constitutive_active
Definition: SolidModel.h:246
virtual void checkElasticConstants()
Definition: SolidModel.C:373
virtual void createElasticityTensor()
Definition: SolidModel.C:496
std::vector< SubdomainID > _block_id
Definition: SolidModel.h:241
std::map< SubdomainID, MooseSharedPointer< ConstitutiveModel > > _constitutive_model
Definition: SolidModel.h:243
Function * _alpha_function
Definition: SolidModel.h:96
std::map< SubdomainID, std::vector< MooseSharedPointer< VolumetricModel > > > _volumetric_models
Definition: SolidModel.h:103
void AbaqusUmatMaterial::initQpStatefulProperties ( )
protectedvirtual

Reimplemented from SolidModel.

Definition at line 169 of file AbaqusUmatMaterial.C.

170 {
171  // Initialize state variable vector
172  _state_var[_qp].resize(_num_state_vars);
173  for (unsigned int i = 0; i < _num_state_vars; ++i)
174  _state_var[_qp][i] = 0.0;
175 }
MaterialProperty< std::vector< Real > > & _state_var
unsigned int _num_state_vars
void SolidModel::initStatefulProperties ( unsigned  n_points)
virtualinherited

Reimplemented in AbaqusCreepMaterial.

Definition at line 1614 of file SolidModel.C.

1615 {
1616  for (_qp = 0; _qp < n_points; ++_qp)
1617  {
1619  }
1621  {
1622  const SubdomainID current_block = _current_elem->subdomain_id();
1623  MooseSharedPointer<ConstitutiveModel> cm = _constitutive_model[current_block];
1624  cm->initStatefulProperties(n_points);
1625  }
1626 }
bool _constitutive_active
Definition: SolidModel.h:246
virtual void initQpStatefulProperties()
Definition: SolidModel.C:692
std::map< SubdomainID, MooseSharedPointer< ConstitutiveModel > > _constitutive_model
Definition: SolidModel.h:243
void SolidModel::jacobianSetup ( )
protectedvirtualinherited

Definition at line 529 of file SolidModel.C.

530 {
531  // if (_cracking_stress > 0)
532  // {
533  // for (std::map<Point, unsigned>::iterator i = _cracked_this_step.begin();
534  // i != _cracked_this_step.end(); ++i)
535  // {
536  // if (i->second)
537  // {
538  // ++_cracked_this_step_count[i->first];
539  // }
540  // }
541  // }
542 }
Real SolidModel::JxW ( unsigned  i) const
inlineinherited
void SolidModel::modifyStrainIncrement ( )
protectedvirtualinherited

Modify increment for things like thermal strain.

Definition at line 556 of file SolidModel.C.

Referenced by SolidModel::computeProperties().

557 {
558  bool modified = false;
559  _d_strain_dT.zero();
560 
561  const SubdomainID current_block = _current_elem->subdomain_id();
563  {
564  MooseSharedPointer<ConstitutiveModel> cm = _constitutive_model[current_block];
565 
566  // Let's be a little careful and check for a non-existent
567  // ConstitutiveModel, which could be returned as a default value
568  // from std::map::operator[]
569  if (!cm)
570  mooseError("ConstitutiveModel not available for block ", current_block);
571 
572  cm->setQp(_qp);
573  modified |= cm->modifyStrainIncrement(*_current_elem, _strain_increment, _d_strain_dT);
574  }
575 
576  if (!modified)
577  {
579  }
580 
582 }
bool _constitutive_active
Definition: SolidModel.h:246
void zero()
Definition: SymmTensor.h:273
virtual void applyThermalStrain()
Definition: SolidModel.C:587
SymmTensor _d_strain_dT
Definition: SolidModel.h:137
virtual void applyVolumetricStrain()
Definition: SolidModel.C:645
std::map< SubdomainID, MooseSharedPointer< ConstitutiveModel > > _constitutive_model
Definition: SolidModel.h:243
SymmTensor _strain_increment
Definition: SolidModel.h:143
const Point& SolidModel::q_point ( unsigned  i) const
inlineinherited
QBase* SolidModel::qrule ( )
inlineinherited
void SolidModel::rotateSymmetricTensor ( const ColumnMajorMatrix &  R,
const SymmTensor T,
SymmTensor result 
)
staticinherited

Definition at line 659 of file SolidModel.C.

Referenced by SolidModel::applyCracksToTensor(), SolidModel::computeCrackStrainAndOrientation(), SolidModel::crackingStrainDirections(), and SolidModel::crackingStressRotation().

662 {
663 
664  // R T Rt
665  // 00 01 02 00 01 02 00 10 20
666  // 10 11 12 * 10 11 12 * 01 11 21
667  // 20 21 22 20 21 22 02 12 22
668  //
669  const Real T00 = R(0, 0) * T.xx() + R(0, 1) * T.xy() + R(0, 2) * T.zx();
670  const Real T01 = R(0, 0) * T.xy() + R(0, 1) * T.yy() + R(0, 2) * T.yz();
671  const Real T02 = R(0, 0) * T.zx() + R(0, 1) * T.yz() + R(0, 2) * T.zz();
672 
673  const Real T10 = R(1, 0) * T.xx() + R(1, 1) * T.xy() + R(1, 2) * T.zx();
674  const Real T11 = R(1, 0) * T.xy() + R(1, 1) * T.yy() + R(1, 2) * T.yz();
675  const Real T12 = R(1, 0) * T.zx() + R(1, 1) * T.yz() + R(1, 2) * T.zz();
676 
677  const Real T20 = R(2, 0) * T.xx() + R(2, 1) * T.xy() + R(2, 2) * T.zx();
678  const Real T21 = R(2, 0) * T.xy() + R(2, 1) * T.yy() + R(2, 2) * T.yz();
679  const Real T22 = R(2, 0) * T.zx() + R(2, 1) * T.yz() + R(2, 2) * T.zz();
680 
681  result.xx(T00 * R(0, 0) + T01 * R(0, 1) + T02 * R(0, 2));
682  result.yy(T10 * R(1, 0) + T11 * R(1, 1) + T12 * R(1, 2));
683  result.zz(T20 * R(2, 0) + T21 * R(2, 1) + T22 * R(2, 2));
684  result.xy(T00 * R(1, 0) + T01 * R(1, 1) + T02 * R(1, 2));
685  result.yz(T10 * R(2, 0) + T11 * R(2, 1) + T12 * R(2, 2));
686  result.zx(T00 * R(2, 0) + T01 * R(2, 1) + T02 * R(2, 2));
687 }
Real yy() const
Definition: SymmTensor.h:130
Real xx() const
Definition: SymmTensor.h:129
Real zz() const
Definition: SymmTensor.h:131
Real xy() const
Definition: SymmTensor.h:132
Real yz() const
Definition: SymmTensor.h:133
Real zx() const
Definition: SymmTensor.h:134
void SolidModel::timestepSetup ( )
protectedvirtualinherited

Definition at line 518 of file SolidModel.C.

519 {
520  // if (_cracking_stress > 0)
521  // {
522  // _cracked_this_step_count.clear();
523  // }
524 }
bool SolidModel::updateElasticityTensor ( SymmElasticityTensor tensor)
protectedvirtualinherited

Return true if the elasticity tensor changed.

Reimplemented in MacroElastic.

Definition at line 888 of file SolidModel.C.

Referenced by SolidModel::computeElasticityTensor().

889 {
890  bool changed(false);
892  {
893  const SubdomainID current_block = _current_elem->subdomain_id();
894  MooseSharedPointer<ConstitutiveModel> cm = _constitutive_model[current_block];
895 
896  // Let's be a little careful and check for a non-existent
897  // ConstitutiveModel, which could be returned as a default value
898  // from std::map::operator[]
899  if (!cm)
900  mooseError("ConstitutiveModel not available for block ", current_block);
901 
902  cm->setQp(_qp);
903  changed |= cm->updateElasticityTensor(tensor);
904  }
905 
907  {
908  SymmIsotropicElasticityTensor * t = dynamic_cast<SymmIsotropicElasticityTensor *>(&tensor);
909  if (!t)
910  {
911  mooseError("Cannot use Youngs modulus or Poissons ratio functions");
912  }
913  t->unsetConstants();
914  Point p;
916  ? _youngs_modulus_function->value(_temperature[_qp], p)
917  : _youngs_modulus));
919  ? _poissons_ratio_function->value(_temperature[_qp], p)
920  : _poissons_ratio));
921  changed = true;
922  }
923  return changed;
924 }
Real _poissons_ratio
Definition: SolidModel.h:70
bool _constitutive_active
Definition: SolidModel.h:246
Function * _youngs_modulus_function
Definition: SolidModel.h:74
Function * _poissons_ratio_function
Definition: SolidModel.h:75
std::map< SubdomainID, MooseSharedPointer< ConstitutiveModel > > _constitutive_model
Definition: SolidModel.h:243
Real _youngs_modulus
Definition: SolidModel.h:72
const VariableValue & _temperature
Definition: SolidModel.h:92
void setYoungsModulus(const Real E)
Set the Young&#39;s Modulus.
Defines an Isotropic Elasticity Tensor.
void setPoissonsRatio(const Real nu)
Set Poissons Ratio.

Member Data Documentation

std::vector<unsigned int> SolidModel::_active_crack_planes
protectedinherited

Definition at line 85 of file SolidModel.h.

Referenced by SolidModel::crackingStressRotation(), and SolidModel::SolidModel().

const Real SolidModel::_alpha
protectedinherited
Function* SolidModel::_alpha_function
protectedinherited
const std::string SolidModel::_appended_property_name
protectedinherited

Definition at line 60 of file SolidModel.h.

std::vector<SubdomainID> SolidModel::_block_id
protectedinherited
Real SolidModel::_bulk_modulus
protectedinherited

Definition at line 68 of file SolidModel.h.

Referenced by SolidModel::checkElasticConstants().

bool SolidModel::_bulk_modulus_set
protectedinherited

Definition at line 62 of file SolidModel.h.

Referenced by SolidModel::checkElasticConstants().

Real AbaqusUmatMaterial::_CELENT
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

Real AbaqusUmatMaterial::_CMNAME
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

const bool SolidModel::_compute_InteractionIntegral
protectedinherited

Definition at line 146 of file SolidModel.h.

Referenced by SolidModel::computeProperties(), and SolidModel::SolidModel().

const bool SolidModel::_compute_JIntegral
protectedinherited
const std::string SolidModel::_compute_method
protectedinherited

Definition at line 81 of file SolidModel.h.

Referenced by SolidModel::crackingStrainDirections().

bool SolidModel::_constitutive_active
protectedinherited
std::map<SubdomainID, MooseSharedPointer<ConstitutiveModel> > SolidModel::_constitutive_model
protectedinherited
Moose::CoordinateSystemType SolidModel::_coord_type
protectedinherited

Definition at line 58 of file SolidModel.h.

Referenced by SolidModel::createElement(), and SolidModel::SolidModel().

Real AbaqusUmatMaterial::_COORDS[3]
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

MaterialProperty<RealVectorValue>* SolidModel::_crack_count
protectedinherited

Definition at line 123 of file SolidModel.h.

Referenced by SolidModel::initQpStatefulProperties(), and SolidModel::SolidModel().

const MaterialProperty<RealVectorValue>* SolidModel::_crack_count_old
protectedinherited

Definition at line 124 of file SolidModel.h.

Referenced by SolidModel::crackingStressRotation(), and SolidModel::SolidModel().

MaterialProperty<RealVectorValue>* SolidModel::_crack_flags
protectedinherited
RealVectorValue SolidModel::_crack_flags_local
protectedinherited
const MaterialProperty<RealVectorValue>* SolidModel::_crack_flags_old
protectedinherited

Definition at line 121 of file SolidModel.h.

Referenced by SolidModel::crackingStressRotation(), and SolidModel::SolidModel().

MaterialProperty<RealVectorValue>* SolidModel::_crack_max_strain
protectedinherited
const MaterialProperty<RealVectorValue>* SolidModel::_crack_max_strain_old
protectedinherited
MaterialProperty<ColumnMajorMatrix>* SolidModel::_crack_rotation
protectedinherited
const MaterialProperty<ColumnMajorMatrix>* SolidModel::_crack_rotation_old
protectedinherited

Definition at line 126 of file SolidModel.h.

Referenced by SolidModel::SolidModel().

MaterialProperty<RealVectorValue>* SolidModel::_crack_strain
protectedinherited
const MaterialProperty<RealVectorValue>* SolidModel::_crack_strain_old
protectedinherited

Definition at line 128 of file SolidModel.h.

Referenced by SolidModel::crackingStressRotation(), and SolidModel::SolidModel().

Real SolidModel::_cracking_alpha
protectedinherited

Definition at line 84 of file SolidModel.h.

Referenced by SolidModel::computeCrackFactor(), and SolidModel::SolidModel().

const Real SolidModel::_cracking_beta
protectedinherited

Definition at line 80 of file SolidModel.h.

Referenced by SolidModel::computeCrackFactor().

const Real SolidModel::_cracking_neg_fraction
protectedinherited
const CRACKING_RELEASE SolidModel::_cracking_release
protectedinherited
const Real SolidModel::_cracking_residual_stress
protectedinherited

Definition at line 79 of file SolidModel.h.

Referenced by SolidModel::computeCrackFactor().

Real SolidModel::_cracking_stress
protectedinherited
Function* const SolidModel::_cracking_stress_function
protectedinherited
MaterialProperty<Real>& AbaqusUmatMaterial::_creep_dissipation
protected

Definition at line 101 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

MaterialProperty<Real>* SolidModel::_current_instantaneous_thermal_expansion_coef
protectedinherited
SymmTensor SolidModel::_d_strain_dT
protectedinherited
MaterialProperty<SymmTensor>& SolidModel::_d_stress_dT
protectedinherited

Definition at line 140 of file SolidModel.h.

Referenced by SolidModel::computePreconditioning().

Real * AbaqusUmatMaterial::_DDSDDE
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), computeStress(), and ~AbaqusUmatMaterial().

Real * AbaqusUmatMaterial::_DDSDDT
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), computeStress(), and ~AbaqusUmatMaterial().

std::set<std::string> SolidModel::_dep_matl_props
protectedinherited

Definition at line 104 of file SolidModel.h.

Referenced by SolidModel::initialSetup(), and SolidModel::SolidModel().

Real * AbaqusUmatMaterial::_DFGRD0
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), computeStress(), and ~AbaqusUmatMaterial().

Real * AbaqusUmatMaterial::_DFGRD1
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), computeStress(), and ~AbaqusUmatMaterial().

Real AbaqusUmatMaterial::_DPRED[1]
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

Real AbaqusUmatMaterial::_DROT[3][3]
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

Real * AbaqusUmatMaterial::_DRPLDE
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), computeStress(), and ~AbaqusUmatMaterial().

Real AbaqusUmatMaterial::_DRPLDT
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

Real * AbaqusUmatMaterial::_DSTRAN
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), computeStress(), and ~AbaqusUmatMaterial().

Real AbaqusUmatMaterial::_DTEMP
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

Real AbaqusUmatMaterial::_DTIME
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

MaterialProperty<SymmTensor>& SolidModel::_elastic_strain
protectedinherited
MaterialProperty<Real>& AbaqusUmatMaterial::_elastic_strain_energy
protected

Definition at line 99 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

const MaterialProperty<SymmTensor>& SolidModel::_elastic_strain_old
protectedinherited
MaterialProperty<SymmElasticityTensor>& SolidModel::_elasticity_tensor
protectedinherited
MaterialProperty<RankTwoTensor>* SolidModel::_Eshelby_tensor
protectedinherited

Definition at line 152 of file SolidModel.h.

Referenced by SolidModel::computeEshelby(), and SolidModel::SolidModel().

MaterialProperty<ColumnMajorMatrix>& AbaqusUmatMaterial::_Fbar
protected

Definition at line 97 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

const MaterialProperty<ColumnMajorMatrix>& AbaqusUmatMaterial::_Fbar_old
protected

Definition at line 98 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

const VariableGradient& AbaqusUmatMaterial::_grad_disp_x
protected

Definition at line 89 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

const VariableGradient& AbaqusUmatMaterial::_grad_disp_x_old
protected

Definition at line 92 of file AbaqusUmatMaterial.h.

const VariableGradient& AbaqusUmatMaterial::_grad_disp_y
protected

Definition at line 90 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

const VariableGradient& AbaqusUmatMaterial::_grad_disp_y_old
protected

Definition at line 93 of file AbaqusUmatMaterial.h.

const VariableGradient& AbaqusUmatMaterial::_grad_disp_z
protected

Definition at line 91 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

const VariableGradient& AbaqusUmatMaterial::_grad_disp_z_old
protected

Definition at line 94 of file AbaqusUmatMaterial.h.

void* AbaqusUmatMaterial::_handle
protected

Definition at line 71 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), and ~AbaqusUmatMaterial().

bool SolidModel::_has_stress_free_temp
protectedinherited

Definition at line 98 of file SolidModel.h.

Referenced by SolidModel::applyThermalStrain(), and SolidModel::SolidModel().

const bool SolidModel::_has_temp
protectedinherited
MaterialProperty<RealVectorValue>* SolidModel::_J_thermal_term_vec
protectedinherited

Definition at line 153 of file SolidModel.h.

Referenced by SolidModel::computeThermalJvec(), and SolidModel::SolidModel().

MaterialProperty<SymmElasticityTensor>& SolidModel::_Jacobian_mult
protectedinherited

Definition at line 134 of file SolidModel.h.

Referenced by SolidModel::computePreconditioning().

int AbaqusUmatMaterial::_KINC
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

int AbaqusUmatMaterial::_KSPT
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

int AbaqusUmatMaterial::_KSTEP
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

Real SolidModel::_lambda
protectedinherited

Definition at line 69 of file SolidModel.h.

Referenced by SolidModel::checkElasticConstants().

bool SolidModel::_lambda_set
protectedinherited

Definition at line 63 of file SolidModel.h.

Referenced by SolidModel::checkElasticConstants().

int AbaqusUmatMaterial::_LAYER
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

const unsigned int SolidModel::_max_cracks
protectedinherited

Definition at line 86 of file SolidModel.h.

Referenced by SolidModel::crackingStressRotation().

bool SolidModel::_mean_alpha_function
protectedinherited
std::vector<Real> AbaqusUmatMaterial::_mechanical_constants
protected

Definition at line 65 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial().

std::set<MooseSharedPointer<ConstitutiveModel> > SolidModel::_models_to_free
protectedinherited

Definition at line 245 of file SolidModel.h.

Referenced by SolidModel::createConstitutiveModel().

int AbaqusUmatMaterial::_NDI
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), and computeStress().

int AbaqusUmatMaterial::_NOEL
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

int AbaqusUmatMaterial::_NPROPS
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), and computeStress().

int AbaqusUmatMaterial::_NPT
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

int AbaqusUmatMaterial::_NSHR
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), and computeStress().

int AbaqusUmatMaterial::_NSTATV
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), and computeStress().

int AbaqusUmatMaterial::_NTENS
protected

Definition at line 80 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), and computeStress().

unsigned int AbaqusUmatMaterial::_num_props
protected

Definition at line 68 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial().

unsigned int AbaqusUmatMaterial::_num_state_vars
protected
PiecewiseLinear* SolidModel::_piecewise_linear_alpha_function
protectedinherited

Definition at line 97 of file SolidModel.h.

MaterialProperty<Real>& AbaqusUmatMaterial::_plastic_dissipation
protected

Definition at line 100 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

FileName AbaqusUmatMaterial::_plugin
protected

Definition at line 64 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial().

Real AbaqusUmatMaterial::_PNEWDT
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

Real SolidModel::_poissons_ratio
protectedinherited
Function* SolidModel::_poissons_ratio_function
protectedinherited
bool SolidModel::_poissons_ratio_set
protectedinherited
Real AbaqusUmatMaterial::_PREDEF[1]
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

ColumnMajorMatrix SolidModel::_principal_strain
protectedinherited
Real * AbaqusUmatMaterial::_PROPS
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), computeStress(), and ~AbaqusUmatMaterial().

Real SolidModel::_ref_temp
protectedinherited
Real AbaqusUmatMaterial::_RPL
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

Real AbaqusUmatMaterial::_SCD
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

MaterialProperty<Real>* SolidModel::_SED
protectedinherited
const MaterialProperty<Real>* SolidModel::_SED_old
protectedinherited

Definition at line 151 of file SolidModel.h.

Referenced by SolidModel::computeStrainEnergyDensity(), and SolidModel::SolidModel().

Real SolidModel::_shear_modulus
protectedinherited
bool SolidModel::_shear_modulus_set
protectedinherited

Definition at line 65 of file SolidModel.h.

Referenced by SolidModel::checkElasticConstants().

Real AbaqusUmatMaterial::_SPD
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

Real AbaqusUmatMaterial::_SSE
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

MaterialProperty<std::vector<Real> >& AbaqusUmatMaterial::_state_var
protected

Definition at line 95 of file AbaqusUmatMaterial.h.

Referenced by computeStress(), and initQpStatefulProperties().

const MaterialProperty<std::vector<Real> >& AbaqusUmatMaterial::_state_var_old
protected

Definition at line 96 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

Real* AbaqusUmatMaterial::_STATEV
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), computeStress(), and ~AbaqusUmatMaterial().

bool& SolidModel::_step_one
protectedinherited

Definition at line 255 of file SolidModel.h.

Referenced by SolidModel::applyThermalStrain(), and SolidModel::computeProperties().

bool& SolidModel::_step_zero
protectedinherited

Restartable data to check for the zeroth and first time steps for thermal calculations.

Definition at line 254 of file SolidModel.h.

Referenced by SolidModel::applyThermalStrain(), SolidModel::computeConstitutiveModelStress(), and SolidModel::computeProperties().

bool SolidModel::_store_stress_older
protectedinherited

Definition at line 147 of file SolidModel.h.

SymmTensor SolidModel::_strain_increment
protectedinherited
Real * AbaqusUmatMaterial::_STRAN
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), computeStress(), and ~AbaqusUmatMaterial().

Real * AbaqusUmatMaterial::_STRESS
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), computeStress(), and ~AbaqusUmatMaterial().

MaterialProperty<SymmTensor>& SolidModel::_stress
protectedinherited
Real SolidModel::_stress_free_temp
protectedinherited
SymmTensor SolidModel::_stress_old
protectedinherited
Real AbaqusUmatMaterial::_TEMP
protected

Definition at line 77 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

const VariableGradient& SolidModel::_temp_grad
protectedinherited

Definition at line 94 of file SolidModel.h.

Referenced by SolidModel::computeThermalJvec().

const VariableValue& SolidModel::_temperature
protectedinherited
const VariableValue& SolidModel::_temperature_old
protectedinherited

Definition at line 93 of file SolidModel.h.

Referenced by SolidModel::applyThermalStrain().

std::vector<Real> AbaqusUmatMaterial::_thermal_constants
protected

Definition at line 66 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial().

Real AbaqusUmatMaterial::_TIME[2]
protected

Definition at line 83 of file AbaqusUmatMaterial.h.

Referenced by computeStress().

MaterialProperty<SymmTensor>& SolidModel::_total_strain
protectedinherited
SymmTensor SolidModel::_total_strain_increment
protectedinherited

Definition at line 142 of file SolidModel.h.

Referenced by SolidModel::computeProperties().

const MaterialProperty<SymmTensor>& SolidModel::_total_strain_old
protectedinherited

Definition at line 115 of file SolidModel.h.

Referenced by SolidModel::computeProperties().

umat_t AbaqusUmatMaterial::_umat
protected

Definition at line 74 of file AbaqusUmatMaterial.h.

Referenced by AbaqusUmatMaterial(), and computeStress().

std::map<SubdomainID, std::vector<MooseSharedPointer<VolumetricModel> > > SolidModel::_volumetric_models
protectedinherited

Definition at line 103 of file SolidModel.h.

Referenced by SolidModel::applyVolumetricStrain(), and SolidModel::initialSetup().

Real SolidModel::_youngs_modulus
protectedinherited
Function* SolidModel::_youngs_modulus_function
protectedinherited
bool SolidModel::_youngs_modulus_set
protectedinherited

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