MCPcopy Create free account
hub / github.com/OpenSees/OpenSees / commitSensitivity

Method commitSensitivity

SRC/material/nD/BeamFiberMaterial2dPS.cpp:277–311  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

275}
276
277int
278BeamFiberMaterial2dPS::commitSensitivity(const Vector &depsdh, int gradIndex,
279 int numGrads)
280{
281 static Vector dstraindh(6);
282
283 const Matrix &PStangent = theMaterial->getTangent();
284
285 static Matrix dd22(1,1);
286 dd22(0,0) = PStangent(1,1);
287
288 static Matrix dd21(1,2);
289 dd21(0,0) = PStangent(1,0);
290 dd21(0,1) = PStangent(1,2);
291
292 static Vector sigma2(1);
293 sigma2.addMatrixVector(0.0, dd21, depsdh, -1.0);
294
295 const Vector &PSstress = theMaterial->getStressSensitivity(gradIndex, true);
296 //opserr << PSstress;
297 sigma2(0) -= PSstress(1);
298
299 //const Vector &PSstress2 = theMaterial->getStressSensitivity(gradIndex, false);
300 //opserr << PSstress2;
301 //sigma2(0) += PSstress2(1);
302
303 static Vector strain2(1);
304 dd22.Solve(sigma2,strain2);
305
306 dstraindh(0) = depsdh(0);
307 dstraindh(1) = strain2(0);
308 dstraindh(2) = depsdh(1);
309
310 return theMaterial->commitSensitivity(dstraindh, gradIndex, numGrads);
311}
312
313const Matrix&
314BeamFiberMaterial2dPS::getTangent()

Callers

nothing calls this directly

Calls 4

getTangentMethod · 0.45
addMatrixVectorMethod · 0.45
getStressSensitivityMethod · 0.45
SolveMethod · 0.45

Tested by

no test coverage detected