38 #include "../sm/Materials/structuralms.h" 44 #include "../sm/Materials/structuralmaterial.h" 70 #ifdef SOPHISTICATED_SIZEDEPENDENT_ADJUSTMENT 97 #ifdef SOPHISTICATED_SIZEDEPENDENT_ADJUSTMENT 121 fprintf(file,
"\tstatus { ");
126 fprintf(file,
"statusflag 0 (Elastic),");
129 fprintf(file,
"statusflag 1 (Unloading),");
132 fprintf(file,
"statusflag 2 (Plastic),");
135 fprintf(file,
"statusflag 3 (Damage),");
138 fprintf(file,
"statusflag 4 (PlasticDamage),");
141 fprintf(file,
"statusflag 5 (VertexCompression),");
144 fprintf(file,
"statusflag 6 (VertexTension),");
147 fprintf(file,
"statusflag 7 (VertexCompressionDamage),");
150 fprintf(file,
"statusflag 8 (VertexTensionDamage),");
157 giveFullPlasticStrainVector(plasticStrainVector);
158 fprintf(file,
"plastic strains ");
159 for (
auto &val : plasticStrainVector )
160 fprintf(file,
" %.4e", val);
168 fprintf(file,
", damage %.4e",
damage);
171 fprintf(file,
"}\n");
271 if ( type == IST_DamageScalar ) {
276 if ( type == IST_CumPlasticStrain ) {
281 if ( type == IST_CumPlasticStrain_2 ) {
318 effectiveStress(_Unknown)
327 #ifdef SOPHISTICATED_SIZEDEPENDENT_ADJUSTMENT 364 gM =
eM / ( 2. * ( 1. +
nu ) );
365 kM =
eM / ( 3. * ( 1. - 2. *
nu ) );
401 #ifdef SOPHISTICATED_SIZEDEPENDENT_ADJUSTMENT 407 m = 3. * ( pow(
fc, 2.) - pow(
ft, 2.) ) / (
fc *
ft ) *
ecc / (
ecc + 1. );
446 elasticStrain.
subtract(tempPlasticStrain);
463 #ifdef SOPHISTICATED_SIZEDEPENDENT_ADJUSTMENT 471 double work = strainIncrement.
dotProduct(stressIncrement, n);
474 double E = this->
give(
'E', gp);
490 double f = equivStrain - status->
giveKappaD();
498 #ifdef SOPHISTICATED_SIZEDEPENDENT_ADJUSTMENT 521 double deltaEquivStrain = 0.;
523 tempEquivStrain = equivStrain;
529 double volumetricPlasticStrain = plasticStrain(0) + plasticStrain(1) + plasticStrain(2);
530 double tempVolumetricPlasticStrain = tempPlasticStrain(0) + tempPlasticStrain(1) + tempPlasticStrain(2);
534 ( tempVolumetricPlasticStrain - volumetricPlasticStrain ) +
535 volumetricPlasticStrain;
536 if ( peakVolumetricPlasticStrain < 0. ) {
537 peakVolumetricPlasticStrain = 0.;
541 tempVolumetricPlasticStrain - peakVolumetricPlasticStrain;
544 if ( tempEquivStrain < 0. ) {
545 tempEquivStrain = 0.;
548 deltaEquivStrain = ( tempVolumetricPlasticStrain - volumetricPlasticStrain );
549 if ( deltaEquivStrain < 0. ) {
550 deltaEquivStrain = 0.;
553 tempEquivStrain = equivStrain +
566 double le = status->
giveLe();
577 double answer = -( this->
ef / le ) * log(1. - dam) - dam *
ft /
eM;
581 #define DPM_DAMAGE_TOLERANCE 1.e-8 592 double R, Lhs, aux, aux1;
594 double h = status->
giveLe();
596 #ifdef SOPHISTICATED_SIZEDEPENDENT_ADJUSTMENT 599 if ( (
href <= 0. ) || ( epsloc < 0. ) ) {
606 aux1 = (
ft /
eM ) * h /
ef;
608 printf(
"computeDamageParam: ft=%g, E=%g, wf=%g, hmax=E*wf/ft=%g, h=%g\n",
ft,
eM,
ef,
eM *
ef /
ft, h);
614 aux = exp(-h * ( omega *
ft /
eM + kappa ) /
ef);
615 R = 1. - omega - aux;
616 Lhs = -1. + aux1 * aux;
623 #ifdef SOPHISTICATED_SIZEDEPENDENT_ADJUSTMENT 631 aux1 = (
ft /
eM ) * h /
ef;
634 aux = exp(-( (
href - h ) * epsloc + h * ( omega *
ft /
eM + kappa ) ) /
ef);
635 R = 1. - omega - aux;
636 Lhs = -1. + aux1 * aux;
639 printf(
"computeDamageParam: algorithm not converging (part 2)");
645 if ( ( omega > 1.0 ) || ( omega < 0.0 ) ) {
659 if ( kappaD <= 0. ) {
664 FloatArray principalStrains, crackPlaneNormal(3);
673 for (
int i = 2; i <= 3; i++ ) {
674 if ( principalStrains.
at(i) > principalStrains.
at(indx) ) {
679 for (
int i = 1; i <= 3; i++ ) {
680 crackPlaneNormal.
at(i) = principalDir.
at(i, indx);
691 }
else if ( status->
giveLe() == 0. ) {
705 tempPlasticStrain.
subtract(plasticStrain);
707 double ductilityMeasure;
708 double volStrain = tempPlasticStrain(0) + tempPlasticStrain(1) + tempPlasticStrain(2);
711 double negativeVolStrain = 0.;
712 for (
int i = 0; i < principalStrain.
giveSize(); i++ ) {
713 if ( principalStrain(i) < 0. ) {
714 negativeVolStrain += principalStrain(i);
719 double Rs = -negativeVolStrain / volStrain;
721 ductilityMeasure = 1. +
ASoft *pow(Rs, 2.);
723 ductilityMeasure = 1. - 3. *
ASoft + 4. *
ASoft *sqrt(Rs);
726 return ductilityMeasure;
743 elasticStrain.
subtract(tempPlasticStrain);
752 double apexStress = 0.;
775 tempPlasticStrain = strain;
776 tempPlasticStrain.
subtract(elasticStrain);
784 const double tempKappa)
789 double dFZeroDSigZero = 0.;
792 double apexCompression = 0.;
795 if ( ( tempKappa < 1. ) && ( sig < 0. ) ) {
799 FZero = pow( ( 1. - yieldHardOne ), 2. ) * pow( ( sigZero /
fc ), 4. ) +
800 pow(yieldHardOne, 2.) *
m * ( sigZero /
fc ) - pow(yieldHardOne, 2.);
802 dFZeroDSigZero = pow( ( 1. - yieldHardOne ), 2. ) * 4. * pow( ( sigZero /
fc ), 3. ) /
fc +
803 pow(yieldHardOne, 2.) *
m /
fc;
805 sigZero = sigZero - FZero / dFZeroDSigZero;
808 if ( l < 15 && sigZero < 0. ) {
809 apexCompression = sigZero;
811 apexCompression = -15. *
fc;
815 if ( ( sig > 0. && tempKappa < 1. ) || ( sig >
fc /
m && tempKappa >= 1. ) ) {
818 }
else if ( sig < apexCompression ) {
820 answer = apexCompression;
838 double deltaLambdaIncrement = 0.;
842 double deltaLambdaIncrementNew = 0.;
843 double tempKappaPTest = 0.;
844 int iterationCount = 0;
845 int negativeRhoFlag = 0;
853 double dKappaDDeltaLambda;
854 double dFDKappa = 0.;
869 const double volumetricPlasticStrain =
872 const double deviatoricPlasticStrainNorm =
875 double tempVolumetricPlasticStrain = volumetricPlasticStrain;
876 double tempDeviatoricPlasticStrainNorm = deviatoricPlasticStrainNorm;
882 residualNorm = fabs(yieldValue);
886 OOFEM_ERROR(
"Closest point projection did not converge.");
896 residual(0) = volumetricPlasticStrain - tempVolumetricPlasticStrain +
898 residual(1) = deviatoricPlasticStrainNorm -
899 tempDeviatoricPlasticStrainNorm +
deltaLambda *dGDInv(1);
903 residualNorm = pow(residual(0), 2.) + pow(residual(1), 2.) +
904 pow(residual(2), 2.) + pow(yieldValue, 2.);
905 residualNorm = sqrt(residualNorm);
911 for (
int i = 0; i < 2; i++ ) {
912 derivativesOfYieldSurface(i) = dFDInv(i);
915 derivativesOfYieldSurface(2) = dFDKappa;
917 for (
int i = 0; i < 2; i++ ) {
918 flowRules(i) = dGDInv(i);
921 flowRules(2) = dKappaDDeltaLambda;
924 deltaLambdaIncrement = yieldValue;
926 for (
int i = 0; i < 3; i++ ) {
927 deltaLambdaIncrement -= derivativesOfYieldSurface(i) * helpVectorA(i);
931 double denominator = 0.;
932 for (
int i = 0; i < 3; i++ ) {
933 denominator += derivativesOfYieldSurface(i) * helpVectorB(i);
936 deltaLambdaIncrement /= denominator;
940 helpVectorC = residual;
941 helpVectorC.
add(deltaLambdaIncrement, flowRules);
944 rhoTest =
rho + answerIncrement(1);
947 if ( rhoTest < 0. && negativeRhoFlag == 0 ) {
949 answerIncrement(1) = -
rho;
951 deltaLambdaIncrementNew =
952 ( -aMatrix(1, 0) * residual(0) - aMatrix(1, 1) * residual(1) -
953 aMatrix(1, 2) * residual(2) - answerIncrement(1) ) /
954 ( flowRules(0) * aMatrix(1, 0) + flowRules(1) * aMatrix(1, 1) +
955 flowRules(2) * aMatrix(1, 2) );
958 if ( fabs(deltaLambdaIncrementNew) <
yieldTol * 1.e3 ) {
960 deltaLambdaIncrementNew = deltaLambdaIncrement;
963 helpVectorC = residual;
964 helpVectorC.
add(deltaLambdaIncrementNew, flowRules);
965 answerIncrement.beProductOf(aMatrix, helpVectorC);
966 answerIncrement.negated();
968 sig += answerIncrement(0);
969 rho += answerIncrement(1);
977 sig += answerIncrement(0);
978 rho += answerIncrement(1);
988 tempVolumetricPlasticStrain -= answerIncrement(0) / (
kM );
989 tempDeviatoricPlasticStrainNorm -= answerIncrement(1) / ( 2. *
gM );
1000 printf(
"plastic multiplier less than zero");
1006 stressPrincipal.
zero();
1024 double yieldValueMid;
1029 double ratioPotential;
1055 if ( yieldValue * yieldValueMid >= 0. ) {
1060 if ( yieldValue < 0.0 ) {
1061 dSig = sig2 - sigTrial;
1064 dSig = sigTrial - sig2;
1068 for (
int j = 0; j < 250; j++ ) {
1071 sigMid = sigAnswer + dSig;
1079 if ( yieldValueMid <= 0. ) {
1083 if ( fabs(yieldValueMid) <
yieldTol && yieldValueMid <= 0. ) {
1084 for (
int i = 0; i < 3; i++ ) {
1088 for (
int i = 3; i < effectiveStress.
giveSize(); i++ ) {
1095 double ratioTrial = rhoTrial / ( sigTrial - sigAnswer );
1113 const double sigTrial,
1114 const double rhoTrial,
1118 double equivalentDeltaPlasticStrain;
1120 equivalentDeltaPlasticStrain = sqrt( 1. / 9. * pow( ( sigTrial - sig ) / (
kM ), 2. ) +
1121 pow(rhoTrial / ( 2. *
gM ), 2.) );
1123 double thetaVertex = 0.;
1126 return kappaInitial + equivalentDeltaPlasticStrain / ductilityMeasure;
1134 const double tempKappa)
const 1141 const double rFunction = ( 4. * ( 1. - pow(
ecc, 2.) ) * pow(cos(theta), 2.) +
1142 pow( ( 2. *
ecc - 1. ), 2. ) ) /
1143 ( 2. * ( 1. - pow(
ecc, 2.) ) * cos(theta) +
1144 ( 2. *
ecc - 1. ) * sqrt(4. * ( 1. - pow(
ecc, 2.) ) * pow(cos(theta), 2.)
1145 + 5. * pow(
ecc, 2.) - 4. *
ecc) );
1148 const double Al = ( 1. - yieldHardOne ) * pow( ( sig /
fc + rho / ( sqrt(6.) *
fc ) ), 2. ) +
1149 sqrt(3. / 2.) * rho /
fc;
1152 return pow(Al, 2.) +
1153 pow(yieldHardOne, 2.) *
m * ( sig /
fc + rho * rFunction / ( sqrt(6.) *
fc ) ) -
1154 pow(yieldHardTwo, 2.);
1161 const double tempKappa)
1172 const double rFunction =
1173 ( 4. * ( 1. -
ecc *
ecc ) * cos(theta) * cos(theta) + ( 2. *
ecc - 1. ) * ( 2. *
ecc - 1. ) ) /
1174 ( 2 * ( 1. -
ecc *
ecc ) * cos(theta) + ( 2. * ecc - 1. ) *
1175 sqrt(4. * ( 1. - ecc * ecc ) * cos(theta) * cos(theta) + 5. * ecc * ecc - 4. *
ecc) );
1178 const double Al = ( 1. - yieldHardOne ) * pow( ( sig /
fc + rho / ( sqrt(6.) *
fc ) ), 2. ) + sqrt(3. / 2.) * rho /
fc;
1180 const double Bl = sig /
fc + rho / (
fc * sqrt(6.) );
1182 const double dFDYieldHardOne = -2. *Al *pow(Bl, 2.)
1183 + 2. * yieldHardOne *
m * ( sig /
fc + rho * rFunction / ( sqrt(6.) *
fc ) );
1185 const double dFDYieldHardTwo = -2. * yieldHardTwo;
1188 double dFDKappa = dFDYieldHardOne * dYieldHardOneDKappa +
1189 dFDYieldHardTwo * dYieldHardTwoDKappa;
1197 if ( dFDKappa > 0. ) {
1208 const double tempKappa)
const 1216 const double rFunction = ( 4. * ( 1. -
ecc *
ecc ) * cos(theta) * cos(theta) + ( 2. *
ecc - 1. ) * ( 2. *
ecc - 1. ) ) /
1217 ( 2. * ( 1. -
ecc *
ecc ) * cos(theta) + ( 2. * ecc - 1. ) * sqrt(4. * ( 1. - ecc * ecc ) * cos(theta) * cos(theta)
1218 + 5. * ecc * ecc - 4. *
ecc) );
1221 const double AL = ( 1. - yieldHardOne ) * pow( ( sig /
fc + rho / ( sqrt(6.) *
fc ) ), 2. ) + sqrt(3. / 2.) * rho /
fc;
1222 const double BL = sig /
fc + rho / (
fc * sqrt(6.) );
1225 const double dfdsig = 4. * ( 1. - yieldHardOne ) /
fc * AL * BL + yieldHardOne * yieldHardOne *
m /
fc;
1227 const double dfdrho = AL / ( sqrt(6.) *
fc ) * ( 4. * ( 1. - yieldHardOne ) * BL + 6. ) + rFunction *
m * yieldHardOne * yieldHardOne / ( sqrt(6.) *
fc );
1236 const double tempKappa)
1239 double equivalentDGDStress;
1243 equivalentDGDStress = sqrt( 1. / 3. * pow(dGDInv(0), 2.) +
1244 pow(dGDInv(1), 2.) );
1247 double dKappaDDeltaLambda = equivalentDGDStress / ductilityMeasure;
1248 return dKappaDDeltaLambda;
1256 const double tempKappa)
1259 double equivalentDGDStress;
1269 equivalentDGDStress = sqrt( 1. / 3. * pow(dGDInv(0), 2.) +
1270 pow(dGDInv(1), 2.) );
1276 dEquivalentDGDStressDInv(0) =
1277 ( 2. / 3. * dGDInv(0) * dDGDDInv(0, 0) + 2. * dGDInv(1) * dDGDDInv(1, 0) ) / ( 2. * equivalentDGDStress );
1278 dEquivalentDGDStressDInv(1) =
1279 ( 2. / 3. * dGDInv(0) * dDGDDInv(0, 1) + 2. * dGDInv(1) * dDGDDInv(1, 1) ) / ( 2. * equivalentDGDStress );
1287 answer(0) = ( dEquivalentDGDStressDInv(0) * ductilityMeasure - equivalentDGDStress * dDuctilityMeasureDInv(0) ) / pow(ductilityMeasure, 2.);
1289 answer(1) = ( dEquivalentDGDStressDInv(1) * ductilityMeasure - equivalentDGDStress * dDuctilityMeasureDInv(1) ) / pow(ductilityMeasure, 2.);
1295 const double tempKappa)
1298 double equivalentDGDStress;
1301 double dEquivalentDGDStressDKappa;
1307 equivalentDGDStress = sqrt( 1. / 3. * pow(dGDInv(0), 2.) +
1308 pow(dGDInv(1), 2.) );
1314 dEquivalentDGDStressDKappa =
1315 ( 2. / 3. * dGDInv(0) * dDGDInvDKappa(0) + 2. * dGDInv(1) * dDGDInvDKappa(1) ) / ( 2. * equivalentDGDStress );
1318 double dDuctilityMeasureDKappa = 0.;
1320 double dDKappaDDeltaLambdaDKappa =
1321 ( dEquivalentDGDStressDKappa * ductilityMeasure -
1322 equivalentDGDStress * dDuctilityMeasureDKappa ) / pow(ductilityMeasure, 2.);
1324 return dDKappaDDeltaLambdaDKappa;
1332 double thetaConst = pow(2. * cos(theta), 2.);
1333 double ductilityMeasure;
1334 double x = -( sig +
fc / 3 ) /
fc;
1338 double fZero =
BHard;
1340 double CHelp =
DHard;
1341 double AHelp = fZero - CHelp;
1342 double BHelp = ( fZero - CHelp ) / fPrimeZero;
1343 ductilityMeasure = ( AHelp * exp(x / BHelp) + CHelp ) / thetaConst;
1348 if ( ductilityMeasure <= 0. ) {
1349 printf(
"ductilityMeasure is zero or negative");
1352 return ductilityMeasure;
1359 const double tempKappa)
1361 double thetaConst = pow(2. * cos(
thetaTrial), 2.);
1362 double x = ( -( sig +
fc / 3 ) ) /
fc;
1364 double dXDSig = -1. /
fc;
1367 double fZero =
BHard;
1369 double CHelp =
DHard;
1370 double AHelp = fZero - CHelp;
1371 double BHelp = ( fZero - CHelp ) / fPrimeZero;
1372 double dDuctilityMeasureDX = AHelp / BHelp *exp(x / BHelp) / thetaConst;
1373 answer(0) = dDuctilityMeasureDX * dXDSig;
1376 double dXDSig = -1. /
fc;
1377 double dDuctilityMeasureDX = -(
BHard -
AHard ) / (
CHard ) / thetaConst *exp( -x / (
CHard ) );
1378 answer(0) = dDuctilityMeasureDX * dXDSig;
1388 const double tempKappa)
1391 const double R = ( sig -
ft / 3. ) /
fc;
1392 const double mQTension = ( 3. *
ft /
fc +
m / 2. );
1393 const double mQCompression =
1395 const double AConst = -(
ft +
fc ) / ( 3. *
fc ) / log(mQCompression / mQTension);
1396 const double mQ = mQTension * exp(R / AConst);
1401 const double Bl = sig /
fc + rho / (
fc * sqrt(6.) );
1403 const double Al = ( 1. - yieldHardOne ) * pow(Bl, 2.) + sqrt(3. / 2.) * rho /
fc;
1405 const double dgdsig = 4. * ( 1. - yieldHardOne ) /
fc * Al * Bl + yieldHardOne * yieldHardOne * mQ /
fc;
1407 const double dgdrho = Al / ( sqrt(6.) *
fc ) * ( 4. * ( 1. - yieldHardOne ) * Bl + 6. ) +
1408 m *pow(yieldHardOne, 2.) / ( sqrt(6.) *
fc );
1417 const double tempKappa)
1420 const double R = ( sig -
ft / 3. ) /
fc;
1421 const double mQTension = ( 3. *
ft /
fc +
m / 2. );
1422 const double mQCompression =
1424 const double AConst = -(
ft +
fc ) / ( 3. *
fc ) / log(mQCompression / mQTension);
1425 const double mQ = mQTension * exp(R / AConst);
1430 const double Bl = sig /
fc;
1432 const double Al = ( 1. - yieldHardOne ) * pow(Bl, 2.);
1434 const double dgdsig = 4. * ( 1. - yieldHardOne ) /
fc * Al * Bl + yieldHardOne * yieldHardOne * mQ /
fc;
1436 const double dgdrho = Al / ( sqrt(6.) *
fc ) * ( 4. * ( 1. - yieldHardOne ) * Bl + 6. ) +
1437 m *pow(yieldHardOne, 2.) / ( sqrt(6.) *
fc );
1441 return dgdrho / dgdsig * 3. * ( 1. - 2. *
nu ) / ( 1. +
nu );
1449 const double tempKappa)
1452 const double R = ( sig -
ft / 3. ) /
fc;
1453 const double mQTension = ( 3. *
ft /
fc +
m / 2. );
1454 const double mQCompression =
1456 const double AConst = -(
ft +
fc ) / ( 3. *
fc ) / log(mQCompression / mQTension);
1457 const double mQ = mQTension * exp(R / AConst);
1463 const double Bl = sig /
fc + rho / (
fc * sqrt(6.) );
1465 const double Al = ( 1. - yieldHardOne ) * pow(Bl, 2.) + sqrt(3. / 2.) * rho /
fc;
1467 const double dAlDYieldHard = -pow(Bl, 2.);
1469 const double dDGDSigDKappa =
1470 ( -4. * Al * Bl /
fc + 4. * ( 1 - yieldHardOne ) /
fc * dAlDYieldHard * Bl +
1471 2. * yieldHardOne * mQ /
fc ) * dYieldHardOneDKappa;
1473 const double dDGDRhoDKappa =
1474 ( dAlDYieldHard / ( sqrt(6.) *
fc ) * ( 4. * ( 1. - yieldHardOne ) * Bl + 6. ) -
1475 4. * Al / ( sqrt(6.) *
fc ) * Bl + 2. *
m * yieldHardOne / ( sqrt(6.) *
fc ) ) * dYieldHardOneDKappa;
1477 answer(0) = dDGDSigDKappa;
1478 answer(1) = dDGDRhoDKappa;
1485 const double tempKappa)
1488 const double R = ( sig -
ft / 3. ) /
fc;
1489 const double mQTension = ( 3. *
ft /
fc +
m / 2. );
1490 const double mQCompression =
1492 const double AConst = -(
ft +
fc ) / ( 3. *
fc ) / log(mQCompression / mQTension);
1494 const double dMQDSig = mQTension / ( AConst *
fc ) * exp(R / AConst);
1500 const double Bl = sig /
fc + rho / (
fc * sqrt(6.) );
1502 const double Al = ( 1. - yieldHardOne ) * pow(Bl, 2.) +
1503 sqrt(3. / 2.) * rho /
fc;
1505 const double dAlDSig = 2. * ( 1. - yieldHardOne ) * Bl /
fc;
1506 const double dBlDSig = 1. /
fc;
1508 const double dAlDRho = 2. * ( 1. - yieldHardOne ) * Bl / (
fc * sqrt(6.) ) + sqrt(3. / 2.) /
fc;
1509 const double dBlDRho = 1. / (
fc * sqrt(6.) );
1512 const double ddgddSig = 4. * ( 1. - yieldHardOne ) /
fc * ( dAlDSig * Bl + Al * dBlDSig ) +
1513 yieldHardOne * yieldHardOne * dMQDSig /
fc;
1515 const double ddgddRho = dAlDRho / ( sqrt(6.) *
fc ) * ( 4. * ( 1. - yieldHardOne ) * Bl + 6. ) +
1516 Al * dBlDRho * 4. * ( 1. - yieldHardOne ) / ( sqrt(6.) *
fc );
1518 const double ddgdSigdRho = 4. * ( 1. - yieldHardOne ) /
fc * ( dAlDRho * Bl + Al * dBlDRho );
1520 const double ddgdRhodSig = dAlDSig / ( sqrt(6.) *
fc ) * ( 4. * ( 1. - yieldHardOne ) * Bl + 6. )
1521 + Al / ( sqrt(6.) *
fc ) * ( 4. * ( 1. - yieldHardOne ) * dBlDSig );
1523 answer(0, 0) = ddgddSig;
1524 answer(0, 1) = ddgdSigdRho;
1525 answer(1, 0) = ddgdRhodSig;
1526 answer(1, 1) = ddgddRho;
1533 const double tempKappa)
1539 double dDKappaDDeltaLambdaDKappa;
1544 dDKappaDDeltaLambdaDKappa =
1549 aMatrixInverse(0, 0) = 1. / (
kM ) +
deltaLambda *dDGDDInv(0, 0);
1550 aMatrixInverse(0, 1) =
deltaLambda * dDGDDInv(0, 1);
1551 aMatrixInverse(0, 2) =
deltaLambda * dDGDInvDKappa(0);
1553 aMatrixInverse(1, 0) =
deltaLambda * dDGDDInv(1, 0);
1554 aMatrixInverse(1, 1) = 1. / ( 2. *
gM ) +
deltaLambda *dDGDDInv(1, 1);
1555 aMatrixInverse(1, 2) =
deltaLambda * dDGDInvDKappa(1);
1557 aMatrixInverse(2, 0) =
deltaLambda * dDKappaDDeltaLambdaDInv(0);
1558 aMatrixInverse(2, 1) =
deltaLambda * dDKappaDDeltaLambdaDInv(1);
1559 aMatrixInverse(2, 2) = -1. +
deltaLambda * dDKappaDDeltaLambdaDKappa;
1569 if ( kappa <= 0. ) {
1571 }
else if ( kappa > 0. && kappa < 1. ) {
1573 kappa * ( pow(kappa, 2.) - 3. * kappa + 3. );
1585 }
else if ( kappa >= 0. && kappa < 1. ) {
1586 return ( 1. -
yieldHardInitial ) * ( 3. * pow(kappa, 2.) - 6. * kappa + 3. );
1600 if ( mode == SecantStiffness || mode == TangentStiffness ) {
1602 if ( omega > 0.9999 ) {
1606 answer.
times(1. - omega);
1672 dJ2DStress = deviatoricStress;
1673 for (
int i = 3; i < size; i++ ) {
1674 dJ2DStress(i) = deviatoricStress(i) * 2.0;
1679 dRhoDStress = dJ2DStress;
1680 dRhoDStress.
times(1. / rho);
1682 answer = dRhoDStress;
1689 for (
int i = 0; i < 3; i++ ) {
1690 answer(i) = 1. / 3.;
1693 for (
int i = 3; i < size; i++ ) {
1714 dJ2dstress = deviatoricStress;
1715 for (
int i = 3; i < deviatoricStress.
giveSize(); i++ ) {
1716 dJ2dstress(i) = deviatoricStress(i) * 2.;
1721 ddJ2ddstress.
zero();
1722 for (
int i = 0; i < size; i++ ) {
1724 ddJ2ddstress(i, i) = 2. / 3.;
1728 ddJ2ddstress(i, i) = 2.;
1732 ddJ2ddstress(0, 1) = -1. / 3.;
1733 ddJ2ddstress(0, 2) = -1. / 3.;
1734 ddJ2ddstress(1, 0) = -1. / 3.;
1735 ddJ2ddstress(1, 2) = -1. / 3.;
1736 ddJ2ddstress(2, 0) = -1. / 3.;
1737 ddJ2ddstress(2, 1) = -1. / 3.;
1741 for (
int v = 0; v < size; v++ ) {
1742 for (
int w = 0; w < size; ++w ) {
1743 dJ2DJ2(v, w) = dJ2dstress(v) * dJ2dstress(w);
1749 ddRhoddStress = ddJ2ddstress;
1750 ddRhoddStress.
times(1. / rho);
1753 help1.
times( -1. / ( rho * rho * rho ) );
1754 ddRhoddStress.
add(help1);
1755 answer = ddRhoddStress;
1778 ds1DStress(0) = principalDir(0, 0) * principalDir(0, 0) - 1. / 3.;
1779 ds1DStress(1) = principalDir(1, 0) * principalDir(1, 0) - 1. / 3.;
1780 ds1DStress(2) = principalDir(2, 0) * principalDir(2, 0) - 1. / 3.;
1781 ds1DStress(3) = 2. * principalDir(1, 0) * principalDir(2, 0);
1782 ds1DStress(4) = 2. * principalDir(2, 0) * principalDir(0, 0);
1783 ds1DStress(5) = 2. * principalDir(0, 0) * principalDir(1, 0);
1787 dCosThetaDStress = ds1DStress;
1788 dCosThetaDStress.
times( sqrt(3. / 2.) * rho / pow(rho, 2.) );
1791 help.
times( -sqrt(3. / 2.) * principalDeviatoricStress(0) / pow(rho, 2.) );
1792 dCosThetaDStress.
add(help);
1793 answer = dCosThetaDStress;
1799 double ACostheta = 4. * ( 1. - ecc *
ecc ) * cos(theta) * cos(theta) +
1800 ( 2. * ecc - 1. ) * ( 2. * ecc - 1. );
1801 double BCostheta = 2. * ( 1. - ecc *
ecc ) * cos(theta) +
1802 ( 2. * ecc - 1. ) * sqrt(4. * ( 1. - ecc * ecc ) * cos(theta) * cos(theta)
1803 + 5. * ecc * ecc - 4. *
ecc);
1804 double A1Costheta = 8. * ( 1. - pow(ecc, 2.) ) * cos(theta);
1805 double B1Costheta = 2. * ( 1. - pow(ecc, 2.) ) +
1806 4. * ( 2. * ecc - 1. ) * ( 1. - pow(ecc, 2.) ) * cos(theta) /
1807 sqrt(4. * ( 1. - pow(ecc, 2.) ) * pow(cos(theta), 2.) +
1808 5. * pow(ecc, 2.) - 4. * ecc);
1809 double dRDCostheta = A1Costheta / BCostheta - ACostheta / pow(BCostheta, 2.) * B1Costheta;
1831 if ( type == IST_PlasticStrainTensor ) {
1834 }
else if ( type == IST_DamageScalar ) {
1838 }
else if ( type == IST_DamageTensor ) {
1843 }
else if ( type == IST_PrincipalDamageTensor ) {
1848 }
else if ( type == IST_DamageTensorTemp ) {
1852 }
else if ( type == IST_CumPlasticStrain ) {
1856 }
else if ( type == IST_CumPlasticStrain_2 ) {
1860 }
else if ( type == IST_VolumetricPlasticStrain ) {
virtual void updateYourself(TimeStep *tStep)
Update equilibrium history variables according to temp-variables.
InternalStateType
Type representing the physical meaning of element or constitutive model internal variable.
void computeDDGDInvDKappa(FloatArray &answer, double sig, double rho, double tempKappa)
Here, the mixed derivative of the plastic potential with respect to the invariants and the hardening ...
static void computePrincipalValues(FloatArray &answer, const FloatArray &s, stressStrainPrincMode mode)
Common functions for convenience.
void subtract(const FloatArray &src)
Subtracts array src to receiver.
void computeDDKappaDDeltaLambdaDInv(FloatArray &answer, double sig, double rho, double tempKappa)
Computes the mixed derivative of the hardening parameter kappa with respect to the plastic multiplier...
double ef
Control parameter for the exponential softening law.
void letTempStrainVectorBe(const FloatArray &v)
Assigns tempStrainVector to given vector v.
void performPlasticityReturn(GaussPoint *gp, FloatArray &strain)
LinearElasticMaterial * giveLinearElasticMaterial()
#define _IFT_ConcreteDPM_fc
GaussPoint * gp
Associated integration point.
double computeDuctilityMeasureDamage(const FloatArray &strain, GaussPoint *gp)
Compute the ductility measure for the damage model.
For computing principal stresses.
For computing principal strains from engineering strains.
double computeMeanSize()
Computes the size of the element defined as its length.
bool solveForRhs(const FloatArray &b, FloatArray &answer, bool transpose=false)
Solves the system of linear equations .
void letTempKappaPBe(double v)
Assign the temp value of the hardening variable of the plasticity model.
#define _IFT_ConcreteDPM_asoft
static double computeSecondCoordinate(const FloatArray &s)
FloatArray tempStrainVector
Temporary strain vector in reduced form (to find balanced state)
The purpose of DataStream abstract class is to allow to store/restore context to different streams...
contextIOResultType storeYourself(DataStream &stream) const
virtual int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep)
Returns the integration point corresponding value in Reduced form.
double & at(int i)
Coefficient access function.
#define _IFT_ConcreteDPM_bhard
double BHard
Parameter of the ductilityMeasure of the plasticity model.
#define _IFT_ConcreteDPM_href
This class implements a structural material status information.
double href
Material parameter of the size-dependent adjustment (reference element size)
#define DPM_DAMAGE_TOLERANCE
FloatArray tempPlasticStrain
FloatArray stressVector
Equilibrated stress vector in reduced form.
virtual contextIOResultType saveContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Stores receiver state to output stream.
void computeDCosThetaDStress(FloatArray &answer, const FloatArray &stress) const
Computes the derivative of costheta with respect to the stress.
static void applyElasticCompliance(FloatArray &strain, const FloatArray &stress, double EModulus, double nu)
void computeDRhoDStress(FloatArray &answer, const FloatArray &stress) const
Computes the derivative of rho with respect to the stress.
Dictionary propertyDictionary
Property dictionary.
int giveStateFlag() const
Get the state flag from the material status.
Concrete_VertexType vertexType
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
virtual void computeEquivalentStrain(double &kappaD, const FloatArray &elasticStrain, GaussPoint *gp, TimeStep *tStep)
Compute equivalent strain value.
Element * giveElement()
Returns corresponding element to receiver.
double dilationConst
Control parameter for te volumetric plastic flow of the plastic potential.
void initDamaged(double kappa, const FloatArray &elasticStrain, GaussPoint *gp)
Initialize the characteristic length, if damage is not yet activated.
#define _IFT_ConcreteDPM_dilation
ConcreteDPM(int n, Domain *d)
Constructor.
virtual void printOutputAt(FILE *file, TimeStep *tStep)
Print receiver's output to given stream.
static void computePrincipalValDir(FloatArray &answer, FloatMatrix &dir, const FloatArray &s, stressStrainPrincMode mode)
Computes principal values and directions of stress or strain vector.
MatResponseMode
Describes the character of characteristic material matrix.
virtual int read(int *data, int count)=0
Reads count integer values into array pointed by data.
#define _IFT_ConcreteDPM_gf
void letTempPlasticStrainBe(const FloatArray &v)
Assign the temp value of deviatoric plastic strain.
void letTempEquivStrainBe(double v)
Assign the temp value of the hardening variable of the damage model.
const FloatArray & givePlasticStrain() const
Get the plastic strain deviator from the material status.
double thetaTrial
The lode angle of the trial stress.
#define _IFT_ConcreteDPM_kinit
virtual void give3dMaterialStiffnessMatrix(FloatMatrix &answer, MatResponseMode mode, GaussPoint *gp, TimeStep *tStep)
Computes full 3d material stiffness matrix at given integration point, time, respecting load history ...
double eM
Elastic Young's modulus.
double giveEquivStrain() const
Get the equivalent strain from the material status.
void beDifferenceOf(const FloatArray &a, const FloatArray &b)
Sets receiver to be a - b.
double kappaD
Hardening variable of damage model.
void computeDDuctilityMeasureDInv(FloatArray &answer, double sig, double rho, double tempKappa)
Computes the first derivative of the ductility measure with respect to the invariants sig and rho bas...
REGISTER_Material_Alt(ConcreteDPM, concreteidp)
double computeInverseDamage(double dam, GaussPoint *gp)
Compute the damage-driving variable from given damage.
double giveLe()
Gives the characteristic length.
virtual int write(const int *data, int count)=0
Writes count integer values from array pointed by data.
void computeAMatrix(FloatMatrix &answer, double sig, double rho, double tempKappa)
This matrix is the core of the closest point projection and collects the derivative of the flow rule ...
virtual contextIOResultType restoreContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Restores the receiver state previously written in stream.
virtual double give(int aProperty, GaussPoint *gp)
Returns the value of material property 'aProperty'.
void computeDGDInv(FloatArray &answer, double sig, double rho, double tempKappa)
Here, the first derivative of the plastic potential with respect to the invariants sig and rho are co...
double giveDeviatoricPlasticStrainNorm()
Get the deviatoric plastic strain norm from the material status.
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
#define _IFT_IsotropicLinearElasticMaterial_talpha
ConcreteDPMStatus(int n, Domain *d, GaussPoint *gp)
Constructor.
#define _IFT_IsotropicLinearElasticMaterial_n
#define _IFT_ConcreteDPM_wf
#define _IFT_ConcreteDPM_chard
double DHard
Parameter of the ductilityMeasure of the plasticity model.
virtual ~ConcreteDPMStatus()
Destructor.
#define _IFT_ConcreteDPM_yieldtol
double computeDDKappaDDeltaLambdaDKappa(double sig, double rho, double tempKappa)
Computes the derivative of the evolution law of the hardening parameter kappa with respect to the har...
LinearElasticMaterial * linearElasticMaterial
Pointer for linear elastic material.
double dotProduct(const FloatArray &x) const
Computes the dot product (or inner product) of receiver and argument.
This class implements an isotropic linear elastic material in a finite element problem.
double fc
Parameters of the yield surface of the plasticity model.
static void applyElasticStiffness(FloatArray &stress, const FloatArray &strain, double EModulus, double nu)
double giveEpsLoc() const
Get the value of omega*ft/E at the expected onset of localization (defined by negative second-order w...
double yieldTol
Yield tolerance for the plasticity model.
double kappaP
Hardening variable of plasticity model.
virtual void give3dMaterialStiffnessMatrix(FloatMatrix &answer, MatResponseMode mode, GaussPoint *gp, TimeStep *tStep)
Computes full 3d material stiffness matrix at given integration point, time, respecting load history ...
double computeHardeningOne(double tempKappa) const
Compute the value of the hardening function based on the hardening variable.
void times(double f)
Multiplies receiver by factor f.
double giveKappaD() const
Get the hardening variable of the damage model from the material status.
virtual int setIPValue(const FloatArray &value, GaussPoint *gp, InternalStateType type)
Sets the value of a certain variable at a given integration point to the given value.
virtual void updateYourself(TimeStep *tStep)
Update equilibrium history variables according to temp-variables.
contextIOResultType restoreYourself(DataStream &stream)
double computeRatioPotential(double sig, double tempKappa)
This function computes the ratio of the volumetric and deviatoric component of the flow direction...
virtual int setIPValue(const FloatArray &value, GaussPoint *gp, InternalStateType type)
Sets the value of a certain variable at a given integration point to the given value.
void giveStressDependentPartOfStrainVector_3d(FloatArray &answer, GaussPoint *gp, const FloatArray &reducedStrainVector, TimeStep *tStep, ValueModeType mode)
#define _IFT_ConcreteDPM_ft
void beProductOf(const FloatMatrix &aMatrix, const FloatArray &anArray)
Receiver becomes the result of the product of aMatrix and anArray.
virtual ConcreteDPMStatus * giveStatus(GaussPoint *gp) const
Returns material status of receiver in given integration point.
double m
The friction parameter of the yield surface.
#define _IFT_IsotropicLinearElasticMaterial_e
void computeTrialCoordinates(const FloatArray &stress, GaussPoint *gp)
Compute the trial coordinates.
void letTempKappaDBe(double v)
Assign the temp value of the hardening variable of the damage model.
void letTempStateFlagBe(int v)
Assign the temp value of the state flag.
double at(int i, int j) const
Coefficient access function.
virtual IRResultType initializeFrom(InputRecord *ir)
Initializes receiver according to object description stored in input record.
double giveTempKappaP() const
Get the temp value of the hardening variable of the plasticity model from the material status...
double yieldHardInitial
Parameter of the hardening law of the plasticity model.
#define _IFT_ConcreteDPM_helem
double computeYieldValue(double sig, double rho, double theta, double tempKappa) const
Compute the yield value based on stress and hardening variable.
virtual contextIOResultType restoreContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Restores the receiver state previously written in stream.
double ASoft
Parameter of the ductilityMeasure of the damage model.
#define _IFT_ConcreteDPM_ahard
void letDeltaLambdaBe(double v)
Assign the value of deviatoric plastic strain.
Abstract base class representing a material status information.
Pair * add(int aKey, double value)
Adds a new Pair with given keyword and value into receiver.
virtual void giveRealStressVector_3d(FloatArray &answer, GaussPoint *gp, const FloatArray &reducedStrain, TimeStep *tStep)
Default implementation relies on giveRealStressVector for second Piola-Kirchoff stress.
FloatArray effectiveStress
Stress and its deviatoric part.
int setIPValue(const FloatArray &value, InternalStateType type)
static double computeThirdCoordinate(const FloatArray &s)
double mQ
The dilation parameter of the plastic potential.
Class representing vector of real numbers.
double deltaLambda
Plastic multiplier of the plasticity model.
const FloatArray & giveTempPlasticStrain() const
Get the temp value of the full plastic strain vector from the material status.
FloatArray strainVector
Equilibrated strain vector in reduced form.
Implementation of matrix containing floating point numbers.
double nu
Elastic Poisson's ration.
IRResultType
Type defining the return values of InputRecord reading operations.
double kM
Elastic bulk modulus.
void letDeltaEquivStrainBe(double v)
Assign the temp value of the damage variable of the damage model.
void letTempStressVectorBe(const FloatArray &v)
Assigns tempStressVector to given vector v.
#define _IFT_ConcreteDPM_dhard
const FloatArray & giveStressVector() const
Returns the const pointer to receiver's stress vector.
double computeDFDKappa(double sig, double rho, double tempKappa)
Compute the derivative of the yield surface with respect to the hardening variable based on the stres...
void computeDDGDDInv(FloatMatrix &answer, double sig, double rho, double tempKappa)
Here, the second derivative of the plastic potential with respect to the invariants sig and rho are c...
void add(const FloatMatrix &a)
Adds matrix to the receiver.
void computeDFDInv(FloatArray &answer, double sig, double rho, double tempKappa) const
Computes the derivative of the yield surface with respect to the invariants sig and rho...
double sig
the volumetric stress.
virtual double computeDuctilityMeasure(double sig, double rho, double theta)
Compute the ductility measure based on the stress state.
#define _IFT_ConcreteDPM_ecc
double computeDKappaDDeltaLambda(double sig, double rho, double tempKappa)
Compute the derivative of kappa with respect of delta lambda based on the stress state and the harden...
double AHard
Parameter of the ductilityMeasure of the plasticity model.
void zero()
Zeroes all coefficients of receiver.
double giveVolumetricPlasticStrain() const
void computeDSigDStress(FloatArray &answer) const
Computes the derivative of sig with respect to the stress.
virtual double giveCharacteristicLength(const FloatArray &normalToCrackPlane)
Returns the size of element in the given direction, in some cases adjusted (e.g.
double computeDRDCosTheta(double theta, double ecc) const
Compute the derivative of R with respect to costheta.
double rho
The length of the deviatoric stress.
virtual void restoreConsistency()
Restores consistency of the status, i.e., computes or corrects the values of certain status variables...
void times(double s)
Multiplies receiver with scalar.
static double computeDeviatoricVolumetricSplit(FloatArray &dev, const FloatArray &s)
Computes split of receiver into deviatoric and volumetric part.
long ContextMode
Context mode (mask), defining the type of information written/read to/from context.
double gM
Elastic shear modulus.
Abstract base class for all "structural" constitutive models.
void letTempEpslocBe(double v)
History variable of the modified size-dependent adjustment Assign the temp value of the damage variab...
void zero()
Zeroes all coefficient of receiver.
virtual void initTempStatus()
Initializes the temporary internal variables, describing the current state according to previously re...
Domain * giveDomain() const
virtual ~ConcreteDPM()
Destructor.
double helem
Element size (to be used in fracture energy approach (crack band).
REGISTER_Material(DummyMaterial)
void letTempVolumetricPlasticStrainBe(double v)
Assign the temp value of the volumetric plastic strain in plane stress.
void performRegularReturn(FloatArray &stress, GaussPoint *gp)
Perform regular stress return for the plasticity model, i.e.
double CHard
Parameter of the ductilityMeasure of the plasticity model.
virtual void initTempStatus()
Initializes the temporary internal variables, describing the current state according to previously re...
int newtonIter
Maximum number of iterations for stress return.
int giveSize() const
Returns the size of receiver.
void assignStateFlag(GaussPoint *gp)
Assign state flag.
virtual contextIOResultType saveContext(DataStream &stream, ContextMode mode, void *obj=NULL)
Stores receiver state to output stream.
double giveTempDamage() const
Get the temp value of the hardening variable of the damage model from the material status...
the oofem namespace is to define a context or scope in which all oofem names are defined.
double damage
Damage variable of damage model.
virtual MaterialStatus * CreateStatus(GaussPoint *gp) const
Creates new copy of associated status and inserts it into given integration point.
double computeDamage(const FloatArray &strain, GaussPoint *gp, TimeStep *tStep)
Perform stress return for the damage model, i.e.
void beInverseOf(const FloatMatrix &src)
Modifies receiver to become inverse of given parameter.
void negated()
Switches the sign of every coefficient of receiver.
double giveKappaP() const
Get the hardening variable of the plasticity model.
const FloatArray & giveStrainVector() const
Returns the const pointer to receiver's strain vector.
FloatArray tempStressVector
Temporary stress vector in reduced form (increments are used mainly in nonlinear analysis) ...
void computeDDRhoDDStress(FloatMatrix &answer, const FloatArray &stress) const
Computes the second derivative of rho with the respect to the stress.
static void transformStressVectorTo(FloatArray &answer, const FloatMatrix &base, const FloatArray &stressVector, bool transpose=false)
Transforms 3d stress vector into another coordinate system.
double computeHardeningOnePrime(double tempKappa) const
Compute the derivative of the hardening function based on the hardening parameter.
virtual int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep)
Returns the integration point corresponding value in Reduced form.
double giveDamage() const
Get the damage variable of the damage model from the material status.
Class representing integration point in finite element program.
This class contains the combination of a local plasticity model for concrete with a local isotropic d...
#define _IFT_ConcreteDPM_newtoniter
Class representing solution step.
virtual void printOutputAt(FILE *file, TimeStep *tStep)
Print receiver's output to given stream.
void performVertexReturn(FloatArray &stress, double apexStress, GaussPoint *gp)
Perform stress return for vertex case of the plasticity model, i.e.
double computeTempKappa(double kappaInitial, double sigTrial, double rhoTrial, double sig)
Compute temporary kappa.
void letTempDamageBe(double v)
Assign the temp value of the damage variable of the damage model.
void add(const FloatArray &src)
Adds array src to receiver.
void setLe(double ls)
Sets the characteristic length.
virtual Material * giveMaterial()
bool checkForVertexCase(double &answer, double sig, double tempKappa)
Check if the trial stress state falls within the vertex region of the plasticity model at the apex of...
void resize(int s)
Resizes receiver towards requested size.
virtual double computeDamageParam(double kappa, GaussPoint *gp)
Compute damage parameter.