computes the complete B matrix (membrane, bending and shear)
| 304 | |
| 305 | // computes the complete B matrix (membrane, bending and shear) |
| 306 | void computeBMatrix( |
| 307 | const ASDShellT3LocalCoordinateSystem& LCS, |
| 308 | const Matrix& dNdX, const Vector& N, double xi, double eta, |
| 309 | bool do_opt, Matrix& B |
| 310 | ) |
| 311 | { |
| 312 | // initialize |
| 313 | B.Zero(); |
| 314 | |
| 315 | // geometric data |
| 316 | const auto& p1 = LCS.P1(); |
| 317 | const auto& p2 = LCS.P2(); |
| 318 | const auto& p3 = LCS.P3(); |
| 319 | double y12 = p1.y() - p2.y(); |
| 320 | double y23 = p2.y() - p3.y(); |
| 321 | double y31 = p3.y() - p1.y(); |
| 322 | double x23 = p2.x() - p3.x(); |
| 323 | double x31 = p3.x() - p1.x(); |
| 324 | double x12 = p1.x() - p2.x(); |
| 325 | double x32 = p3.x() - p2.x(); |
| 326 | double y32 = p3.y() - p2.y(); |
| 327 | double x13 = p1.x() - p3.x(); |
| 328 | double y13 = p1.y() - p3.y(); |
| 329 | double x21 = p2.x() - p1.x(); |
| 330 | double y21 = p2.y() - p1.y(); |
| 331 | |
| 332 | // membrane part (ANDeS, basic) |
| 333 | constexpr double alpha_membrane = 1.5; |
| 334 | double A2 = LCS.Area() * 2.0; |
| 335 | B(0, 0) = y23 / A2; |
| 336 | B(2, 0) = -x23 / A2; |
| 337 | B(1, 1) = -x23 / A2; |
| 338 | B(2, 1) = y23 / A2; |
| 339 | B(0, 5) = alpha_membrane * y23 * (-y31 + y12) / 6 / A2; |
| 340 | B(1, 5) = alpha_membrane * (-x23) * (x31 - x12) / 6 / A2; |
| 341 | B(2, 5) = alpha_membrane * (-x31 * y31 + x12 * y12) / 3 / A2; |
| 342 | |
| 343 | B(0, 6) = y31 / A2; |
| 344 | B(2, 6) = -x31 / A2; |
| 345 | B(1, 7) = -x31 / A2; |
| 346 | B(2, 7) = y31 / A2; |
| 347 | B(0, 11) = alpha_membrane * y31 * (-y12 + y23) / 6 / A2; |
| 348 | B(1, 11) = alpha_membrane * (-x31) * (x12 - x23) / 6 / A2; |
| 349 | B(2, 11) = alpha_membrane * (-x12 * y12 + x23 * y23) / 3 / A2; |
| 350 | |
| 351 | B(0, 12) = y12 / A2; |
| 352 | B(2, 12) = -x12 / A2; |
| 353 | B(1, 13) = -x12 / A2; |
| 354 | B(2, 13) = y12 / A2; |
| 355 | B(0, 17) = alpha_membrane * y12 * (-y23 + y31) / 6 / A2; |
| 356 | B(1, 17) = alpha_membrane * (-x12) * (x23 - x31) / 6 / A2; |
| 357 | B(2, 17) = alpha_membrane * (-x23 * y23 + x31 * y31) / 3 / A2; |
| 358 | |
| 359 | // membrane part (ANDeS, higher order) |
| 360 | if (do_opt) { |
| 361 | double b1 = 1.0; |
| 362 | double b2 = 2.0; |
| 363 | double b3 = 1.0; |
no test coverage detected