Skip to content
Snippets Groups Projects
Commit 9f154450 authored by Christophe Geuzaine's avatar Christophe Geuzaine
Browse files

create ghost cells in the usual way in PartitionUsingThisSplit() if they are...

create ghost cells in the usual way in PartitionUsingThisSplit() if they are not explicitly specified
parent 0484eb27
Branches
Tags
No related merge requests found
(Work-in-progress):
4.10.4 (Work-in-progress): small bug fixes.
* New API function: mesh/removeDuplicateElements
......
......@@ -220,7 +220,8 @@ public:
return elements;
}
std::vector<GEntity *> createGhostEntities() {
std::vector<GEntity *> createGhostEntities()
{
std::vector<GEntity *> ghostEntities(_nparts, (GEntity *)nullptr);
int elementaryNumber = _model->getMaxElementaryNumber(_dim);
for(std::size_t i = 1; i <= _nparts; i++) {
......@@ -899,6 +900,7 @@ divideNonConnectedEntities(GModel *model, int dim,
std::set<GVertex *, GEntityPtrLessThan> &vertices)
{
bool ret = false;
// Loop over points
if(dim < 0 || dim == 0) {
int elementaryNumber = model->getMaxElementaryNumber(0);
......@@ -1022,12 +1024,12 @@ divideNonConnectedEntities(GModel *model, int dim,
}
// Move B-Rep
if(BRepFaces.size() > 0) {
std::size_t i = 0;
std::size_t j = 0;
for(auto itBRep = BRepFaces.begin(); itBRep != BRepFaces.end();
++itBRep) {
(*itBRep)->setEdge(pedge, oldOrientations[i]);
(*itBRep)->setEdge(pedge, oldOrientations[j]);
pedge->addFace(*itBRep);
i++;
j++;
}
}
}
......@@ -1118,12 +1120,12 @@ divideNonConnectedEntities(GModel *model, int dim,
}
// Move B-Rep
if(BRepRegions.size() > 0) {
std::size_t i = 0;
std::size_t j = 0;
for(auto itBRep = BRepRegions.begin();
itBRep != BRepRegions.end(); ++itBRep) {
(*itBRep)->setFace(pface, oldOrientations[i]);
(*itBRep)->setFace(pface, oldOrientations[j]);
pface->addRegion(*itBRep);
i++;
j++;
}
}
}
......@@ -2604,7 +2606,7 @@ int PartitionUsingThisSplit(GModel *model,
}
else if(CTX::instance()->mesh.partitionCreateGhostCells) {
graph.clearDualGraph();
graph.createDualGraph(false);
graph.createDualGraph(true);
graph.assignGhostCells();
}
elmToPartition.clear();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment