Skip to content
Snippets Groups Projects
Commit ffddf4e5 authored by mattijs's avatar mattijs
Browse files

ENH: regionSplit: improve algorithm order

The old version of regionSplit would hand out regions one by one. This
is a big problem when there are lots of regions - the extreme being
in the decompositionMethods, where it is used to cluster cells and most clusters
being only one cell. This rewrite uses a mesh wave to determine disconnected
regions in one go. This produced non-compact numbering which is then compacted
in a second phase.
On a 14M cell case with cyclic constraints this reduced decompose
time from 40 mins down to 5.
parent 6a1d6567
No related merge requests found
This diff is collapsed.
......@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
......@@ -89,6 +89,9 @@ Description
Can optionally keep all regions local to the processor.
Note: does not walk across cyclicAMI/cyclicACMI - since not 'coupled()'
at the patch level.
SourceFiles
regionSplit.C
......@@ -126,30 +129,10 @@ class regionSplit
// Private Member Functions
//- Transfer faceRegion data from one face to the other (or vice versa)
void transferCoupledFaceRegion
(
const label faceI,
const label otherFaceI,
labelList& faceRegion,
DynamicList<label>& newChangedFaces
) const;
//- Given a seed cell label, fill cellRegion/faceRegion with markValue
// for contiguous region around it
void fillSeedMask
(
const List<labelPair>& explicitConnections,
labelList& cellRegion,
labelList& faceRegion,
const label seedCellID,
const label markValue
) const;
//- Calculate local region split. Return number of regions.
label calcLocalRegionSplit
//- Calculate region split in non-compact (global) numbering.
void calcNonCompactRegionSplit
(
const globalIndex& globalFaces,
const boolList& blockedFace,
const List<labelPair>& explicitConnections,
labelList& cellRegion
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment