NeoPZ
|
An interface to "feed" the datastructure of the Dohrmann algorithm. Sub Structure. More...
#include <tpzgensubstruct.h>
Public Types | |
enum | ETypemesh { DistMaterial, RandomMat } |
Public Member Functions | |
TPZGenSubStruct (int dimension, int numlevels, int substructlevel) | |
Constructor. More... | |
~TPZGenSubStruct () | |
TPZAutoPointer< TPZCompMesh > | GenerateMesh () |
Method which will generate the computational mesh. More... | |
void | InitializeDohr (TPZAutoPointer< TPZMatrix< STATE > > dohr, TPZAutoPointer< TPZDohrAssembly< STATE > > assembly) |
Initialize the TPZDohrMatrix structure. More... | |
void | InitializeDohrCondense (TPZAutoPointer< TPZMatrix< STATE > > dohr, TPZAutoPointer< TPZDohrAssembly< STATE > > assembly) |
Initialize the TPZDohrMatrix structure. More... | |
void | ReorderInternalNodes (TPZSubCompMesh *sub, std::map< int, int > &globaltolocal, TPZVec< int > &internalnodes) |
void | SubStructure () |
Divide the elements in substructures. More... | |
Static Public Member Functions | |
static void | ReorderInternalNodes2 (TPZSubCompMesh *sub, TPZVec< int > &internalnodes, TPZVec< int64_t > &invpermute) |
static void | ComputeInternalEquationPermutation (TPZSubCompMesh *sub, TPZVec< int > &scatterpermute, TPZVec< int > &gatherpermute) |
Computes the permutation vectors from the subcompmesh ordening to the "internal first" ordering. More... | |
Public Attributes | |
ETypemesh | fMatDist |
TPZVec< REAL > | fK |
Private Member Functions | |
void | UniformRefine () |
Divide the geometric elements till num levels is achieved. More... | |
void | IdentifyCornerNodes () |
Identify cornernodes. More... | |
void | IdentifyEqNumbers (TPZSubCompMesh *sub, TPZVec< std::pair< int, int > > &globaleq, std::map< int, int > &globinv) |
Identify the global equations as a pair of local equation and global equation. More... | |
void | IdentifyEqNumbers (TPZSubCompMesh *sub, TPZVec< int > &global, std::map< int, int > &globinv) |
Get the global equation numbers of a substructure (and their inverse) More... | |
void | IdentifySubCornerEqs (std::map< int, int > &globaltolocal, TPZVec< int > &cornereqs, TPZVec< int > &coarseindex) |
Identify the corner equations associated with a substructure. More... | |
Static Private Member Functions | |
static int64_t | NInternalEq (TPZSubCompMesh *sub) |
Private Attributes | |
int | fDimension |
Dimension of the mesh. More... | |
int | fNumLevels |
Number of uniform refinements. More... | |
int | fSubstructLevel |
Level of substructures. More... | |
TPZAutoPointer< TPZCompMesh > | fCMesh |
computational mesh More... | |
std::set< int > | fCornerEqs |
The set of equations which correspond to corner nodes. More... | |
An interface to "feed" the datastructure of the Dohrmann algorithm. Sub Structure.
Definition at line 27 of file tpzgensubstruct.h.
Enumerator | |
---|---|
DistMaterial | |
RandomMat |
Definition at line 29 of file tpzgensubstruct.h.
TPZGenSubStruct::TPZGenSubStruct | ( | int | dimension, |
int | numlevels, | ||
int | substructlevel | ||
) |
Constructor.
dimension | |
numlevels | number of uniform refinements |
substructlevel | number of refinements which define the substructures |
Definition at line 44 of file tpzgensubstruct.cpp.
TPZGenSubStruct::~TPZGenSubStruct | ( | ) |
Definition at line 50 of file tpzgensubstruct.cpp.
References co.
|
static |
Computes the permutation vectors from the subcompmesh ordening to the "internal first" ordering.
The mesh is modified during this method but is returned to its original state at the end of execution
Definition at line 729 of file tpzgensubstruct.cpp.
References TPZCompMesh::Block(), TPZSubCompMesh::ComputePermutationInternalFirst(), TPZCompMesh::ConnectVec(), TPZVec< T >::Fill(), TPZConnect::HasDependency(), TPZConnect::IsCondensed(), LOGPZ_DEBUG, TPZBlock< TVar >::NBlocks(), TPZVec< T >::NElements(), TPZChunkVector< T, EXP >::NElements(), TPZBlock< TVar >::Position(), TPZBlock< TVar >::Resequence(), TPZVec< T >::Resize(), TPZBlock< TVar >::Set(), and TPZBlock< TVar >::Size().
Referenced by InitializeDohrCondense().
TPZAutoPointer< TPZCompMesh > TPZGenSubStruct::GenerateMesh | ( | ) |
Method which will generate the computational mesh.
Definition at line 69 of file tpzgensubstruct.cpp.
References TPZCompMesh::AutoBuild(), bc, TPZGeoMesh::BuildConnectivity(), TPZGeoMesh::CreateGeoElement(), ECube, fCMesh, fDimension, TPZCompMesh::FindMaterial(), fK, TPZCompMesh::InsertMaterialObject(), LOGPZ_DEBUG, TPZVec< T >::NElements(), TPZCompMesh::NEquations(), TPZGeoMesh::NodeVec(), TPZCompMesh::Print(), TPZGenGrid::Read(), TPZAdmChunkVector< T, EXP >::Resize(), TPZMatPoisson3d::SetInternalFlux(), TPZMatPoisson3d::SetParameters(), and UniformRefine().
|
private |
Identify cornernodes.
Definition at line 302 of file tpzgensubstruct.cpp.
References TPZNodesetCompute::AnalyseGraph(), TPZCompMesh::Block(), TPZCompMesh::ComputeElGraph(), TPZCompMesh::ComputeNodElCon(), TPZCompMesh::ConnectVec(), TPZRenumbering::ConvertGraph(), fCMesh, fCornerEqs, fDimension, TPZNodesetCompute::Levels(), LOGPZ_DEBUG, TPZNodesetCompute::MaxLevel(), TPZVec< T >::NElements(), TPZCompMesh::NIndependentConnects(), TPZNodesetCompute::Nodegraph(), TPZNodesetCompute::Nodegraphindex(), TPZBlock< TVar >::Position(), TPZNodesetCompute::Print(), TPZfTime::ReturnTimeString(), and TPZBlock< TVar >::Size().
|
private |
Identify the global equations as a pair of local equation and global equation.
Definition at line 599 of file tpzgensubstruct.cpp.
References TPZCompMesh::Block(), TPZCompMesh::ConnectVec(), fCMesh, LOGPZ_DEBUG, TPZChunkVector< T, EXP >::NElements(), TPZCompMesh::NEquations(), TPZSubCompMesh::NodeIndex(), TPZBlock< TVar >::Position(), and TPZBlock< TVar >::Size().
Referenced by InitializeDohr(), and InitializeDohrCondense().
|
private |
Get the global equation numbers of a substructure (and their inverse)
Definition at line 642 of file tpzgensubstruct.cpp.
References TPZCompMesh::Block(), TPZCompMesh::ConnectVec(), fCMesh, LOGPZ_DEBUG, TPZChunkVector< T, EXP >::NElements(), TPZCompMesh::NEquations(), TPZSubCompMesh::NodeIndex(), TPZBlock< TVar >::Position(), TPZVec< T >::Resize(), and TPZBlock< TVar >::Size().
|
private |
Identify the corner equations associated with a substructure.
Definition at line 845 of file tpzgensubstruct.cpp.
References fCornerEqs, LOGPZ_DEBUG, and TPZVec< T >::Resize().
Referenced by InitializeDohr(), and InitializeDohrCondense().
void TPZGenSubStruct::InitializeDohr | ( | TPZAutoPointer< TPZMatrix< STATE > > | dohr, |
TPZAutoPointer< TPZDohrAssembly< STATE > > | assembly | ||
) |
Initialize the TPZDohrMatrix structure.
Definition at line 391 of file tpzgensubstruct.cpp.
References TPZDohrMatrix< TVar, TSubStruct >::AddSubstruct(), TPZCompMesh::ComputeNodElCon(), fCMesh, fCornerEqs, IdentifyEqNumbers(), IdentifySubCornerEqs(), InitializeMatrices(), LOGPZ_DEBUG, TPZCompMesh::NEquations(), nsub, NSubMesh(), TPZMatrix< TVar >::Resize(), TPZDohrMatrix< TVar, TSubStruct >::SetNumCornerEqs(), and SubMesh().
void TPZGenSubStruct::InitializeDohrCondense | ( | TPZAutoPointer< TPZMatrix< STATE > > | dohr, |
TPZAutoPointer< TPZDohrAssembly< STATE > > | assembly | ||
) |
Initialize the TPZDohrMatrix structure.
Definition at line 489 of file tpzgensubstruct.cpp.
References TPZDohrMatrix< TVar, TSubStruct >::AddSubstruct(), ComputeInternalEquationPermutation(), TPZCompMesh::ComputeNodElCon(), fCMesh, fCornerEqs, IdentifyEqNumbers(), IdentifySubCornerEqs(), InitializeMatrices(), LOGPZ_DEBUG, TPZVec< T >::NElements(), TPZCompMesh::NEquations(), nsub, NSubMesh(), TPZVec< T >::Resize(), TPZMatrix< TVar >::Resize(), TPZDohrMatrix< TVar, TSubStruct >::SetNumCornerEqs(), and SubMesh().
|
staticprivate |
Definition at line 900 of file tpzgensubstruct.cpp.
References TPZCompMesh::Block(), TPZCompMesh::ConnectVec(), TPZSubCompMesh::PotentialInternal(), and TPZBlock< TVar >::Size().
Referenced by ReorderInternalNodes(), and ReorderInternalNodes2().
TPZGenSubStruct::ReorderInternalNodes | ( | TPZSubCompMesh * | sub, |
std::map< int, int > & | globaltolocal, | ||
TPZVec< int > & | internalnodes | ||
) |
Definition at line 684 of file tpzgensubstruct.cpp.
References TPZCompMesh::Block(), TPZCompMesh::ConnectVec(), fCMesh, TPZVec< T >::Fill(), LOGPZ_DEBUG, TPZChunkVector< T, EXP >::NElements(), NInternalEq(), TPZSubCompMesh::NodeIndex(), TPZSubCompMesh::PermuteInternalFirst(), TPZBlock< TVar >::Position(), TPZVec< T >::Resize(), and TPZBlock< TVar >::Size().
|
static |
Definition at line 796 of file tpzgensubstruct.cpp.
References TPZCompMesh::Block(), TPZCompMesh::ConnectVec(), TPZVec< T >::Fill(), LOGPZ_DEBUG, TPZVec< T >::NElements(), TPZChunkVector< T, EXP >::NElements(), NInternalEq(), TPZSubCompMesh::PermuteInternalFirst(), TPZBlock< TVar >::Position(), TPZVec< T >::Resize(), and TPZBlock< TVar >::Size().
Referenced by InitializeMatrices().
void TPZGenSubStruct::SubStructure | ( | ) |
Divide the elements in substructures.
Definition at line 188 of file tpzgensubstruct.cpp.
References TPZCompMesh::CleanUpUnconnectedNodes(), TPZCompMesh::ComputeNodElCon(), TPZCompEl::ConnectIndex(), TPZSubCompMesh::ConnectIndex(), TPZCompEl::Dimension(), TPZCompElSide::Element(), TPZGeoMesh::ElementVec(), TPZCompMesh::ElementVec(), TPZCompMesh::ExpandSolution(), fCMesh, fDimension, fSubstructLevel, TPZCompEl::Index(), TPZGeoEl::Level(), TPZCompMesh::LoadReferences(), TPZSubCompMesh::MakeAllInternal(), TPZSubCompMesh::NConnects(), TPZGeoMesh::NElements(), TPZCompMesh::NElements(), TPZVec< T >::NElements(), TPZGeoEl::NSides(), TPZStack< T, NumExtAlloc >::Push(), TPZCompMesh::Reference(), TPZCompElSide::Reference(), TPZGeoMesh::ResetReference(), TPZfTime::ReturnTimeString(), TPZSubCompMesh::TransferElement(), and TPZSubCompMesh::VerifyDatastructureConsistency().
|
private |
Divide the geometric elements till num levels is achieved.
Definition at line 142 of file tpzgensubstruct.cpp.
References TPZGeoEl::Dimension(), DistMaterial, TPZGeoEl::Divide(), TPZGeoMesh::ElementVec(), fCMesh, fK, fMatDist, fNumLevels, TPZGeoEl::HasSubElement(), TPZGeoEl::Level(), TPZGeoEl::MaterialId(), TPZGeoMesh::NElements(), TPZVec< T >::NElements(), nsub, and TPZCompMesh::Reference().
Referenced by GenerateMesh().
|
private |
computational mesh
Definition at line 78 of file tpzgensubstruct.h.
Referenced by GenerateMesh(), IdentifyCornerNodes(), IdentifyEqNumbers(), InitializeDohr(), InitializeDohrCondense(), ReorderInternalNodes(), SubStructure(), and UniformRefine().
|
private |
The set of equations which correspond to corner nodes.
Definition at line 81 of file tpzgensubstruct.h.
Referenced by IdentifyCornerNodes(), IdentifySubCornerEqs(), InitializeDohr(), and InitializeDohrCondense().
|
private |
Dimension of the mesh.
Definition at line 71 of file tpzgensubstruct.h.
Referenced by GenerateMesh(), IdentifyCornerNodes(), and SubStructure().
TPZVec<REAL> TPZGenSubStruct::fK |
Definition at line 36 of file tpzgensubstruct.h.
Referenced by GenerateMesh(), and UniformRefine().
ETypemesh TPZGenSubStruct::fMatDist |
Definition at line 34 of file tpzgensubstruct.h.
Referenced by UniformRefine().
|
private |
Number of uniform refinements.
Definition at line 73 of file tpzgensubstruct.h.
Referenced by UniformRefine().
|
private |
Level of substructures.
Definition at line 75 of file tpzgensubstruct.h.
Referenced by SubStructure().