本文整理汇总了C++中TPZAutoPointer::SetAllCreateFunctionsContinuousWithMem方法的典型用法代码示例。如果您正苦于以下问题:C++ TPZAutoPointer::SetAllCreateFunctionsContinuousWithMem方法的具体用法?C++ TPZAutoPointer::SetAllCreateFunctionsContinuousWithMem怎么用?C++ TPZAutoPointer::SetAllCreateFunctionsContinuousWithMem使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TPZAutoPointer
的用法示例。
在下文中一共展示了TPZAutoPointer::SetAllCreateFunctionsContinuousWithMem方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: main1
int main1(int argc, char *argv[])
{
#ifdef LOG4CXX
InitializePZLOG();
#endif
TPZTimer total;
total.start();
std::cout << "COMECA O TEMPO"<< std::endl;
int dimension = 3;
int dim = 2;
int maxlevel = 5;
int sublevel = 3;
int plevel = 1;
TPZPairStructMatrix::gNumThreads = 20;
int numthreads = 20;
// tempo.fNumthreads = numthreads; // alimenta timeTemp com o numero de threads
TPZGeoMesh *gmesh = 0;
{
TPZCompEl::SetgOrder(plevel);
TPZAutoPointer<TPZCompMesh> cmesh;
if(0)
{
TPZGenSubStruct sub(dim,maxlevel,sublevel);
cmesh = sub.GenerateMesh();
cmesh->SetDimModel(dim);
gmesh = cmesh->Reference();
}
else
{
dim = 3;
if (1) // Predio Viscoso
{
int dimension = 3;
gmesh = MalhaPredio();
cmesh = new TPZCompMesh(gmesh);
cmesh->SetDimModel(3);
cmesh->SetDefaultOrder(plevel);
cmesh->SetAllCreateFunctionsContinuousWithMem(dimension);
InsertViscoElasticity(cmesh);
cmesh->AutoBuild();
}
else // Cubo Viscoso
{
int dimension = 3;
gmesh = MalhaCubo();
cmesh = new TPZCompMesh(gmesh);
cmesh->SetDimModel(3);
cmesh->SetDefaultOrder(plevel);
cmesh->SetAllCreateFunctionsContinuousWithMem(dimension);
InsertViscoElasticityCubo(cmesh);
cmesh->AutoBuild();
}
}
std::cout << "Numero de equacoes " << cmesh->NEquations() << std::endl;
int numthread_assemble = 20;
int numthread_decompose = 20;
TPZAutoPointer<TPZCompMesh> cmeshauto(cmesh);
TPZDohrStructMatrix dohrstruct(cmeshauto);
dohrstruct.IdentifyExternalConnectIndexes();
std::cout << "Substructuring the mesh\n";
// TPZfTime timetosub; // init of timer
//REAL height = Height(gmesh);
//int nsubstruct = SubStructure(cmesh, height/2);
dohrstruct.SubStructure(16);
// tempo.ft0sub = timetosub.ReturnTimeDouble(); // end of timer
// std::cout << tempo.ft0sub << std::endl;
// sub.SubStructure();
//Teste Skyline
/*
TPZSkylineStructMatrix skyl(cmesh);
TPZFMatrix<REAL> rhsfake(cmesh->NEquations(),1,0);
int numsubmesh = cmesh->NElements();
TPZAutoPointer<TPZGuiInterface> fakegui = new TPZGuiInterface;
int nel = cmesh->NElements();
for (int iel = 0 ; iel < nel ; iel++)
{
TPZSubCompMesh *subcompmesh = dynamic_cast<TPZSubCompMesh*>(cmesh->ElementVec()[iel]);
if(subcompmesh)
{
subcompmesh->SetAnalysisSkyline(0,0,fakegui);
}
}
TPZMatrix<REAL> *stiff2 = skyl.CreateAssemble(rhsfake, fakegui,numthread_assemble,numthread_decompose);
*/
#ifdef LOG4CXX
//.........这里部分代码省略.........