NeoPZ
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
TPZMHMixedMeshControl Class Reference

class for creating TPZMHMM with Mixed Meshes More...

#include <TPZMHMixedMeshControl.h>

Inheritance diagram for TPZMHMixedMeshControl:
[legend]
Collaboration diagram for TPZMHMixedMeshControl:
[legend]

Public Member Functions

 TPZMHMixedMeshControl ()
 
 TPZMHMixedMeshControl (int dimension)
 
 TPZMHMixedMeshControl (TPZAutoPointer< TPZGeoMesh > gmesh, TPZVec< int64_t > &coarseindices)
 
 TPZMHMixedMeshControl (TPZAutoPointer< TPZGeoMesh > gmesh)
 
 TPZMHMixedMeshControl (const TPZMHMixedMeshControl &copy)
 
TPZMHMixedMeshControloperator= (const TPZMHMixedMeshControl &cp)
 
virtual ~TPZMHMixedMeshControl ()
 
virtual void InsertPeriferalMaterialObjects ()
 Insert Boundary condition objects that do not perform any actual computation. More...
 
virtual void InsertPeriferalHdivMaterialObjects ()
 Insert the necessary H(div) material objects to create the flux mesh. More...
 
virtual void InsertPeriferalPressureMaterialObjects ()
 Insert the necessary Pressure material objects to create the flux mesh. More...
 
virtual void InsertPeriferalRotationMaterialObjects ()
 Insert the necessary Rotation material objects to create the flux mesh. More...
 
virtual void BuildComputationalMesh (bool usersubstructure)
 Create all data structures for the computational mesh. More...
 
TPZAutoPointer< TPZCompMeshFluxMesh ()
 
void SetLagrangeAveragePressure (bool flag)
 Set the flag for creating Lagrange Dofs for the average pressure. More...
 
virtual void Hybridize (bool flag)
 Set the hybridization to true. More...
 
void GetMeshVec (TPZVec< TPZCompMesh *> &meshvec)
 Put the pointers to the meshes in a vector. More...
 
TPZVec< TPZAutoPointer< TPZCompMesh > > GetMeshes ()
 
void Print (std::ostream &out)
 print the data structure More...
 
virtual void PrintFriendly (std::ostream &out)
 print in a user friendly manner More...
 
- Public Member Functions inherited from TPZMHMeshControl
 TPZMHMeshControl ()
 
 TPZMHMeshControl (int dimension)
 
 TPZMHMeshControl (TPZAutoPointer< TPZGeoMesh > gmesh, TPZVec< int64_t > &geotomhm)
 constructor, indicating that the MHM approximation will use the elements indicated by coarseindices as the macro elements More...
 
 TPZMHMeshControl (TPZAutoPointer< TPZGeoMesh > gmesh)
 create the mhm object without defining the MHM partition More...
 
 TPZMHMeshControl (const TPZMHMeshControl &copy)
 
virtual ~TPZMHMeshControl ()
 
TPZMHMeshControloperator= (const TPZMHMeshControl &cp)
 
TPZAutoPointer< TPZCompMeshCMesh () const
 
TPZAutoPointer< TPZGeoMeshGMesh () const
 
TPZAutoPointer< TPZCompMeshPressureMesh ()
 
void DefinePartitionbyCoarseIndices (TPZVec< int64_t > &coarseindices)
 Define the MHM partition by the coarse element indices. More...
 
void DefineSkeleton (std::map< int64_t, std::pair< int64_t, int64_t > > &skeleton)
 
void DefinePartition (TPZVec< int64_t > &partitionindex, std::map< int64_t, std::pair< int64_t, int64_t > > &skeleton)
 Define the partitioning information of the MHM mesh. More...
 
void DefinePartition (TPZVec< int64_t > &partitionindex)
 Define the partitioning information of the MHM mesh. More...
 
void SetProblemType (MProblemType problem)
 Set the problem type of the simulation. More...
 
void SetInternalPOrder (int order)
 Set the porder for the internal elements. More...
 
void SetSkeletonPOrder (int order)
 
void SetHdivmaismaisPOrder (int order)
 
void SetLagrangeAveragePressure (bool flag)
 Set the flag for creating Lagrange Dofs for the average pressure. More...
 
virtual void SetHybridize (bool flag=true)
 Set the hybridization to true. More...
 
virtual bool GetHybridize ()
 
void DivideSkeletonElements (int ndivide)
 divide the skeleton elements More...
 
void DivideBoundarySkeletonElements ()
 divide the boundary skeleton elements More...
 
void SwitchLagrangeMultiplierSign (bool sw)
 switch the sign of the lagrange multipliers More...
 
void Print (std::ostream &out)
 print the data structure More...
 
void PrintDiagnostics (std::ostream &out)
 Print diagnostics. More...
 
void GetMeshVec (TPZVec< TPZCompMesh *> &meshvec)
 Put the pointers to the meshes in a vector. More...
 
TPZVec< TPZAutoPointer< TPZCompMesh > > GetMeshes ()
 
TPZManVector< int64_t > GetGeoToMHMDomain ()
 
std::map< int64_t, int64_t > & Coarse_to_Submesh ()
 return the coarseindex to submesh index data structure More...
 
virtual void CheckMeshConsistency ()
 verify the consistency of the datastructure More...
 

Protected Member Functions

void CreateHDivMHMMesh ()
 Create the mesh of the flux approximation space. More...
 
virtual void CreatePressureMHMMesh ()
 Create the pressure mesh which is dual to the flux mesh. More...
 
virtual void CreateRotationMesh ()
 Create the rotation mesh to elasticity problem. More...
 
virtual void CreateInternalFluxElements ()
 
virtual void CreateSkeleton ()
 will create the elements on the skeleton More...
 
void CreateHDivPressureMHMMesh ()
 Create the multiphysics mesh. More...
 
void BuildMultiPhysicsMesh ()
 build the multi physics mesh (not at the finest geometric mesh level More...
 
virtual void CreateMultiPhysicsInterfaceElements (int dim)
 Create the interfaces between the pressure elements of dimension dim. More...
 
virtual void CreateMultiPhysicsInterfaceElements (int dim, int pressmatid, std::pair< int, int > skelmatid)
 Create the multiphysics interface elements between elements of specified material id. More...
 
void HideTheElements ()
 put the elements in TPZSubCompMesh, group the elements and condense locally More...
 
virtual void HybridizeSkeleton (int skeletonmatid, int pressurematid)
 
void OptimizeInterfaceElements ()
 switch the elements pointed to by the interface by lower dimensional elements More...
 
virtual void GroupandCondenseElements ()
 group and condense the elements More...
 
void DeletePressureElements ()
 delete the pressure elements leaving the geometric mesh without pointing to the computational mesh More...
 
- Protected Member Functions inherited from TPZMHMeshControl
virtual void CreateSkeletonElements ()
 will create dim-1 geometric elements on the interfaces between the coarse element indices More...
 
TPZCompMeshCriaMalhaTemporaria ()
 will create a computational mesh using the coarse element indexes and its interface elements More...
 
void CreateInternalElements ()
 will create the internal elements, one coarse element at a time More...
 
void AddBoundaryElements ()
 Add the boundary elements to the computational mesh. More...
 
void AddBoundaryInterfaceElements ()
 Add the boundary interface elements to the computational mesh. More...
 
void CreateSkeleton ()
 will create the elements on the skeleton More...
 
void CreateInterfaceElements ()
 will create the interface elements between the internal elements and the skeleton More...
 
void CreateInterfaceElements2 ()
 
bool IsSibling (int64_t son, int64_t father)
 verify if the element is a sibling of More...
 
void AddElementBoundaries (int64_t elseed, int64_t compelindex, TPZStack< TPZCompElSide > &result)
 put the element side which face the boundary on the stack More...
 
void TransferToMultiphysics ()
 transform the computational mesh into a multiphysics mesh More...
 
void SubStructure ()
 substructure the mesh More...
 
void SubStructure2 ()
 
void BuildWrapMesh (int dim)
 Create the wrap elements. More...
 
int HasWrapNeighbour (TPZGeoElSide gelside)
 Verify if the element side contains a wrap neighbour. More...
 
void CheckDivisionConsistency (TPZGeoElSide gelside)
 
int WrapMaterialId (TPZGeoElSide gelside)
 Return the wrap material id (depends on being boundary, neighbour of skeleton or interior. More...
 
virtual bool IsSkeletonMatid (int matid)
 Return true if the material id is related to a skeleton. More...
 
virtual bool IsBoundaryMatid (int matid)
 return true if the material id is related to a boundary More...
 
void CreateWrap (TPZGeoElSide gelside)
 CreateWrapMesh of a given material id. More...
 
void CreateWrap (TPZGeoElSide gelside, int wrapmaterial)
 CreateWrapMesh of a given material id. More...
 
void DivideWrap (TPZGeoEl *wrapelement)
 Divide the wrap element while it has divided neighbours. More...
 
void CreateLagrangeMultiplierMesh ()
 create the lagrange multiplier mesh, one element for each subdomain More...
 
void SetSubdomain (TPZCompEl *cel, int64_t subdomain)
 associates the connects of an element with a subdomain More...
 
void SetSubdomain (TPZCompMesh *cmesh, int64_t connectindex, int64_t subdomain)
 associates the connects index with a subdomain More...
 
int64_t WhichSubdomain (TPZCompEl *cel)
 returns to which subdomain a given element beint64_ts More...
 
void JoinSubdomains (TPZVec< TPZCompMesh *> &meshvec, TPZCompMesh *multiphysicsmesh)
 Subdomains are identified by computational mesh, this method will join. More...
 
void PrintSubdomain (int64_t elindex, std::ostream &out)
 print the diagnostics for a subdomain More...
 
void PrintBoundaryInfo (std::ostream &out)
 print the indices of the boundary elements and interfaces More...
 
void ConnectedElements (int64_t skeleton, std::pair< int64_t, int64_t > &leftright, std::map< int64_t, std::list< TPZCompElSide > > &ellist)
 identify connected elements to the skeleton elements More...
 
void ConnectedInterfaceElements (int64_t skeleton, std::pair< int64_t, int64_t > &leftright, std::map< int64_t, std::list< TPZInterfaceElement *> > &ellist)
 identify interface elements connected to the skeleton elements More...
 

Protected Attributes

TPZAutoPointer< TPZCompMeshfFluxMesh
 computational mesh to contain the pressure elements More...
 
TPZAutoPointer< TPZCompMeshfRotationMesh
 computational mesh to contain the rotation elements More...
 
- Protected Attributes inherited from TPZMHMeshControl
TPZAutoPointer< TPZGeoMeshfGMesh
 geometric mesh used to create the computational mesh More...
 
TPZAutoPointer< TPZCompMeshfCMesh
 computational MHM mesh being built by this class More...
 
TPZAutoPointer< TPZCompMeshfCMeshLagrange
 computational mesh to represent the distributed flux in each subdomain More...
 
TPZAutoPointer< TPZCompMeshfCMeshConstantPressure
 computational mesh to represent the constant states More...
 
TPZAutoPointer< TPZCompMeshfPressureFineMesh
 computational mesh to contain the pressure elements More...
 
MProblemType fProblemType
 Variable defining the type of problem. More...
 
int fNState
 number of state variables More...
 
int fpOrderInternal
 interpolation order of the internal elements More...
 
int fpOrderSkeleton
 interpolation order of the skeleton elements More...
 
int fHdivmaismais
 
int fSkeletonWrapMatId
 material index of the skeleton wrap More...
 
int fBoundaryWrapMatId
 material index of the boundary wrap More...
 
int fInternalWrapMatId
 material index of the internal wrap More...
 
TPZManVector< int64_t > fGeoToMHMDomain
 vector of coarse domain index associated with each geometric element More...
 
std::map< int64_t, int64_t > fMHMtoSubCMesh
 indices of the geometric elements which define the skeleton mesh and their corresponding subcmesh indices More...
 
std::map< int64_t, std::pair< int64_t, int64_t > > fInterfaces
 indices of the skeleton elements and their left/right partition indexes More...
 
std::map< TPZCompMesh *, TPZManVector< int64_t > > fConnectToSubDomainIdentifier
 geometric index of the connects - subdomain where the connect will be internal More...
 
bool fLagrangeAveragePressure
 flag to determine whether a lagrange multiplier is included to force zero average pressures in the subdomains More...
 
bool fHybridize
 flag to indicate whether we create a hybridized mesh More...
 
bool fSwitchLagrangeSign
 flag to indicate whether the lagrange multipliers should switch signal More...
 

Additional Inherited Members

- Public Types inherited from TPZMHMeshControl
enum  MProblemType { ENone, EScalar, EElasticity2D, EElasticity3D }
 Specify the type of differential equation. More...
 
- Public Attributes inherited from TPZMHMeshControl
int fSkeletonMatId
 material id associated with the skeleton elements More...
 
int fSecondSkeletonMatId
 material id associated with the skeleton elements More...
 
int fPressureSkeletonMatId
 material id associated with the skeleton elements in a hybrid context More...
 
int fLagrangeMatIdLeft
 material id associated with the lagrange multiplier elements More...
 
int fLagrangeMatIdRight
 
std::set< int > fMaterialIds
 materials used for modeling the differential equation More...
 
std::set< int > fMaterialBCIds
 materials for boundary conditions More...
 
int64_t fGlobalSystemSize
 number of equations when not condensing anything More...
 
int64_t fGlobalSystemWithLocalCondensationSize
 number of equations considering local condensation More...
 
int64_t fNumeq
 number of equations of the global system More...
 

Detailed Description

class for creating TPZMHMM with Mixed Meshes

Definition at line 17 of file TPZMHMixedMeshControl.h.

Constructor & Destructor Documentation

◆ TPZMHMixedMeshControl() [1/5]

TPZMHMixedMeshControl::TPZMHMixedMeshControl ( )
inline

Definition at line 31 of file TPZMHMixedMeshControl.h.

References dimension.

◆ TPZMHMixedMeshControl() [2/5]

TPZMHMixedMeshControl::TPZMHMixedMeshControl ( int  dimension)

◆ TPZMHMixedMeshControl() [3/5]

TPZMHMixedMeshControl::TPZMHMixedMeshControl ( TPZAutoPointer< TPZGeoMesh gmesh,
TPZVec< int64_t > &  coarseindices 
)

◆ TPZMHMixedMeshControl() [4/5]

TPZMHMixedMeshControl::TPZMHMixedMeshControl ( TPZAutoPointer< TPZGeoMesh gmesh)

◆ TPZMHMixedMeshControl() [5/5]

TPZMHMixedMeshControl::TPZMHMixedMeshControl ( const TPZMHMixedMeshControl copy)
inline

Definition at line 44 of file TPZMHMixedMeshControl.h.

References fFluxMesh.

◆ ~TPZMHMixedMeshControl()

TPZMHMixedMeshControl::~TPZMHMixedMeshControl ( )
virtual

Member Function Documentation

◆ BuildComputationalMesh()

void TPZMHMixedMeshControl::BuildComputationalMesh ( bool  usersubstructure)
virtual

◆ BuildMultiPhysicsMesh()

void TPZMHMixedMeshControl::BuildMultiPhysicsMesh ( )
protected

◆ CreateHDivMHMMesh()

void TPZMHMixedMeshControl::CreateHDivMHMMesh ( )
protected

◆ CreateHDivPressureMHMMesh()

void TPZMHMixedMeshControl::CreateHDivPressureMHMMesh ( )
protected

◆ CreateInternalFluxElements()

void TPZMHMixedMeshControl::CreateInternalFluxElements ( )
protectedvirtual

◆ CreateMultiPhysicsInterfaceElements() [1/2]

void TPZMHMixedMeshControl::CreateMultiPhysicsInterfaceElements ( int  dim)
protectedvirtual

◆ CreateMultiPhysicsInterfaceElements() [2/2]

void TPZMHMixedMeshControl::CreateMultiPhysicsInterfaceElements ( int  dim,
int  pressmatid,
std::pair< int, int >  hdivmatid 
)
protectedvirtual

◆ CreatePressureMHMMesh()

void TPZMHMixedMeshControl::CreatePressureMHMMesh ( )
protectedvirtual

◆ CreateRotationMesh()

void TPZMHMixedMeshControl::CreateRotationMesh ( )
protectedvirtual

◆ CreateSkeleton()

void TPZMHMixedMeshControl::CreateSkeleton ( )
protectedvirtual

◆ DeletePressureElements()

void TPZMHMixedMeshControl::DeletePressureElements ( )
protected

delete the pressure elements leaving the geometric mesh without pointing to the computational mesh

Definition at line 1323 of file TPZMHMixedMeshControl.cpp.

References TPZCompMesh::Element(), TPZMHMeshControl::fGMesh, TPZMHMeshControl::fPressureFineMesh, TPZCompMesh::NElements(), and TPZGeoMesh::ResetReference().

Referenced by PrintFriendly(), and ~TPZMHMixedMeshControl().

◆ FluxMesh()

TPZAutoPointer<TPZCompMesh> TPZMHMixedMeshControl::FluxMesh ( )
inline

Definition at line 72 of file TPZMHMixedMeshControl.h.

References fFluxMesh.

Referenced by TPZMHMixedMeshChannelControl::BuildComputationalMesh().

◆ GetMeshes()

TPZVec<TPZAutoPointer<TPZCompMesh> > TPZMHMixedMeshControl::GetMeshes ( )
inline

Definition at line 99 of file TPZMHMixedMeshControl.h.

References fFluxMesh, TPZMHMeshControl::fPressureFineMesh, and Print().

◆ GetMeshVec()

void TPZMHMixedMeshControl::GetMeshVec ( TPZVec< TPZCompMesh *> &  meshvec)
inline

Put the pointers to the meshes in a vector.

Definition at line 92 of file TPZMHMixedMeshControl.h.

References TPZMHMeshControl::fPressureFineMesh, and TPZVec< T >::Resize().

◆ GroupandCondenseElements()

void TPZMHMixedMeshControl::GroupandCondenseElements ( )
protectedvirtual

◆ HideTheElements()

void TPZMHMixedMeshControl::HideTheElements ( )
protected

◆ Hybridize()

virtual void TPZMHMixedMeshControl::Hybridize ( bool  flag)
inlinevirtual

Set the hybridization to true.

Definition at line 86 of file TPZMHMixedMeshControl.h.

References DebugStop.

◆ HybridizeSkeleton()

void TPZMHMixedMeshControl::HybridizeSkeleton ( int  skeletonmatid,
int  pressurematid 
)
protectedvirtual

◆ InsertPeriferalHdivMaterialObjects()

void TPZMHMixedMeshControl::InsertPeriferalHdivMaterialObjects ( )
virtual

◆ InsertPeriferalMaterialObjects()

void TPZMHMixedMeshControl::InsertPeriferalMaterialObjects ( )
virtual

◆ InsertPeriferalPressureMaterialObjects()

void TPZMHMixedMeshControl::InsertPeriferalPressureMaterialObjects ( )
virtual

◆ InsertPeriferalRotationMaterialObjects()

void TPZMHMixedMeshControl::InsertPeriferalRotationMaterialObjects ( )
virtual

◆ operator=()

TPZMHMixedMeshControl& TPZMHMixedMeshControl::operator= ( const TPZMHMixedMeshControl cp)
inline

◆ OptimizeInterfaceElements()

void TPZMHMixedMeshControl::OptimizeInterfaceElements ( )
protected

switch the elements pointed to by the interface by lower dimensional elements

Referenced by PrintFriendly().

◆ Print()

void TPZMHMixedMeshControl::Print ( std::ostream &  out)

print the data structure

geometric mesh used to create the computational mesh

computational mesh to contain the pressure elements

computational mesh to contain the pressure elements

computational MHM mesh being built by this class

computational mesh to represent the constant states

computational mesh to represent the constant states

material id associated with the skeleton elements

material id associated with the lagrange multiplier elements

interpolation order of the internal elements

interpolation order of the skeleton elements

indices of the geometric elements which define the skeleton mesh

indices of the skeleton elements and their left/right elements of the skeleton mesh

flag to determine whether a lagrange multiplier is included to force zero average pressures in the subdomains

when imposing average pressure to be zero, a multiphysics mesh is created

subdonain indices of the connects

Definition at line 668 of file TPZMHMixedMeshControl.cpp.

References TPZMHMeshControl::fCMesh, TPZMHMeshControl::fCMeshConstantPressure, TPZMHMeshControl::fCMeshLagrange, TPZMHMeshControl::fConnectToSubDomainIdentifier, fFluxMesh, TPZMHMeshControl::fGMesh, TPZMHMeshControl::fInterfaces, TPZMHMeshControl::fLagrangeAveragePressure, TPZMHMeshControl::fLagrangeMatIdLeft, TPZMHMeshControl::fLagrangeMatIdRight, TPZMHMeshControl::fMHMtoSubCMesh, TPZMHMeshControl::fpOrderInternal, TPZMHMeshControl::fpOrderSkeleton, TPZMHMeshControl::fPressureFineMesh, TPZMHMeshControl::fSkeletonMatId, TPZGeoMesh::Print(), TPZCompMesh::Print(), and TPZVec< T >::size().

Referenced by CreateHDivMHMMesh(), and GetMeshes().

◆ PrintFriendly()

virtual void TPZMHMixedMeshControl::PrintFriendly ( std::ostream &  out)
inlinevirtual

◆ SetLagrangeAveragePressure()

void TPZMHMixedMeshControl::SetLagrangeAveragePressure ( bool  flag)
inline

Set the flag for creating Lagrange Dofs for the average pressure.

Definition at line 78 of file TPZMHMixedMeshControl.h.

References DebugStop.

Member Data Documentation

◆ fFluxMesh

TPZAutoPointer<TPZCompMesh> TPZMHMixedMeshControl::fFluxMesh
protected

◆ fRotationMesh

TPZAutoPointer<TPZCompMesh> TPZMHMixedMeshControl::fRotationMesh
protected

computational mesh to contain the rotation elements

Definition at line 26 of file TPZMHMixedMeshControl.h.

Referenced by BuildComputationalMesh(), BuildMultiPhysicsMesh(), CreateHDivPressureMHMMesh(), CreateRotationMesh(), and InsertPeriferalRotationMaterialObjects().


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