mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-12-28 03:37:59 +00:00
ENH: extend globalMeshData::calcCellCells handling
- add convenience forms for common combinations - avoid allocation for 1:1 identity agglomerations - support subsetting forms (avoids an intermediate fvMeshSubset) that also return the cellMap - refactored to eliminate code duplication between weighted and unweighted forms
This commit is contained in:
@ -123,15 +123,9 @@ int main(int argc, char *argv[])
|
||||
|
||||
const label nDomains = max(cellToProc) + 1;
|
||||
|
||||
// Local mesh connectivity
|
||||
CompactListList<label> cellCells;
|
||||
globalMeshData::calcCellCells
|
||||
(
|
||||
mesh,
|
||||
identity(mesh.nCells()),
|
||||
mesh.nCells(),
|
||||
false,
|
||||
cellCells
|
||||
);
|
||||
globalMeshData::calcCellCells(mesh, cellCells);
|
||||
|
||||
decompositionInformation info
|
||||
(
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
\\ / A nd | www.openfoam.com
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
Copyright (C) 2018-2023 OpenCFD Ltd.
|
||||
Copyright (C) 2018-2024 OpenCFD Ltd.
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
@ -112,15 +112,9 @@ void Foam::domainDecompositionDryRun::execute
|
||||
|
||||
decompositionMethod& method = model.decomposer();
|
||||
|
||||
// Local mesh connectivity
|
||||
CompactListList<label> cellCells;
|
||||
globalMeshData::calcCellCells
|
||||
(
|
||||
mesh_,
|
||||
identity(mesh_.nCells()),
|
||||
mesh_.nCells(),
|
||||
false, // false = local only
|
||||
cellCells
|
||||
);
|
||||
globalMeshData::calcCellCells(mesh_, cellCells);
|
||||
|
||||
labelList cellToProc = method.decompose(mesh_, cellWeights);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user