www.mooseframework.org
OutOfPlaneStress.C
Go to the documentation of this file.
1 /****************************************************************/
2 /* MOOSE - Multiphysics Object Oriented Simulation Environment */
3 /* */
4 /* All contents are licensed under LGPL V2.1 */
5 /* See LICENSE for full restrictions */
6 /****************************************************************/
7 
8 #include "OutOfPlaneStress.h"
9 
10 #include "Material.h"
11 #include "SymmElasticityTensor.h"
12 
13 template <>
14 InputParameters
16 {
17  InputParameters params = validParams<Kernel>();
18  params.addCoupledVar("disp_x", "The x displacement");
19  params.addCoupledVar("disp_y", "The y displacement");
20  params.addCoupledVar("temp", "The temperature");
21  params.addParam<std::string>(
22  "appended_property_name", "", "Name appended to material properties to make them unique");
23 
24  params.set<bool>("use_displaced_mesh") = true;
25 
26  return params;
27 }
28 
29 OutOfPlaneStress::OutOfPlaneStress(const InputParameters & parameters)
30  : Kernel(parameters),
31  _stress(getMaterialProperty<SymmTensor>("stress" +
32  getParam<std::string>("appended_property_name"))),
33  _Jacobian_mult(getMaterialProperty<SymmElasticityTensor>(
34  "Jacobian_mult" + getParam<std::string>("appended_property_name"))),
35  _d_stress_dT(getMaterialProperty<SymmTensor>("d_stress_dT" +
36  getParam<std::string>("appended_property_name"))),
37  _xdisp_coupled(isCoupled("disp_x")),
38  _ydisp_coupled(isCoupled("disp_y")),
39  _temp_coupled(isCoupled("temp")),
40  _xdisp_var(_xdisp_coupled ? coupled("disp_x") : 0),
41  _ydisp_var(_ydisp_coupled ? coupled("disp_y") : 0),
42  _temp_var(_temp_coupled ? coupled("temp") : 0)
43 {
44 }
45 
46 Real
48 {
49  return _stress[_qp].component(2) * _test[_i][_qp];
50 }
51 
52 Real
54 {
55  Real C33 = _Jacobian_mult[_qp].valueAtIndex(11);
56  return C33 * _test[_i][_qp] * _phi[_j][_qp];
57 }
58 
59 Real
61 {
62  return 0;
63 }
This class defines a basic set of capabilities any elasticity tensor should have. ...
virtual Real computeQpResidual()
virtual Real computeQpOffDiagJacobian(unsigned int jvar)
const MaterialProperty< SymmTensor > & _stress
const MaterialProperty< SymmElasticityTensor > & _Jacobian_mult
InputParameters validParams< OutOfPlaneStress >()
OutOfPlaneStress(const InputParameters &parameters)
virtual Real computeQpJacobian()