00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030 #include <ElasticCrossAnisotropic.h>
00031
00032 Tensor ElasticCrossAnisotropic::Dt(4, def_dim_4, 0.0 );
00033 stresstensor ElasticCrossAnisotropic::Stress;
00034
00035
00037 ElasticCrossAnisotropic::ElasticCrossAnisotropic(int tag,
00038 double Ehp,
00039 double Evp,
00040 double nuhvp,
00041 double nuhhp,
00042 double Ghvp,
00043 double rhop):
00044 NDMaterial(tag, ND_TAG_ElasticCrossAnisotropic3D),
00045 Eh(Ehp),
00046 Ev(Evp),
00047 nuhv(nuhvp),
00048 nuhh(nuhhp),
00049 Ghv(Ghvp),
00050 rho(rhop)
00051 {
00052
00053 }
00054
00056 ElasticCrossAnisotropic::ElasticCrossAnisotropic()
00057 {
00058
00059 }
00060
00062 ElasticCrossAnisotropic::~ElasticCrossAnisotropic ()
00063 {
00064
00065 }
00066
00068 double ElasticCrossAnisotropic::getrho()
00069 {
00070 return rho;
00071 }
00072
00074 double ElasticCrossAnisotropic::getMatParameter(int MatParameterID)
00075 {
00076 switch (MatParameterID) {
00077 case (1):
00078 return Eh;
00079 case (2):
00080 return Ev;
00081 case (3):
00082 return nuhv;
00083 case (4):
00084 return nuhh;
00085 case (5):
00086 return Ghv;
00087 case (6):
00088 return rho;
00089 default: {
00090 opserr << "Warning! ElasticIsotropic3D:: incorrect Materal parameter ID" << "\n";
00091 return 0.0;
00092 }
00093 }
00094 }
00095
00097 NDMaterial* ElasticCrossAnisotropic::getCopy (const char *type)
00098 {
00099 if (strcmp(type,"ThreeDimensional") == 0) {
00100 ElasticCrossAnisotropic *theModel;
00101 theModel = new ElasticCrossAnisotropic (this->getTag(), Eh, Ev, nuhv, nuhh, Ghv, rho);
00102 return theModel;
00103 }
00104
00105 else {
00106 opserr <<"ElasticCrossAnisotropic::getModel failed to get model " << type << "\n";
00107 return 0;
00108 }
00109 }
00110
00111 int
00112 ElasticCrossAnisotropic::setTrialStrain (const Tensor &v)
00113 {
00114 Strain = v;
00115 return 0;
00116 }
00117
00118 int
00119 ElasticCrossAnisotropic::setTrialStrain (const Tensor &v, const Tensor &r)
00120 {
00121 Strain = v;
00122 return 0;
00123 }
00124
00125 int
00126 ElasticCrossAnisotropic::setTrialStrainIncr (const Tensor &v)
00127 {
00128 Strain += v;
00129 return 0;
00130 }
00131
00132 int
00133 ElasticCrossAnisotropic::setTrialStrainIncr (const Tensor &v, const Tensor &r)
00134 {
00135 Strain += v;
00136 return 0;
00137 }
00138
00139 const Tensor&
00140 ElasticCrossAnisotropic::getTangentTensor (void)
00141 {
00142
00143
00144
00145
00146
00147
00148
00149
00150
00151
00152
00153
00154
00155
00156
00157
00158
00159
00160
00161 Matrix D(6,6);
00162 double A = 1.0/Eh;
00163 double B = 1.0/Ev;
00164 D(0,0) = D(1,1) = A;
00165 D(2,2) = B;
00166 D(0,1) = D(1,0) = -nuhh*A;
00167 D(0,2) = D(2,0) = D(1,2) = D(2,1) = -nuhv*B;
00168 D(3,3) = 2*(1.0+nuhh)*A;
00169 D(4,4) = D(5,5) = 1.0/Ghv;
00170
00171 D.Invert( D );
00172
00173 Dt.val(1,1,1,1) = D(0,0);
00174 Dt.val(1,1,2,2) = D(0,1);
00175 Dt.val(1,1,3,3) = D(0,2);
00176
00177 Dt.val(1,2,1,2) = D(3,3);
00178 Dt.val(1,2,2,1) = D(3,3);
00179
00180 Dt.val(1,3,1,3) = D(4,4);
00181 Dt.val(1,3,3,1) = D(4,4);
00182
00183 Dt.val(2,1,1,2) = D(3,3);
00184 Dt.val(2,1,2,1) = D(3,3);
00185
00186 Dt.val(2,2,1,1) = D(1,0);
00187 Dt.val(2,2,2,2) = D(1,1);
00188 Dt.val(2,2,3,3) = D(1,2);
00189
00190 Dt.val(2,3,2,3) = D(5,5);
00191 Dt.val(2,3,3,2) = D(5,5);
00192
00193 Dt.val(3,1,1,3) = D(4,4);
00194 Dt.val(3,1,3,1) = D(4,4);
00195
00196 Dt.val(3,2,2,3) = D(5,5);
00197 Dt.val(3,2,3,2) = D(5,5);
00198
00199 Dt.val(3,3,1,1) = D(2,0);
00200 Dt.val(3,3,2,2) = D(2,1);
00201 Dt.val(3,3,3,3) = D(2,2);
00202
00203 return Dt;
00204 }
00205
00206 const stresstensor& ElasticCrossAnisotropic::getStressTensor (void)
00207 {
00208 Tensor Dt0 = getTangentTensor();
00209 Stress = Dt0("ijkl") * Strain("kl");
00210
00211 return Stress;
00212 }
00213
00214 const straintensor& ElasticCrossAnisotropic::getStrainTensor (void)
00215 {
00216 return Strain;
00217 }
00218
00219 int
00220 ElasticCrossAnisotropic::commitState (void)
00221 {
00222 return 0;
00223 }
00224
00225 int
00226 ElasticCrossAnisotropic::revertToLastCommit (void)
00227 {
00228 return 0;
00229 }
00230
00231 int
00232 ElasticCrossAnisotropic::revertToStart (void)
00233 {
00234 Strain = Strain*0.0;
00235 return 0;
00236 }
00237
00238 NDMaterial*
00239 ElasticCrossAnisotropic::getCopy (void)
00240 {
00241 ElasticCrossAnisotropic *theCopy =
00242 new ElasticCrossAnisotropic (this->getTag(), Eh, Ev, nuhv, nuhh, Ghv, rho);
00243
00244 return theCopy;
00245 }
00246
00247 const char*
00248 ElasticCrossAnisotropic::getType (void) const
00249 {
00250 return "ThreeDimensional";
00251 }
00252
00253 int
00254 ElasticCrossAnisotropic::sendSelf(int commitTag, Channel &theChannel)
00255 {
00256
00257 return 0;
00258 }
00259
00260 int
00261 ElasticCrossAnisotropic::recvSelf(int commitTag, Channel &theChannel, FEM_ObjectBroker &theBroker)
00262 {
00263
00264 return 0;
00265 }
00266
00267 void
00268 ElasticCrossAnisotropic::Print (OPS_Stream &s, int flag)
00269 {
00270 s << "Elastic Cross-Anisotropic Material Model\n";
00271 s << "\tEh: " << Eh << "\tEv: " << Ev << "\n";
00272 s << "\tnuhv: " << nuhv << "\tnuhh: " << nuhh << "\n";
00273 s << "\tGhv: " << Ghv << "\trho: " << rho << "\n";
00274
00275 return;
00276 }
00277