Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Development
openfoam
Commits
14a40417
Commit
14a40417
authored
Jan 07, 2019
by
Mark OLESEN
Browse files
ENH: for-range, forAllIters() ... in applications/utilities
- reduced clutter when iterating over containers
parent
1458b4f6
Changes
76
Hide whitespace changes
Inline
Side-by-side
applications/test/callback/Test-callback.C
View file @
14a40417
...
...
@@ -72,7 +72,7 @@ public:
void
testCallbackFunction
()
const
{
forAllConstIter
(
callbackRegistry
,
*
this
,
iter
)
forAllConstIter
s
(
*
this
,
iter
)
{
iter
().
testCallbackFunction
();
}
...
...
applications/test/cyclic/Test-cyclic.C
View file @
14a40417
...
...
@@ -55,7 +55,7 @@ int main(int argc, char *argv[])
Info
<<
fvc
::
div
(
U
);
Info
<<
"
e
nd"
<<
endl
;
Info
<<
"
E
nd"
<<
endl
;
}
...
...
applications/test/delete/Test-delete.C
View file @
14a40417
...
...
@@ -54,7 +54,7 @@ int main()
a
=
h
+
i
+
j
;
Info
<<
a
<<
endl
;
Info
<<
"
e
nd"
<<
endl
;
Info
<<
"
E
nd"
<<
endl
;
return
0
;
}
...
...
applications/test/fvc/Test-fvc.C
View file @
14a40417
...
...
@@ -57,7 +57,7 @@ int main(int argc, char *argv[])
Info
<<
(
gradx4a
-
gradx4
[
i
])
/
gradx4a
<<
endl
;
}
Info
<<
"
e
nd"
<<
endl
;
Info
<<
"
E
nd"
<<
endl
;
}
...
...
applications/test/fvc2D/Test-fvc2D.C
View file @
14a40417
...
...
@@ -65,7 +65,7 @@ int main(int argc, char *argv[])
mesh
);
Info
<<
"
e
nd"
<<
endl
;
Info
<<
"
E
nd"
<<
endl
;
}
...
...
applications/test/graph/Test-graph.C
View file @
14a40417
...
...
@@ -65,7 +65,7 @@ int main()
);
phi
.
write
(
"phi"
,
"xmgr"
);
Info
<<
"
e
nd"
<<
endl
;
Info
<<
"
E
nd"
<<
endl
;
}
...
...
applications/test/graph/graphTest2.C
View file @
14a40417
...
...
@@ -57,7 +57,7 @@ int main()
"xmgr"
);
Info
<<
"
e
nd"
<<
endl
;
Info
<<
"
E
nd"
<<
endl
;
}
...
...
applications/test/graphXi/Test-graphXi.C
View file @
14a40417
...
...
@@ -57,7 +57,7 @@ int main()
graph
(
"r"
,
"x"
,
"r"
,
x
,
r
).
write
(
"r"
,
"xmgr"
);
Info
<<
"
e
nd"
<<
endl
;
Info
<<
"
E
nd"
<<
endl
;
return
0
;
}
...
...
applications/test/passiveParticle/Test-passiveParticle.C
View file @
14a40417
...
...
@@ -59,11 +59,11 @@ int main(int argc, char *argv[])
Pout
<<
"Adding a particle."
<<
endl
;
particles
.
addParticle
(
new
passiveParticle
(
mesh
,
Zero
,
-
1
));
for
AllConstIter
(
passiveParticle
Cloud
,
particles
,
iter
)
for
(
const
passiveParticle
&
p
:
particles
)
{
Pout
<<
" "
<<
iter
()
.
position
()
<<
" cell:"
<<
iter
()
.
cell
()
<<
" origProc:"
<<
iter
()
.
origProc
()
<<
" origId:"
<<
iter
()
.
origId
()
Pout
<<
" "
<<
p
.
position
()
<<
" cell:"
<<
p
.
cell
()
<<
" origProc:"
<<
p
.
origProc
()
<<
" origId:"
<<
p
.
origId
()
<<
endl
;
}
...
...
@@ -80,11 +80,11 @@ int main(int argc, char *argv[])
passiveParticleCloud
particles
(
mesh
,
cloudName
);
Pout
<<
"Reread particles:"
<<
particles
.
size
()
<<
endl
;
for
AllConstIter
(
passiveParticle
Cloud
,
particles
,
iter
)
for
(
const
passiveParticle
&
p
:
particles
)
{
Pout
<<
" "
<<
iter
()
.
position
()
<<
" cell:"
<<
iter
()
.
cell
()
<<
" origProc:"
<<
iter
()
.
origProc
()
<<
" origId:"
<<
iter
()
.
origId
()
Pout
<<
" "
<<
p
.
position
()
<<
" cell:"
<<
p
.
cell
()
<<
" origProc:"
<<
p
.
origProc
()
<<
" origId:"
<<
p
.
origId
()
<<
endl
;
}
}
...
...
applications/test/syncTools/Test-syncTools.C
View file @
14a40417
...
...
@@ -261,10 +261,10 @@ void testSparseData(const polyMesh& mesh, Random& rndGen)
}
// 2. Does sparseData contain more?
forAllConstIter
(
Map
<
point
>
,
sparseData
,
iter
)
forAllConstIter
s
(
sparseData
,
iter
)
{
const
point
&
sparsePt
=
iter
();
label
meshPointi
=
iter
.
key
();
const
label
meshPointi
=
iter
.
key
();
const
point
&
sparsePt
=
iter
.
val
();
const
point
&
fullPt
=
fullData
[
meshPointi
];
if
(
fullPt
!=
sparsePt
)
...
...
@@ -350,9 +350,9 @@ void testSparseData(const polyMesh& mesh, Random& rndGen)
{
const
edge
&
e
=
mesh
.
edges
()[
meshEdgeI
];
EdgeMap
<
point
>::
const_itera
to
r
iter
=
sparseData
.
find
(
e
);
const
au
to
iter
=
sparseData
.
c
find
(
e
);
if
(
iter
!=
sparseData
.
e
nd
())
if
(
iter
.
fou
nd
())
{
const
point
&
sparsePt
=
iter
();
const
point
&
fullPt
=
fullData
[
meshEdgeI
];
...
...
applications/utilities/mesh/advanced/PDRMesh/PDRMesh.C
View file @
14a40417
...
...
@@ -711,18 +711,18 @@ int main(int argc, char *argv[])
setsAndPatches
[
setI
][
1
]
);
for
AllConstIter
(
faceSet
,
fSet
,
iter
)
for
(
const
label
facei
:
fSet
)
{
if
(
wantedPatch
[
iter
.
key
()
]
!=
-
1
)
if
(
wantedPatch
[
facei
]
!=
-
1
)
{
FatalErrorInFunction
<<
"Face "
<<
iter
.
key
()
<<
"Face "
<<
facei
<<
" is in faceSet "
<<
setsAndPatches
[
setI
][
0
]
<<
" destined for patch "
<<
setsAndPatches
[
setI
][
1
]
<<
" but also in patch "
<<
wantedPatch
[
iter
.
key
()
]
<<
" but also in patch "
<<
wantedPatch
[
facei
]
<<
exit
(
FatalError
);
}
wantedPatch
[
iter
.
key
()
]
=
patchi
;
wantedPatch
[
facei
]
=
patchi
;
}
}
...
...
@@ -749,20 +749,21 @@ int main(int argc, char *argv[])
faceSet
fSet
(
mesh
,
coupledAndPatches
[
setI
][
0
]);
label
patchi
=
findPatch
(
patches
,
coupledAndPatches
[
setI
][
1
]);
for
AllConstIter
(
faceSet
,
fSet
,
iter
)
for
(
const
label
facei
:
fSet
)
{
if
(
coupledWantedPatch
[
iter
.
key
()
]
!=
-
1
)
if
(
coupledWantedPatch
[
facei
]
!=
-
1
)
{
FatalErrorInFunction
<<
"Face "
<<
iter
.
key
()
<<
"Face "
<<
facei
<<
" is in faceSet "
<<
coupledAndPatches
[
setI
][
0
]
<<
" destined for patch "
<<
coupledAndPatches
[
setI
][
1
]
<<
" but also in patch "
<<
coupledWantedPatch
[
iter
.
key
()
]
<<
" but also in patch "
<<
coupledWantedPatch
[
facei
]
<<
exit
(
FatalError
);
}
coupledWantedPatch
[
iter
.
key
()]
=
patchi
;
cyclicWantedPatch_half0
[
iter
.
key
()]
=
cyclicId
;
cyclicWantedPatch_half1
[
iter
.
key
()]
=
cyclicSlaveId
;
coupledWantedPatch
[
facei
]
=
patchi
;
cyclicWantedPatch_half0
[
facei
]
=
cyclicId
;
cyclicWantedPatch_half1
[
facei
]
=
cyclicSlaveId
;
}
}
...
...
applications/utilities/mesh/advanced/modifyMesh/cellSplitter.C
View file @
14a40417
...
...
@@ -80,25 +80,24 @@ Foam::label Foam::cellSplitter::newOwner
const
Map
<
labelList
>&
cellToCells
)
const
{
label
old
Own
=
mesh_
.
faceOwner
()[
facei
];
const
label
old
=
mesh_
.
faceOwner
()[
facei
];
Map
<
labelList
>::
const_iterator
fnd
=
cellToCells
.
find
(
old
Own
);
const
auto
iter
=
cellToCells
.
c
find
(
old
);
if
(
fnd
==
cellToCells
.
e
nd
())
if
(
!
iter
.
fou
nd
())
{
// Unsplit cell
return
old
Own
;
return
old
;
}
else
{
// Look up index of face in the cells' faces.
const
labelList
&
newCells
=
fnd
();
const
cell
&
cFaces
=
mesh_
.
cells
()[
oldOwn
];
// Look up index of face in the cells' faces.
return
newCells
[
cFaces
.
find
(
facei
)];
}
const
labelList
&
newCells
=
*
iter
;
const
cell
&
cFaces
=
mesh_
.
cells
()[
old
];
return
newCells
[
cFaces
.
find
(
facei
)];
}
...
...
@@ -108,31 +107,29 @@ Foam::label Foam::cellSplitter::newNeighbour
const
Map
<
labelList
>&
cellToCells
)
const
{
label
old
Nbr
=
mesh_
.
faceNeighbour
()[
facei
];
const
label
old
=
mesh_
.
faceNeighbour
()[
facei
];
Map
<
labelList
>::
const_iterator
fnd
=
cellToCells
.
find
(
old
Nbr
);
const
auto
iter
=
cellToCells
.
c
find
(
old
);
if
(
fnd
==
cellToCells
.
e
nd
())
if
(
!
iter
.
fou
nd
())
{
// Unsplit cell
return
old
Nbr
;
return
old
;
}
else
{
// Look up index of face in the cells' faces.
const
labelList
&
newCells
=
fnd
();
const
cell
&
cFaces
=
mesh_
.
cells
()[
oldNbr
];
// Look up index of face in the cells' faces.
return
newCells
[
cFaces
.
find
(
facei
)];
}
const
labelList
&
newCells
=
*
iter
;
const
cell
&
cFaces
=
mesh_
.
cells
()[
old
];
return
newCells
[
cFaces
.
find
(
facei
)];
}
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
// Construct from components
Foam
::
cellSplitter
::
cellSplitter
(
const
polyMesh
&
mesh
)
:
mesh_
(
mesh
),
...
...
@@ -140,12 +137,6 @@ Foam::cellSplitter::cellSplitter(const polyMesh& mesh)
{}
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
Foam
::
cellSplitter
::~
cellSplitter
()
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
void
Foam
::
cellSplitter
::
setRefinement
...
...
@@ -162,9 +153,9 @@ void Foam::cellSplitter::setRefinement
// Introduce cellToMidPoints.
//
forAllConstIter
(
Map
<
point
>
,
cellToMidPoint
,
iter
)
forAllConstIter
s
(
cellToMidPoint
,
iter
)
{
label
celli
=
iter
.
key
();
const
label
celli
=
iter
.
key
();
label
anchorPoint
=
mesh_
.
cellPoints
()[
celli
][
0
];
...
...
@@ -173,7 +164,7 @@ void Foam::cellSplitter::setRefinement
(
polyAddPoint
(
iter
(),
// point
iter
.
val
(),
// point
anchorPoint
,
// master point
-
1
,
// zone for point
true
// supports a cell
...
...
@@ -193,9 +184,9 @@ void Foam::cellSplitter::setRefinement
Map
<
labelList
>
cellToCells
(
cellToMidPoint
.
size
());
forAllConstIter
(
Map
<
point
>
,
cellToMidPoint
,
iter
)
forAllConstIter
s
(
cellToMidPoint
,
iter
)
{
label
celli
=
iter
.
key
();
const
label
celli
=
iter
.
key
();
const
cell
&
cFaces
=
mesh_
.
cells
()[
celli
];
...
...
@@ -238,9 +229,9 @@ void Foam::cellSplitter::setRefinement
// point.
//
forAllConstIter
(
Map
<
point
>
,
cellToMidPoint
,
iter
)
forAllConstIter
s
(
cellToMidPoint
,
iter
)
{
label
celli
=
iter
.
key
();
const
label
celli
=
iter
.
key
();
label
midPointi
=
addedPoints_
[
celli
];
...
...
@@ -368,9 +359,9 @@ void Foam::cellSplitter::setRefinement
// Mark off affected face.
bitSet
faceUpToDate
(
mesh_
.
nFaces
(),
true
);
forAllConstIter
(
Map
<
point
>
,
cellToMidPoint
,
iter
)
forAllConstIter
s
(
cellToMidPoint
,
iter
)
{
label
celli
=
iter
.
key
();
const
label
celli
=
iter
.
key
();
const
cell
&
cFaces
=
mesh_
.
cells
()[
celli
];
...
...
@@ -462,15 +453,13 @@ void Foam::cellSplitter::updateMesh(const mapPolyMesh& morphMap)
// point get mapped do they get inserted.
Map
<
label
>
newAddedPoints
(
addedPoints_
.
size
());
forAllConstIter
(
Map
<
label
>
,
addedPoints_
,
iter
)
forAllConstIter
s
(
addedPoints_
,
iter
)
{
label
oldCelli
=
iter
.
key
();
label
newCelli
=
morphMap
.
reverseCellMap
()[
oldCelli
];
label
oldPointi
=
iter
();
const
label
oldCelli
=
iter
.
key
();
const
label
oldPointi
=
iter
.
val
();
label
newPointi
=
morphMap
.
reversePointMap
()[
oldPointi
];
const
label
newCelli
=
morphMap
.
reverseCellMap
()[
oldCelli
];
const
label
newPointi
=
morphMap
.
reversePointMap
()[
oldPointi
];
if
(
newCelli
>=
0
&&
newPointi
>=
0
)
{
...
...
applications/utilities/mesh/advanced/modifyMesh/cellSplitter.H
View file @
14a40417
...
...
@@ -109,7 +109,7 @@ public:
//- Destructor
~
cellSplitter
();
~
cellSplitter
()
=
default
;
// Member Functions
...
...
applications/utilities/mesh/advanced/modifyMesh/modifyMesh.C
View file @
14a40417
...
...
@@ -83,10 +83,8 @@ label findPoint(const primitivePatch& pp, const point& nearPoint)
scalar
almostMinDistSqr
=
GREAT
;
label
almostMinI
=
-
1
;
for
All
(
meshPoints
,
i
)
for
(
const
label
pointi
:
meshPoints
)
{
label
pointi
=
meshPoints
[
i
];
scalar
distSqr
=
magSqr
(
nearPoint
-
points
[
pointi
]);
if
(
distSqr
<
minDistSqr
)
...
...
@@ -147,10 +145,8 @@ label findEdge
scalar
almostMinDist
=
GREAT
;
label
almostMinI
=
-
1
;
for
All
(
edges
,
edge
I
)
for
(
const
edge
&
e
:
edge
s
)
{
const
edge
&
e
=
edges
[
edgeI
];
pointHit
pHit
(
e
.
line
(
localPoints
).
nearestDist
(
nearPoint
));
if
(
pHit
.
hit
())
...
...
@@ -296,10 +292,8 @@ label findCell(const primitiveMesh& mesh, const point& nearPoint)
label
minI
=
-
1
;
scalar
minDistSqr
=
GREAT
;
for
All
(
cPoints
,
i
)
for
(
const
label
pointi
:
cPoints
)
{
label
pointi
=
cPoints
[
i
];
scalar
distSqr
=
magSqr
(
nearPoint
-
mesh
.
points
()[
pointi
]);
if
(
distSqr
<
minDistSqr
)
...
...
@@ -432,11 +426,9 @@ int main(int argc, char *argv[])
Info
<<
nl
<<
"Looking up points to move ..."
<<
nl
<<
endl
;
Map
<
point
>
pointToPos
(
pointsToMove
.
size
());
for
All
(
pointsToMove
,
i
)
for
(
const
Pair
<
point
>&
pts
:
pointsToMove
)
{
const
Pair
<
point
>&
pts
=
pointsToMove
[
i
];
label
pointi
=
findPoint
(
allBoundary
,
pts
.
first
());
const
label
pointi
=
findPoint
(
allBoundary
,
pts
.
first
());
if
(
pointi
==
-
1
||
!
pointToPos
.
insert
(
pointi
,
pts
.
second
()))
{
...
...
@@ -450,10 +442,8 @@ int main(int argc, char *argv[])
Info
<<
nl
<<
"Looking up edges to split ..."
<<
nl
<<
endl
;
Map
<
List
<
point
>>
edgeToCuts
(
edgesToSplit
.
size
());
for
All
(
edgesToSplit
,
i
)
for
(
const
Pair
<
point
>&
pts
:
edgesToSplit
)
{
const
Pair
<
point
>&
pts
=
edgesToSplit
[
i
];
label
edgeI
=
findEdge
(
mesh
,
allBoundary
,
pts
.
first
());
if
...
...
@@ -473,10 +463,8 @@ int main(int argc, char *argv[])
Info
<<
nl
<<
"Looking up faces to triangulate ..."
<<
nl
<<
endl
;
Map
<
point
>
faceToDecompose
(
facesToTriangulate
.
size
());
for
All
(
facesToTriangulate
,
i
)
for
(
const
Pair
<
point
>&
pts
:
facesToTriangulate
)
{
const
Pair
<
point
>&
pts
=
facesToTriangulate
[
i
];
label
facei
=
findFace
(
mesh
,
allBoundary
,
pts
.
first
());
if
(
facei
==
-
1
||
!
faceToDecompose
.
insert
(
facei
,
pts
.
second
()))
...
...
@@ -494,10 +482,8 @@ int main(int argc, char *argv[])
Info
<<
nl
<<
"Looking up cells to convert to pyramids around"
<<
" cell centre ..."
<<
nl
<<
endl
;
Map
<
point
>
cellToPyrCentre
(
cellsToPyramidise
.
size
());
for
All
(
cellsToPyramidise
,
i
)
for
(
const
Pair
<
point
>&
pts
:
cellsToPyramidise
)
{
const
Pair
<
point
>&
pts
=
cellsToPyramidise
[
i
];
label
celli
=
findCell
(
mesh
,
pts
.
first
());
if
(
celli
==
-
1
||
!
cellToPyrCentre
.
insert
(
celli
,
pts
.
second
()))
...
...
@@ -513,10 +499,8 @@ int main(int argc, char *argv[])
Info
<<
nl
<<
"Looking up edges to collapse ..."
<<
nl
<<
endl
;
Map
<
point
>
edgeToPos
(
edgesToCollapse
.
size
());
for
All
(
edgesToCollapse
,
i
)
for
(
const
Pair
<
point
>&
pts
:
edgesToCollapse
)
{
const
Pair
<
point
>&
pts
=
edgesToCollapse
[
i
];
label
edgeI
=
findEdge
(
mesh
,
allBoundary
,
pts
.
first
());
if
(
edgeI
==
-
1
||
!
edgeToPos
.
insert
(
edgeI
,
pts
.
second
()))
...
...
@@ -590,7 +574,7 @@ int main(int argc, char *argv[])
Map
<
point
>
collapsePointToLocation
(
mesh
.
nPoints
());
// Get new positions and construct collapse network
forAllConstIter
(
Map
<
point
>
,
edgeToPos
,
iter
)
forAllConstIter
s
(
edgeToPos
,
iter
)
{
label
edgeI
=
iter
.
key
();
const
edge
&
e
=
edges
[
edgeI
];
...
...
@@ -598,7 +582,7 @@ int main(int argc, char *argv[])
collapseEdge
.
set
(
edgeI
);
collapsePointToLocation
.
set
(
e
[
1
],
points
[
e
[
0
]]);
newPoints
[
e
[
0
]]
=
iter
();
newPoints
[
e
[
0
]]
=
iter
.
val
();
}
// Move master point to destination.
...
...
applications/utilities/mesh/advanced/splitCells/splitCells.C
View file @
14a40417
...
...
@@ -222,10 +222,8 @@ bool splitHex
const
cell
&
cFaces
=
mesh
.
cells
()[
celli
];
for
All
(
cFaces
,
i
)
for
(
const
label
facei
:
cFaces
)
{
label
facei
=
cFaces
[
i
];
const
face
&
f
=
faces
[
facei
];
label
fp0
=
f
.
find
(
e
[
0
]);
...
...
@@ -399,15 +397,12 @@ void collectCuts
boolList
edgeIsCut
(
mesh
.
nEdges
(),
false
);
scalarField
edgeWeight
(
mesh
.
nEdges
(),
-
GREAT
);
for
AllConstIter
(
cellSet
,
cellsToCut
,
iter
)
for
(
const
label
celli
:
cellsToCut
)
{
const
label
celli
=
iter
.
key
();
const
labelList
&
cEdges
=
cellEdges
[
celli
];
for
All
(
cEdges
,
i
)
for
(
const
label
edgeI
:
cEdges
)
{
label
edgeI
=
cEdges
[
i
];
label
f0
,
f1
;
meshTools
::
getEdgeFaces
(
mesh
,
celli
,
edgeI
,
f0
,
f1
);
...
...
applications/utilities/mesh/conversion/ansysToFoam/ansysToFoam.L
View file @
14a40417
...
...
@@ -197,7 +197,7 @@ elementType ^{space}"TYPE"{cspace}
forAll(slPatchCells, i)
{
if (!slPatchCells(i))
if (!slPatchCells
.set
(i))
{
slPatchCells.set(i, new SLList<label>);
}
...
...
@@ -210,7 +210,7 @@ elementType ^{space}"TYPE"{cspace}
forAll(slPatchCells, i)
{
if (!slPatchCellFaces(i))
if (!slPatchCellFaces
.set
(i))
{
slPatchCellFaces.set(i, new SLList<label>);
}
...
...
@@ -344,19 +344,19 @@ int main(int argc, char *argv[])
pointField points(slPoints.size());
label i = 0;
for
AllConstIter(SLList<point>, slPoints, pointIter
)
for
(const point& pt : slPoints
)
{
// Scale points for the given scale factor
points[i++] = scaleFactor * p
ointIter()
;
points[i++] = scaleFactor * p
t
;
}
labelList pointMap(maxNodei+1);
i = 0;
for
AllConstIter(SLList<label>, slPointMap, p
ointMap
Iter
)
for
(const label pointi : slP
ointMap)
{
pointMap[point
MapIter()
] = i++;
pointMap[point
i
] = i++;
}
Info<< "Creating cells" << endl;
...
...
@@ -364,9 +364,9 @@ int main(int argc, char *argv[])
labelList cellMap(maxCelli+1);
i = 0;
for
AllConstIter(SLList<label>, slCellMap, c
ellMap
Iter
)
for
(const label celli : slC
ellMap)
{
cellMap[cell
MapIter()
] = i++;
cellMap[cell
i
] = i++;
}
...
...
@@ -383,66 +383,66 @@ int main(int argc, char *argv[])
cellShapeList cellShapes(slCellLabels.size());
label nCells = 0;
for
AllConstIter(SLPtr
List
<
label
List>,
slCellLabels
, cellIter
)
for
(const label
List
&
label
s :
slCellLabels)
{
if // Tetrahedron
(
cellIter()[2] == cellIter()
[3]
&&
cellIter()[4] == cellIter()
[5]
&&
cellIter()[5] == cellIter()
[6]
&&
cellIter()[6] == cellIter()
[7]
labels[2] == labels
[3]
&&
labels[4] == labels
[5]
&&
labels[5] == labels
[6]
&&
labels[6] == labels
[7]
)
{
labelsTet[0] = pointMap[
cellIter()
[0]
];
labelsTet[1] = pointMap[
cellIter()
[1]
];
labelsTet[2] = pointMap[
cellIter()
[2]
];
labelsTet[3] = pointMap[
cellIter()
[4]
];
labelsTet[0] = pointMap[
labels
[0]];
labelsTet[1] = pointMap[
labels
[1]];
labelsTet[2] = pointMap[
labels
[2]];
labelsTet[3] = pointMap[
labels
[4]];