v0.13.1
Public Member Functions | Public Attributes | List of all members
FractureMechanics::OpPrint Struct Reference

Inherits VolumeElementForcesAndSourcesCore::UserDataOperator.

Collaboration diagram for FractureMechanics::OpPrint:
[legend]

Public Member Functions

 OpPrint (boost::shared_ptr< NonlinearElasticElement > fe, MatrixDouble &s_jac, MatrixDouble &s_inv_jac, bool &s)
 
MoFEMErrorCode doWork (int side, EntityType type, DataForcesAndSourcesCore::EntData &data)
 

Public Attributes

MatrixDouble & sJac
 
MatrixDouble & sInvJac
 
bool S
 
boost::shared_ptr< NonlinearElasticElementfE
 

Detailed Description

Definition at line 4694 of file CrackPropagation.cpp.

Constructor & Destructor Documentation

◆ OpPrint()

FractureMechanics::OpPrint::OpPrint ( boost::shared_ptr< NonlinearElasticElement fe,
MatrixDouble &  s_jac,
MatrixDouble &  s_inv_jac,
bool s 
)

Definition at line 4700 of file CrackPropagation.cpp.

4703 "MESH_NODE_POSITIONS", UserDataOperator::OPROW),
4704 sJac(s_jac), sInvJac(s_inv_jac), S(s), fE(fe) {}
ForcesAndSourcesCore::UserDataOperator UserDataOperator
boost::shared_ptr< NonlinearElasticElement > fE

Member Function Documentation

◆ doWork()

MoFEMErrorCode FractureMechanics::OpPrint::doWork ( int  side,
EntityType  type,
DataForcesAndSourcesCore::EntData data 
)

Definition at line 4706 of file CrackPropagation.cpp.

4707 {
4709 if (type != MBVERTEX)
4711
4712 if (!S)
4714
4715 // double *s_jac_ptr = &sJac(0,0);
4716 // FTensor::Tensor2<double*,3,3> t_s_jac(
4717 // s_jac_ptr,&s_jac_ptr[1],&s_jac_ptr[2],
4718 // &s_jac_ptr[3],&s_jac_ptr[4],&s_jac_ptr[5],
4719 // &s_jac_ptr[6],&s_jac_ptr[7],&s_jac_ptr[8],9
4720 // );
4721 // double *s_inv_jac_ptr = &sInvJac(0,0);
4722 // FTensor::Tensor2<double*,3,3> t_s_inv_jac(
4723 // s_inv_jac_ptr,&s_inv_jac_ptr[1],&s_inv_jac_ptr[2],
4724 // &s_inv_jac_ptr[3],&s_inv_jac_ptr[4],&s_inv_jac_ptr[5],
4725 // &s_inv_jac_ptr[6],&s_inv_jac_ptr[7],&s_inv_jac_ptr[8],9
4726 // );
4727
4728 cerr << data.getDiffN(AINSWORTH_LEGENDRE_BASE) -
4729 data.getDiffN(AINSWORTH_LOBATTO_BASE)
4730 << endl;
4731 cerr << data.getDiffN() << endl;
4732 cerr << data.getBase() << " " << AINSWORTH_LEGENDRE_BASE << endl;
4733
4734 data.getDiffN() = data.getDiffN(AINSWORTH_LOBATTO_BASE);
4735
4736 for (int gg = 0;
4737 gg != static_cast<int>(
4738 fE->commonData.gradAtGaussPts["MESH_NODE_POSITIONS"].size());
4739 gg++) {
4740 MatrixDouble &mat =
4741 fE->commonData.gradAtGaussPts["MESH_NODE_POSITIONS"][gg];
4742 FTensor::Tensor2<double *, 3, 3> tH(&mat(0, 0), &mat(0, 1), &mat(0, 2),
4743 &mat(1, 0), &mat(1, 1), &mat(1, 2),
4744 &mat(2, 0), &mat(2, 1), &mat(2, 2));
4748 cerr << "[" << tH(0, 0) << "," << tH(0, 1) << "," << tH(0, 2) << ";"
4749 << tH(1, 0) << "," << tH(1, 1) << "," << tH(1, 2) << ";" << tH(2, 0)
4750 << "," << tH(2, 1) << "," << tH(2, 2) << "]" << endl;
4751
4752 // cerr << "["
4753 // << t_s_jac(0,0) << "," << t_s_jac(0,1) << "," << t_s_jac(0,2) << ";"
4754 // << t_s_jac(1,0) << "," << t_s_jac(1,1) << "," << t_s_jac(1,2) << ";"
4755 // << t_s_jac(2,0) << "," << t_s_jac(2,1) << "," << t_s_jac(2,2) << "]" <<
4756 // endl;
4757 // cerr << "["
4758 // << t_s_inv_jac(0,0) << "," << t_s_inv_jac(0,1) << "," <<
4759 // t_s_inv_jac(0,2) << ";"
4760 // << t_s_inv_jac(1,0) << "," << t_s_inv_jac(1,1) << "," <<
4761 // t_s_inv_jac(1,2) << ";"
4762 // << t_s_inv_jac(2,0) << "," << t_s_inv_jac(2,1) << "," <<
4763 // t_s_inv_jac(2,2) << "]" << endl;
4764
4765 // FTensor::Tensor2<double,3,3> t_tmp;
4766 // t_tmp(i,j) = tH(i,k)*t_s_inv_jac(j,k);
4767 // tH(i,j) = t_tmp(i,j);
4768 // cerr << std::fixed << std::setprecision(2) <<
4769 // fE->commonData.gradAtGaussPts["MESH_NODE_POSITIONS"][gg] << endl;
4770 //
4771 // ++t_s_jac;
4772 // ++t_s_inv_jac;
4773 }
4774 // cerr << endl << endl;
4776 }
@ AINSWORTH_LEGENDRE_BASE
Ainsworth Cole (Legendre) approx. base .
Definition: definitions.h:60
@ AINSWORTH_LOBATTO_BASE
Definition: definitions.h:62
#define MoFEMFunctionReturnHot(a)
Last executable line of each PETSc function used for error handling. Replaces return()
Definition: definitions.h:447
#define MoFEMFunctionBeginHot
First executable line of each MoFEM function, used for error handling. Final line of MoFEM functions ...
Definition: definitions.h:440
FTensor::Index< 'i', SPACE_DIM > i
FTensor::Index< 'j', 3 > j
FTensor::Index< 'k', 3 > k
UBlasMatrix< double > MatrixDouble
Definition: Types.hpp:77

Member Data Documentation

◆ fE

boost::shared_ptr<NonlinearElasticElement> FractureMechanics::OpPrint::fE

Definition at line 4699 of file CrackPropagation.cpp.

◆ S

bool FractureMechanics::OpPrint::S

Definition at line 4697 of file CrackPropagation.cpp.

◆ sInvJac

MatrixDouble& FractureMechanics::OpPrint::sInvJac

Definition at line 4696 of file CrackPropagation.cpp.

◆ sJac

MatrixDouble& FractureMechanics::OpPrint::sJac

Definition at line 4695 of file CrackPropagation.cpp.


The documentation for this struct was generated from the following file: