mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-02-05 01:34:17 +05:00
0021422: EDF 1963 SMESH: Viscous layer algorithm fails in some cases (cylindre_partition.py)
fix shrinking on cancave FACEs
This commit is contained in:
parent
d27fd22e6d
commit
cd1e7dd18f
@ -772,7 +772,7 @@ namespace
|
|||||||
//const double maxAngle = 5 * Standard_PI180;
|
//const double maxAngle = 5 * Standard_PI180;
|
||||||
if ( !isConvex )
|
if ( !isConvex )
|
||||||
{
|
{
|
||||||
cout << "Concave FACE " << helper.GetMeshDS()->ShapeToIndex( F ) << endl;
|
//cout << "Concave FACE " << helper.GetMeshDS()->ShapeToIndex( F ) << endl;
|
||||||
return true;
|
return true;
|
||||||
// map< double, const SMDS_MeshNode* > u2nodes;
|
// map< double, const SMDS_MeshNode* > u2nodes;
|
||||||
// if ( !SMESH_Algo::GetSortedNodesOnEdge( helper.GetMeshDS(), E,
|
// if ( !SMESH_Algo::GetSortedNodesOnEdge( helper.GetMeshDS(), E,
|
||||||
@ -811,10 +811,12 @@ namespace
|
|||||||
<< "meshSO = GetCurrentStudy().FindObjectID('0:1:2:3')" << endl
|
<< "meshSO = GetCurrentStudy().FindObjectID('0:1:2:3')" << endl
|
||||||
<< "mesh = Mesh( meshSO.GetObject() )"<<endl;
|
<< "mesh = Mesh( meshSO.GetObject() )"<<endl;
|
||||||
}
|
}
|
||||||
~PyDump() {
|
void Finish() {
|
||||||
*py << "mesh.MakeGroup('Prisms of viscous layers',VOLUME,FT_ElemGeomType,'=',Geom_PENTA)"
|
if (py)
|
||||||
<<endl; delete py; py=0;
|
*py << "mesh.MakeGroup('Viscous Prisms',VOLUME,FT_ElemGeomType,'=',Geom_PENTA)"<<endl;
|
||||||
|
delete py; py=0;
|
||||||
}
|
}
|
||||||
|
~PyDump() { Finish(); }
|
||||||
};
|
};
|
||||||
#define dumpFunction(f) { _dumpFunction(f, __LINE__);}
|
#define dumpFunction(f) { _dumpFunction(f, __LINE__);}
|
||||||
#define dumpMove(n) { _dumpMove(n, __LINE__);}
|
#define dumpMove(n) { _dumpMove(n, __LINE__);}
|
||||||
@ -833,12 +835,12 @@ namespace
|
|||||||
for ( int i=1; i < f->NbNodes(); ++i ) *py << f->GetNode(i-1)->GetID()<<", ";
|
for ( int i=1; i < f->NbNodes(); ++i ) *py << f->GetNode(i-1)->GetID()<<", ";
|
||||||
*py << f->GetNode( f->NbNodes()-1 )->GetID() << " ])"<< endl; }}
|
*py << f->GetNode( f->NbNodes()-1 )->GetID() << " ])"<< endl; }}
|
||||||
#else
|
#else
|
||||||
struct PyDump { };
|
struct PyDump { void Finish() {} };
|
||||||
#define dumpFunction(f)
|
#define dumpFunction(f) f
|
||||||
#define dumpMove(n)
|
#define dumpMove(n)
|
||||||
#define dumpCmd(txt)
|
#define dumpCmd(txt)
|
||||||
#define dumpFunctionEnd()
|
#define dumpFunctionEnd()
|
||||||
#define dumpChangeNodes()
|
#define dumpChangeNodes(f)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -982,6 +984,7 @@ SMESH_ComputeErrorPtr _ViscousBuilder::Compute(SMESH_Mesh& theMesh,
|
|||||||
addBoundaryElements();
|
addBoundaryElements();
|
||||||
|
|
||||||
makeGroupOfLE(); // debug
|
makeGroupOfLE(); // debug
|
||||||
|
debugDump.Finish();
|
||||||
|
|
||||||
return _error;
|
return _error;
|
||||||
}
|
}
|
||||||
@ -3944,7 +3947,7 @@ void _ViscousBuilder::fixBadFaces(const TopoDS_Face& F, SMESH_MesherHelper& help
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
involvedFaces.erase( trias[bestCouple].first );
|
involvedFaces.erase( badTrias[iTia] );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ( triaCouples.empty() )
|
if ( triaCouples.empty() )
|
||||||
|
Loading…
Reference in New Issue
Block a user