Skip to content
Snippets Groups Projects
Commit 8463c41f authored by Jean-François Remacle's avatar Jean-François Remacle
Browse files

wrong detj in MLine

parent 2c4d5700
No related branches found
No related tags found
No related merge requests found
...@@ -161,7 +161,7 @@ static double _computeDeterminantAndRegularize(MElement *ele, double jac[3][3]) ...@@ -161,7 +161,7 @@ static double _computeDeterminantAndRegularize(MElement *ele, double jac[3][3])
} }
case 1: case 1:
{ {
dJ = sqrt(SQU(jac[0][0]) + SQU(jac[1][0]) + SQU(jac[2][0])); dJ = sqrt(SQU(jac[0][0]) + SQU(jac[0][1]) + SQU(jac[0][2]));
// regularize matrix // regularize matrix
double a[3], b[3], c[3]; double a[3], b[3], c[3];
......
...@@ -381,6 +381,7 @@ class drawGFace { ...@@ -381,6 +381,7 @@ class drawGFace {
{ {
if(!f->getVisibility()) return; if(!f->getVisibility()) return;
if(f->geomType() == GEntity::DiscreteSurface) return; if(f->geomType() == GEntity::DiscreteSurface) return;
if(f->geomType() == GEntity::PartitionSurface) return;
if(f->geomType() == GEntity::BoundaryLayerSurface) return; if(f->geomType() == GEntity::BoundaryLayerSurface) return;
bool select = (_ctx->render_mode == drawContext::GMSH_SELECT && bool select = (_ctx->render_mode == drawContext::GMSH_SELECT &&
......
...@@ -826,20 +826,15 @@ int CreatePartitionBoundaries(GModel *model) ...@@ -826,20 +826,15 @@ int CreatePartitionBoundaries(GModel *model)
std::set<partitionFace*, Less_partitionFace> pfaces; std::set<partitionFace*, Less_partitionFace> pfaces;
// assign partition faces // assign partition faces
{ if (meshDim == 3){
std::multimap<MFace,MElement*,Less_Face> faceToElement; std::multimap<MFace,MElement*,Less_Face> faceToElement;
if (meshDim == 3){ for(GModel::riter it = model->firstRegion(); it != model->lastRegion(); ++it){
for(GModel::riter it = model->firstRegion(); it != model->lastRegion(); ++it){ fillit_ ( faceToElement,(*it)->tetrahedra.begin(),(*it)->tetrahedra.end());
fillit_ ( faceToElement,(*it)->tetrahedra.begin(),(*it)->tetrahedra.end()); fillit_ ( faceToElement,(*it)->hexahedra.begin(),(*it)->hexahedra.end());
fillit_ ( faceToElement,(*it)->hexahedra.begin(),(*it)->hexahedra.end()); fillit_ ( faceToElement,(*it)->prisms.begin(),(*it)->prisms.end());
fillit_ ( faceToElement,(*it)->prisms.begin(),(*it)->prisms.end()); fillit_ ( faceToElement,(*it)->pyramids.begin(),(*it)->pyramids.end());
fillit_ ( faceToElement,(*it)->pyramids.begin(),(*it)->pyramids.end()); fillit_ ( faceToElement,(*it)->polyhedra.begin(),(*it)->polyhedra.end());
fillit_ ( faceToElement,(*it)->polyhedra.begin(),(*it)->polyhedra.end()); }
}
}
// printf("%d edges to elements\n",edgeToElement.size());
{ {
std::multimap<MFace,MElement*,Less_Face>::iterator it = faceToElement.begin(); std::multimap<MFace,MElement*,Less_Face>::iterator it = faceToElement.begin();
Equal_Face oper; Equal_Face oper;
...@@ -857,7 +852,7 @@ int CreatePartitionBoundaries(GModel *model) ...@@ -857,7 +852,7 @@ int CreatePartitionBoundaries(GModel *model)
} }
// assign partition edges // assign partition edges
{ if (meshDim > 1){
std::multimap<MEdge,MElement*,Less_Edge> edgeToElement; std::multimap<MEdge,MElement*,Less_Edge> edgeToElement;
if (meshDim == 2){ if (meshDim == 2){
for(GModel::fiter it = model->firstFace(); it != model->lastFace(); ++it){ for(GModel::fiter it = model->firstFace(); it != model->lastFace(); ++it){
...@@ -875,9 +870,6 @@ int CreatePartitionBoundaries(GModel *model) ...@@ -875,9 +870,6 @@ int CreatePartitionBoundaries(GModel *model)
fillit_ ( edgeToElement,(*it)->polyhedra.begin(),(*it)->polyhedra.end()); fillit_ ( edgeToElement,(*it)->polyhedra.begin(),(*it)->polyhedra.end());
} }
} }
// printf("%d edges to elements\n",edgeToElement.size());
{ {
std::multimap<MEdge,MElement*,Less_Edge>::iterator it = edgeToElement.begin(); std::multimap<MEdge,MElement*,Less_Edge>::iterator it = edgeToElement.begin();
Equal_Edge oper; Equal_Edge oper;
...@@ -895,7 +887,7 @@ int CreatePartitionBoundaries(GModel *model) ...@@ -895,7 +887,7 @@ int CreatePartitionBoundaries(GModel *model)
} }
// make partition vertices // make partition vertices
{ if (meshDim > 1){
std::multimap<MVertex*,MElement*> vertexToElement; std::multimap<MVertex*,MElement*> vertexToElement;
if (meshDim == 2){ if (meshDim == 2){
for(GModel::fiter it = model->firstFace(); it != model->lastFace(); ++it){ for(GModel::fiter it = model->firstFace(); it != model->lastFace(); ++it){
......
OCCShape("Torus",{0,0,0,0,0,1,10,9},"None"); OCCShape("Torus",{0,0,0,0,0,1,10,9},"None");
//BoundingBox{0,0,0,10,10,10}; BoundingBox{0,0,0,10,10,10};
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment