KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
generic_cl_integrator_plasticity.h
Go to the documentation of this file.
1 // KRATOS ___ _ _ _ _ _ __ _
2 // / __\___ _ __ ___| |_(_) |_ _ _| |_(_)_ _____ / / __ ___ _____ /_\ _ __ _ __
3 // / / / _ \| '_ \/ __| __| | __| | | | __| \ \ / / _ \/ / / _` \ \ /\ / / __| //_\\| '_ \| '_ |
4 // / /__| (_) | | | \__ \ |_| | |_| |_| | |_| |\ V / __/ /__| (_| |\ V V /\__ \/ _ \ |_) | |_) |
5 // \____/\___/|_| |_|___/\__|_|\__|\__,_|\__|_| \_/ \___\____/\__,_| \_/\_/ |___/\_/ \_/ .__/| .__/
6 // |_| |_|
7 //
8 // License: BSD License
9 // license: structural_mechanics_application/license.txt
10 //
11 // Main authors: Alejandro Cornejo
12 // Lucia Barbu
13 // Sergio Jimenez
14 //
15 
16 #pragma once
17 
18 // System includes
19 
20 // Project includes
21 #include "includes/define.h"
22 #include "includes/checks.h"
23 #include "includes/properties.h"
24 #include "utilities/math_utils.h"
27 
28 namespace Kratos
29 {
32 
36 
37  // The size type definition
38  typedef std::size_t SizeType;
39 
43 
47 
51 
68 template<class TYieldSurfaceType>
70 {
71  public:
74 
76  static constexpr double tolerance = std::numeric_limits<double>::epsilon();
77 
79  typedef std::size_t IndexType;
80 
82  typedef TYieldSurfaceType YieldSurfaceType;
83 
85  static constexpr SizeType Dimension = YieldSurfaceType::Dimension;
86 
88  static constexpr SizeType VoigtSize = YieldSurfaceType::VoigtSize;
89 
91  typedef typename YieldSurfaceType::PlasticPotentialType PlasticPotentialType;
92 
95 
99 
101  {
102  LinearSoftening = 0,
105  PerfectPlasticity = 3,
109  };
110 
114 
117  {
118  }
119 
122  {
123  }
124 
127  {
128  return *this;
129  }
130 
133  {
134  }
135 
139 
143 
161  array_1d<double, VoigtSize>& rPredictiveStressVector,
162  Vector& rStrainVector,
163  double& rUniaxialStress,
164  double& rThreshold,
165  double& rPlasticDenominator,
168  double& rPlasticDissipation,
169  array_1d<double, VoigtSize>& rPlasticStrainIncrement,
170  Matrix& rConstitutiveMatrix,
171  Vector& rPlasticStrain,
173  const double CharacteristicLength
174  )
175  {
176  // Material properties
177  const Properties& r_material_properties = rValues.GetMaterialProperties();
178 
179  bool is_converged = false;
180  IndexType iteration = 0, max_iter = r_material_properties.Has(MAX_NUMBER_NL_CL_ITERATIONS)
181  ? r_material_properties.GetValue(MAX_NUMBER_NL_CL_ITERATIONS) : 100;
182  array_1d<double, VoigtSize> delta_sigma;
183  double plastic_consistency_factor_increment;
184  double F = rUniaxialStress - rThreshold;
185  const bool analytic_tangent = (r_material_properties.Has(TANGENT_OPERATOR_ESTIMATION) && r_material_properties[TANGENT_OPERATOR_ESTIMATION] == 0) ? true : false;
186 
187  // Backward Euler
188  while (!is_converged && iteration <= max_iter) {
189  plastic_consistency_factor_increment = F * rPlasticDenominator;
190  plastic_consistency_factor_increment = (plastic_consistency_factor_increment < 0.0) ? 0.0 : plastic_consistency_factor_increment;
191  noalias(rPlasticStrainIncrement) = plastic_consistency_factor_increment * rGflux;
192  noalias(rPlasticStrain) += rPlasticStrainIncrement;
193  noalias(delta_sigma) = prod(rConstitutiveMatrix, rPlasticStrainIncrement);
194 
195  noalias(rPredictiveStressVector) -= delta_sigma;
196 
197  F = CalculatePlasticParameters(rPredictiveStressVector, rStrainVector, rUniaxialStress, rThreshold, rPlasticDenominator, rFflux, rGflux, rPlasticDissipation, rPlasticStrainIncrement, rConstitutiveMatrix, rValues, CharacteristicLength, rPlasticStrain);
198 
199  if (F <= std::abs(1.0e-4 * rThreshold)) { // Has converged
200  is_converged = true;
201  } else {
202  iteration++;
203  }
204  }
205  if (analytic_tangent) {
206  Matrix tangent_tensor;
207  tangent_tensor.resize(VoigtSize, VoigtSize, false);
208  CalculateTangentMatrix(tangent_tensor, rConstitutiveMatrix, rFflux, rGflux, rPlasticDenominator);
209  noalias(rConstitutiveMatrix) = tangent_tensor;
210  }
211  KRATOS_WARNING_IF("GenericConstitutiveLawIntegratorPlasticity", iteration > max_iter) << "Maximum number of iterations in plasticity loop reached..." << std::endl;
212  }
213 
231  array_1d<double, VoigtSize>& rPredictiveStressVector,
232  Vector& rStrainVector,
233  double& rUniaxialStress,
234  double& rThreshold,
235  double& rPlasticDenominator,
238  double& rPlasticDissipation,
239  array_1d<double, VoigtSize>& rPlasticStrainIncrement,
240  const Matrix& rConstitutiveMatrix,
242  const double CharacteristicLength,
243  const Vector& rPlasticStrain
244  )
245  {
248  double J2, tensile_indicator_factor, compression_indicator_factor, slope, hardening_parameter, equivalent_plastic_strain;
249 
250  YieldSurfaceType::CalculateEquivalentStress( rPredictiveStressVector, rStrainVector, rUniaxialStress, rValues);
251  const double I1 = rPredictiveStressVector[0] + rPredictiveStressVector[1] + rPredictiveStressVector[2];
252  AdvancedConstitutiveLawUtilities<VoigtSize>::CalculateJ2Invariant(rPredictiveStressVector, I1, deviator, J2);
253  CalculateFFluxVector(rPredictiveStressVector, deviator, J2, rFflux, rValues);
254  CalculateGFluxVector(rPredictiveStressVector, deviator, J2, rGflux, rValues);
255  CalculateIndicatorsFactors(rPredictiveStressVector, tensile_indicator_factor,compression_indicator_factor);
256  CalculatePlasticDissipation(rPredictiveStressVector, tensile_indicator_factor,compression_indicator_factor, rPlasticStrainIncrement,rPlasticDissipation, h_capa, rValues, CharacteristicLength);
257  CalculateEquivalentPlasticStrain(rPredictiveStressVector, rUniaxialStress, rPlasticStrain, tensile_indicator_factor, rValues, equivalent_plastic_strain);
258  CalculateEquivalentStressThreshold(rPlasticDissipation, tensile_indicator_factor,compression_indicator_factor, rThreshold, slope, rValues, equivalent_plastic_strain, CharacteristicLength);
259  CalculateHardeningParameter(rGflux, slope, h_capa, hardening_parameter);
260  CalculatePlasticDenominator(rFflux, rGflux, rConstitutiveMatrix, hardening_parameter, rPlasticDenominator);
261 
262  return rUniaxialStress - rThreshold;
263  }
264 
274  Matrix& rTangent,
275  const Matrix& rElasticMatrix,
276  const array_1d<double, VoigtSize>& rFFluxVector,
277  const array_1d<double, VoigtSize>& rGFluxVector,
278  const double Denominator
279  )
280  {
281  rTangent = rElasticMatrix - outer_prod(Vector(prod(rElasticMatrix, rGFluxVector)), Vector(prod(rElasticMatrix, rFFluxVector))) * Denominator;
282  }
283 
284 
293  static void CalculateFFluxVector(
294  const array_1d<double, VoigtSize>& rPredictiveStressVector,
295  const array_1d<double, VoigtSize>& rDeviator,
296  const double J2,
297  array_1d<double, VoigtSize>& rFFluxVector,
299  )
300  {
301  YieldSurfaceType::CalculateYieldSurfaceDerivative(rPredictiveStressVector, rDeviator, J2, rFFluxVector, rValues);
302  }
303 
312  static void CalculateGFluxVector(
313  const array_1d<double, VoigtSize>& rPredictiveStressVector,
314  const array_1d<double, VoigtSize>& rDeviator,
315  const double J2,
316  array_1d<double, VoigtSize>& rGFluxVector,
318  )
319  {
320  YieldSurfaceType::CalculatePlasticPotentialDerivative(rPredictiveStressVector, rDeviator, J2, rGFluxVector, rValues);
321  }
322 
330  const array_1d<double, VoigtSize>& rPredictiveStressVector,
331  double& rTensileIndicatorFactor,
332  double& rCompressionIndicatorFactor
333  )
334  {
335  // We do an initial check
336  if (norm_2(rPredictiveStressVector) < 1.0e-8) {
337  rTensileIndicatorFactor = 1.0;
338  rCompressionIndicatorFactor = 0.0;
339  return;
340  }
341 
342  // We proceed as usual
343  array_1d<double, Dimension> principal_stresses = ZeroVector(Dimension);
344  AdvancedConstitutiveLawUtilities<VoigtSize>::CalculatePrincipalStresses(principal_stresses, rPredictiveStressVector);
345 
346  double suma = 0.0, sumb = 0.0, sumc = 0.0;
347  double aux_sa;
348 
349  for (IndexType i = 0; i < Dimension; ++i) {
350  aux_sa = std::abs(principal_stresses[i]);
351  suma += aux_sa;
352  sumb += 0.5 * (principal_stresses[i] + aux_sa);
353  sumc += 0.5 * (-principal_stresses[i] + aux_sa);
354  }
355 
356  if (std::abs(suma) > tolerance) {
357  rTensileIndicatorFactor = sumb / suma;
358  rCompressionIndicatorFactor = sumc / suma;
359  } else {
360  rTensileIndicatorFactor = sumb;
361  rCompressionIndicatorFactor = sumc;
362  }
363 
364  // Final check
365  if ((std::abs(rTensileIndicatorFactor) + std::abs(rCompressionIndicatorFactor)) < tolerance) {
366  rTensileIndicatorFactor = 0.0;
367  rCompressionIndicatorFactor = 0.0;
368  return;
369  }
370  }
371 
384  const array_1d<double, VoigtSize>& rPredictiveStressVector,
385  const double TensileIndicatorFactor,
386  const double CompressionIndicatorFactor,
387  const Vector& PlasticStrainInc,
388  double& rPlasticDissipation,
391  const double CharacteristicLength
392  )
393  {
394  const Properties& r_material_properties = rValues.GetMaterialProperties();
395 
396  const double young_modulus = r_material_properties[YOUNG_MODULUS];
397  const bool has_symmetric_yield_stress = r_material_properties.Has(YIELD_STRESS);
398  const double yield_compression = has_symmetric_yield_stress ? r_material_properties[YIELD_STRESS] : r_material_properties[YIELD_STRESS_COMPRESSION];
399  const double yield_tension = has_symmetric_yield_stress ? r_material_properties[YIELD_STRESS] : r_material_properties[YIELD_STRESS_TENSION];
400  const double n = yield_compression / yield_tension;
401  const double fracture_energy_tension = r_material_properties[FRACTURE_ENERGY]; // Frac energy in tension
402  const double fracture_energy_compression = r_material_properties[FRACTURE_ENERGY] * std::pow(n, 2); // Frac energy in compression
403 
404  const double characteristic_fracture_energy_tension = fracture_energy_tension / CharacteristicLength;
405  const double characteristic_fracture_energy_compression = fracture_energy_compression / CharacteristicLength;
406 
407  const double hlim = 2.0 * young_modulus * fracture_energy_compression / (std::pow(yield_compression, 2));
408  KRATOS_ERROR_IF(CharacteristicLength > hlim) << "The Fracture Energy is to low: " << characteristic_fracture_energy_compression << std::endl;
409 
410  double constant0 = 0.0, constant1 = 0.0, dplastic_dissipation = 0.0;
411  if (characteristic_fracture_energy_tension > 0.000001) {
412  constant0 = TensileIndicatorFactor / characteristic_fracture_energy_tension;
413  constant1 = CompressionIndicatorFactor / characteristic_fracture_energy_compression;
414  }
415  const double constant = constant0 + constant1;
416 
417  for (IndexType i = 0; i < VoigtSize; ++i) {
418  rHCapa[i] = constant * rPredictiveStressVector[i];
419  dplastic_dissipation += rHCapa[i] * PlasticStrainInc[i];
420  }
421 
422  if (dplastic_dissipation < 0.0 || dplastic_dissipation > 1.0)
423  dplastic_dissipation = 0.0;
424 
425  rPlasticDissipation += dplastic_dissipation;
426  if (rPlasticDissipation >= 0.9999)
427  rPlasticDissipation = 0.9999;
428  else if (rPlasticDissipation < 0.0)
429  rPlasticDissipation = 0.0;
430 
431  // We add a check
432  KRATOS_DEBUG_ERROR_IF(std::isnan(rPlasticDissipation)) << "rPlasticDissipation is nan" << std::endl;
433  }
434 
447  const double PlasticDissipation,
448  const double TensileIndicatorFactor,
449  const double CompressionIndicatorFactor,
450  double& rEquivalentStressThreshold,
451  double& rSlope,
453  const double EquivalentPlasticStrain,
454  const double CharacteristicLength
455  )
456  {
457  const Properties& r_material_properties = rValues.GetMaterialProperties();
458  const int curve_type = r_material_properties[HARDENING_CURVE];
459  BoundedVector<double, 2> slopes, eq_thresholds;
460 
461  for (IndexType i = 0; i < 2; ++i) { // i:0 Tension ; i:1 compression
462  switch (static_cast<HardeningCurveType>(curve_type))
463  {
466  PlasticDissipation, TensileIndicatorFactor,
467  CompressionIndicatorFactor, eq_thresholds[i], slopes[i],
468  rValues);
469  break;
470 
473  PlasticDissipation, TensileIndicatorFactor,
474  CompressionIndicatorFactor, eq_thresholds[i], slopes[i],
475  rValues, CharacteristicLength);
476  break;
477 
480  PlasticDissipation, TensileIndicatorFactor,
481  CompressionIndicatorFactor, eq_thresholds[i], slopes[i],
482  rValues);
483  break;
484 
487  PlasticDissipation, TensileIndicatorFactor,
488  CompressionIndicatorFactor, eq_thresholds[i], slopes[i],
489  rValues);
490  break;
491 
492  case HardeningCurveType::CurveFittingHardening: // Only for VonMises + Tresca!
494  PlasticDissipation, TensileIndicatorFactor,
495  CompressionIndicatorFactor, eq_thresholds[i], slopes[i],
496  rValues, EquivalentPlasticStrain, CharacteristicLength);
497  break;
498 
501  PlasticDissipation, TensileIndicatorFactor,
502  CompressionIndicatorFactor, eq_thresholds[i], slopes[i], CharacteristicLength,
503  rValues);
504  break;
505 
508  PlasticDissipation, TensileIndicatorFactor,
509  CompressionIndicatorFactor, eq_thresholds[i], slopes[i],
510  rValues, CharacteristicLength);
511  break;
512 
513  // Add more cases...
514  default:
515  KRATOS_ERROR << " The HARDENING_CURVE of plasticity is not set or wrong..." << curve_type << std::endl;
516  break;
517  }
518  }
519 
520  rEquivalentStressThreshold = TensileIndicatorFactor * eq_thresholds[0] + CompressionIndicatorFactor * eq_thresholds[1];
521  rSlope = rEquivalentStressThreshold * ((TensileIndicatorFactor * slopes[0] / eq_thresholds[0]) + (CompressionIndicatorFactor * slopes[1] / eq_thresholds[1]));
522  }
523 
534  const double PlasticDissipation,
535  const double TensileIndicatorFactor,
536  const double CompressionIndicatorFactor,
537  double& rEquivalentStressThreshold,
538  double& rSlope,
540  )
541  {
542  const Properties& r_material_properties = rValues.GetMaterialProperties();
543  const bool has_plastic_dissipation_limit = r_material_properties.Has(PLASTIC_DISSIPATION_LIMIT_LINEAR_SOFTENING);
544  const double plastic_dissipation_limit = has_plastic_dissipation_limit ? r_material_properties[PLASTIC_DISSIPATION_LIMIT_LINEAR_SOFTENING] : 0.99;
545  double initial_threshold;
546  GetInitialUniaxialThreshold(rValues, initial_threshold);
547 
548  if (PlasticDissipation <= plastic_dissipation_limit){ //Linear branch
549  rEquivalentStressThreshold = initial_threshold * std::sqrt(1.0 - PlasticDissipation);
550  rSlope = -0.5 * (std::pow(initial_threshold, 2.0) / (rEquivalentStressThreshold));
551  } else { //Exponential branch included to achieve consistent results after full plasticity scenarios
552  rEquivalentStressThreshold = (initial_threshold / std::sqrt(1.0 - plastic_dissipation_limit)) * (1.0 - PlasticDissipation);
553  rSlope = - (initial_threshold / std::sqrt(1.0 - plastic_dissipation_limit));
554  }
555  }
556 
568  const double PlasticDissipation,
569  const double TensileIndicatorFactor,
570  const double CompressionIndicatorFactor,
571  double& rEquivalentStressThreshold,
572  double& rSlope,
574  const double CharacteristicLength
575  )
576  {
577  const Properties& r_material_properties = rValues.GetMaterialProperties();
578 
579  const double young_modulus = r_material_properties[YOUNG_MODULUS];
580  const bool has_symmetric_yield_stress = r_material_properties.Has(YIELD_STRESS);
581  const double yield_compression = has_symmetric_yield_stress ? r_material_properties[YIELD_STRESS] : r_material_properties[YIELD_STRESS_COMPRESSION];
582  const double yield_tension = has_symmetric_yield_stress ? r_material_properties[YIELD_STRESS] : r_material_properties[YIELD_STRESS_TENSION];
583  const double n = yield_compression / yield_tension;
584  const double fracture_energy_compression = r_material_properties[FRACTURE_ENERGY] * std::pow(n, 2); // Frac energy in compression
585  const double characteristic_fracture_energy_compression = fracture_energy_compression / CharacteristicLength;
586 
587  const double minimum_characteristic_fracture_energy_exponential_softening = (std::pow(yield_compression, 2)) / young_modulus;
588 
589  double initial_threshold;
590  GetInitialUniaxialThreshold(rValues, initial_threshold);
591  KRATOS_ERROR_IF(characteristic_fracture_energy_compression < minimum_characteristic_fracture_energy_exponential_softening) << "The Fracture Energy is to low: " << characteristic_fracture_energy_compression << std::endl;
592  rEquivalentStressThreshold = initial_threshold * (1.0 - PlasticDissipation);
593  rSlope = - initial_threshold;
594  }
595 
606  const double PlasticDissipation,
607  const double TensileIndicatorFactor,
608  const double CompressionIndicatorFactor,
609  double& rEquivalentStressThreshold,
610  double& rSlope,
612  )
613  {
614  const Properties& r_material_properties = rValues.GetMaterialProperties();
615 
616  double initial_threshold;
617  GetInitialUniaxialThreshold(rValues, initial_threshold);
618  const double ultimate_stress = r_material_properties[MAXIMUM_STRESS]; // sikpi
619  const double max_stress_position = r_material_properties[MAXIMUM_STRESS_POSITION]; // cappi
620 
621  if (PlasticDissipation < 1.0) {
622  const double ro = std::sqrt(1.0 - initial_threshold / ultimate_stress);
623  double alpha = std::log((1.0 - (1.0 - ro) * (1.0 - ro)) / ((3.0 - ro) * (1.0 + ro) * max_stress_position));
624  alpha = std::exp(alpha / (1.0 - max_stress_position));
625  const double phi = std::pow((1.0 - ro), 2.0) + ((3.0 - ro) * (1.0 + ro) * PlasticDissipation * (std::pow(alpha, (1.0 - PlasticDissipation))));
626 
627  rEquivalentStressThreshold = ultimate_stress * (2.0 * std::sqrt(phi) - phi);
628  rSlope = ultimate_stress * ((1.0 / std::sqrt(phi)) - 1.0) * (3.0 - ro) * (1.0 + ro) * (std::pow(alpha, (1.0 - PlasticDissipation))) *
629  (1.0 - std::log(alpha) * PlasticDissipation);
630  } else {
631  KRATOS_ERROR << "PlasticDissipation > 1.0 " << PlasticDissipation << std::endl;
632  }
633  }
634 
645  const double PlasticDissipation,
646  const double TensileIndicatorFactor,
647  const double CompressionIndicatorFactor,
648  double& rEquivalentStressThreshold,
649  double& rSlope,
651  )
652  {
653  double initial_threshold;
654  GetInitialUniaxialThreshold(rValues, initial_threshold);
655 
656  rEquivalentStressThreshold = initial_threshold;
657  rSlope = 0.0;
658  }
659 
672  const double PlasticDissipation,
673  const double TensileIndicatorFactor,
674  const double CompressionIndicatorFactor,
675  double& rEquivalentStressThreshold,
676  double& rSlope,
678  const double EquivalentPlasticStrain,
679  const double CharacteristicLength
680  )
681  {
682  const Properties& r_material_properties = rValues.GetMaterialProperties();
683  const Vector& curve_fitting_parameters = r_material_properties[CURVE_FITTING_PARAMETERS];
684 
685  const bool has_tangency_linear_region = r_material_properties.Has(TANGENCY_REGION2);
686  const bool tangency_linear_region = has_tangency_linear_region ? r_material_properties[TANGENCY_REGION2] : false;
687 
688  const Vector& plastic_strain_indicators = r_material_properties[PLASTIC_STRAIN_INDICATORS];
689  const double fracture_energy = r_material_properties[FRACTURE_ENERGY];
690  const double volumetric_fracture_energy = fracture_energy / CharacteristicLength;
691 
692  const SizeType order_polinomial = curve_fitting_parameters.size();
693  const double plastic_strain_indicator_1 = plastic_strain_indicators[0];
694  const double plastic_strain_indicator_2 = plastic_strain_indicators[1];
695 
696  // Compute the initial and the final stresses
697  double stress_indicator_1 = curve_fitting_parameters[0];
698  double dS_dEp = 0.0;
699 
700  for (IndexType i = 1; i < order_polinomial; ++i) {
701  stress_indicator_1 += curve_fitting_parameters[i] * (std::pow(plastic_strain_indicator_1, i));
702  dS_dEp += i * curve_fitting_parameters[i] * std::pow(plastic_strain_indicator_1, i - 1);
703  }
704 
705  double dKp_dEp = stress_indicator_1 / volumetric_fracture_energy;
706  if (!tangency_linear_region){
707  dS_dEp = 0.0; // initial slope is zero, else the slope is the tangent of the polinomial region.
708  }
709 
710  const double stress_indicator_2 = stress_indicator_1 + dS_dEp * (plastic_strain_indicator_2 - plastic_strain_indicator_1);
711 
712  // Compute volumetric fracture energies of each region
713  double Gt1 = 0.0;
714  for (IndexType i = 0; i < order_polinomial; ++i) {
715  Gt1 += curve_fitting_parameters[i] * (std::pow(plastic_strain_indicator_1, i + 1)) / (i + 1);
716  }
717  const double Gt2 = (stress_indicator_1 + stress_indicator_2) * (plastic_strain_indicator_2 - plastic_strain_indicator_1) * 0.5;
718  const double Gt3 = volumetric_fracture_energy - Gt2 - Gt1;
719 
720  KRATOS_ERROR_IF(Gt3 < 0.0) << "Fracture energy too low in CurveFittingHardening of plasticity..." << std::endl;
721 
722  // Compute segment threshold
723  const double segment_threshold = (Gt2 + Gt1) / volumetric_fracture_energy;
724 
725  if (PlasticDissipation <= segment_threshold) {
726  const double Eps = EquivalentPlasticStrain;
727 
728  if (EquivalentPlasticStrain < plastic_strain_indicator_1) { // Polinomial region
729  double S_Ep = curve_fitting_parameters[0];
730  double dS_dEp = 0.0;
731  for (IndexType i = 1; i < order_polinomial; ++i) {
732  S_Ep += curve_fitting_parameters[i] * std::pow(Eps, i);
733  dS_dEp += i * curve_fitting_parameters[i] * std::pow(Eps, i - 1);
734  }
735  dKp_dEp = S_Ep / volumetric_fracture_energy;
736 
737  rEquivalentStressThreshold = S_Ep;
738  rSlope = dS_dEp / dKp_dEp;
739  } else { // Linear region
740  const double S_Ep = stress_indicator_1 + (stress_indicator_2 - stress_indicator_1) / (plastic_strain_indicator_2 - plastic_strain_indicator_1) * (Eps - plastic_strain_indicator_1);
741  double dS_dEp = (stress_indicator_2 - stress_indicator_1) / (plastic_strain_indicator_2 - plastic_strain_indicator_1);
742  dKp_dEp = S_Ep / volumetric_fracture_energy;
743 
744  rEquivalentStressThreshold = S_Ep;
745  rSlope = dS_dEp / dKp_dEp;
746  }
747  } else { // Exponential softening
748  const double Eps = EquivalentPlasticStrain;
749  const double alpha = std::pow(stress_indicator_1, 2);
750  const double beta = (std::pow(stress_indicator_2, 2) - alpha) / (plastic_strain_indicator_2 - plastic_strain_indicator_1);
751 
752  const double S_Ep = std::sqrt(alpha + beta * (Eps - plastic_strain_indicator_1));
753  const double plastic_dissipation_region_3 = PlasticDissipation - segment_threshold;
754 
755  const double beta2 = 1.5 * S_Ep / Gt3;
756  const double alpha2 = std::sqrt((plastic_dissipation_region_3 * 2.0 * beta2 * volumetric_fracture_energy / S_Ep) + 1.0);
757  rEquivalentStressThreshold = S_Ep * alpha2 * (2.0 - alpha2);
758  rSlope = 2.0 * beta2 * volumetric_fracture_energy * (1.0 / alpha2 - 1.0);
759  }
760 
761  }
762 
774  const double PlasticDissipation,
775  const double TensileIndicatorFactor,
776  const double CompressionIndicatorFactor,
777  double& rEquivalentStressThreshold,
778  double& rSlope,
779  const double CharacteristicLength,
781  )
782  {
783  const Properties& r_material_properties = rValues.GetMaterialProperties();
784  const bool has_plastic_dissipation_limit = r_material_properties.Has(PLASTIC_DISSIPATION_LIMIT_LINEAR_SOFTENING);
785 
786  const double plastic_dissipation_limit = has_plastic_dissipation_limit ? r_material_properties[PLASTIC_DISSIPATION_LIMIT_LINEAR_SOFTENING] : 0.9;
787  const double fracture_energy = r_material_properties[FRACTURE_ENERGY];
788  const double volumetric_fracture_energy = fracture_energy / CharacteristicLength;
789  double initial_threshold;
790  GetInitialUniaxialThreshold(rValues, initial_threshold);
791 
792  const double volumetric_fracture_energy_linear_branch = 0.5 * volumetric_fracture_energy * (plastic_dissipation_limit + 1.0);
793 
794  if (PlasticDissipation <= plastic_dissipation_limit){ //Linear branch
795  rEquivalentStressThreshold = initial_threshold * std::sqrt(1.0 - PlasticDissipation * volumetric_fracture_energy / volumetric_fracture_energy_linear_branch);
796  rSlope = - 0.5 * initial_threshold * (volumetric_fracture_energy / volumetric_fracture_energy_linear_branch) * std::pow(1.0 - PlasticDissipation * volumetric_fracture_energy / volumetric_fracture_energy_linear_branch, -0.5);
797  } else { //Exponential branch included to achieve consistent results after full plasticity scenarios
798  const double volumetric_fracture_energy_exponential_branch = volumetric_fracture_energy * (1.0 - plastic_dissipation_limit) * std::exp((plastic_dissipation_limit + 1.0) / (std::sqrt(1.0 - std::pow(plastic_dissipation_limit, 2.0))) - 1.0);
799  const double initial_threshold_exponential = initial_threshold * volumetric_fracture_energy_exponential_branch / volumetric_fracture_energy * std::sqrt(1.0 - plastic_dissipation_limit * volumetric_fracture_energy / volumetric_fracture_energy_linear_branch) / (1.0 - plastic_dissipation_limit);
800  rEquivalentStressThreshold = initial_threshold_exponential * (1.0 - PlasticDissipation) * volumetric_fracture_energy / volumetric_fracture_energy_exponential_branch;
801  rSlope = - initial_threshold_exponential * volumetric_fracture_energy / volumetric_fracture_energy_exponential_branch;
802  }
803  }
804 
818  const double PlasticDissipation,
819  const double TensileIndicatorFactor,
820  const double CompressionIndicatorFactor,
821  double& rEquivalentStressThreshold,
822  double& rSlope,
824  const double CharacteristicLength
825  )
826  {
827  const Properties& r_material_properties = rValues.GetMaterialProperties();
828  const Vector& equivalent_stress_vector = r_material_properties[EQUIVALENT_STRESS_VECTOR_PLASTICITY_POINT_CURVE];
829  const bool has_plastic_strain_vector = r_material_properties.Has(PLASTIC_STRAIN_VECTOR_PLASTICITY_POINT_CURVE);
830  const double young_modulus = r_material_properties[YOUNG_MODULUS];
831  Vector plastic_strain_vector;
832  if (has_plastic_strain_vector) { // Strain input is equivalent plastic strain
833  plastic_strain_vector = r_material_properties[PLASTIC_STRAIN_VECTOR_PLASTICITY_POINT_CURVE];
834  } else {
835  const Vector& total_strain_vector = r_material_properties[TOTAL_STRAIN_VECTOR_PLASTICITY_POINT_CURVE];
836  plastic_strain_vector = total_strain_vector - 1.0 / young_modulus * equivalent_stress_vector;
837  }
838  const double fracture_energy = r_material_properties[FRACTURE_ENERGY];
839  const double volumetric_fracture_energy = fracture_energy / CharacteristicLength;
840  const SizeType points_hardening_curve = equivalent_stress_vector.size();
841 
842  // Compute volumetric fracture energies of each region
843  double Gt1 = 0.0;
844  for (IndexType i = 1; i < points_hardening_curve; ++i) {
845  Gt1 += 0.5 * (equivalent_stress_vector(i - 1) + equivalent_stress_vector(i)) * (plastic_strain_vector(i) - plastic_strain_vector(i - 1));
846  }
847  const double Gt2 = volumetric_fracture_energy - Gt1;
848 
849  KRATOS_ERROR_IF(Gt2 < 0.0) << "Fracture energy too low in CurveDefinedByPoints of plasticity..." << std::endl;
850 
851  // Compute segment threshold
852  const double segment_threshold = (Gt1) / volumetric_fracture_energy;
853  if (PlasticDissipation < segment_threshold) {
854  IndexType i = 0;
855  double gf_point_region = 0.0;
856  double plastic_dissipation_previous_point = 0.0;
857  while (PlasticDissipation >= gf_point_region / volumetric_fracture_energy) {
858  i += 1;
859  plastic_dissipation_previous_point = gf_point_region / volumetric_fracture_energy;
860  gf_point_region += 0.5 * (equivalent_stress_vector(i - 1) + equivalent_stress_vector(i)) * (plastic_strain_vector(i) - plastic_strain_vector(i - 1));
861  }
862  const double plastic_dissipation_next_point = gf_point_region / volumetric_fracture_energy;
863 
864  // Stress is computed using an equivalent equation to the one used for the linear softening curve, i.e. f(S) = a * (1.0 - b * kp)
865  const double b = (std::pow(equivalent_stress_vector(i), 2.0) - std::pow(equivalent_stress_vector(i - 1), 2.0)) / (plastic_dissipation_previous_point * std::pow(equivalent_stress_vector(i), 2.0) - plastic_dissipation_next_point * std::pow(equivalent_stress_vector(i - 1), 2.0));
866  const double a = equivalent_stress_vector(i - 1) / std::sqrt(1.0 - b * plastic_dissipation_previous_point);
867  rEquivalentStressThreshold = a * std::sqrt(1.0 - b * PlasticDissipation);
868  rSlope = - 0.5 * std::pow(a, 2.0) * b / rEquivalentStressThreshold;
869 
870  } else { // Exponential branch included to achieve consistent results after full plasticity scenarios
871  const bool has_total_or_plastic_strain_space = r_material_properties.Has(TOTAL_OR_PLASTIC_STRAIN_SPACE);
872  const bool total_or_plastic_strain_space = has_total_or_plastic_strain_space ? r_material_properties[TOTAL_OR_PLASTIC_STRAIN_SPACE] : false; // Default value = plastic strain space
873  if (total_or_plastic_strain_space) { // Curve built in the total strain space
874  const double yield_strain = equivalent_stress_vector(0) / young_modulus;
875  const double a = (0.5 * equivalent_stress_vector(points_hardening_curve - 1) * yield_strain + equivalent_stress_vector(0) / equivalent_stress_vector(points_hardening_curve - 1)
876  * volumetric_fracture_energy * (segment_threshold - 1.0)) / yield_strain;
877 
878  rEquivalentStressThreshold = a + std::sqrt(std::pow(a, 2.0) + 2.0 * equivalent_stress_vector(0) * volumetric_fracture_energy * (1.0 - PlasticDissipation) / yield_strain);
879  rSlope = - equivalent_stress_vector(0) * volumetric_fracture_energy / (yield_strain * std::sqrt(std::pow(a, 2.0) + 2.0 * equivalent_stress_vector(0) * volumetric_fracture_energy * (1.0 - PlasticDissipation) / yield_strain));
880 
881  } else { // Curve built in the plastic strain space
882  const double a = equivalent_stress_vector(points_hardening_curve - 1) / (1.0 - segment_threshold);
883  rEquivalentStressThreshold = a * (1.0 - PlasticDissipation);
884  rSlope = - a;
885  }
886  }
887  }
888 
899  const Vector& rStressVector,
900  const double UniaxialStress,
901  const Vector& rPlasticStrain,
902  const double r0,
904  double& rEquivalentPlasticStrain
905  )
906  {
907  double scalar_product = 0.0;
908  for (IndexType i = 0; i < rPlasticStrain.size(); ++i) {
909  scalar_product += rStressVector[i] * rPlasticStrain[i];
910  }
911 
912  /*Since this law is used for Von Mises and Tresca, no
913  scaling is necessary, even though the needed params are available*/
914  rEquivalentPlasticStrain = scalar_product / UniaxialStress;
915  }
916 
922  static void GetInitialUniaxialThreshold(ConstitutiveLaw::Parameters& rValues, double& rThreshold)
923  {
924  TYieldSurfaceType::GetInitialUniaxialThreshold(rValues, rThreshold);
925  }
926 
935  const array_1d<double, VoigtSize>& rGFlux,
936  const double SlopeThreshold,
937  const array_1d<double, VoigtSize>& rHCapa,
938  double& rHardeningParameter
939  )
940  {
941  rHardeningParameter = SlopeThreshold;
942  double aux = 0.0;
943 
944  for (IndexType i = 0; i < VoigtSize; ++i) {
945  aux += rHCapa[i] * rGFlux[i];
946  }
947  if (aux != 0.0)
948  rHardeningParameter *= aux;
949  }
950 
961  const array_1d<double, VoigtSize>& rFFlux,
962  const array_1d<double, VoigtSize>& rGFlux,
963  const Matrix& rConstitutiveMatrix,
964  double& rHardeningParameter,
965  double& rPlasticDenominator
966  )
967  {
968  //const Vector delta_vector = prod(C, rGFlux);
969  const array_1d<double, VoigtSize> delta_vector = prod(rGFlux, rConstitutiveMatrix);
970  double A1 = 0.0;
971 
972  for (IndexType i = 0; i < VoigtSize; ++i) {
973  A1 += rFFlux[i] * delta_vector[i];
974  }
975  const double A2 = 0.0; // Only for isotropic hard
976  const double A3 = rHardeningParameter;
977  if (std::abs(A1 + A2 + A3) > tolerance)
978  rPlasticDenominator = 1.0 / (A1 + A2 + A3);
979  else {
980  rPlasticDenominator = 1.0e-3 * std::numeric_limits<double>::max(); // TODO: Discuss this!!!
981  }
982  }
983 
988  static int Check(const Properties& rMaterialProperties)
989  {
990  // Checking is defined
991  KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(YOUNG_MODULUS)) << "HARDENING_CURVE is not a defined value" << std::endl;
992  KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(HARDENING_CURVE)) << "HARDENING_CURVE is not a defined value" << std::endl;
993  KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(FRACTURE_ENERGY)) << "FRACTURE_ENERGY is not a defined value" << std::endl;
994 
995  // Checking curves
996  const int curve_type = rMaterialProperties[HARDENING_CURVE];
998  KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(MAXIMUM_STRESS)) << "MAXIMUM_STRESS is not a defined value" << std::endl;
999  KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(MAXIMUM_STRESS_POSITION)) << "MAXIMUM_STRESS_POSITION is not a defined value" << std::endl;
1000  } else if (static_cast<HardeningCurveType>(curve_type) == HardeningCurveType::CurveFittingHardening) {
1001  KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(CURVE_FITTING_PARAMETERS)) << "CURVE_FITTING_PARAMETERS is not a defined value" << std::endl;
1002  KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(PLASTIC_STRAIN_INDICATORS)) << "PLASTIC_STRAIN_INDICATORS is not a defined value" << std::endl;
1003  }
1004 
1005  if (!rMaterialProperties.Has(YIELD_STRESS)) {
1006  KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(YIELD_STRESS_TENSION)) << "YIELD_STRESS_TENSION is not a defined value" << std::endl;
1007  KRATOS_ERROR_IF_NOT(rMaterialProperties.Has(YIELD_STRESS_COMPRESSION)) << "YIELD_STRESS_COMPRESSION is not a defined value" << std::endl;
1008 
1009  const double yield_compression = rMaterialProperties[YIELD_STRESS_COMPRESSION];
1010  const double yield_tension = rMaterialProperties[YIELD_STRESS_TENSION];
1011 
1012  KRATOS_ERROR_IF(yield_compression < tolerance) << "Yield stress in compression almost zero or negative, include YIELD_STRESS_COMPRESSION in definition";
1013  KRATOS_ERROR_IF(yield_tension < tolerance) << "Yield stress in tension almost zero or negative, include YIELD_STRESS_TENSION in definition";
1014  } else {
1015  const double yield_stress = rMaterialProperties[YIELD_STRESS];
1016 
1017  KRATOS_ERROR_IF(yield_stress < tolerance) << "Yield stress almost zero or negative, include YIELD_STRESS in definition";
1018  }
1019 
1020  return TYieldSurfaceType::Check(rMaterialProperties);
1021  }
1022 
1026 
1030 
1034 
1038 
1040 
1041  protected:
1044 
1048 
1052 
1056 
1060 
1064 
1068 
1070 
1071  private:
1074 
1078 
1082 
1086 
1090 
1094 
1098 
1100 
1101 }; // Class GenericYieldSurface
1102 
1104 
1107 
1111 
1113 
1114 } // namespace Kratos.
static void CalculateJ2Invariant(const TVector &rStressVector, const double I1, BoundedVectorType &rDeviator, double &rJ2)
This method computes the second invariant of J.
Definition: advanced_constitutive_law_utilities.h:157
static void CalculatePrincipalStresses(array_1d< double, Dimension > &rPrincipalStressVector, const BoundedVectorType &rStressVector)
This method computes the principal stresses vector.
This object integrates the predictive stress using the plasticity theory by means of linear/exponenti...
Definition: generic_cl_integrator_plasticity.h:70
static void CalculateTangentMatrix(Matrix &rTangent, const Matrix &rElasticMatrix, const array_1d< double, VoigtSize > &rFFluxVector, const array_1d< double, VoigtSize > &rGFluxVector, const double Denominator)
This method calculates the analytical tangent tensor.
Definition: generic_cl_integrator_plasticity.h:273
static constexpr SizeType VoigtSize
The define the Voigt size, already defined in the yield surface.
Definition: generic_cl_integrator_plasticity.h:88
static void CalculateEquivalentStressThresholdHardeningCurvePerfectPlasticity(const double PlasticDissipation, const double TensileIndicatorFactor, const double CompressionIndicatorFactor, double &rEquivalentStressThreshold, double &rSlope, ConstitutiveLaw::Parameters &rValues)
This method computes the uniaxial threshold using a perfect plasticity law.
Definition: generic_cl_integrator_plasticity.h:644
static void CalculateEquivalentStressThresholdHardeningCurveDefinedByPoints(const double PlasticDissipation, const double TensileIndicatorFactor, const double CompressionIndicatorFactor, double &rEquivalentStressThreshold, double &rSlope, ConstitutiveLaw::Parameters &rValues, const double CharacteristicLength)
This method computes the uniaxial threshold using a two region curve:
Definition: generic_cl_integrator_plasticity.h:817
KRATOS_CLASS_POINTER_DEFINITION(GenericConstitutiveLawIntegratorPlasticity)
Counted pointer of GenericConstitutiveLawIntegratorPlasticity.
static void CalculateGFluxVector(const array_1d< double, VoigtSize > &rPredictiveStressVector, const array_1d< double, VoigtSize > &rDeviator, const double J2, array_1d< double, VoigtSize > &rGFluxVector, ConstitutiveLaw::Parameters &rValues)
This method calculates the derivative of the plastic potential.
Definition: generic_cl_integrator_plasticity.h:312
static void CalculatePlasticDissipation(const array_1d< double, VoigtSize > &rPredictiveStressVector, const double TensileIndicatorFactor, const double CompressionIndicatorFactor, const Vector &PlasticStrainInc, double &rPlasticDissipation, array_1d< double, VoigtSize > &rHCapa, ConstitutiveLaw::Parameters &rValues, const double CharacteristicLength)
This method computes the plastic dissipation of the plasticity model.
Definition: generic_cl_integrator_plasticity.h:383
static constexpr SizeType Dimension
The define the working dimension size, already defined in the yield surface.
Definition: generic_cl_integrator_plasticity.h:85
static void CalculateIndicatorsFactors(const array_1d< double, VoigtSize > &rPredictiveStressVector, double &rTensileIndicatorFactor, double &rCompressionIndicatorFactor)
This method computes the tensile/compressive indicators.
Definition: generic_cl_integrator_plasticity.h:329
static void CalculateHardeningParameter(const array_1d< double, VoigtSize > &rGFlux, const double SlopeThreshold, const array_1d< double, VoigtSize > &rHCapa, double &rHardeningParameter)
This method computes hardening parameter needed for the algorithm.
Definition: generic_cl_integrator_plasticity.h:934
static void CalculateEquivalentStressThresholdHardeningCurveInitialHardeningExponentialSoftening(const double PlasticDissipation, const double TensileIndicatorFactor, const double CompressionIndicatorFactor, double &rEquivalentStressThreshold, double &rSlope, ConstitutiveLaw::Parameters &rValues)
This method computes the uniaxial threshold using a hardening-softening law.
Definition: generic_cl_integrator_plasticity.h:605
GenericConstitutiveLawIntegratorPlasticity()
Initialization constructor.
Definition: generic_cl_integrator_plasticity.h:116
static void CalculateEquivalentPlasticStrain(const Vector &rStressVector, const double UniaxialStress, const Vector &rPlasticStrain, const double r0, ConstitutiveLaw::Parameters &rValues, double &rEquivalentPlasticStrain)
This method returns the equivalent plastic strain.
Definition: generic_cl_integrator_plasticity.h:898
static void CalculateEquivalentStressThresholdHardeningCurveLinearSoftening(const double PlasticDissipation, const double TensileIndicatorFactor, const double CompressionIndicatorFactor, double &rEquivalentStressThreshold, double &rSlope, ConstitutiveLaw::Parameters &rValues)
This method computes the uniaxial threshold using a linear softening.
Definition: generic_cl_integrator_plasticity.h:533
GenericConstitutiveLawIntegratorPlasticity(GenericConstitutiveLawIntegratorPlasticity const &rOther)
Copy constructor.
Definition: generic_cl_integrator_plasticity.h:121
static void CalculateEquivalentStressThresholdHardeningCurveLinearExponentialSoftening(const double PlasticDissipation, const double TensileIndicatorFactor, const double CompressionIndicatorFactor, double &rEquivalentStressThreshold, double &rSlope, const double CharacteristicLength, ConstitutiveLaw::Parameters &rValues)
This method computes the uniaxial threshold using a linear-exponential softening, which changes from ...
Definition: generic_cl_integrator_plasticity.h:773
static void CalculateEquivalentStressThresholdHardeningCurveExponentialSoftening(const double PlasticDissipation, const double TensileIndicatorFactor, const double CompressionIndicatorFactor, double &rEquivalentStressThreshold, double &rSlope, ConstitutiveLaw::Parameters &rValues, const double CharacteristicLength)
This method computes the uniaxial threshold using a exponential softening.
Definition: generic_cl_integrator_plasticity.h:567
static double CalculatePlasticParameters(array_1d< double, VoigtSize > &rPredictiveStressVector, Vector &rStrainVector, double &rUniaxialStress, double &rThreshold, double &rPlasticDenominator, array_1d< double, VoigtSize > &rFflux, array_1d< double, VoigtSize > &rGflux, double &rPlasticDissipation, array_1d< double, VoigtSize > &rPlasticStrainIncrement, const Matrix &rConstitutiveMatrix, ConstitutiveLaw::Parameters &rValues, const double CharacteristicLength, const Vector &rPlasticStrain)
This method calculates all the plastic parameters required for the integration of the PredictiveStres...
Definition: generic_cl_integrator_plasticity.h:230
virtual ~GenericConstitutiveLawIntegratorPlasticity()
Destructor.
Definition: generic_cl_integrator_plasticity.h:132
TYieldSurfaceType YieldSurfaceType
The type of yield surface.
Definition: generic_cl_integrator_plasticity.h:82
static void CalculatePlasticDenominator(const array_1d< double, VoigtSize > &rFFlux, const array_1d< double, VoigtSize > &rGFlux, const Matrix &rConstitutiveMatrix, double &rHardeningParameter, double &rPlasticDenominator)
This method computes the plastic denominator needed to compute the plastic consistency factor.
Definition: generic_cl_integrator_plasticity.h:960
static void IntegrateStressVector(array_1d< double, VoigtSize > &rPredictiveStressVector, Vector &rStrainVector, double &rUniaxialStress, double &rThreshold, double &rPlasticDenominator, array_1d< double, VoigtSize > &rFflux, array_1d< double, VoigtSize > &rGflux, double &rPlasticDissipation, array_1d< double, VoigtSize > &rPlasticStrainIncrement, Matrix &rConstitutiveMatrix, Vector &rPlasticStrain, ConstitutiveLaw::Parameters &rValues, const double CharacteristicLength)
This method integrates the predictive stress vector with the CL using differents evolution laws using...
Definition: generic_cl_integrator_plasticity.h:160
static void CalculateEquivalentStressThreshold(const double PlasticDissipation, const double TensileIndicatorFactor, const double CompressionIndicatorFactor, double &rEquivalentStressThreshold, double &rSlope, ConstitutiveLaw::Parameters &rValues, const double EquivalentPlasticStrain, const double CharacteristicLength)
This method computes the uniaxial threshold that differentiates the elastic-plastic behaviour.
Definition: generic_cl_integrator_plasticity.h:446
HardeningCurveType
Definition: generic_cl_integrator_plasticity.h:101
GenericConstitutiveLawIntegratorPlasticity & operator=(GenericConstitutiveLawIntegratorPlasticity const &rOther)
Assignment operator.
Definition: generic_cl_integrator_plasticity.h:126
static void CalculateEquivalentStressThresholdCurveFittingHardening(const double PlasticDissipation, const double TensileIndicatorFactor, const double CompressionIndicatorFactor, double &rEquivalentStressThreshold, double &rSlope, ConstitutiveLaw::Parameters &rValues, const double EquivalentPlasticStrain, const double CharacteristicLength)
This method computes the uniaxial threshold using a perfect plasticity law.
Definition: generic_cl_integrator_plasticity.h:671
std::size_t IndexType
Definition of index.
Definition: generic_cl_integrator_plasticity.h:79
static void GetInitialUniaxialThreshold(ConstitutiveLaw::Parameters &rValues, double &rThreshold)
This method returns the initial uniaxial stress threshold.
Definition: generic_cl_integrator_plasticity.h:922
static constexpr double tolerance
The machine precision tolerance.
Definition: generic_cl_integrator_plasticity.h:76
static void CalculateFFluxVector(const array_1d< double, VoigtSize > &rPredictiveStressVector, const array_1d< double, VoigtSize > &rDeviator, const double J2, array_1d< double, VoigtSize > &rFFluxVector, ConstitutiveLaw::Parameters &rValues)
This method calculates the derivative of the yield surface.
Definition: generic_cl_integrator_plasticity.h:293
static int Check(const Properties &rMaterialProperties)
This method defines in the CL integrator.
Definition: generic_cl_integrator_plasticity.h:988
YieldSurfaceType::PlasticPotentialType PlasticPotentialType
The type of plastic potential.
Definition: generic_cl_integrator_plasticity.h:91
void resize(std::size_t NewSize1, std::size_t NewSize2, bool preserve=0)
Definition: amatrix_interface.h:224
Properties encapsulates data shared by different Elements or Conditions. It can store any type of dat...
Definition: properties.h:69
TVariableType::Type & GetValue(const TVariableType &rVariable)
Definition: properties.h:228
bool Has(TVariableType const &rThisVariable) const
Definition: properties.h:578
#define KRATOS_ERROR
Definition: exception.h:161
#define KRATOS_ERROR_IF_NOT(conditional)
Definition: exception.h:163
#define KRATOS_ERROR_IF(conditional)
Definition: exception.h:162
#define KRATOS_DEBUG_ERROR_IF(conditional)
Definition: exception.h:171
#define KRATOS_WARNING_IF(label, conditional)
Definition: logger.h:266
iteration
Definition: DEM_benchmarks.py:172
static double max(double a, double b)
Definition: GeometryFunctions.h:79
REF: G. R. Cowper, GAUSSIAN QUADRATURE FORMULAS FOR TRIANGLES.
Definition: mesh_condition.cpp:21
KratosZeroVector< double > ZeroVector
Definition: amatrix_interface.h:561
TExpressionType::data_type norm_2(AMatrix::MatrixExpression< TExpressionType, TCategory > const &TheExpression)
Definition: amatrix_interface.h:625
Internals::Matrix< double, AMatrix::dynamic, 1 > Vector
Definition: amatrix_interface.h:472
AMatrix::MatrixProductExpression< TExpression1Type, TExpression2Type > prod(AMatrix::MatrixExpression< TExpression1Type, TCategory1 > const &First, AMatrix::MatrixExpression< TExpression2Type, TCategory2 > const &Second)
Definition: amatrix_interface.h:568
AMatrix::VectorOuterProductExpression< TExpression1Type, TExpression2Type > outer_prod(AMatrix::MatrixExpression< TExpression1Type, TCategory1 > const &First, AMatrix::MatrixExpression< TExpression2Type, TCategory2 > const &Second)
Definition: amatrix_interface.h:582
std::size_t SizeType
The definition of the size type.
Definition: mortar_classes.h:43
T & noalias(T &TheMatrix)
Definition: amatrix_interface.h:484
alpha
Definition: generate_convection_diffusion_explicit_element.py:113
a
Definition: generate_stokes_twofluid_element.py:77
b
Definition: generate_total_lagrangian_mixed_volumetric_strain_element.py:31
F
Definition: hinsberg_optimization.py:144
int max_iter
Definition: hinsberg_optimization.py:139
float J2
Definition: isotropic_damage_automatic_differentiation.py:133
I1
Definition: isotropic_damage_automatic_differentiation.py:230
phi
Definition: isotropic_damage_automatic_differentiation.py:168
int n
manufactured solution and derivatives (u=0 at z=0 dudz=0 at z=domain_height)
Definition: ode_solve.py:402
integer i
Definition: TensorModule.f:17
Definition: constitutive_law.h:189
const Properties & GetMaterialProperties()
Definition: constitutive_law.h:457