579 {
581
582
583 const size_t nb_gauss_pts = getGaussPts().size2();
584 std::array<double, 9> def;
585 std::fill(def.begin(), def.end(), 0);
586
587 auto get_tag = [&](const std::string name, size_t size) {
590 MB_TAG_CREAT | MB_TAG_SPARSE,
591 def.data());
593 };
594
596
598 mat.clear();
599 for (
size_t r = 0;
r != 3; ++
r)
600 for (
size_t c = 0;
c != 3; ++
c)
602 return mat;
603 };
605 mat.clear();
606 for (
size_t r = 0;
r != 3; ++
r)
608 return mat;
609 };
611 mat.clear();
613 return mat;
614 };
615
618 &*mat.data().begin());
619 };
620
621 auto th_rot_vel = get_tag("ROT_VELOCITY", 3);
622 auto th_tau_jump = get_tag("TAU_JUMP", 1);
623 auto th_plastic_jump = get_tag("PLASTIC_STRAIN_JUMP", 9);
624 auto t_coords = getFTensor1CoordsAtGaussPts();
625 auto t_ep_jump =
626 getFTensor2SymmetricFromMat<3>(*(
commonDataPtr->plasticStrainJumpPtr));
628
629 for (size_t gg = 0; gg != nb_gauss_pts; ++gg) {
630
632 velocity(
i) = (*cache).Omega(
i,
j) * t_coords(
j);
633
634 CHKERR set_tag(th_tau_jump, gg, set_scalar(t_tau_jump));
635 CHKERR set_tag(th_plastic_jump, gg, set_matrix_3d(t_ep_jump));
636 CHKERR set_tag(th_rot_vel, gg, set_vector(velocity));
637 ++t_coords;
638 ++t_ep_jump;
639 ++t_tau_jump;
640 }
641
643}
#define MoFEMFunctionBegin
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
#define MoFEMFunctionReturn(a)
Last executable line of each PETSc function used for error handling. Replaces return()
#define CHKERR
Inline error check.
FTensor::Index< 'i', SPACE_DIM > i
const double c
speed of light (cm/ns)
FTensor::Index< 'j', 3 > j
static auto getFTensor0FromVec(ublas::vector< T, A > &data)
Get tensor rank 0 (scalar) form data vector.
constexpr double t
plate stiffness