45 c_matrix<double,DIM,DIM>& rInvC,
47 c_matrix<double,DIM,DIM>& rT,
55 assert((DIM==2) || (DIM==3));
56 assert(pressure==0.0);
58 static c_matrix<double,DIM,DIM> identity = identity_matrix<double>(DIM);
60 double I1 =
Trace(rC);
64 static c_matrix<double,DIM,DIM> dI2dC;
65 dI2dC = I1*identity - rC;
67 double w1 = Get_dW_dI1(I1,I2,I3);
68 double w2 = Get_dW_dI2(I1,I2,I3);
69 double w3 = Get_dW_dI3(I1,I2,I3);
81 rT = 2*w1*identity + 2*w3*I3*rInvC;
104 double w11 = Get_d2W_dI1(I1,I2,I3);
105 double w22 = Get_d2W_dI2(I1,I2,I3);
106 double w33 = Get_d2W_dI3(I1,I2,I3);
108 double w23 = Get_d2W_dI2I3(I1,I2,I3);
109 double w13 = Get_d2W_dI1I3(I1,I2,I3);
110 double w12 = Get_d2W_dI1I2(I1,I2,I3);
112 for (
unsigned M=0; M<DIM; M++)
114 for (
unsigned N=0; N<DIM; N++)
116 for (
unsigned P=0; P<DIM; P++)
118 for (
unsigned Q=0; Q<DIM; Q++)
120 rDTdE(M,N,P,Q) = 4 * w11 * (M==N) * (P==Q)
121 + 4 * w13 * I3 * ( (M==N) * rInvC(P,Q) + rInvC(M,N)*(P==Q) )
122 + 4 * (w33*I3 + w3) * I3 * rInvC(M,N) * rInvC(P,Q)
123 - 4 * w3 * I3 * rInvC(M,P) * rInvC(Q,N);
127 rDTdE(M,N,P,Q) += 4 * w22 * dI2dC(M,N) * dI2dC(P,Q)
128 + 4 * w12 * ((M==N)*dI2dC(P,Q) + (P==Q)*dI2dC(M,N))
129 + 4 * w23 * I3 * ( dI2dC(M,N)*rInvC(P,Q) + rInvC(M,N)*dI2dC(P,Q))
130 + 4 * w2 * ((M==N)*(P==Q) - (M==P)*(N==Q));
void ComputeStressAndStressDerivative(c_matrix< double, DIM, DIM > &rC, c_matrix< double, DIM, DIM > &rInvC, double pressure, c_matrix< double, DIM, DIM > &rT, FourthOrderTensor< DIM, DIM, DIM, DIM > &rDTdE, bool computeDTdE)