68 template<
class TYieldSurfaceType>
76 static constexpr
double tolerance = std::numeric_limits<double>::epsilon();
163 double& rUniaxialStress,
165 double& rPlasticDenominator,
168 double& rPlasticDissipation,
170 Matrix& rConstitutiveMatrix,
173 const double CharacteristicLength
179 bool is_converged =
false;
181 ? r_material_properties.
GetValue(MAX_NUMBER_NL_CL_ITERATIONS) : 100;
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;
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);
195 noalias(rPredictiveStressVector) -= delta_sigma;
197 F =
CalculatePlasticParameters(rPredictiveStressVector, rStrainVector, rUniaxialStress, rThreshold, rPlasticDenominator, rFflux, rGflux, rPlasticDissipation, rPlasticStrainIncrement, rConstitutiveMatrix, rValues, CharacteristicLength, rPlasticStrain);
199 if (
F <= std::abs(1.0e-4 * rThreshold)) {
205 if (analytic_tangent) {
209 noalias(rConstitutiveMatrix) = tangent_tensor;
233 double& rUniaxialStress,
235 double& rPlasticDenominator,
238 double& rPlasticDissipation,
240 const Matrix& rConstitutiveMatrix,
242 const double CharacteristicLength,
243 const Vector& rPlasticStrain
248 double J2, tensile_indicator_factor, compression_indicator_factor, slope, hardening_parameter, equivalent_plastic_strain;
250 YieldSurfaceType::CalculateEquivalentStress( rPredictiveStressVector, rStrainVector, rUniaxialStress, rValues);
251 const double I1 = rPredictiveStressVector[0] + rPredictiveStressVector[1] + rPredictiveStressVector[2];
256 CalculatePlasticDissipation(rPredictiveStressVector, tensile_indicator_factor,compression_indicator_factor, rPlasticStrainIncrement,rPlasticDissipation, h_capa, rValues, CharacteristicLength);
258 CalculateEquivalentStressThreshold(rPlasticDissipation, tensile_indicator_factor,compression_indicator_factor, rThreshold, slope, rValues, equivalent_plastic_strain, CharacteristicLength);
262 return rUniaxialStress - rThreshold;
275 const Matrix& rElasticMatrix,
278 const double Denominator
301 YieldSurfaceType::CalculateYieldSurfaceDerivative(rPredictiveStressVector, rDeviator,
J2, rFFluxVector, rValues);
320 YieldSurfaceType::CalculatePlasticPotentialDerivative(rPredictiveStressVector, rDeviator,
J2, rGFluxVector, rValues);
331 double& rTensileIndicatorFactor,
332 double& rCompressionIndicatorFactor
336 if (
norm_2(rPredictiveStressVector) < 1.0e-8) {
337 rTensileIndicatorFactor = 1.0;
338 rCompressionIndicatorFactor = 0.0;
346 double suma = 0.0, sumb = 0.0, sumc = 0.0;
350 aux_sa = std::abs(principal_stresses[
i]);
352 sumb += 0.5 * (principal_stresses[
i] + aux_sa);
353 sumc += 0.5 * (-principal_stresses[
i] + aux_sa);
357 rTensileIndicatorFactor = sumb / suma;
358 rCompressionIndicatorFactor = sumc / suma;
360 rTensileIndicatorFactor = sumb;
361 rCompressionIndicatorFactor = sumc;
365 if ((std::abs(rTensileIndicatorFactor) + std::abs(rCompressionIndicatorFactor)) <
tolerance) {
366 rTensileIndicatorFactor = 0.0;
367 rCompressionIndicatorFactor = 0.0;
385 const double TensileIndicatorFactor,
386 const double CompressionIndicatorFactor,
387 const Vector& PlasticStrainInc,
388 double& rPlasticDissipation,
391 const double CharacteristicLength
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];
402 const double fracture_energy_compression = r_material_properties[FRACTURE_ENERGY] * std::pow(
n, 2);
404 const double characteristic_fracture_energy_tension = fracture_energy_tension / CharacteristicLength;
405 const double characteristic_fracture_energy_compression = fracture_energy_compression / CharacteristicLength;
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;
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;
415 const double constant = constant0 + constant1;
418 rHCapa[
i] = constant * rPredictiveStressVector[
i];
419 dplastic_dissipation += rHCapa[
i] * PlasticStrainInc[
i];
422 if (dplastic_dissipation < 0.0 || dplastic_dissipation > 1.0)
423 dplastic_dissipation = 0.0;
425 rPlasticDissipation += dplastic_dissipation;
426 if (rPlasticDissipation >= 0.9999)
427 rPlasticDissipation = 0.9999;
428 else if (rPlasticDissipation < 0.0)
429 rPlasticDissipation = 0.0;
447 const double PlasticDissipation,
448 const double TensileIndicatorFactor,
449 const double CompressionIndicatorFactor,
450 double& rEquivalentStressThreshold,
453 const double EquivalentPlasticStrain,
454 const double CharacteristicLength
458 const int curve_type = r_material_properties[HARDENING_CURVE];
466 PlasticDissipation, TensileIndicatorFactor,
467 CompressionIndicatorFactor, eq_thresholds[
i], slopes[
i],
473 PlasticDissipation, TensileIndicatorFactor,
474 CompressionIndicatorFactor, eq_thresholds[
i], slopes[
i],
475 rValues, CharacteristicLength);
480 PlasticDissipation, TensileIndicatorFactor,
481 CompressionIndicatorFactor, eq_thresholds[
i], slopes[
i],
487 PlasticDissipation, TensileIndicatorFactor,
488 CompressionIndicatorFactor, eq_thresholds[
i], slopes[
i],
494 PlasticDissipation, TensileIndicatorFactor,
495 CompressionIndicatorFactor, eq_thresholds[
i], slopes[
i],
496 rValues, EquivalentPlasticStrain, CharacteristicLength);
501 PlasticDissipation, TensileIndicatorFactor,
502 CompressionIndicatorFactor, eq_thresholds[
i], slopes[
i], CharacteristicLength,
508 PlasticDissipation, TensileIndicatorFactor,
509 CompressionIndicatorFactor, eq_thresholds[
i], slopes[
i],
510 rValues, CharacteristicLength);
515 KRATOS_ERROR <<
" The HARDENING_CURVE of plasticity is not set or wrong..." << curve_type << std::endl;
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]));
534 const double PlasticDissipation,
535 const double TensileIndicatorFactor,
536 const double CompressionIndicatorFactor,
537 double& rEquivalentStressThreshold,
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;
548 if (PlasticDissipation <= plastic_dissipation_limit){
549 rEquivalentStressThreshold = initial_threshold * std::sqrt(1.0 - PlasticDissipation);
550 rSlope = -0.5 * (std::pow(initial_threshold, 2.0) / (rEquivalentStressThreshold));
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));
568 const double PlasticDissipation,
569 const double TensileIndicatorFactor,
570 const double CompressionIndicatorFactor,
571 double& rEquivalentStressThreshold,
574 const double CharacteristicLength
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);
585 const double characteristic_fracture_energy_compression = fracture_energy_compression / CharacteristicLength;
587 const double minimum_characteristic_fracture_energy_exponential_softening = (std::pow(yield_compression, 2)) / young_modulus;
589 double 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;
606 const double PlasticDissipation,
607 const double TensileIndicatorFactor,
608 const double CompressionIndicatorFactor,
609 double& rEquivalentStressThreshold,
616 double initial_threshold;
618 const double ultimate_stress = r_material_properties[MAXIMUM_STRESS];
619 const double max_stress_position = r_material_properties[MAXIMUM_STRESS_POSITION];
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))));
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);
631 KRATOS_ERROR <<
"PlasticDissipation > 1.0 " << PlasticDissipation << std::endl;
645 const double PlasticDissipation,
646 const double TensileIndicatorFactor,
647 const double CompressionIndicatorFactor,
648 double& rEquivalentStressThreshold,
653 double initial_threshold;
656 rEquivalentStressThreshold = initial_threshold;
672 const double PlasticDissipation,
673 const double TensileIndicatorFactor,
674 const double CompressionIndicatorFactor,
675 double& rEquivalentStressThreshold,
678 const double EquivalentPlasticStrain,
679 const double CharacteristicLength
683 const Vector& curve_fitting_parameters = r_material_properties[CURVE_FITTING_PARAMETERS];
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;
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;
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];
697 double stress_indicator_1 = curve_fitting_parameters[0];
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);
705 double dKp_dEp = stress_indicator_1 / volumetric_fracture_energy;
706 if (!tangency_linear_region){
710 const double stress_indicator_2 = stress_indicator_1 + dS_dEp * (plastic_strain_indicator_2 - plastic_strain_indicator_1);
715 Gt1 += curve_fitting_parameters[
i] * (std::pow(plastic_strain_indicator_1,
i + 1)) / (
i + 1);
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;
720 KRATOS_ERROR_IF(Gt3 < 0.0) <<
"Fracture energy too low in CurveFittingHardening of plasticity..." << std::endl;
723 const double segment_threshold = (Gt2 + Gt1) / volumetric_fracture_energy;
725 if (PlasticDissipation <= segment_threshold) {
726 const double Eps = EquivalentPlasticStrain;
728 if (EquivalentPlasticStrain < plastic_strain_indicator_1) {
729 double S_Ep = curve_fitting_parameters[0];
732 S_Ep += curve_fitting_parameters[
i] * std::pow(Eps,
i);
733 dS_dEp +=
i * curve_fitting_parameters[
i] * std::pow(Eps,
i - 1);
735 dKp_dEp = S_Ep / volumetric_fracture_energy;
737 rEquivalentStressThreshold = S_Ep;
738 rSlope = dS_dEp / dKp_dEp;
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;
744 rEquivalentStressThreshold = S_Ep;
745 rSlope = dS_dEp / dKp_dEp;
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);
752 const double S_Ep = std::sqrt(
alpha + beta * (Eps - plastic_strain_indicator_1));
753 const double plastic_dissipation_region_3 = PlasticDissipation - segment_threshold;
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);
774 const double PlasticDissipation,
775 const double TensileIndicatorFactor,
776 const double CompressionIndicatorFactor,
777 double& rEquivalentStressThreshold,
779 const double CharacteristicLength,
784 const bool has_plastic_dissipation_limit = r_material_properties.
Has(PLASTIC_DISSIPATION_LIMIT_LINEAR_SOFTENING);
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;
792 const double volumetric_fracture_energy_linear_branch = 0.5 * volumetric_fracture_energy * (plastic_dissipation_limit + 1.0);
794 if (PlasticDissipation <= plastic_dissipation_limit){
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);
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;
818 const double PlasticDissipation,
819 const double TensileIndicatorFactor,
820 const double CompressionIndicatorFactor,
821 double& rEquivalentStressThreshold,
824 const double CharacteristicLength
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) {
833 plastic_strain_vector = r_material_properties[PLASTIC_STRAIN_VECTOR_PLASTICITY_POINT_CURVE];
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;
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();
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));
847 const double Gt2 = volumetric_fracture_energy - Gt1;
849 KRATOS_ERROR_IF(Gt2 < 0.0) <<
"Fracture energy too low in CurveDefinedByPoints of plasticity..." << std::endl;
852 const double segment_threshold = (Gt1) / volumetric_fracture_energy;
853 if (PlasticDissipation < segment_threshold) {
855 double gf_point_region = 0.0;
856 double plastic_dissipation_previous_point = 0.0;
857 while (PlasticDissipation >= gf_point_region / volumetric_fracture_energy) {
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));
862 const double plastic_dissipation_next_point = gf_point_region / volumetric_fracture_energy;
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;
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;
873 if (total_or_plastic_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;
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));
882 const double a = equivalent_stress_vector(points_hardening_curve - 1) / (1.0 - segment_threshold);
883 rEquivalentStressThreshold =
a * (1.0 - PlasticDissipation);
899 const Vector& rStressVector,
900 const double UniaxialStress,
901 const Vector& rPlasticStrain,
904 double& rEquivalentPlasticStrain
907 double scalar_product = 0.0;
909 scalar_product += rStressVector[
i] * rPlasticStrain[
i];
914 rEquivalentPlasticStrain = scalar_product / UniaxialStress;
924 TYieldSurfaceType::GetInitialUniaxialThreshold(rValues, rThreshold);
936 const double SlopeThreshold,
938 double& rHardeningParameter
941 rHardeningParameter = SlopeThreshold;
945 aux += rHCapa[
i] * rGFlux[
i];
948 rHardeningParameter *= aux;
963 const Matrix& rConstitutiveMatrix,
964 double& rHardeningParameter,
965 double& rPlasticDenominator
973 A1 += rFFlux[
i] * delta_vector[
i];
975 const double A2 = 0.0;
976 const double A3 = rHardeningParameter;
978 rPlasticDenominator = 1.0 / (A1 + A2 + A3);
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;
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;
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;
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;
1009 const double yield_compression = rMaterialProperties[YIELD_STRESS_COMPRESSION];
1010 const double yield_tension = rMaterialProperties[YIELD_STRESS_TENSION];
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";
1015 const double yield_stress = rMaterialProperties[YIELD_STRESS];
1017 KRATOS_ERROR_IF(yield_stress <
tolerance) <<
"Yield stress almost zero or negative, include YIELD_STRESS in definition";
1020 return TYieldSurfaceType::Check(rMaterialProperties);
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
@ InitialHardeningExponentialSoftening
@ LinearExponentialSoftening
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