v0.16.3
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Public Attributes | List of all members
ADOLCPlasticity::J2Plasticity< 3 > Struct Reference

J2 (Von Misses) plasticity. More...

#include "users_modules/adolc-plasticity/src/ADOLCPlasticityMaterialModels.hpp"

Inheritance diagram for ADOLCPlasticity::J2Plasticity< 3 >:
[legend]
Collaboration diagram for ADOLCPlasticity::J2Plasticity< 3 >:
[legend]

Public Types

enum  ModelParams {
  LAMBDA , MU , ISOH , KINK ,
  PHI , SIGMA_Y , LAST_PARAM
}
 
using ParamsArray = std::array< double, LAST_PARAM >
 
- Public Types inherited from ADOLCPlasticity::ClosestPointProjection
enum  TypesTags { W = 0 , Y , H , LAST_TAPE }
 

Public Member Functions

 J2Plasticity ()
 
MoFEMErrorCode getDefaultMaterialParameters ()
 
MoFEMErrorCode addMatBlockOps (MoFEM::Interface &m_field, boost::ptr_deque< ForcesAndSourcesCore::UserDataOperator > &pip, std::string block_name, Sev sev)
 Get material parameters from block.
 
MoFEMErrorCode setParams (short tag, bool &recalculate_elastic_tangent)
 Set material parameters at integration point.
 
MoFEMErrorCode freeHemholtzEnergy ()
 [Free energy J2]
 
MoFEMErrorCode evalF ()
 [Yield function J2]
 
MoFEMErrorCode yieldFunction ()
 Set yield function.
 
MoFEMErrorCode flowPotential ()
 [Yield function J2]
 
MoFEMErrorCode codedHessianW (vector< double * > hessian)
 
- Public Member Functions inherited from ADOLCPlasticity::ClosestPointProjection
VectorAdaptor getPlasticStrain ()
 
VectorAdaptor getTotalStrain ()
 
VectorAdaptor getInternalVariables ()
 
VectorAdaptor getActiveVariablesYH ()
 
VectorAdaptor getStress ()
 
VectorAdaptor getInternalFluxes ()
 
 ClosestPointProjection ()
 
MoFEMErrorCode recordW ()
 Record strain energy.
 
MoFEMErrorCode recordY ()
 Record yield function.
 
MoFEMErrorCode recordH ()
 Record flow potential.
 
MoFEMErrorCode playW ()
 
MoFEMErrorCode playW_NoHessian ()
 
MoFEMErrorCode playY ()
 
MoFEMErrorCode playY_NoGradient ()
 
MoFEMErrorCode playH ()
 
MoFEMErrorCode playH_NoHessian ()
 
MoFEMErrorCode createMatAVecR ()
 
MoFEMErrorCode evaluatePotentials ()
 
MoFEMErrorCode playPotentials ()
 
MoFEMErrorCode playPotentials_NoHessian ()
 
MoFEMErrorCode calculateR (Vec R)
 
MoFEMErrorCode calculateA ()
 
MoFEMErrorCode snesCreate ()
 Create nested snes.
 
MoFEMErrorCode solveClosestProjection ()
 Solve nonlinear system of equations to find stress, internal fluxes, and Lagrange plastic multiplier.
 
MoFEMErrorCode consistentTangent ()
 Calculate consistent tangent matrix.
 
MoFEMErrorCode recordTapes ()
 Record tapes.
 

Public Attributes

FTensor::Index< 'i', 3 > i
 
FTensor::Index< 'j', 3 > j
 
FTensor::Index< 'Z', 6 > Z
 
FTensor::Tensor2_symmetric< adouble, 3 > tTotalStrain
 
FTensor::Tensor2_symmetric< adouble, 3 > tPlasticStrain
 
FTensor::Tensor2_symmetric< adouble, 3 > tElasticStrain
 
FTensor::Tensor2_symmetric< adouble, 3 > tInternalTensor
 
FTensor::Tensor2_symmetric< adouble, 3 > tStress
 
FTensor::Tensor2_symmetric< adouble, 3 > tBackStress
 
FTensor::Tensor2_symmetric< adouble, 3 > tDeviator
 
adouble tR
 
double mu
 
double lambda
 
double H
 
double K
 
double phi
 
double sigmaY
 
boost::shared_ptr< ParamsArray > defaultParamsArrayPtr = nullptr
 
boost::shared_ptr< ParamsArray > paramsArrayPtr = nullptr
 
boost::shared_ptr< ParamsArray > oldParamsArrayPtr = nullptr
 
adouble f
 [Free energy J2]
 
- Public Attributes inherited from ADOLCPlasticity::ClosestPointProjection
int nbInternalVariables
 
boost::function< int(int, int, int)> integrationRule
 
VectorDouble internalVariables0
 
VectorDouble plasticStrain0
 
std::array< int, LAST_TAPE > tapesTags
 
VectorAdaptor activeVariablesW
 
VectorAdaptor gradientW
 
double w
 
double y
 
double h
 
double deltaGamma
 
MatrixDouble Ep
 
MatrixDouble Cp
 
MatrixDouble Cep
 
ublas::symmetric_matrix< double, ublas::lower > C
 
ublas::symmetric_matrix< double, ublas::lower > D
 
PetscBool implHessianW
 
MatrixDouble hessianW
 
VectorDouble gradientY
 
VectorDouble gradientH
 
MatrixDouble hessianH
 
MatrixDouble partialWStrainPlasticStrain
 
VectorAdaptor partialYSigma
 
VectorAdaptor partialYFlux
 
VectorAdaptor partialHSigma
 
VectorAdaptor partialHFlux
 
ublas::symmetric_matrix< double, ublas::lower > partial2HSigma
 
ublas::symmetric_matrix< double, ublas::lower > partial2HFlux
 
MatrixDouble partial2HSigmaFlux
 
SmartPetscObj< Mat > A
 
SmartPetscObj< Vec > R
 
SmartPetscObj< Vec > Chi
 
SmartPetscObj< Vec > dChi
 
ublas::matrix< double, ublas::column_major > dataA
 
SmartPetscObj< SNES > sNes
 
ublas::vector< adouble > a_sTrain
 
ublas::vector< adouble > a_plasticStrain
 
ublas::vector< adouble > a_internalVariables
 
ublas::vector< adouble > a_sTress
 
ublas::vector< adouble > a_internalFluxes
 
adouble a_w
 
adouble a_y
 
adouble a_h
 

Detailed Description

J2 (Von Misses) plasticity.

Free energy:

\[ \psi(\varepsilon^e, \alpha, \beta) = \frac{1}{2} \lambda \textrm{tr}[\varepsilon^e]^2 + \mu \varepsilon^e : \varepsilon^e + \sigma_y\alpha + \frac{1}{2} \phi H \alpha^2 + \frac{1}{2} (1-\phi)K \beta^2 \]

Isotropic hardening variable \(\alpha\) is in first index of internal variables vector. Kinematic hardening variable is in the remaining indices of internal variables vector.

Yield function:

Deviator of actual stress:

\[ \eta=\textrm{dev}[\sigma]-\overline{\beta} \]

where \(\overline{\beta}\) is back stress.

Square of the deviator norm

\[ f = \frac{3}{2} \eta:\eta \]

Yield function:

\[ y = \sqrt{f} - \overline{\alpha} \]

where \(f\) is defined in eva

This is associated potential model, so flow potential is equal to yield

Definition at line 74 of file ADOLCPlasticityMaterialModels.hpp.

Member Typedef Documentation

◆ ParamsArray

using ADOLCPlasticity::J2Plasticity< 3 >::ParamsArray = std::array<double, LAST_PARAM>

Definition at line 104 of file ADOLCPlasticityMaterialModels.hpp.

Member Enumeration Documentation

◆ ModelParams

enum ADOLCPlasticity::J2Plasticity< 3 >::ModelParams

Constructor & Destructor Documentation

◆ J2Plasticity()

ADOLCPlasticity::J2Plasticity< 3 >::J2Plasticity ( )
inline

Member Function Documentation

◆ addMatBlockOps()

MoFEMErrorCode ADOLCPlasticity::J2Plasticity< 3 >::addMatBlockOps ( MoFEM::Interface &  m_field,
boost::ptr_deque< ForcesAndSourcesCore::UserDataOperator > &  pip,
std::string  block_name,
Sev  sev 
)
inlinevirtual

Get material parameters from block.

Parameters
m_field
pip
block_name
sev
Returns
MoFEMErrorCode

Reimplemented from ADOLCPlasticity::ClosestPointProjection.

Definition at line 177 of file ADOLCPlasticityMaterialModels.hpp.

179 {
181
182 struct OpMatBlocks : public ForcesAndSourcesCore::UserDataOperator {
183
184 using OP = ForcesAndSourcesCore::UserDataOperator;
185
186 OpMatBlocks(boost::shared_ptr<ParamsArray> params_array_ptr,
187 boost::shared_ptr<ParamsArray> def_params_array_otr,
188 MoFEM::Interface &m_field, Sev sev,
189 std::vector<const CubitMeshSets *> meshset_vec_ptr)
190 : OP(NOSPACE, OP::OPSPACE), paramsArrayPtr(params_array_ptr),
191 defParamsArray(def_params_array_otr) {
192 CHK_THROW_MESSAGE(extractBlockData(m_field, meshset_vec_ptr, sev),
193 "Can not get data from block");
194 }
195
196 MoFEMErrorCode doWork(int side, EntityType type,
197 EntitiesFieldData::EntData &data) {
199
200 for (auto &b : blockData) {
201
202 if (b.blockEnts.find(getFEEntityHandle()) != b.blockEnts.end()) {
203 std::copy(b.paramsArray.begin(), b.paramsArray.end(),
204 paramsArrayPtr->begin());
206 }
207 }
208
209 std::copy(defParamsArray->begin(), defParamsArray->end(),
210 paramsArrayPtr->begin());
211
213 }
214
215 private:
216 boost::shared_ptr<ParamsArray> paramsArrayPtr;
217 boost::shared_ptr<ParamsArray> defParamsArray;
218
219 struct BlockData {
220 ParamsArray paramsArray;
221 Range blockEnts;
222 };
223
224 std::vector<BlockData> blockData;
225
227 extractBlockData(MoFEM::Interface &m_field,
228 std::vector<const CubitMeshSets *> meshset_vec_ptr,
229 Sev sev) {
231
232 for (auto m : meshset_vec_ptr) {
233 MOFEM_TAG_AND_LOG("ADOLCPlasticityWold", sev, "JP2 parameters") << *m;
234 std::vector<double> block_data;
235 CHKERR m->getAttributes(block_data);
236 if (block_data.size() != 6) {
237 SETERRQ(PETSC_COMM_SELF, MOFEM_DATA_INCONSISTENCY,
238 "Expected that block has two attribute");
239 }
240 auto get_block_ents = [&]() {
241 Range ents;
242 CHKERR
243 m_field.get_moab().get_entities_by_handle(m->meshset, ents, true);
244 return ents;
245 };
246
247 blockData.push_back({*defParamsArray, get_block_ents()});
248 std::copy(block_data.begin(), block_data.end(),
249 blockData.back().paramsArray.begin());
250 const auto young_modulus = blockData.back().paramsArray[LAMBDA];
251 const auto poisson_ratio = blockData.back().paramsArray[MU];
252
253 // It is assumed that user provide young_modulus and poisson_ratio in
254 // first two arguments of the block
255
256 MOFEM_LOG("ADOLCPlasticityWold", sev)
257 << "Young modulus: " << (blockData.back().paramsArray)[LAMBDA];
258 MOFEM_LOG("ADOLCPlasticityWold", sev)
259 << "Poisson ratio: " << (blockData.back().paramsArray)[MU];
260
261 blockData.back().paramsArray[LAMBDA] =
263 blockData.back().paramsArray[MU] = MU(young_modulus, poisson_ratio);
264
265 MOFEM_LOG("ADOLCPlasticityWold", sev)
266 << "LAMBDA: " << (blockData.back().paramsArray)[LAMBDA];
267 MOFEM_LOG("ADOLCPlasticityWold", sev)
268 << "MU: " << (blockData.back().paramsArray)[MU];
269 MOFEM_LOG("ADOLCPlasticityWold", sev)
270 << "H: " << (blockData.back().paramsArray)[ISOH];
271 MOFEM_LOG("ADOLCPlasticityWold", sev)
272 << "K: " << (blockData.back().paramsArray)[KINK];
273 MOFEM_LOG("ADOLCPlasticityWold", sev)
274 << "PHI: " << (blockData.back().paramsArray)[PHI];
275 MOFEM_LOG("ADOLCPlasticityWold", sev)
276 << "SIGMA_Y: " << (blockData.back().paramsArray)[SIGMA_Y];
277 }
279 }
280 };
281
282 auto cubit_meshsets_vec_ptr =
283 m_field.getInterface<MeshsetsManager>()->getCubitMeshsetPtr(
284 std::regex((boost::format("%s(.*)") % block_name).str()));
285
286 pip.push_back(new OpMatBlocks(paramsArrayPtr, defaultParamsArrayPtr,
287 m_field, sev, cubit_meshsets_vec_ptr));
288
290 }
std::string type
#define MOFEM_TAG_AND_LOG(channel, severity, tag)
Tag and log in channel.
#define CHK_THROW_MESSAGE(err, msg)
Check and throw MoFEM exception.
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
@ NOSPACE
Definition definitions.h:83
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
@ MOFEM_DATA_INCONSISTENCY
Definition definitions.h:31
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
#define CHKERR
Inline error check.
#define MU(E, NU)
Definition fem_tools.h:23
#define LAMBDA(E, NU)
Definition fem_tools.h:22
#define MOFEM_LOG(channel, severity)
Log.
PetscErrorCode MoFEMErrorCode
MoFEM/PETSc error code.
double young_modulus
Young modulus.
Definition plastic.cpp:126
double poisson_ratio
Poisson ratio.
Definition plastic.cpp:127
FTensor::Index< 'm', 3 > m
boost::shared_ptr< ParamsArray > defaultParamsArrayPtr
boost::shared_ptr< ParamsArray > paramsArrayPtr
virtual moab::Interface & get_moab()=0
Deprecated interface functions.
MoFEMErrorCode getInterface(IFACE *&iface) const
Get interface reference to pointer of interface.

◆ codedHessianW()

MoFEMErrorCode ADOLCPlasticity::J2Plasticity< 3 >::codedHessianW ( vector< double * >  hessian)
inlinevirtual

Reimplemented from ADOLCPlasticity::ClosestPointProjection.

Definition at line 409 of file ADOLCPlasticityMaterialModels.hpp.

409 {
411 lambda = (*paramsArrayPtr)[0];
412 mu = (*paramsArrayPtr)[1];
413 H = (*paramsArrayPtr)[5];
414
415 double lambda_plus_2mu = lambda + 2 * mu;
416 // first 6x6 is \frac{\partial^2 \psi}{\partial \varepsilon^p^2}
417 // lower symmetric part
418 // Diagonal elements
419 hessian[0][0] = lambda_plus_2mu;
420 hessian[1][1] = lambda_plus_2mu;
421 hessian[2][2] = lambda_plus_2mu;
422
423 // Off-diagonal elements
424 hessian[1][0] = lambda;
425 hessian[2][0] = lambda;
426 hessian[2][1] = lambda;
427
428 // Shear components
429 for (int i = 3; i <= 5; ++i) {
430 hessian[i][i] = mu;
431 }
432
433 // next 6x6 is \frac{\partial^2 \psi}{\partial \varepsilon \partial
434 // \varepsilon^p}
435 double neg_lambda_plus_2mu = -(lambda + 2 * mu);
436 double neg_lambda = -lambda;
437 double neg_mu = -mu;
438
439 for (int i = 6; i <= 8; ++i) {
440 for (int j = 0; j <= 2; ++j) {
441 hessian[i][j] = (i - 6 == j) ? neg_lambda_plus_2mu : neg_lambda;
442 }
443 }
444
445 hessian[9][3] = neg_mu;
446 hessian[10][4] = neg_mu;
447 hessian[11][5] = neg_mu;
448
449 // next 6x6 is \frac{\partial^2 \psi}{\partial \varepsilon \partial
450 // \varepsilon}
451 hessian[6][6] = lambda_plus_2mu;
452 hessian[7][6] = lambda;
453 hessian[7][7] = lambda_plus_2mu;
454 hessian[8][6] = lambda;
455 hessian[8][7] = lambda;
456 hessian[8][8] = lambda_plus_2mu;
457 hessian[9][9] = mu;
458 hessian[10][10] = mu;
459 hessian[11][11] = mu;
460
461 // internalVariables is \frac{\partial^2 \psi}{\partial \alpha^2}
462 hessian[12][12] = H;
463
465 }

◆ evalF()

MoFEMErrorCode ADOLCPlasticity::J2Plasticity< 3 >::evalF ( )
inline

[Yield function J2]

Definition at line 375 of file ADOLCPlasticityMaterialModels.hpp.

375 {
377 auto t_voight_stress_op = voight_to_stress_op();
378 auto t_vioght_stress = getFTensor1FromPtr<6>(&a_sTress[0]);
379 auto t_back_stress = getFTensor1FromPtr<6>(&a_internalFluxes[1]);
380 tStress(i, j) = t_voight_stress_op(i, j, Z) * t_vioght_stress(Z);
381 tBackStress(i, j) = t_voight_stress_op(i, j, Z) * t_back_stress(Z);
382
384 tR = tStress(i, i) / 3.;
385 tDeviator(i, j) = tStress(i, j) - tR * t_kd(i, j) - tBackStress(i, j);
386
387 // Fix the constant to mach uniaxial test
388 constexpr double c = 3. / 2.;
389 f = c * tDeviator(i, j) * tDeviator(i, j);
390
392 }
Kronecker Delta class symmetric.
constexpr auto t_kd
const double c
speed of light (cm/ns)
FTensor::Dg< double, 3, 6 > voight_to_stress_op()
Op convert Vight stress vector to stress tensor.
FTensor::Tensor2_symmetric< adouble, 3 > tDeviator
FTensor::Tensor2_symmetric< adouble, 3 > tStress
FTensor::Tensor2_symmetric< adouble, 3 > tBackStress

◆ flowPotential()

MoFEMErrorCode ADOLCPlasticity::J2Plasticity< 3 >::flowPotential ( )
inlinevirtual

[Yield function J2]

Implements ADOLCPlasticity::ClosestPointProjection.

Definition at line 402 of file ADOLCPlasticityMaterialModels.hpp.

◆ freeHemholtzEnergy()

MoFEMErrorCode ADOLCPlasticity::J2Plasticity< 3 >::freeHemholtzEnergy ( )
inlinevirtual

[Free energy J2]

Implements ADOLCPlasticity::ClosestPointProjection.

Definition at line 326 of file ADOLCPlasticityMaterialModels.hpp.

326 {
328
329 // ADOL-C register parameters (those can varied for integration points)
330 auto p_lambda = mkparam(lambda); // 0
331 auto p_mu = mkparam(mu); // 1
332 auto p_H = mkparam(H); // 2
333 auto p_K = mkparam(K); // 3
334 auto p_phi = mkparam(phi); // 4
335 auto p_sigma_y = mkparam(sigmaY); // 5
336
337 // Operator converting Voight and tensor notation
338 auto t_voight_strain_op = voight_to_strain_op();
339
340 // Variable in voight notation
341 auto t_voight_total_strain = getFTensor1FromPtr<6>(&a_sTrain[0]);
342 auto t_voight_plastic_strain = getFTensor1FromPtr<6>(&a_plasticStrain[0]);
343 auto t_voight_internal_tensor =
344 getFTensor1FromPtr<6>(&a_internalVariables[1]);
345
346 // Convert variables to tensor notation
347 tTotalStrain(i, j) = t_voight_strain_op(i, j, Z) * t_voight_total_strain(Z);
348 tPlasticStrain(i, j) =
349 t_voight_strain_op(i, j, Z) * t_voight_plastic_strain(Z);
351 t_voight_strain_op(i, j, Z) * t_voight_internal_tensor(Z);
352
353 // Evaluate elastic strain
355 tR = tElasticStrain(i, i);
356
357 // Strain energy
358 a_w = 0.5 * p_lambda * tR * tR +
359 p_mu * (tElasticStrain(i, j) * tElasticStrain(i, j));
360 // Isotropic strain energy
361 a_w +=
362 a_internalVariables[0] * p_sigma_y +
363 0.5 * p_phi * p_H * (a_internalVariables[0] * a_internalVariables[0]);
364 // Kinematic strain energy
365 a_w += (0.5 * (1 - p_phi) * p_K) *
367
369 }
FTensor::Dg< double, 3, 6 > voight_to_strain_op()
Op convert Vight strain vector to strain tensor.
FTensor::Tensor2_symmetric< adouble, 3 > tInternalTensor
FTensor::Tensor2_symmetric< adouble, 3 > tPlasticStrain
FTensor::Tensor2_symmetric< adouble, 3 > tTotalStrain
FTensor::Tensor2_symmetric< adouble, 3 > tElasticStrain

◆ getDefaultMaterialParameters()

MoFEMErrorCode ADOLCPlasticity::J2Plasticity< 3 >::getDefaultMaterialParameters ( )
inline

Definition at line 109 of file ADOLCPlasticityMaterialModels.hpp.

109 {
111
112 double young_modulus = 1;
113 double poisson_ratio = 0.25;
114 sigmaY = 1;
115 H = 0.1;
116 K = 0;
117 phi = 1;
118
119 CHKERR PetscOptionsGetScalar(PETSC_NULLPTR, "-young_modulus",
120 &young_modulus, PETSC_NULLPTR);
121 CHKERR PetscOptionsGetScalar(PETSC_NULLPTR, "-poisson_ratio",
122 &poisson_ratio, 0);
123 CHKERR PetscOptionsGetScalar(PETSC_NULLPTR, "-sigma_y", &sigmaY,
124 PETSC_NULLPTR);
125 CHKERR PetscOptionsGetScalar(PETSC_NULLPTR, "-H", &H, PETSC_NULLPTR);
126 CHKERR PetscOptionsGetScalar(PETSC_NULLPTR, "-K", &K, PETSC_NULLPTR);
127 CHKERR PetscOptionsGetScalar(PETSC_NULLPTR, "-phi", &phi, PETSC_NULLPTR);
128
129 MOFEM_LOG("ADOLCPlasticityWold", Sev::inform)
130 << "Young modulus: " << young_modulus;
131 MOFEM_LOG("ADOLCPlasticityWold", Sev::inform)
132 << "Poisson ratio: " << poisson_ratio;
133
136
137 defaultParamsArrayPtr = boost::make_shared<ParamsArray>();
138 (*defaultParamsArrayPtr)[LAMBDA] = lambda;
139 (*defaultParamsArrayPtr)[MU] = mu;
140 (*defaultParamsArrayPtr)[ISOH] = H;
141 (*defaultParamsArrayPtr)[KINK] = K;
142 (*defaultParamsArrayPtr)[PHI] = phi;
143 (*defaultParamsArrayPtr)[SIGMA_Y] = sigmaY;
144
145 MOFEM_LOG("ADOLCPlasticityWold", Sev::inform)
146 << "LAMBDA: " << (*defaultParamsArrayPtr)[LAMBDA];
147 MOFEM_LOG("ADOLCPlasticityWold", Sev::inform)
148 << "MU: " << (*defaultParamsArrayPtr)[MU];
149 MOFEM_LOG("ADOLCPlasticityWold", Sev::inform)
150 << "H: " << (*defaultParamsArrayPtr)[ISOH];
151 MOFEM_LOG("ADOLCPlasticityWold", Sev::inform)
152 << "K: " << (*defaultParamsArrayPtr)[KINK];
153 MOFEM_LOG("ADOLCPlasticityWold", Sev::inform)
154 << "PHI: " << (*defaultParamsArrayPtr)[PHI];
155 MOFEM_LOG("ADOLCPlasticityWold", Sev::inform)
156 << "SIGMA_Y: " << (*defaultParamsArrayPtr)[SIGMA_Y];
157
158 paramsArrayPtr = boost::make_shared<ParamsArray>();
159 std::copy(defaultParamsArrayPtr->begin(), defaultParamsArrayPtr->end(),
160 paramsArrayPtr->begin());
161 oldParamsArrayPtr = boost::make_shared<ParamsArray>();
162 std::fill(oldParamsArrayPtr->begin(), oldParamsArrayPtr->end(), 0);
163
165 };
PetscErrorCode PetscOptionsGetScalar(PetscOptions *, const char pre[], const char name[], PetscScalar *dval, PetscBool *set)
boost::shared_ptr< ParamsArray > oldParamsArrayPtr

◆ setParams()

MoFEMErrorCode ADOLCPlasticity::J2Plasticity< 3 >::setParams ( short  tag,
bool &  recalculate_elastic_tangent 
)
inlinevirtual

Set material parameters at integration point.

Parameters
tag
recalculate_elastic_tangent
Returns
MoFEMErrorCode

Reimplemented from ADOLCPlasticity::ClosestPointProjection.

Definition at line 299 of file ADOLCPlasticityMaterialModels.hpp.

299 {
301 switch (tag) {
302 case TypesTags::W: {
303 set_param_vec(tapesTags[tag], paramsArrayPtr->size(),
304 paramsArrayPtr->data());
305 for (auto p = 0; p != LAST_PARAM; p++) {
306 if ((*paramsArrayPtr)[p] != (*oldParamsArrayPtr)[p]) {
307 recalculate_elastic_tangent = true;
308 std::copy(paramsArrayPtr->begin(), paramsArrayPtr->end(),
309 oldParamsArrayPtr->begin());
310 break;
311 }
312 }
313
314 } break;
315 case TypesTags::Y:
316 case TypesTags::H:
317 break;
318 default:
319 SETERRQ(PETSC_COMM_SELF, MOFEM_DATA_INCONSISTENCY,
320 "Unknown tag for setParams");
321 }
323 }
Tag tag
std::array< int, LAST_TAPE > tapesTags

◆ yieldFunction()

MoFEMErrorCode ADOLCPlasticity::J2Plasticity< 3 >::yieldFunction ( )
inlinevirtual

Set yield function.

Implements ADOLCPlasticity::ClosestPointProjection.

Definition at line 394 of file ADOLCPlasticityMaterialModels.hpp.

Member Data Documentation

◆ defaultParamsArrayPtr

boost::shared_ptr<ParamsArray> ADOLCPlasticity::J2Plasticity< 3 >::defaultParamsArrayPtr = nullptr

Definition at line 105 of file ADOLCPlasticityMaterialModels.hpp.

◆ f

[Free energy J2]

Definition at line 372 of file ADOLCPlasticityMaterialModels.hpp.

◆ H

Definition at line 97 of file ADOLCPlasticityMaterialModels.hpp.

◆ i

Definition at line 81 of file ADOLCPlasticityMaterialModels.hpp.

◆ j

Definition at line 82 of file ADOLCPlasticityMaterialModels.hpp.

◆ K

Definition at line 98 of file ADOLCPlasticityMaterialModels.hpp.

◆ lambda

Definition at line 96 of file ADOLCPlasticityMaterialModels.hpp.

◆ mu

Definition at line 95 of file ADOLCPlasticityMaterialModels.hpp.

◆ oldParamsArrayPtr

boost::shared_ptr<ParamsArray> ADOLCPlasticity::J2Plasticity< 3 >::oldParamsArrayPtr = nullptr

Definition at line 107 of file ADOLCPlasticityMaterialModels.hpp.

◆ paramsArrayPtr

boost::shared_ptr<ParamsArray> ADOLCPlasticity::J2Plasticity< 3 >::paramsArrayPtr = nullptr

Definition at line 106 of file ADOLCPlasticityMaterialModels.hpp.

◆ phi

Definition at line 99 of file ADOLCPlasticityMaterialModels.hpp.

◆ sigmaY

Definition at line 100 of file ADOLCPlasticityMaterialModels.hpp.

◆ tBackStress

Definition at line 90 of file ADOLCPlasticityMaterialModels.hpp.

◆ tDeviator

Definition at line 91 of file ADOLCPlasticityMaterialModels.hpp.

◆ tElasticStrain

Definition at line 87 of file ADOLCPlasticityMaterialModels.hpp.

◆ tInternalTensor

Definition at line 88 of file ADOLCPlasticityMaterialModels.hpp.

◆ tPlasticStrain

Definition at line 86 of file ADOLCPlasticityMaterialModels.hpp.

◆ tR

Definition at line 93 of file ADOLCPlasticityMaterialModels.hpp.

◆ tStress

Definition at line 89 of file ADOLCPlasticityMaterialModels.hpp.

◆ tTotalStrain

Definition at line 85 of file ADOLCPlasticityMaterialModels.hpp.

◆ Z

Definition at line 83 of file ADOLCPlasticityMaterialModels.hpp.


The documentation for this struct was generated from the following file: