v0.5.86
Classes | Public Member Functions | Public Attributes | List of all members
MoFEM::VolumeElementForcesAndSourcesCoreOnSide Struct Reference

Volume element used to integrate on skeleton. More...

#include <src/finite_elements/VolumeElementForcesAndSourcesCore.hpp>

Inheritance diagram for MoFEM::VolumeElementForcesAndSourcesCoreOnSide:
[legend]
Collaboration diagram for MoFEM::VolumeElementForcesAndSourcesCoreOnSide:
[legend]

Classes

struct  UserDataOperator
 default operator for TET element More...
 

Public Member Functions

 VolumeElementForcesAndSourcesCoreOnSide (Interface &m_field, const EntityType type=MBTET)
 
 ~VolumeElementForcesAndSourcesCoreOnSide ()
 
PetscErrorCode setFaceFEPtr (const FaceElementForcesAndSourcesCore *face_fe_ptr)
 
int getRule (int order)
 set integration rule for finite element More...
 
PetscErrorCode setGaussPts (int order)
 It will be removed in the future use other variant. More...
 
- Public Member Functions inherited from MoFEM::VolumeElementForcesAndSourcesCore
 VolumeElementForcesAndSourcesCore (Interface &m_field, const EntityType type=MBTET)
 
virtual ~VolumeElementForcesAndSourcesCore ()
 
virtual PetscErrorCode setIntegartionPts ()
 Set integration points. More...
 
virtual PetscErrorCode calculateVolumeAndJacobian ()
 Calculate element volume and Jacobian. More...
 
virtual PetscErrorCode calculateCoordinatesAtGaussPts ()
 Calculate coordinate at integration points. More...
 
virtual PetscErrorCode getSpaceBaseAndOrderOnElement ()
 Determine approximation space and order of base functions. More...
 
virtual PetscErrorCode calculateBaseFunctionsOnElement (const int b)
 Calculate base functions. More...
 
virtual PetscErrorCode calculateBaseFunctionsOnElement ()
 Calculate base functions. More...
 
virtual PetscErrorCode transformBaseFunctions ()
 Transform base functions based on geometric element Jacobian. More...
 
virtual PetscErrorCode calculateHoJacobian ()
 Calculate Jacobian for HO geometry. More...
 
virtual PetscErrorCode transformHoBaseFunctions ()
 Transform base functions based on ho-geometry element Jacobian. More...
 
PetscErrorCode operator() ()
 function is run for every finite element More...
 
- Public Member Functions inherited from MoFEM::ForcesAndSourcesCore
 ForcesAndSourcesCore (MoFEM::Interface &m_field)
 
virtual ~ForcesAndSourcesCore ()
 
PetscErrorCode getNumberOfNodes (int &num_nodes) const
 
int getMaxDataOrder () const
 Get max order of approximation for data fields. More...
 
int getMaxRowOrder () const
 Get max order of approximation for field in rows. More...
 
int getMaxColOrder () const
 Get max order of approximation for field in columns. More...
 
PetscErrorCode getSense (EntityType type, boost::ptr_vector< DataForcesAndSourcesCore::EntData > &data) const
 get sense (orientation) of entity More...
 
PetscErrorCode getDataOrder (const EntityType type, const FieldSpace space, boost::ptr_vector< DataForcesAndSourcesCore::EntData > &data) const
 get maximal approximation order of approximation on the entity More...
 
PetscErrorCode getDataOrderSpaceAndBase (const std::string &field_name, const EntityType type, boost::ptr_vector< DataForcesAndSourcesCore::EntData > &data) const
 get maximal approximation order on entity More...
 
PetscErrorCode getEdgesSense (DataForcesAndSourcesCore &data) const
 
PetscErrorCode getTrisSense (DataForcesAndSourcesCore &data) const
 
PetscErrorCode getQuadSense (DataForcesAndSourcesCore &data) const
 
PetscErrorCode getEdgesDataOrder (DataForcesAndSourcesCore &data, const FieldSpace space) const
 
PetscErrorCode getTrisDataOrder (DataForcesAndSourcesCore &data, const FieldSpace space) const
 
PetscErrorCode getQuadDataOrder (DataForcesAndSourcesCore &data, const FieldSpace space) const
 
PetscErrorCode getTetDataOrder (DataForcesAndSourcesCore &data, const FieldSpace space) const
 
PetscErrorCode getPrismDataOrder (DataForcesAndSourcesCore &data, const FieldSpace space) const
 
PetscErrorCode getEdgesDataOrderSpaceAndBase (DataForcesAndSourcesCore &data, const std::string &field_name) const
 
PetscErrorCode getTrisDataOrderSpaceAndBase (DataForcesAndSourcesCore &data, const std::string &field_name) const
 
PetscErrorCode getQuadDataOrderSpaceAndBase (DataForcesAndSourcesCore &data, const std::string &field_name) const
 
PetscErrorCode getTetDataOrderSpaceAndBase (DataForcesAndSourcesCore &data, const std::string &field_name) const
 
PetscErrorCode getPrismDataOrderSpaceAndBase (DataForcesAndSourcesCore &data, const std::string &field_name) const
 
PetscErrorCode getNodesIndices (const boost::string_ref field_name, FENumeredDofEntity_multiIndex &dofs, VectorInt &nodes_indices, VectorInt &local_nodes_indices) const
 get node indices More...
 
PetscErrorCode getTypeIndices (const boost::string_ref field_name, FENumeredDofEntity_multiIndex &dofs, EntityType type, int side_number, VectorInt &indices, VectorInt &local_indices) const
 get indices by type (generic function) More...
 
PetscErrorCode getTypeIndices (const boost::string_ref field_name, FENumeredDofEntity_multiIndex &dofs, EntityType type, boost::ptr_vector< DataForcesAndSourcesCore::EntData > &data) const
 get indices by type (generic function) More...
 
PetscErrorCode getRowNodesIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get row node indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getColNodesIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get col node indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getEdgesRowIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get Edges row indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getEdgesColIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get Edges col indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getTrisRowIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get Tris row indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getTrisColIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get Tris col indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getTetsRowIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get Tets row indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getTetsColIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get Tets col indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getQuadRowIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get Quad row indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getQuadColIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get Quad col indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getPrismRowIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get Prism row indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getPrismColIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get Prism col indices from FENumeredDofEntity_multiIndex More...
 
PetscErrorCode getNoFieldIndices (const std::string &field_name, FENumeredDofEntity_multiIndex &dofs, VectorInt &nodes_indices) const
 get NoField indices More...
 
PetscErrorCode getNoFieldRowIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get col NoField indices More...
 
PetscErrorCode getNoFieldColIndices (DataForcesAndSourcesCore &data, const std::string &field_name) const
 get col NoField indices More...
 
PetscErrorCode getNodesFieldData (const boost::string_ref field_name, FEDofEntity_multiIndex &dofs, VectorDouble &nodes_data, VectorDofs &nodes_dofs, FieldSpace &space, FieldApproximationBase &base) const
 Get field data on nodes. More...
 
PetscErrorCode getTypeFieldData (const boost::string_ref field_name, FEDofEntity_multiIndex &dofs, EntityType type, int side_number, VectorDouble &ent_field_data, VectorDofs &ent_field_dofs) const
 Get field data on entities. More...
 
PetscErrorCode getTypeFieldData (const boost::string_ref field_name, FEDofEntity_multiIndex &dofs, EntityType type, boost::ptr_vector< DataForcesAndSourcesCore::EntData > &data) const
 
PetscErrorCode getNoFieldFieldData (const boost::string_ref field_name, FEDofEntity_multiIndex &dofs, VectorDouble &ent_field_data, VectorDofs &ent_field_dofs) const
 
PetscErrorCode getNoFieldFieldData (DataForcesAndSourcesCore &data, const boost::string_ref field_name) const
 
PetscErrorCode getNodesFieldData (DataForcesAndSourcesCore &data, const std::string &field_name) const
 Get data on nodes. More...
 
PetscErrorCode getEdgesFieldData (DataForcesAndSourcesCore &data, const std::string &field_name) const
 
PetscErrorCode getTrisFieldData (DataForcesAndSourcesCore &data, const std::string &field_name) const
 
PetscErrorCode getQuadFieldData (DataForcesAndSourcesCore &data, const std::string &field_name) const
 
PetscErrorCode getTetsFieldData (DataForcesAndSourcesCore &data, const std::string &field_name) const
 
PetscErrorCode getPrismFieldData (DataForcesAndSourcesCore &data, const std::string &field_name) const
 
PetscErrorCode getFaceTriNodes (DataForcesAndSourcesCore &data) const
 Get nodes on triangles. More...
 
PetscErrorCode getSpacesAndBaseOnEntities (DataForcesAndSourcesCore &data) const
 Get field approximation space and base on entities. More...
 
PetscErrorCode getProblemNodesIndices (const std::string &field_name, const NumeredDofEntity_multiIndex &dofs, VectorInt &nodes_indices) const
 get indices of nodal indices which are declared for problem but not this particular element More...
 
PetscErrorCode getProblemTypeIndices (const std::string &field_name, const NumeredDofEntity_multiIndex &dofs, EntityType type, int side_number, VectorInt &indices) const
 get indices by type (generic function) which are declared for problem but not this particular element More...
 
PetscErrorCode getProblemNodesRowIndices (const std::string &field_name, VectorInt &nodes_indices) const
 
PetscErrorCode getProblemTypeRowIndices (const std::string &field_name, EntityType type, int side_number, VectorInt &indices) const
 
PetscErrorCode getProblemNodesColIndices (const std::string &field_name, VectorInt &nodes_indices) const
 
PetscErrorCode getProblemTypeColIndices (const std::string &field_name, EntityType type, int side_number, VectorInt &indices) const
 
virtual int getRule (int order_row, int order_col, int order_data)
 another variant of getRule More...
 
virtual PetscErrorCode setGaussPts (int order_row, int order_col, int order_data)
 set user specific integration rule More...
 
boost::ptr_vector< UserDataOperator > & getOpPtrVector ()
 Use to push back operator for row operator. More...
 
virtual PetscErrorCode preProcess ()
 function is run at the beginning of loop More...
 
virtual PetscErrorCode postProcess ()
 function is run at the end of loop More...
 
- Public Member Functions inherited from MoFEM::FEMethod
PetscErrorCode queryInterface (const MOFEMuuid &uuid, UnknownInterface **iface)
 
 FEMethod ()
 
template<class MULTIINDEX >
MULTIINDEX::iterator get_begin (const MULTIINDEX &index, const std::string &field_name, const EntityType type, const int side_number) const
 
template<class MULTIINDEX >
MULTIINDEX::iterator get_end (const MULTIINDEX &index, const std::string &field_name, const EntityType type, const int side_number) const
 
template<class MULTIINDEX >
MULTIINDEX::iterator get_begin (const MULTIINDEX &index, const std::string &field_name, const EntityType type) const
 
template<class MULTIINDEX >
MULTIINDEX::iterator get_end (const MULTIINDEX &index, const std::string &field_name, const EntityType type) const
 
template<class MULTIINDEX >
MULTIINDEX::iterator get_begin (const MULTIINDEX &index, const std::string &field_name) const
 
template<class MULTIINDEX >
MULTIINDEX::iterator get_end (const MULTIINDEX &index, const std::string &field_name) const
 
template<class MULTIINDEX >
MULTIINDEX::iterator get_begin (const MULTIINDEX &index, const EntityHandle ent) const
 
template<class MULTIINDEX >
MULTIINDEX::iterator get_end (const MULTIINDEX &index, const EntityHandle ent) const
 
template<class MULTIINDEX >
MULTIINDEX::iterator get_begin (const MULTIINDEX &index, const std::string &field_name, const EntityHandle ent) const
 
template<class MULTIINDEX >
MULTIINDEX::iterator get_end (const MULTIINDEX &index, const std::string &field_name, const EntityHandle ent) const
 
- Public Member Functions inherited from MoFEM::BasicMethod
 BasicMethod ()
 
virtual ~BasicMethod ()
 
int getNinTheLoop () const
 get number of evaluated element in the loop More...
 
int getLoopSize () const
 get loop size More...
 
PetscErrorCode copyBasicMethod (const BasicMethod &basic)
 
- Public Member Functions inherited from MoFEM::KspMethod
 KspMethod ()
 
virtual ~KspMethod ()
 
PetscErrorCode setKspCtx (const KSPContext &ctx)
 set operator type More...
 
PetscErrorCode setKsp (KSP ksp)
 set solver More...
 
PetscErrorCode copyKsp (const KspMethod &ksp)
 copy data form another method More...
 
- Public Member Functions inherited from MoFEM::UnknownInterface
virtual ~UnknownInterface ()
 
virtual PetscErrorCode getLibVersion (Version &version) const
 Get library version. More...
 
virtual const PetscErrorCode getFileVersion (moab::Interface &moab, Version &version) const
 Get database major version. More...
 
virtual PetscErrorCode getInterfaceVersion (Version &version) const
 Get database major version. More...
 
- Public Member Functions inherited from MoFEM::SnesMethod
 SnesMethod ()
 
virtual ~SnesMethod ()
 
PetscErrorCode setSnesCtx (const SNESContext &ctx)
 Set SNES context. More...
 
PetscErrorCode setSnes (SNES snes)
 Set SNES instance. More...
 
PetscErrorCode copySnes (const SnesMethod &snes)
 Copy snes data. More...
 
DEPRECATED PetscErrorCode set_snes (SNES snes)
 
DEPRECATED PetscErrorCode set_snes_ctx (const SNESContext &ctx)
 
DEPRECATED PetscErrorCode copy_snes (const SnesMethod &snes)
 
- Public Member Functions inherited from MoFEM::TSMethod
 TSMethod ()
 
virtual ~TSMethod ()
 
PetscErrorCode setTsCtx (const TSContext &ctx)
 Set Ts context. More...
 
PetscErrorCode copyTs (const TSMethod &ts)
 Copy TS solver data. More...
 
PetscErrorCode setTs (TS _ts)
 Set TS solver. More...
 
DEPRECATED PetscErrorCode set_ts_ctx (const TSContext &ctx)
 
DEPRECATED PetscErrorCode copy_ts (const TSMethod &ts)
 
DEPRECATED PetscErrorCode set_ts (TS _ts)
 

Public Attributes

FaceElementForcesAndSourcesCorefaceFEPtr
 
int faceSense
 Sense of face, could be 1 or -1. More...
 
int faceSideNumber
 Face side number. More...
 
int faceConnMap [3]
 
int tetConnMap [4]
 
int oppositeNode
 
- Public Attributes inherited from MoFEM::VolumeElementForcesAndSourcesCore
VectorDouble coords
 
MatrixDouble3by3 jAc
 
MatrixDouble3by3 invJac
 
DataForcesAndSourcesCore dataH1
 
DerivedDataForcesAndSourcesCore derivedDataH1
 
DataForcesAndSourcesCore dataL2
 
DerivedDataForcesAndSourcesCore derivedDataL2
 
DataForcesAndSourcesCore dataHdiv
 
DerivedDataForcesAndSourcesCore derivedDataHdiv
 
DataForcesAndSourcesCore dataHcurl
 
DerivedDataForcesAndSourcesCore derivedDataHcurl
 
DataForcesAndSourcesCore dataNoField
 
DataForcesAndSourcesCore dataNoFieldCol
 
OpSetInvJacH1 opSetInvJacH1
 
OpSetContravariantPiolaTransform opContravariantPiolaTransform
 
OpSetCovariantPiolaTransform opCovariantPiolaTransform
 
OpSetInvJacHdivAndHcurl opSetInvJacHdivAndHcurl
 
std::string meshPositionsFieldName
 
MatrixDouble hoCoordsAtGaussPts
 
MatrixDouble hoGaussPtsJac
 
MatrixDouble hoGaussPtsInvJac
 
VectorDouble hoGaussPtsDetJac
 
OpGetDataAndGradient< 3, 3 > opHOatGaussPoints
 higher order geometry data at Gauss pts More...
 
OpSetHoInvJacH1 opSetHoInvJacH1
 
OpSetHoContravariantPiolaTransform opHoContravariantTransform
 
OpSetHoCovariantPiolaTransform opHoCovariantTransform
 
OpSetHoInvJacHdivAndHcurl opSetHoInvJacHdivAndHcurl
 
double vOlume
 
int num_nodes
 
const EntityHandleconn
 
FTensor::Tensor2< double *, 3, 3 > tJac
 
FTensor::Tensor2< double *, 3, 3 > tInvJac
 
MatrixDouble gaussPts
 
MatrixDouble coordsAtGaussPts
 
unsigned int nbGaussPts
 Number of integration points. More...
 
- Public Attributes inherited from MoFEM::ForcesAndSourcesCore
InterfacemField
 
RuleHookFun getRuleHook
 Hook to get rule. More...
 
boost::ptr_vector< UserDataOperatoropPtrVector
 
- Public Attributes inherited from MoFEM::FEMethod
std::string feName
 
boost::shared_ptr< const NumeredEntFiniteElementnumeredEntFiniteElementPtr
 
boost::shared_ptr< const FENumeredDofEntity_multiIndexrowPtr
 
boost::shared_ptr< const FENumeredDofEntity_multiIndexcolPtr
 
boost::shared_ptr< const FEDofEntity_multiIndexdataPtr
 
- Public Attributes inherited from MoFEM::BasicMethod
int nInTheLoop
 
int loopSize
 
int rAnk
 
int sIze
 
const RefEntity_multiIndexrefinedEntitiesPtr
 
const RefElement_multiIndexrefinedFiniteElementsPtr
 
const ProblemproblemPtr
 
const Field_multiIndexfieldsPtr
 
const FieldEntity_multiIndexentitiesPtr
 
const DofEntity_multiIndexdofsPtr
 
const FiniteElement_multiIndexfiniteElementsPtr
 
const EntFiniteElement_multiIndexfiniteElementsEntitiesPtr
 
const FieldEntityEntFiniteElementAdjacencyMap_multiIndexadjacenciesPtr
 
boost::function< PetscErrorCode()> preProcessHook
 
boost::function< PetscErrorCode()> postProcessHook
 
boost::function< PetscErrorCode()> operatorHook
 
- Public Attributes inherited from MoFEM::KspMethod
KSPContext ksp_ctx
 Context. More...
 
KSP ksp
 KSP solver. More...
 
Vec ksp_f
 the right hand side vector More...
 
Mat ksp_A
 matrix More...
 
Mat ksp_B
 preconditioner matrix More...
 
- Public Attributes inherited from MoFEM::SnesMethod
SNESContext snes_ctx
 
SNES snes
 
Vec snes_x
 
Vec snes_f
 
Mat snes_A
 
Mat snes_B
 
- Public Attributes inherited from MoFEM::TSMethod
TSContext ts_ctx
 
TS ts
 
Vec ts_u
 
Vec ts_u_t
 
Vec ts_F
 
Mat ts_A
 
Mat ts_B
 
PetscInt ts_step
 
PetscReal ts_a
 
PetscReal ts_t
 

Additional Inherited Members

- Public Types inherited from MoFEM::ForcesAndSourcesCore
typedef boost::function< int(int order_row, int order_col, int order_data)> RuleHookFun
 
- Public Types inherited from MoFEM::KspMethod
enum  KSPContext { CTX_SETFUNCTION, CTX_OPERATORS, CTX_KSPNONE }
 pass information about context of KSP/DM for with finite element is computed More...
 
- Public Types inherited from MoFEM::SnesMethod
enum  SNESContext { CTX_SNESSETFUNCTION, CTX_SNESSETJACOBIAN, CTX_SNESNONE }
 
- Public Types inherited from MoFEM::TSMethod
enum  TSContext {
  CTX_TSSETRHSFUNCTION, CTX_TSSETRHSJACOBIAN, CTX_TSSETIFUNCTION, CTX_TSSETIJACOBIAN,
  CTX_TSTSMONITORSET, CTX_TSNONE
}
 

Detailed Description

Volume element used to integrate on skeleton.

Examples:
hello_world.cpp.

Definition at line 397 of file VolumeElementForcesAndSourcesCore.hpp.

Constructor & Destructor Documentation

◆ VolumeElementForcesAndSourcesCoreOnSide()

MoFEM::VolumeElementForcesAndSourcesCoreOnSide::VolumeElementForcesAndSourcesCoreOnSide ( Interface m_field,
const EntityType  type = MBTET 
)

Definition at line 400 of file VolumeElementForcesAndSourcesCore.hpp.

402  :
403  VolumeElementForcesAndSourcesCore(m_field,type),
404  faceFEPtr(NULL) {
405  }
VolumeElementForcesAndSourcesCore(Interface &m_field, const EntityType type=MBTET)

◆ ~VolumeElementForcesAndSourcesCoreOnSide()

MoFEM::VolumeElementForcesAndSourcesCoreOnSide::~VolumeElementForcesAndSourcesCoreOnSide ( )

Definition at line 406 of file VolumeElementForcesAndSourcesCore.hpp.

406 {}

Member Function Documentation

◆ getRule()

int MoFEM::VolumeElementForcesAndSourcesCoreOnSide::getRule ( int  order)
virtual

set integration rule for finite element

This function is overloaded by the user. The integration rule is set such that specific operator implemented by the user is integrated accurately. For example if user implement bilinear operator

\[ b(u,v) = \int_\mathcal{T} \frac{\partial u_i}{\partial x_j}\frac{\partial v_i}{\partial x_j} \textrm{d}\mathcal{T} \]

then if \(u\) and \(v\) are polynomial of given order, then exact integral would be

int getRule(int order) { return 2*(order-1); };

The integration points and weights are set appropriately for given entity type and integration rule from quad.c

Method ForcesAndSourcesCore::getRule takes at argument takes maximal polynomial order set on the element on all fields defined on the element. If a user likes to have more control, another variant of this function can be called which distinguishing between field orders on rows, columns and data, the i.e. first argument of a bilinear form, the second argument of bilinear form and field coefficents on the element.

Note
If user set rule to -1 or any other negative integer, then method ForcesAndSourcesCore::setGaussPts is called. In that method user can implement own (specific) integration method.
Bug:
this function should be const

Reimplemented from MoFEM::ForcesAndSourcesCore.

Definition at line 414 of file VolumeElementForcesAndSourcesCore.hpp.

414 { return -1; };

◆ setFaceFEPtr()

PetscErrorCode MoFEM::VolumeElementForcesAndSourcesCoreOnSide::setFaceFEPtr ( const FaceElementForcesAndSourcesCore face_fe_ptr)

Definition at line 408 of file VolumeElementForcesAndSourcesCore.hpp.

408  {
409  PetscFunctionBegin;
410  faceFEPtr = const_cast<FaceElementForcesAndSourcesCore*>(face_fe_ptr);
411  PetscFunctionReturn(0);
412  }

◆ setGaussPts()

PetscErrorCode MoFEM::VolumeElementForcesAndSourcesCoreOnSide::setGaussPts ( int  order)
virtual

It will be removed in the future use other variant.

Reimplemented from MoFEM::ForcesAndSourcesCore.

Definition at line 896 of file VolumeElementForcesAndSourcesCore.cpp.

896  {
897  PetscFunctionBegin;
898  if(faceFEPtr==NULL) {
899  SETERRQ(PETSC_COMM_WORLD,MOFEM_DATA_INCONSISTENCY,"Pointer to face element is not set");
900  }
901  const EntityHandle face_entity = faceFEPtr->numeredEntFiniteElementPtr->getEnt();
902  SideNumber_multiIndex& side_table = const_cast<SideNumber_multiIndex&>(
903  numeredEntFiniteElementPtr->getSideNumberTable()
904  );
905  SideNumber_multiIndex::nth_index<0>::type::iterator sit = side_table.get<0>().find(face_entity);
906  if(sit==side_table.get<0>().end()) {
907  SETERRQ(PETSC_COMM_WORLD,MOFEM_DATA_INCONSISTENCY,"Face can not be found on volume element");
908  }
909  faceSense = (*sit)->sense;
910  faceSideNumber = (*sit)->side_number;
911  fill(tetConnMap,&tetConnMap[4],-1);
912  for(int nn = 0;nn!=3;nn++) {
913  faceConnMap[nn] = std::distance(conn,find(conn,&conn[4],faceFEPtr->conn[nn]));
914  tetConnMap[faceConnMap[nn]] = nn;
915  if(faceConnMap[nn]>3) {
916  SETERRQ(
917  PETSC_COMM_WORLD,
919  "No common node on face and element can not be found"
920  );
921  }
922  }
923  oppositeNode = std::distance(tetConnMap,find(tetConnMap,&tetConnMap[4],-1));
924  const int nb_gauss_pts = faceFEPtr->gaussPts.size2();
925  gaussPts.resize(4,nb_gauss_pts,false);
926  gaussPts.clear();
927  const MatrixDouble &face_shape_funtions = faceFEPtr->dataH1.dataOnEntities[MBVERTEX][0].getN(NOBASE);
928  const double tet_coords[] = { 0,0,0, 1,0,0, 0,1,0, 0,0,1 };
929  for(int gg = 0;gg!=nb_gauss_pts;gg++) {
930  gaussPts(0,gg) =
931  face_shape_funtions(gg,0)*tet_coords[3*faceConnMap[0]+0]+
932  face_shape_funtions(gg,1)*tet_coords[3*faceConnMap[1]+0]+
933  face_shape_funtions(gg,2)*tet_coords[3*faceConnMap[2]+0];
934  gaussPts(1,gg) =
935  face_shape_funtions(gg,0)*tet_coords[3*faceConnMap[0]+1]+
936  face_shape_funtions(gg,1)*tet_coords[3*faceConnMap[1]+1]+
937  face_shape_funtions(gg,2)*tet_coords[3*faceConnMap[2]+1];
938  gaussPts(2,gg) =
939  face_shape_funtions(gg,0)*tet_coords[3*faceConnMap[0]+2]+
940  face_shape_funtions(gg,1)*tet_coords[3*faceConnMap[1]+2]+
941  face_shape_funtions(gg,2)*tet_coords[3*faceConnMap[2]+2];
942  gaussPts(3,gg) = faceFEPtr->gaussPts(2,gg);
943  }
944  PetscFunctionReturn(0);
945 }
ublas::matrix< double, ublas::row_major, DoubleAllacator > MatrixDouble
Definition: Common.hpp:136
boost::ptr_vector< EntData > dataOnEntities[MBMAXTYPE]
data on nodes, base function, dofs values, etc.
boost::shared_ptr< const NumeredEntFiniteElement > numeredEntFiniteElementPtr
multi_index_container< boost::shared_ptr< SideNumber >, indexed_by< hashed_unique< member< SideNumber, EntityHandle,&SideNumber::ent > >, ordered_non_unique< composite_key< SideNumber, const_mem_fun< SideNumber, EntityType,&SideNumber::getEntType >, member< SideNumber, char,&SideNumber::side_number > > >, ordered_non_unique< const_mem_fun< SideNumber, EntityType,&SideNumber::getEntType > > > > SideNumber_multiIndex
SideNumber_multiIndex for SideNumber.

Member Data Documentation

◆ faceConnMap

int MoFEM::VolumeElementForcesAndSourcesCoreOnSide::faceConnMap[3]

Definition at line 418 of file VolumeElementForcesAndSourcesCore.hpp.

◆ faceFEPtr

FaceElementForcesAndSourcesCore* MoFEM::VolumeElementForcesAndSourcesCoreOnSide::faceFEPtr

Definition at line 399 of file VolumeElementForcesAndSourcesCore.hpp.

◆ faceSense

int MoFEM::VolumeElementForcesAndSourcesCoreOnSide::faceSense

Sense of face, could be 1 or -1.

Definition at line 414 of file VolumeElementForcesAndSourcesCore.hpp.

◆ faceSideNumber

int MoFEM::VolumeElementForcesAndSourcesCoreOnSide::faceSideNumber

Face side number.

Definition at line 417 of file VolumeElementForcesAndSourcesCore.hpp.

◆ oppositeNode

int MoFEM::VolumeElementForcesAndSourcesCoreOnSide::oppositeNode

Definition at line 420 of file VolumeElementForcesAndSourcesCore.hpp.

◆ tetConnMap

int MoFEM::VolumeElementForcesAndSourcesCoreOnSide::tetConnMap[4]

Definition at line 419 of file VolumeElementForcesAndSourcesCore.hpp.


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