https://mooseframework.inl.gov
Loading...
Searching...
No Matches
ComplianceSensitivity.C
Go to the documentation of this file.
1//* This file is part of the MOOSE framework
2//* https://mooseframework.inl.gov
3//*
4//* All rights reserved, see COPYRIGHT for full restrictions
5//* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6//*
7//* Licensed under LGPL 2.1, please see LICENSE for details
8//* https://www.gnu.org/licenses/lgpl-2.1.html
9
11
13
16{
18 params.addClassDescription("Computes compliance sensitivity needed for SIMP method.");
19 params.addRequiredCoupledVar("design_density", "Design density variable name.");
20 params.addRequiredParam<MaterialPropertyName>("youngs_modulus",
21 "DerivativeParsedMaterial for Youngs modulus.");
22
23 return params;
24}
25
27 : StrainEnergyDensity(parameters),
28 _sensitivity(declareProperty<Real>(_base_name + "sensitivity")),
29 _design_density(coupledValue("design_density")),
30 _design_density_name(coupledName("design_density", 0)),
31 _dEdp(getMaterialPropertyDerivativeByName<Real>(
32 getParam<MaterialPropertyName>("youngs_modulus"), _design_density_name)),
33 _youngs_modulus(getMaterialProperty<Real>(getParam<MaterialPropertyName>("youngs_modulus")))
34{
35}
36
37void
39{
40 // Call the parent class's method to compute the strain energy density
43}
registerMooseObject("SolidMechanicsApp", ComplianceSensitivity)
Computes the elasticity compliance sensitivity with respect to a user-supplied variable.
const MaterialProperty< Real > & _youngs_modulus
Young's modulus of the material.
MaterialProperty< Real > & _sensitivity
Sensitivity material generated by this error.
virtual void computeQpProperties() override
static InputParameters validParams()
ComplianceSensitivity(const InputParameters &parameters)
const MaterialProperty< Real > & _dEdp
Derivative of elasticity modulus with respect to pseudo-density.
void addRequiredCoupledVar(const std::string &name, const std::string &doc_string)
void addRequiredParam(const std::string &name, const std::string &doc_string)
void addClassDescription(const std::string &doc_string)
StrainEnergyDensity calculates the strain energy density.
virtual void computeQpProperties() override
static InputParameters validParams()
MaterialProperty< Real > & _strain_energy_density
The strain energy density material property.