mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Standardized cell, patch and face loop index names
This commit is contained in:
@ -188,10 +188,10 @@ int main(int argc, char *argv[])
|
||||
|
||||
const pointField& cellCentres = topo.cellCentres();
|
||||
|
||||
forAll(cellCentres, cellI)
|
||||
forAll(cellCentres, celli)
|
||||
{
|
||||
//point cc = b.blockShape().centre(b.points());
|
||||
const point& cc = cellCentres[cellI];
|
||||
const point& cc = cellCentres[celli];
|
||||
|
||||
str << "v " << cc.x() << ' ' << cc.y() << ' ' << cc.z() << nl;
|
||||
}
|
||||
@ -257,7 +257,7 @@ int main(int argc, char *argv[])
|
||||
List<DynamicList<label>> zoneCells(nZones);
|
||||
|
||||
// Running cell counter
|
||||
label cellI = 0;
|
||||
label celli = 0;
|
||||
|
||||
// Largest zone so far
|
||||
label freeZoneI = 0;
|
||||
@ -289,12 +289,12 @@ int main(int argc, char *argv[])
|
||||
|
||||
forAll(blockCells, i)
|
||||
{
|
||||
zoneCells[zoneI].append(cellI++);
|
||||
zoneCells[zoneI].append(celli++);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
cellI += b.cells().size();
|
||||
celli += b.cells().size();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -744,9 +744,9 @@ int main(int argc, char *argv[])
|
||||
layerExtrude.layerFaces()
|
||||
)
|
||||
);
|
||||
forAll(addedCells, faceI)
|
||||
forAll(addedCells, facei)
|
||||
{
|
||||
const labelList& aCells = addedCells[faceI];
|
||||
const labelList& aCells = addedCells[facei];
|
||||
forAll(aCells, i)
|
||||
{
|
||||
addedCellsSet.insert(aCells[i]);
|
||||
|
||||
@ -426,14 +426,14 @@ void checkZoneInside
|
||||
|
||||
forAll(extrudeMeshFaces, i)
|
||||
{
|
||||
label faceI = extrudeMeshFaces[i];
|
||||
label facei = extrudeMeshFaces[i];
|
||||
label zoneI = zoneID[i];
|
||||
if (isInternal[zoneI] != mesh.isInternalFace(faceI))
|
||||
if (isInternal[zoneI] != mesh.isInternalFace(facei))
|
||||
{
|
||||
FatalErrorInFunction
|
||||
<< "Zone " << zoneNames[zoneI]
|
||||
<< " is not consistently all internal or all boundary faces."
|
||||
<< " Face " << faceI << " at " << mesh.faceCentres()[faceI]
|
||||
<< " Face " << facei << " at " << mesh.faceCentres()[facei]
|
||||
<< " is the first occurrence."
|
||||
<< exit(FatalError);
|
||||
}
|
||||
@ -532,17 +532,17 @@ label findUncoveredPatchFace
|
||||
const labelList& eFaces = mesh.edgeFaces()[meshEdgeI];
|
||||
forAll(eFaces, i)
|
||||
{
|
||||
label faceI = eFaces[i];
|
||||
label patchi = pbm.whichPatch(faceI);
|
||||
label facei = eFaces[i];
|
||||
label patchi = pbm.whichPatch(facei);
|
||||
|
||||
if
|
||||
(
|
||||
patchi != -1
|
||||
&& !pbm[patchi].coupled()
|
||||
&& !extrudeFaceSet.found(faceI)
|
||||
&& !extrudeFaceSet.found(facei)
|
||||
)
|
||||
{
|
||||
return faceI;
|
||||
return facei;
|
||||
}
|
||||
}
|
||||
return -1;
|
||||
@ -568,17 +568,17 @@ label findUncoveredCyclicPatchFace
|
||||
const labelList& eFaces = mesh.edgeFaces()[meshEdgeI];
|
||||
forAll(eFaces, i)
|
||||
{
|
||||
label faceI = eFaces[i];
|
||||
label patchi = pbm.whichPatch(faceI);
|
||||
label facei = eFaces[i];
|
||||
label patchi = pbm.whichPatch(facei);
|
||||
|
||||
if
|
||||
(
|
||||
patchi != -1
|
||||
&& isA<cyclicPolyPatch>(pbm[patchi])
|
||||
&& !extrudeFaceSet.found(faceI)
|
||||
&& !extrudeFaceSet.found(facei)
|
||||
)
|
||||
{
|
||||
return faceI;
|
||||
return facei;
|
||||
}
|
||||
}
|
||||
return -1;
|
||||
@ -705,14 +705,14 @@ void countExtrudePatches
|
||||
// so choose any uncovered one. If none found put face in
|
||||
// undetermined zone 'side' patch
|
||||
|
||||
label faceI = findUncoveredPatchFace
|
||||
label facei = findUncoveredPatchFace
|
||||
(
|
||||
mesh,
|
||||
UIndirectList<label>(extrudeMeshFaces, eFaces),
|
||||
extrudeMeshEdges[edgeI]
|
||||
);
|
||||
|
||||
if (faceI == -1)
|
||||
if (facei == -1)
|
||||
{
|
||||
zoneSidePatch[minZoneID[edgeI]]++;
|
||||
}
|
||||
@ -927,21 +927,21 @@ void addCoupledPatches
|
||||
// Cyclic patch since both procs the same. This cyclic should
|
||||
// already exist in newPatches so no adding necessary.
|
||||
|
||||
label faceI = findUncoveredCyclicPatchFace
|
||||
label facei = findUncoveredCyclicPatchFace
|
||||
(
|
||||
mesh,
|
||||
UIndirectList<label>(extrudeMeshFaces, eFaces),
|
||||
extrudeMeshEdges[edgeI]
|
||||
);
|
||||
|
||||
if (faceI != -1)
|
||||
if (facei != -1)
|
||||
{
|
||||
const polyBoundaryMesh& patches = mesh.boundaryMesh();
|
||||
|
||||
label newPatchI = findPatchID
|
||||
(
|
||||
newPatches,
|
||||
patches[patches.whichPatch(faceI)].name()
|
||||
patches[patches.whichPatch(facei)].name()
|
||||
);
|
||||
|
||||
sidePatchID[edgeI] = newPatchI;
|
||||
@ -1305,26 +1305,26 @@ void extrudeGeometricProperties
|
||||
// Work out layers. Guaranteed in columns so no fancy parallel bits.
|
||||
|
||||
|
||||
forAll(extruder.faceToFaceMap(), faceI)
|
||||
forAll(extruder.faceToFaceMap(), facei)
|
||||
{
|
||||
if (extruder.faceToFaceMap()[faceI] != 0)
|
||||
if (extruder.faceToFaceMap()[facei] != 0)
|
||||
{
|
||||
// 'horizontal' face
|
||||
label patchFaceI = mag(extruder.faceToFaceMap()[faceI])-1;
|
||||
label patchFaceI = mag(extruder.faceToFaceMap()[facei])-1;
|
||||
|
||||
label cellI = regionMesh.faceOwner()[faceI];
|
||||
if (regionMesh.isInternalFace(faceI))
|
||||
label celli = regionMesh.faceOwner()[facei];
|
||||
if (regionMesh.isInternalFace(facei))
|
||||
{
|
||||
cellI = max(cellI, regionMesh.faceNeighbour()[faceI]);
|
||||
celli = max(celli, regionMesh.faceNeighbour()[facei]);
|
||||
}
|
||||
|
||||
// Calculate layer from cell numbering (see createShellMesh)
|
||||
label layerI = (cellI % model.nLayers());
|
||||
label layerI = (celli % model.nLayers());
|
||||
|
||||
if
|
||||
(
|
||||
!regionMesh.isInternalFace(faceI)
|
||||
&& extruder.faceToFaceMap()[faceI] > 0
|
||||
!regionMesh.isInternalFace(facei)
|
||||
&& extruder.faceToFaceMap()[facei] > 0
|
||||
)
|
||||
{
|
||||
// Top face
|
||||
@ -1333,7 +1333,7 @@ void extrudeGeometricProperties
|
||||
|
||||
|
||||
// Recalculate based on extrusion model
|
||||
faceCentres[faceI] = model
|
||||
faceCentres[facei] = model
|
||||
(
|
||||
patchFaceCentres[patchFaceI],
|
||||
extrudePatch.faceNormals()[patchFaceI],
|
||||
@ -1343,10 +1343,10 @@ void extrudeGeometricProperties
|
||||
else
|
||||
{
|
||||
// 'vertical face
|
||||
label patchEdgeI = extruder.faceToEdgeMap()[faceI];
|
||||
label patchEdgeI = extruder.faceToEdgeMap()[facei];
|
||||
label layerI =
|
||||
(
|
||||
regionMesh.faceOwner()[faceI]
|
||||
regionMesh.faceOwner()[facei]
|
||||
% model.nLayers()
|
||||
);
|
||||
|
||||
@ -1366,7 +1366,7 @@ void extrudeGeometricProperties
|
||||
);
|
||||
|
||||
// Interpolate
|
||||
faceCentres[faceI] = 0.5*(pt0+pt1);
|
||||
faceCentres[facei] = 0.5*(pt0+pt1);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1385,12 +1385,12 @@ void extrudeGeometricProperties
|
||||
regionMesh.nCells()
|
||||
);
|
||||
|
||||
forAll(extruder.cellToFaceMap(), cellI)
|
||||
forAll(extruder.cellToFaceMap(), celli)
|
||||
{
|
||||
label patchFaceI = extruder.cellToFaceMap()[cellI];
|
||||
label patchFaceI = extruder.cellToFaceMap()[celli];
|
||||
|
||||
// Calculate layer from cell numbering (see createShellMesh)
|
||||
label layerI = (cellI % model.nLayers());
|
||||
label layerI = (celli % model.nLayers());
|
||||
|
||||
// Recalculate based on extrusion model
|
||||
point pt0 = model
|
||||
@ -1407,7 +1407,7 @@ void extrudeGeometricProperties
|
||||
);
|
||||
|
||||
// Interpolate
|
||||
cellCentres[cellI] = 0.5*(pt0+pt1);
|
||||
cellCentres[celli] = 0.5*(pt0+pt1);
|
||||
}
|
||||
|
||||
|
||||
@ -1417,29 +1417,29 @@ void extrudeGeometricProperties
|
||||
OBJstream faceStr(regionMesh.time().path()/"faceCentres.obj");
|
||||
OBJstream cellStr(regionMesh.time().path()/"cellCentres.obj");
|
||||
|
||||
forAll(faceCentres, faceI)
|
||||
forAll(faceCentres, facei)
|
||||
{
|
||||
Pout<< "Model :" << faceCentres[faceI] << endl
|
||||
<< "regionMesh:" << regionMesh.faceCentres()[faceI] << endl;
|
||||
Pout<< "Model :" << faceCentres[facei] << endl
|
||||
<< "regionMesh:" << regionMesh.faceCentres()[facei] << endl;
|
||||
faceStr.write
|
||||
(
|
||||
linePointRef
|
||||
(
|
||||
faceCentres[faceI],
|
||||
regionMesh.faceCentres()[faceI]
|
||||
faceCentres[facei],
|
||||
regionMesh.faceCentres()[facei]
|
||||
)
|
||||
);
|
||||
}
|
||||
forAll(cellCentres, cellI)
|
||||
forAll(cellCentres, celli)
|
||||
{
|
||||
Pout<< "Model :" << cellCentres[cellI] << endl
|
||||
<< "regionMesh:" << regionMesh.cellCentres()[cellI] << endl;
|
||||
Pout<< "Model :" << cellCentres[celli] << endl
|
||||
<< "regionMesh:" << regionMesh.cellCentres()[celli] << endl;
|
||||
cellStr.write
|
||||
(
|
||||
linePointRef
|
||||
(
|
||||
cellCentres[cellI],
|
||||
regionMesh.cellCentres()[cellI]
|
||||
cellCentres[celli],
|
||||
regionMesh.cellCentres()[celli]
|
||||
)
|
||||
);
|
||||
}
|
||||
@ -1798,8 +1798,8 @@ int main(int argc, char *argv[])
|
||||
const faceSet& fz = zones[i];
|
||||
forAllConstIter(faceSet, fz, iter)
|
||||
{
|
||||
label faceI = iter.key();
|
||||
if (mesh.isInternalFace(faceI))
|
||||
label facei = iter.key();
|
||||
if (mesh.isInternalFace(facei))
|
||||
{
|
||||
FatalIOErrorIn(args.executable().c_str(), dict)
|
||||
<< "faceSet " << fz.name()
|
||||
@ -1807,13 +1807,13 @@ int main(int argc, char *argv[])
|
||||
<< " This is not permitted."
|
||||
<< exit(FatalIOError);
|
||||
}
|
||||
extrudeMeshFaces[nExtrudeFaces] = faceI;
|
||||
zoneFaces[nExtrudeFaces] = mesh.faces()[faceI];
|
||||
extrudeMeshFaces[nExtrudeFaces] = facei;
|
||||
zoneFaces[nExtrudeFaces] = mesh.faces()[facei];
|
||||
zoneID[nExtrudeFaces] = i;
|
||||
zoneFlipMap[nExtrudeFaces] = false;
|
||||
nExtrudeFaces++;
|
||||
|
||||
if (mesh.isInternalFace(faceI))
|
||||
if (mesh.isInternalFace(facei))
|
||||
{
|
||||
isInternal[i] = true;
|
||||
}
|
||||
@ -1858,8 +1858,8 @@ int main(int argc, char *argv[])
|
||||
const faceSet& fz = shadowZones[i];
|
||||
forAllConstIter(faceSet, fz, iter)
|
||||
{
|
||||
label faceI = iter.key();
|
||||
if (mesh.isInternalFace(faceI))
|
||||
label facei = iter.key();
|
||||
if (mesh.isInternalFace(facei))
|
||||
{
|
||||
FatalIOErrorIn(args.executable().c_str(), dict)
|
||||
<< "faceSet " << fz.name()
|
||||
@ -1867,7 +1867,7 @@ int main(int argc, char *argv[])
|
||||
<< " This is not permitted."
|
||||
<< exit(FatalIOError);
|
||||
}
|
||||
extrudeMeshShadowFaces[nShadowFaces] = faceI;
|
||||
extrudeMeshShadowFaces[nShadowFaces] = facei;
|
||||
zoneShadowFlipMap[nShadowFaces] = false;
|
||||
zoneShadowID[nShadowFaces] = i;
|
||||
nShadowFaces++;
|
||||
@ -2042,10 +2042,10 @@ int main(int argc, char *argv[])
|
||||
labelList extrudeTopPatchID(extrudePatch.size());
|
||||
labelList extrudeBottomPatchID(extrudePatch.size());
|
||||
|
||||
forAll(zoneID, faceI)
|
||||
forAll(zoneID, facei)
|
||||
{
|
||||
extrudeTopPatchID[faceI] = interRegionTopPatch[zoneID[faceI]];
|
||||
extrudeBottomPatchID[faceI] = interRegionBottomPatch[zoneID[faceI]];
|
||||
extrudeTopPatchID[facei] = interRegionTopPatch[zoneID[facei]];
|
||||
extrudeBottomPatchID[facei] = interRegionBottomPatch[zoneID[facei]];
|
||||
}
|
||||
|
||||
|
||||
@ -2231,19 +2231,19 @@ int main(int argc, char *argv[])
|
||||
}
|
||||
else
|
||||
{
|
||||
label faceI = findUncoveredPatchFace
|
||||
label facei = findUncoveredPatchFace
|
||||
(
|
||||
mesh,
|
||||
UIndirectList<label>(extrudeMeshFaces, eFaces),
|
||||
extrudeMeshEdges[edgeI]
|
||||
);
|
||||
|
||||
if (faceI != -1)
|
||||
if (facei != -1)
|
||||
{
|
||||
label newPatchI = findPatchID
|
||||
(
|
||||
regionPatches,
|
||||
patches[patches.whichPatch(faceI)].name()
|
||||
patches[patches.whichPatch(facei)].name()
|
||||
);
|
||||
ePatches.setSize(eFaces.size(), newPatchI);
|
||||
}
|
||||
@ -2283,10 +2283,10 @@ int main(int argc, char *argv[])
|
||||
|
||||
// Per local region an originating point
|
||||
labelList localRegionPoints(localToGlobalRegion.size());
|
||||
forAll(pointLocalRegions, faceI)
|
||||
forAll(pointLocalRegions, facei)
|
||||
{
|
||||
const face& f = extrudePatch.localFaces()[faceI];
|
||||
const face& pRegions = pointLocalRegions[faceI];
|
||||
const face& f = extrudePatch.localFaces()[facei];
|
||||
const face& pRegions = pointLocalRegions[facei];
|
||||
forAll(pRegions, fp)
|
||||
{
|
||||
localRegionPoints[pRegions[fp]] = f[fp];
|
||||
@ -2298,13 +2298,13 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
pointField localSum(localToGlobalRegion.size(), Zero);
|
||||
|
||||
forAll(pointLocalRegions, faceI)
|
||||
forAll(pointLocalRegions, facei)
|
||||
{
|
||||
const face& pRegions = pointLocalRegions[faceI];
|
||||
const face& pRegions = pointLocalRegions[facei];
|
||||
forAll(pRegions, fp)
|
||||
{
|
||||
label localRegionI = pRegions[fp];
|
||||
localSum[localRegionI] += extrudePatch.faceNormals()[faceI];
|
||||
localSum[localRegionI] += extrudePatch.faceNormals()[facei];
|
||||
}
|
||||
}
|
||||
|
||||
@ -2337,13 +2337,13 @@ int main(int argc, char *argv[])
|
||||
|
||||
scalar thickness = model().sumThickness(1);
|
||||
|
||||
forAll(pointLocalRegions, faceI)
|
||||
forAll(pointLocalRegions, facei)
|
||||
{
|
||||
const face& f = extrudeFaces[faceI];
|
||||
const face& f = extrudeFaces[facei];
|
||||
|
||||
forAll(f, fp)
|
||||
{
|
||||
label region = pointLocalRegions[faceI][fp];
|
||||
label region = pointLocalRegions[facei][fp];
|
||||
const point& pt = extrudePoints[f[fp]];
|
||||
|
||||
meshTools::writeOBJ(str, pt);
|
||||
|
||||
@ -39,12 +39,12 @@ namespace Foam
|
||||
void Foam::extrude2DMesh::check2D() const
|
||||
{
|
||||
const faceList& faces = mesh_.faces();
|
||||
forAll(faces, faceI)
|
||||
forAll(faces, facei)
|
||||
{
|
||||
if (faces[faceI].size() != 2)
|
||||
if (faces[facei].size() != 2)
|
||||
{
|
||||
FatalErrorInFunction
|
||||
<< "Face " << faceI << " size " << faces[faceI].size()
|
||||
<< "Face " << facei << " size " << faces[facei].size()
|
||||
<< " is not of size 2: mesh is not a valid two-dimensional "
|
||||
<< "mesh" << exit(FatalError);
|
||||
}
|
||||
@ -205,15 +205,15 @@ void Foam::extrude2DMesh::setRefinement
|
||||
{
|
||||
label offset = layer * mesh_.nCells();
|
||||
|
||||
forAll(mesh_.cells(), cellI)
|
||||
forAll(mesh_.cells(), celli)
|
||||
{
|
||||
meshMod.addCell
|
||||
(
|
||||
-1, //masterPointID,
|
||||
-1, //masterEdgeID,
|
||||
-1, //masterFaceID,
|
||||
cellI + offset, //masterCellID,
|
||||
mesh_.cellZones().whichZone(cellI) //zoneID
|
||||
celli + offset, //masterCellID,
|
||||
mesh_.cellZones().whichZone(celli) //zoneID
|
||||
);
|
||||
}
|
||||
}
|
||||
@ -262,18 +262,18 @@ void Foam::extrude2DMesh::setRefinement
|
||||
label currentLayerOffset = layer * mesh_.nPoints();
|
||||
label nextLayerOffset = currentLayerOffset + mesh_.nPoints();
|
||||
|
||||
for (label faceI = 0; faceI < mesh_.nInternalFaces(); faceI++)
|
||||
for (label facei = 0; facei < mesh_.nInternalFaces(); facei++)
|
||||
{
|
||||
label zoneID = mesh_.faceZones().whichZone(faceI);
|
||||
label zoneID = mesh_.faceZones().whichZone(facei);
|
||||
bool zoneFlip = false;
|
||||
if (zoneID != -1)
|
||||
{
|
||||
const faceZone& fZone = mesh_.faceZones()[zoneID];
|
||||
zoneFlip = fZone.flipMap()[fZone.whichFace(faceI)];
|
||||
zoneFlip = fZone.flipMap()[fZone.whichFace(facei)];
|
||||
}
|
||||
|
||||
face newFace(4);
|
||||
const face& f = faces[faceI];
|
||||
const face& f = faces[facei];
|
||||
newFace[0] = f[0] + currentLayerOffset;
|
||||
newFace[1] = f[1] + currentLayerOffset;
|
||||
newFace[2] = f[1] + nextLayerOffset;
|
||||
@ -281,15 +281,15 @@ void Foam::extrude2DMesh::setRefinement
|
||||
|
||||
//{
|
||||
// vector n = newFace.normal(pointField(meshMod.points()));
|
||||
// label own = mesh_.faceOwner()[faceI];
|
||||
// label own = mesh_.faceOwner()[facei];
|
||||
// const labelList& ownPoints = mesh_.cellPoints()[own];
|
||||
// point ownCc = sum(pointField(mesh_.points(), ownPoints))/ownPoints.size();
|
||||
// label nei = mesh_.faceNeighbour()[faceI];
|
||||
// label nei = mesh_.faceNeighbour()[facei];
|
||||
// const labelList& neiPoints = mesh_.cellPoints()[nei];
|
||||
// point neiCc = sum(pointField(mesh_.points(), neiPoints))/neiPoints.size();
|
||||
// vector d = neiCc - ownCc;
|
||||
|
||||
// Pout<< "face:" << faceI << " at:" << f.centre(mesh_.points()) << endl
|
||||
// Pout<< "face:" << facei << " at:" << f.centre(mesh_.points()) << endl
|
||||
// << " own:" << own << " at:" << ownCc << endl
|
||||
// << " nei:" << nei << " at:" << neiCc << endl
|
||||
// << " sign:" << (n & d) << endl
|
||||
@ -301,8 +301,8 @@ void Foam::extrude2DMesh::setRefinement
|
||||
meshMod.addFace
|
||||
(
|
||||
newFace,
|
||||
mesh_.faceOwner()[faceI] + offset, // own
|
||||
mesh_.faceNeighbour()[faceI] + offset, // nei
|
||||
mesh_.faceOwner()[facei] + offset, // own
|
||||
mesh_.faceNeighbour()[facei] + offset, // nei
|
||||
-1, // masterPointID
|
||||
-1, // masterEdgeID
|
||||
nFaces++, // masterFaceID
|
||||
@ -315,8 +315,8 @@ void Foam::extrude2DMesh::setRefinement
|
||||
if (debug)
|
||||
{
|
||||
Info<< newFace << " "
|
||||
<< mesh_.faceOwner()[faceI] + offset << " "
|
||||
<< mesh_.faceNeighbour()[faceI] + offset << " "
|
||||
<< mesh_.faceOwner()[facei] + offset << " "
|
||||
<< mesh_.faceNeighbour()[facei] + offset << " "
|
||||
<< nFaces - 1
|
||||
<< endl;
|
||||
}
|
||||
@ -333,18 +333,18 @@ void Foam::extrude2DMesh::setRefinement
|
||||
label startFaceI = patches[patchi].start();
|
||||
label endFaceI = startFaceI + patches[patchi].size();
|
||||
|
||||
for (label faceI = startFaceI; faceI < endFaceI; faceI++)
|
||||
for (label facei = startFaceI; facei < endFaceI; facei++)
|
||||
{
|
||||
label zoneID = mesh_.faceZones().whichZone(faceI);
|
||||
label zoneID = mesh_.faceZones().whichZone(facei);
|
||||
bool zoneFlip = false;
|
||||
if (zoneID != -1)
|
||||
{
|
||||
const faceZone& fZone = mesh_.faceZones()[zoneID];
|
||||
zoneFlip = fZone.flipMap()[fZone.whichFace(faceI)];
|
||||
zoneFlip = fZone.flipMap()[fZone.whichFace(facei)];
|
||||
}
|
||||
|
||||
face newFace(4);
|
||||
const face& f = faces[faceI];
|
||||
const face& f = faces[facei];
|
||||
newFace[0] = f[0] + currentLayerOffset;
|
||||
newFace[1] = f[1] + currentLayerOffset;
|
||||
newFace[2] = f[1] + nextLayerOffset;
|
||||
@ -355,7 +355,7 @@ void Foam::extrude2DMesh::setRefinement
|
||||
meshMod.addFace
|
||||
(
|
||||
newFace,
|
||||
mesh_.faceOwner()[faceI] + offset, // own
|
||||
mesh_.faceOwner()[facei] + offset, // own
|
||||
-1, // nei
|
||||
-1, // masterPointID
|
||||
-1, // masterEdgeID
|
||||
@ -369,7 +369,7 @@ void Foam::extrude2DMesh::setRefinement
|
||||
if (debug)
|
||||
{
|
||||
Info<< newFace << " "
|
||||
<< mesh_.faceOwner()[faceI] + offset << " "
|
||||
<< mesh_.faceOwner()[facei] + offset << " "
|
||||
<< nFaces - 1
|
||||
<< endl;
|
||||
}
|
||||
@ -379,9 +379,9 @@ void Foam::extrude2DMesh::setRefinement
|
||||
|
||||
// Add extra internal faces that need special treatment for owners and
|
||||
// neighbours.
|
||||
forAll(mesh_.cells(), cellI)
|
||||
forAll(mesh_.cells(), celli)
|
||||
{
|
||||
const cell& cFaces = mesh_.cells()[cellI];
|
||||
const cell& cFaces = mesh_.cells()[celli];
|
||||
|
||||
face frontFace(cFaces.size());
|
||||
|
||||
@ -391,7 +391,7 @@ void Foam::extrude2DMesh::setRefinement
|
||||
const face& f = faces[nextFaceI];
|
||||
|
||||
label nextPointI;
|
||||
if (mesh_.faceOwner()[nextFaceI] == cellI)
|
||||
if (mesh_.faceOwner()[nextFaceI] == celli)
|
||||
{
|
||||
frontFace[0] = f[0];
|
||||
nextPointI = f[1];
|
||||
@ -410,21 +410,21 @@ void Foam::extrude2DMesh::setRefinement
|
||||
// Find face containing pointI
|
||||
forAll(cFaces, cFaceI)
|
||||
{
|
||||
label faceI = cFaces[cFaceI];
|
||||
if (faceI != nextFaceI)
|
||||
label facei = cFaces[cFaceI];
|
||||
if (facei != nextFaceI)
|
||||
{
|
||||
const face& f = faces[faceI];
|
||||
const face& f = faces[facei];
|
||||
|
||||
if (f[0] == nextPointI)
|
||||
{
|
||||
nextPointI = f[1];
|
||||
nextFaceI = faceI;
|
||||
nextFaceI = facei;
|
||||
break;
|
||||
}
|
||||
else if (f[1] == nextPointI)
|
||||
{
|
||||
nextPointI = f[0];
|
||||
nextFaceI = faceI;
|
||||
nextFaceI = facei;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@ -444,13 +444,13 @@ void Foam::extrude2DMesh::setRefinement
|
||||
label nei = -1;
|
||||
if (layer != nLayers - 1)
|
||||
{
|
||||
nei = cellI + offset + mesh_.nCells();
|
||||
nei = celli + offset + mesh_.nCells();
|
||||
}
|
||||
|
||||
meshMod.addFace
|
||||
(
|
||||
frontFace,
|
||||
cellI + offset, // own
|
||||
celli + offset, // own
|
||||
nei, // nei
|
||||
-1, // masterPointID
|
||||
-1, // masterEdgeID
|
||||
@ -464,7 +464,7 @@ void Foam::extrude2DMesh::setRefinement
|
||||
if (debug)
|
||||
{
|
||||
Info<< frontFace << " "
|
||||
<< cellI + offset << " "
|
||||
<< celli + offset << " "
|
||||
<< nei << " "
|
||||
<< nFaces - 1
|
||||
<< endl;
|
||||
@ -475,9 +475,9 @@ void Foam::extrude2DMesh::setRefinement
|
||||
// Generate front and back faces
|
||||
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
forAll(mesh_.cells(), cellI)
|
||||
forAll(mesh_.cells(), celli)
|
||||
{
|
||||
const cell& cFaces = mesh_.cells()[cellI];
|
||||
const cell& cFaces = mesh_.cells()[celli];
|
||||
|
||||
face frontFace(cFaces.size());
|
||||
|
||||
@ -487,7 +487,7 @@ void Foam::extrude2DMesh::setRefinement
|
||||
const face& f = faces[nextFaceI];
|
||||
|
||||
label nextPointI;
|
||||
if (mesh_.faceOwner()[nextFaceI] == cellI)
|
||||
if (mesh_.faceOwner()[nextFaceI] == celli)
|
||||
{
|
||||
frontFace[0] = f[0];
|
||||
nextPointI = f[1];
|
||||
@ -506,21 +506,21 @@ void Foam::extrude2DMesh::setRefinement
|
||||
// Find face containing pointI
|
||||
forAll(cFaces, cFaceI)
|
||||
{
|
||||
label faceI = cFaces[cFaceI];
|
||||
if (faceI != nextFaceI)
|
||||
label facei = cFaces[cFaceI];
|
||||
if (facei != nextFaceI)
|
||||
{
|
||||
const face& f = faces[faceI];
|
||||
const face& f = faces[facei];
|
||||
|
||||
if (f[0] == nextPointI)
|
||||
{
|
||||
nextPointI = f[1];
|
||||
nextFaceI = faceI;
|
||||
nextFaceI = facei;
|
||||
break;
|
||||
}
|
||||
else if (f[1] == nextPointI)
|
||||
{
|
||||
nextPointI = f[0];
|
||||
nextFaceI = faceI;
|
||||
nextFaceI = facei;
|
||||
break;
|
||||
}
|
||||
}
|
||||
@ -531,7 +531,7 @@ void Foam::extrude2DMesh::setRefinement
|
||||
meshMod.addFace
|
||||
(
|
||||
frontFace.reverseFace(),
|
||||
cellI, // own
|
||||
celli, // own
|
||||
-1, // nei
|
||||
-1, // masterPointID
|
||||
-1, // masterEdgeID
|
||||
@ -545,7 +545,7 @@ void Foam::extrude2DMesh::setRefinement
|
||||
if (debug)
|
||||
{
|
||||
Info<< nl<<frontFace.reverseFace() << " "
|
||||
<< cellI << " "
|
||||
<< celli << " "
|
||||
<< nFaces - 1
|
||||
<< endl;
|
||||
}
|
||||
@ -561,7 +561,7 @@ void Foam::extrude2DMesh::setRefinement
|
||||
meshMod.addFace
|
||||
(
|
||||
frontFace,
|
||||
cellI + offset, // own
|
||||
celli + offset, // own
|
||||
-1, // nei
|
||||
-1, // masterPointID
|
||||
-1, // masterEdgeID
|
||||
@ -575,7 +575,7 @@ void Foam::extrude2DMesh::setRefinement
|
||||
if (debug)
|
||||
{
|
||||
Info<< frontFace << " "
|
||||
<< cellI + offset << " "
|
||||
<< celli + offset << " "
|
||||
<< nFaces - 1
|
||||
<< endl;
|
||||
}
|
||||
|
||||
@ -103,9 +103,9 @@ Foam::labelList Foam::patchToPoly2DMesh::internalFaceOrder()
|
||||
|
||||
label newFaceI = 0;
|
||||
|
||||
forAll(faceEdges, faceI)
|
||||
forAll(faceEdges, facei)
|
||||
{
|
||||
const labelList& fEdges = faceEdges[faceI];
|
||||
const labelList& fEdges = faceEdges[facei];
|
||||
// Neighbouring faces
|
||||
SortableList<label> nbr(fEdges.size(), -1);
|
||||
|
||||
@ -117,14 +117,14 @@ Foam::labelList Foam::patchToPoly2DMesh::internalFaceOrder()
|
||||
|
||||
label nbrFaceI = neighbour_[fEdges[feI]];
|
||||
|
||||
if (nbrFaceI == faceI)
|
||||
if (nbrFaceI == facei)
|
||||
{
|
||||
nbrFaceI = owner_[fEdges[feI]];
|
||||
}
|
||||
|
||||
if (faceI < nbrFaceI)
|
||||
if (facei < nbrFaceI)
|
||||
{
|
||||
// faceI is master
|
||||
// facei is master
|
||||
nbr[feI] = nbrFaceI;
|
||||
}
|
||||
}
|
||||
|
||||
@ -109,16 +109,16 @@ void Foam::DelaunayMesh<Triangulation>::addPatches
|
||||
faces.setSize(nInternalFaces + nBoundaryFaces);
|
||||
owner.setSize(nInternalFaces + nBoundaryFaces);
|
||||
|
||||
label faceI = nInternalFaces;
|
||||
label facei = nInternalFaces;
|
||||
|
||||
forAll(patchFaces, p)
|
||||
{
|
||||
forAll(patchFaces[p], f)
|
||||
{
|
||||
faces[faceI] = patchFaces[p][f];
|
||||
owner[faceI] = patchOwners[p][f];
|
||||
faces[facei] = patchFaces[p][f];
|
||||
owner[facei] = patchOwners[p][f];
|
||||
|
||||
faceI++;
|
||||
facei++;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -429,7 +429,7 @@ Foam::DelaunayMesh<Triangulation>::createMesh
|
||||
|
||||
|
||||
// Index the cells
|
||||
label cellI = 0;
|
||||
label celli = 0;
|
||||
|
||||
for
|
||||
(
|
||||
@ -445,11 +445,11 @@ Foam::DelaunayMesh<Triangulation>::createMesh
|
||||
&& cit->real()
|
||||
)
|
||||
{
|
||||
cellMap[cit->cellIndex()] = cellI++;
|
||||
cellMap[cit->cellIndex()] = celli++;
|
||||
}
|
||||
}
|
||||
|
||||
label faceI = 0;
|
||||
label facei = 0;
|
||||
labelList verticesOnTriFace(3, label(-1));
|
||||
face newFace(verticesOnTriFace);
|
||||
|
||||
@ -566,16 +566,16 @@ Foam::DelaunayMesh<Triangulation>::createMesh
|
||||
neighbourCell = c1I;
|
||||
}
|
||||
|
||||
faces[faceI] = newFace;
|
||||
owner[faceI] = ownerCell;
|
||||
neighbour[faceI] = neighbourCell;
|
||||
faceI++;
|
||||
faces[facei] = newFace;
|
||||
owner[facei] = ownerCell;
|
||||
neighbour[facei] = neighbourCell;
|
||||
facei++;
|
||||
}
|
||||
}
|
||||
|
||||
faces.setSize(faceI);
|
||||
owner.setSize(faceI);
|
||||
neighbour.setSize(faceI);
|
||||
faces.setSize(facei);
|
||||
owner.setSize(facei);
|
||||
neighbour.setSize(facei);
|
||||
|
||||
sortFaces(faces, owner, neighbour);
|
||||
|
||||
@ -583,7 +583,7 @@ Foam::DelaunayMesh<Triangulation>::createMesh
|
||||
|
||||
addPatches
|
||||
(
|
||||
faceI,
|
||||
facei,
|
||||
faces,
|
||||
owner,
|
||||
patchDicts,
|
||||
|
||||
@ -164,13 +164,13 @@ void Foam::backgroundMeshDecomposition::initialRefinement()
|
||||
while (true)
|
||||
{
|
||||
// Determine/update the status of each cell
|
||||
forAll(volumeStatus, cellI)
|
||||
forAll(volumeStatus, celli)
|
||||
{
|
||||
if (volumeStatus[cellI] == volumeType::UNKNOWN)
|
||||
if (volumeStatus[celli] == volumeType::UNKNOWN)
|
||||
{
|
||||
treeBoundBox cellBb
|
||||
(
|
||||
mesh_.cells()[cellI].points
|
||||
mesh_.cells()[celli].points
|
||||
(
|
||||
mesh_.faces(),
|
||||
mesh_.points()
|
||||
@ -179,15 +179,15 @@ void Foam::backgroundMeshDecomposition::initialRefinement()
|
||||
|
||||
if (geometry.overlaps(cellBb))
|
||||
{
|
||||
volumeStatus[cellI] = volumeType::MIXED;
|
||||
volumeStatus[celli] = volumeType::MIXED;
|
||||
}
|
||||
else if (geometry.inside(cellBb.midpoint()))
|
||||
{
|
||||
volumeStatus[cellI] = volumeType::INSIDE;
|
||||
volumeStatus[celli] = volumeType::INSIDE;
|
||||
}
|
||||
else
|
||||
{
|
||||
volumeStatus[cellI] = volumeType::OUTSIDE;
|
||||
volumeStatus[celli] = volumeType::OUTSIDE;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -211,17 +211,17 @@ void Foam::backgroundMeshDecomposition::initialRefinement()
|
||||
|
||||
forAll(newCellsToRefine, nCTRI)
|
||||
{
|
||||
label cellI = newCellsToRefine[nCTRI];
|
||||
label celli = newCellsToRefine[nCTRI];
|
||||
|
||||
if (volumeStatus[cellI] == volumeType::MIXED)
|
||||
if (volumeStatus[celli] == volumeType::MIXED)
|
||||
{
|
||||
volumeStatus[cellI] = volumeType::UNKNOWN;
|
||||
volumeStatus[celli] = volumeType::UNKNOWN;
|
||||
}
|
||||
|
||||
icellWeights[cellI] = max
|
||||
icellWeights[celli] = max
|
||||
(
|
||||
1.0,
|
||||
icellWeights[cellI]/8.0
|
||||
icellWeights[celli]/8.0
|
||||
);
|
||||
}
|
||||
|
||||
@ -283,13 +283,13 @@ void Foam::backgroundMeshDecomposition::initialRefinement()
|
||||
}
|
||||
|
||||
// Determine/update the status of each cell
|
||||
forAll(volumeStatus, cellI)
|
||||
forAll(volumeStatus, celli)
|
||||
{
|
||||
if (volumeStatus[cellI] == volumeType::UNKNOWN)
|
||||
if (volumeStatus[celli] == volumeType::UNKNOWN)
|
||||
{
|
||||
treeBoundBox cellBb
|
||||
(
|
||||
mesh_.cells()[cellI].points
|
||||
mesh_.cells()[celli].points
|
||||
(
|
||||
mesh_.faces(),
|
||||
mesh_.points()
|
||||
@ -298,15 +298,15 @@ void Foam::backgroundMeshDecomposition::initialRefinement()
|
||||
|
||||
if (geometry.overlaps(cellBb))
|
||||
{
|
||||
volumeStatus[cellI] = volumeType::MIXED;
|
||||
volumeStatus[celli] = volumeType::MIXED;
|
||||
}
|
||||
else if (geometry.inside(cellBb.midpoint()))
|
||||
{
|
||||
volumeStatus[cellI] = volumeType::INSIDE;
|
||||
volumeStatus[celli] = volumeType::INSIDE;
|
||||
}
|
||||
else
|
||||
{
|
||||
volumeStatus[cellI] = volumeType::OUTSIDE;
|
||||
volumeStatus[celli] = volumeType::OUTSIDE;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -318,11 +318,11 @@ void Foam::backgroundMeshDecomposition::initialRefinement()
|
||||
{
|
||||
DynamicList<label> cellsToRemove;
|
||||
|
||||
forAll(volumeStatus, cellI)
|
||||
forAll(volumeStatus, celli)
|
||||
{
|
||||
if (volumeStatus[cellI] == volumeType::OUTSIDE)
|
||||
if (volumeStatus[celli] == volumeType::OUTSIDE)
|
||||
{
|
||||
cellsToRemove.append(cellI);
|
||||
cellsToRemove.append(celli);
|
||||
}
|
||||
}
|
||||
|
||||
@ -503,7 +503,7 @@ void Foam::backgroundMeshDecomposition::printMeshData
|
||||
|
||||
bool Foam::backgroundMeshDecomposition::refineCell
|
||||
(
|
||||
label cellI,
|
||||
label celli,
|
||||
volumeType volType,
|
||||
scalar& weightEstimate
|
||||
) const
|
||||
@ -515,7 +515,7 @@ bool Foam::backgroundMeshDecomposition::refineCell
|
||||
|
||||
treeBoundBox cellBb
|
||||
(
|
||||
mesh_.cells()[cellI].points
|
||||
mesh_.cells()[celli].points
|
||||
(
|
||||
mesh_.faces(),
|
||||
mesh_.points()
|
||||
@ -637,29 +637,29 @@ Foam::labelList Foam::backgroundMeshDecomposition::selectRefinementCells
|
||||
labelHashSet cellsToRefine;
|
||||
|
||||
// Determine/update the status of each cell
|
||||
forAll(volumeStatus, cellI)
|
||||
forAll(volumeStatus, celli)
|
||||
{
|
||||
if (volumeStatus[cellI] == volumeType::MIXED)
|
||||
if (volumeStatus[celli] == volumeType::MIXED)
|
||||
{
|
||||
if (meshCutter_.cellLevel()[cellI] < minLevels_)
|
||||
if (meshCutter_.cellLevel()[celli] < minLevels_)
|
||||
{
|
||||
cellsToRefine.insert(cellI);
|
||||
cellsToRefine.insert(celli);
|
||||
}
|
||||
}
|
||||
|
||||
if (volumeStatus[cellI] != volumeType::OUTSIDE)
|
||||
if (volumeStatus[celli] != volumeType::OUTSIDE)
|
||||
{
|
||||
if
|
||||
(
|
||||
refineCell
|
||||
(
|
||||
cellI,
|
||||
volumeStatus[cellI],
|
||||
icellWeights[cellI]
|
||||
celli,
|
||||
volumeStatus[celli],
|
||||
icellWeights[celli]
|
||||
)
|
||||
)
|
||||
{
|
||||
cellsToRefine.insert(cellI);
|
||||
cellsToRefine.insert(celli);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -943,9 +943,9 @@ Foam::backgroundMeshDecomposition::distribute
|
||||
|
||||
forAll(newCellsToRefine, nCTRI)
|
||||
{
|
||||
label cellI = newCellsToRefine[nCTRI];
|
||||
label celli = newCellsToRefine[nCTRI];
|
||||
|
||||
icellWeights[cellI] /= 8.0;
|
||||
icellWeights[celli] /= 8.0;
|
||||
}
|
||||
|
||||
// Mesh changing engine.
|
||||
|
||||
@ -167,7 +167,7 @@ class backgroundMeshDecomposition
|
||||
// it
|
||||
bool refineCell
|
||||
(
|
||||
label cellI,
|
||||
label celli,
|
||||
volumeType volType,
|
||||
scalar& weightEstimate
|
||||
) const;
|
||||
|
||||
@ -133,7 +133,7 @@ void Foam::conformalVoronoiMesh::calcTetMesh
|
||||
points.setSize(vertI);
|
||||
pointToDelaunayVertex.setSize(vertI);
|
||||
|
||||
label cellI = 0;
|
||||
label celli = 0;
|
||||
|
||||
for
|
||||
(
|
||||
@ -144,7 +144,7 @@ void Foam::conformalVoronoiMesh::calcTetMesh
|
||||
{
|
||||
if (cit->internalOrBoundaryDualVertex())
|
||||
{
|
||||
cit->cellIndex() = cellI++;
|
||||
cit->cellIndex() = celli++;
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -170,7 +170,7 @@ void Foam::conformalVoronoiMesh::calcTetMesh
|
||||
|
||||
neighbour.setSize(number_of_finite_facets());
|
||||
|
||||
label faceI = 0;
|
||||
label facei = 0;
|
||||
|
||||
labelList verticesOnTriFace(3, label(-1));
|
||||
|
||||
@ -262,14 +262,14 @@ void Foam::conformalVoronoiMesh::calcTetMesh
|
||||
neighbourCell = c1I;
|
||||
}
|
||||
|
||||
faces[faceI] = newFace;
|
||||
owner[faceI] = ownerCell;
|
||||
neighbour[faceI] = neighbourCell;
|
||||
faceI++;
|
||||
faces[facei] = newFace;
|
||||
owner[facei] = ownerCell;
|
||||
neighbour[facei] = neighbourCell;
|
||||
facei++;
|
||||
}
|
||||
}
|
||||
|
||||
label nInternalFaces = faceI;
|
||||
label nInternalFaces = facei;
|
||||
|
||||
faces.setSize(nInternalFaces);
|
||||
owner.setSize(nInternalFaces);
|
||||
@ -910,11 +910,11 @@ void Foam::conformalVoronoiMesh::checkCellSizing()
|
||||
pointField cellsToResize(cellsToResizeMap.size());
|
||||
|
||||
label count = 0;
|
||||
for (label cellI = 0; cellI < pMesh.nCells(); ++cellI)
|
||||
for (label celli = 0; celli < pMesh.nCells(); ++celli)
|
||||
{
|
||||
if (cellsToResizeMap.found(cellI))
|
||||
if (cellsToResizeMap.found(celli))
|
||||
{
|
||||
cellsToResize[count++] = pMesh.cellCentres()[cellI];
|
||||
cellsToResize[count++] = pMesh.cellCentres()[celli];
|
||||
}
|
||||
}
|
||||
|
||||
@ -1152,9 +1152,9 @@ Foam::labelHashSet Foam::conformalVoronoiMesh::checkPolyMeshQuality
|
||||
|
||||
// forAllConstIter(labelHashSet, limitCells, iter)
|
||||
// {
|
||||
// label cellI = iter.key();
|
||||
// label celli = iter.key();
|
||||
|
||||
// const labelList& cP = cellPts[cellI];
|
||||
// const labelList& cP = cellPts[celli];
|
||||
|
||||
// forAll(cP, cPI)
|
||||
// {
|
||||
@ -2527,17 +2527,17 @@ void Foam::conformalVoronoiMesh::addPatches
|
||||
owner.setSize(nInternalFaces + nBoundaryFaces);
|
||||
boundaryFacesToRemove.setSize(nInternalFaces + nBoundaryFaces);
|
||||
|
||||
label faceI = nInternalFaces;
|
||||
label facei = nInternalFaces;
|
||||
|
||||
forAll(patchFaces, p)
|
||||
{
|
||||
forAll(patchFaces[p], f)
|
||||
{
|
||||
faces[faceI] = patchFaces[p][f];
|
||||
owner[faceI] = patchOwners[p][f];
|
||||
boundaryFacesToRemove[faceI] = indirectPatchFace[p][f];
|
||||
faces[facei] = patchFaces[p][f];
|
||||
owner[facei] = patchOwners[p][f];
|
||||
boundaryFacesToRemove[facei] = indirectPatchFace[p][f];
|
||||
|
||||
faceI++;
|
||||
facei++;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -2623,7 +2623,7 @@ Foam::labelList Foam::conformalVoronoiMesh::removeUnusedCells
|
||||
cellUsed[neighbour[nI]] = true;
|
||||
}
|
||||
|
||||
label cellI = 0;
|
||||
label celli = 0;
|
||||
|
||||
labelList oldToNew(cellUsed.size(), label(-1));
|
||||
|
||||
@ -2634,11 +2634,11 @@ Foam::labelList Foam::conformalVoronoiMesh::removeUnusedCells
|
||||
{
|
||||
if (cellUsed[cellUI] == true)
|
||||
{
|
||||
oldToNew[cellUI] = cellI++;
|
||||
oldToNew[cellUI] = celli++;
|
||||
}
|
||||
}
|
||||
|
||||
labelList newToOld(invert(cellI, oldToNew));
|
||||
labelList newToOld(invert(celli, oldToNew));
|
||||
|
||||
// Find all of the unused cells, create a list of them, then
|
||||
// subtract one from each owner and neighbour entry for each of
|
||||
|
||||
@ -132,30 +132,30 @@ Foam::label Foam::conformalVoronoiMesh::findVerticesNearBoundaries()
|
||||
continue;
|
||||
}
|
||||
|
||||
for (label cellI = 0; cellI < 4; ++cellI)
|
||||
for (label celli = 0; celli < 4; ++celli)
|
||||
{
|
||||
Vertex_handle v = c1->vertex(cellI);
|
||||
Vertex_handle v = c1->vertex(celli);
|
||||
|
||||
if
|
||||
(
|
||||
!is_infinite(v)
|
||||
&& v->internalPoint()
|
||||
&& fit->second != cellI
|
||||
&& fit->second != celli
|
||||
)
|
||||
{
|
||||
v->setNearBoundary();
|
||||
}
|
||||
}
|
||||
|
||||
for (label cellI = 0; cellI < 4; ++cellI)
|
||||
for (label celli = 0; celli < 4; ++celli)
|
||||
{
|
||||
Vertex_handle v = c2->vertex(cellI);
|
||||
Vertex_handle v = c2->vertex(celli);
|
||||
|
||||
if
|
||||
(
|
||||
!is_infinite(v)
|
||||
&& v->internalPoint()
|
||||
&& fit->second != cellI
|
||||
&& fit->second != celli
|
||||
)
|
||||
{
|
||||
v->setNearBoundary();
|
||||
|
||||
@ -179,7 +179,7 @@ void Foam::conformalVoronoiMesh::writeMesh(const fileName& instance)
|
||||
|
||||
if (foamyHexMeshControls().writeTetDualMesh())
|
||||
{
|
||||
label cellI = 0;
|
||||
label celli = 0;
|
||||
for
|
||||
(
|
||||
Finite_cells_iterator cit = finite_cells_begin();
|
||||
@ -193,7 +193,7 @@ void Foam::conformalVoronoiMesh::writeMesh(const fileName& instance)
|
||||
&& !is_infinite(cit)
|
||||
)
|
||||
{
|
||||
cit->cellIndex() = cellI++;
|
||||
cit->cellIndex() = celli++;
|
||||
}
|
||||
}
|
||||
|
||||
@ -213,20 +213,20 @@ void Foam::conformalVoronoiMesh::writeMesh(const fileName& instance)
|
||||
// // or patch face (negative index)
|
||||
// labelList vertexToDualAddressing(number_of_vertices(), 0);
|
||||
//
|
||||
// forAll(cellToDelaunayVertex, cellI)
|
||||
// forAll(cellToDelaunayVertex, celli)
|
||||
// {
|
||||
// label vertI = cellToDelaunayVertex[cellI];
|
||||
// label vertI = cellToDelaunayVertex[celli];
|
||||
//
|
||||
// if (vertexToDualAddressing[vertI] != 0)
|
||||
// {
|
||||
// FatalErrorInFunction
|
||||
// << "Delaunay vertex " << vertI
|
||||
// << " from cell " << cellI
|
||||
// << " from cell " << celli
|
||||
// << " is already mapped to "
|
||||
// << vertexToDualAddressing[vertI]
|
||||
// << exit(FatalError);
|
||||
// }
|
||||
// vertexToDualAddressing[vertI] = cellI+1;
|
||||
// vertexToDualAddressing[vertI] = celli+1;
|
||||
// }
|
||||
//
|
||||
// forAll(patchToDelaunayVertex, patchi)
|
||||
@ -356,15 +356,15 @@ void Foam::conformalVoronoiMesh::writeMesh(const fileName& instance)
|
||||
//
|
||||
// if (index > 0)
|
||||
// {
|
||||
// label cellI = index-1;
|
||||
// dualPoints[pointI] = mesh.cellCentres()[cellI];
|
||||
// label celli = index-1;
|
||||
// dualPoints[pointI] = mesh.cellCentres()[celli];
|
||||
// }
|
||||
// else if (index < 0)
|
||||
// {
|
||||
// label faceI = -index-1;
|
||||
// if (faceI >= mesh.nInternalFaces())
|
||||
// label facei = -index-1;
|
||||
// if (facei >= mesh.nInternalFaces())
|
||||
// {
|
||||
// dualPoints[pointI] = mesh.faceCentres()[faceI];
|
||||
// dualPoints[pointI] = mesh.faceCentres()[facei];
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
@ -736,9 +736,9 @@ void Foam::conformalVoronoiMesh::reorderProcessorPatches
|
||||
{
|
||||
label nReorderedFaces = 0;
|
||||
|
||||
forAll(faceMap, faceI)
|
||||
forAll(faceMap, facei)
|
||||
{
|
||||
if (faceMap[faceI] != -1)
|
||||
if (faceMap[facei] != -1)
|
||||
{
|
||||
nReorderedFaces++;
|
||||
}
|
||||
@ -752,11 +752,11 @@ void Foam::conformalVoronoiMesh::reorderProcessorPatches
|
||||
// Rotate faces (rotation is already in new face indices).
|
||||
label nRotated = 0;
|
||||
|
||||
forAll(rotation, faceI)
|
||||
forAll(rotation, facei)
|
||||
{
|
||||
if (rotation[faceI] != 0)
|
||||
if (rotation[facei] != 0)
|
||||
{
|
||||
faces[faceI] = rotateList(faces[faceI], rotation[faceI]);
|
||||
faces[facei] = rotateList(faces[facei], rotation[facei]);
|
||||
nRotated++;
|
||||
}
|
||||
}
|
||||
@ -961,11 +961,11 @@ void Foam::conformalVoronoiMesh::writeMesh
|
||||
labelList addr(boundaryFacesToRemove.count());
|
||||
label count = 0;
|
||||
|
||||
forAll(boundaryFacesToRemove, faceI)
|
||||
forAll(boundaryFacesToRemove, facei)
|
||||
{
|
||||
if (boundaryFacesToRemove[faceI])
|
||||
if (boundaryFacesToRemove[facei])
|
||||
{
|
||||
addr[count++] = faceI;
|
||||
addr[count++] = facei;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
========= |
|
||||
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
|
||||
\\ / O peration |
|
||||
\\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation
|
||||
\\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
@ -98,22 +98,22 @@ bool Foam::conformalVoronoiMesh::distributeBackground(const Triangulation& mesh)
|
||||
{
|
||||
pointFromPoint v = topoint(vit->point());
|
||||
|
||||
label cellI = cellSearch.findCell(v);
|
||||
label celli = cellSearch.findCell(v);
|
||||
|
||||
if (cellI == -1)
|
||||
if (celli == -1)
|
||||
{
|
||||
// Pout<< "findCell conformalVoronoiMesh::distribute "
|
||||
// << "findCell "
|
||||
// << vit->type() << " "
|
||||
// << vit->index() << " "
|
||||
// << v << " "
|
||||
// << cellI
|
||||
// << " find nearest cellI ";
|
||||
// << celli
|
||||
// << " find nearest celli ";
|
||||
|
||||
cellI = cellSearch.findNearestCell(v);
|
||||
celli = cellSearch.findNearestCell(v);
|
||||
}
|
||||
|
||||
cellVertices[cellI]++;
|
||||
cellVertices[celli]++;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -116,15 +116,15 @@ void Foam::conformalVoronoiMesh::findCellZoneInsideWalk
|
||||
boolList blockedFace(mesh.nFaces());
|
||||
selectSeparatedCoupledFaces(mesh, blockedFace);
|
||||
|
||||
forAll(faceToSurface, faceI)
|
||||
forAll(faceToSurface, facei)
|
||||
{
|
||||
if (faceToSurface[faceI] == -1)
|
||||
if (faceToSurface[facei] == -1)
|
||||
{
|
||||
blockedFace[faceI] = false;
|
||||
blockedFace[facei] = false;
|
||||
}
|
||||
else
|
||||
{
|
||||
blockedFace[faceI] = true;
|
||||
blockedFace[facei] = true;
|
||||
}
|
||||
}
|
||||
// No need to sync since namedSurfaceIndex already is synced
|
||||
@ -156,16 +156,16 @@ void Foam::conformalVoronoiMesh::findCellZoneInsideWalk
|
||||
// Find the region containing the insidePoint
|
||||
label keepRegionI = -1;
|
||||
|
||||
label cellI = mesh.findCell(insidePoint);
|
||||
label celli = mesh.findCell(insidePoint);
|
||||
|
||||
if (cellI != -1)
|
||||
if (celli != -1)
|
||||
{
|
||||
keepRegionI = cellRegion[cellI];
|
||||
keepRegionI = cellRegion[celli];
|
||||
}
|
||||
reduce(keepRegionI, maxOp<label>());
|
||||
|
||||
Info<< " For surface " << surfName
|
||||
<< " found point " << insidePoint << " in cell " << cellI
|
||||
<< " found point " << insidePoint << " in cell " << celli
|
||||
<< " in global region " << keepRegionI
|
||||
<< " out of " << cellRegion.nRegions() << " regions." << endl;
|
||||
|
||||
@ -179,22 +179,22 @@ void Foam::conformalVoronoiMesh::findCellZoneInsideWalk
|
||||
}
|
||||
|
||||
// Set all cells with this region
|
||||
forAll(cellRegion, cellI)
|
||||
forAll(cellRegion, celli)
|
||||
{
|
||||
if (cellRegion[cellI] == keepRegionI)
|
||||
if (cellRegion[celli] == keepRegionI)
|
||||
{
|
||||
if (cellToSurface[cellI] == -2)
|
||||
if (cellToSurface[celli] == -2)
|
||||
{
|
||||
cellToSurface[cellI] = surfI;
|
||||
cellToSurface[celli] = surfI;
|
||||
}
|
||||
else if (cellToSurface[cellI] != surfI)
|
||||
else if (cellToSurface[celli] != surfI)
|
||||
{
|
||||
WarningInFunction
|
||||
<< "Cell " << cellI
|
||||
<< " at " << mesh.cellCentres()[cellI]
|
||||
<< "Cell " << celli
|
||||
<< " at " << mesh.cellCentres()[celli]
|
||||
<< " is inside surface " << surfName
|
||||
<< " but already marked as being in zone "
|
||||
<< cellToSurface[cellI] << endl
|
||||
<< cellToSurface[celli] << endl
|
||||
<< "This can happen if your surfaces are not"
|
||||
<< " (sufficiently) closed."
|
||||
<< endl;
|
||||
@ -343,65 +343,65 @@ void Foam::conformalVoronoiMesh::calcFaceZones
|
||||
|
||||
syncTools::swapBoundaryFaceList(mesh, neiFaceOwner);
|
||||
|
||||
forAll(faces, faceI)
|
||||
forAll(faces, facei)
|
||||
{
|
||||
const label ownerSurfaceI = cellToSurface[faceOwner[faceI]];
|
||||
const label ownerSurfacei = cellToSurface[faceOwner[facei]];
|
||||
|
||||
if (faceToSurface[faceI] >= 0)
|
||||
if (faceToSurface[facei] >= 0)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
if (mesh.isInternalFace(faceI))
|
||||
if (mesh.isInternalFace(facei))
|
||||
{
|
||||
const label neiSurfaceI = cellToSurface[faceNeighbour[faceI]];
|
||||
const label neiSurfacei = cellToSurface[faceNeighbour[facei]];
|
||||
|
||||
if
|
||||
(
|
||||
(ownerSurfaceI >= 0 || neiSurfaceI >= 0)
|
||||
&& ownerSurfaceI != neiSurfaceI
|
||||
(ownerSurfacei >= 0 || neiSurfacei >= 0)
|
||||
&& ownerSurfacei != neiSurfacei
|
||||
)
|
||||
{
|
||||
flipMap[faceI] =
|
||||
flipMap[facei] =
|
||||
(
|
||||
ownerSurfaceI == max(ownerSurfaceI, neiSurfaceI)
|
||||
ownerSurfacei == max(ownerSurfacei, neiSurfacei)
|
||||
? false
|
||||
: true
|
||||
);
|
||||
|
||||
faceToSurface[faceI] = max(ownerSurfaceI, neiSurfaceI);
|
||||
faceToSurface[facei] = max(ownerSurfacei, neiSurfacei);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
label patchID = mesh.boundaryMesh().whichPatch(faceI);
|
||||
label patchID = mesh.boundaryMesh().whichPatch(facei);
|
||||
|
||||
if (mesh.boundaryMesh()[patchID].coupled())
|
||||
{
|
||||
const label neiSurfaceI =
|
||||
neiFaceOwner[faceI - mesh.nInternalFaces()];
|
||||
const label neiSurfacei =
|
||||
neiFaceOwner[facei - mesh.nInternalFaces()];
|
||||
|
||||
if
|
||||
(
|
||||
(ownerSurfaceI >= 0 || neiSurfaceI >= 0)
|
||||
&& ownerSurfaceI != neiSurfaceI
|
||||
(ownerSurfacei >= 0 || neiSurfacei >= 0)
|
||||
&& ownerSurfacei != neiSurfacei
|
||||
)
|
||||
{
|
||||
flipMap[faceI] =
|
||||
flipMap[facei] =
|
||||
(
|
||||
ownerSurfaceI == max(ownerSurfaceI, neiSurfaceI)
|
||||
ownerSurfacei == max(ownerSurfacei, neiSurfacei)
|
||||
? false
|
||||
: true
|
||||
);
|
||||
|
||||
faceToSurface[faceI] = max(ownerSurfaceI, neiSurfaceI);
|
||||
faceToSurface[facei] = max(ownerSurfacei, neiSurfacei);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (ownerSurfaceI >= 0)
|
||||
if (ownerSurfacei >= 0)
|
||||
{
|
||||
faceToSurface[faceI] = ownerSurfaceI;
|
||||
faceToSurface[facei] = ownerSurfacei;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -430,23 +430,23 @@ void Foam::conformalVoronoiMesh::calcFaceZones
|
||||
);
|
||||
|
||||
// Use intersection of cellCentre connections
|
||||
forAll(faces, faceI)
|
||||
forAll(faces, facei)
|
||||
{
|
||||
if (faceToSurface[faceI] >= 0)
|
||||
if (faceToSurface[facei] >= 0)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
label patchID = mesh.boundaryMesh().whichPatch(faceI);
|
||||
label patchID = mesh.boundaryMesh().whichPatch(facei);
|
||||
|
||||
const label own = faceOwner[faceI];
|
||||
const label own = faceOwner[facei];
|
||||
|
||||
List<pointIndexHit> surfHit;
|
||||
labelList hitSurface;
|
||||
|
||||
if (mesh.isInternalFace(faceI))
|
||||
if (mesh.isInternalFace(facei))
|
||||
{
|
||||
const label nei = faceNeighbour[faceI];
|
||||
const label nei = faceNeighbour[facei];
|
||||
|
||||
geometryToConformTo().findSurfaceAllIntersections
|
||||
(
|
||||
@ -461,7 +461,7 @@ void Foam::conformalVoronoiMesh::calcFaceZones
|
||||
geometryToConformTo().findSurfaceAllIntersections
|
||||
(
|
||||
cellCentres[own],
|
||||
neiCc[faceI - mesh.nInternalFaces()],
|
||||
neiCc[facei - mesh.nInternalFaces()],
|
||||
surfHit,
|
||||
hitSurface
|
||||
);
|
||||
@ -481,19 +481,19 @@ void Foam::conformalVoronoiMesh::calcFaceZones
|
||||
norm
|
||||
);
|
||||
|
||||
vector fN = faces[faceI].normal(mesh.points());
|
||||
vector fN = faces[facei].normal(mesh.points());
|
||||
fN /= mag(fN) + SMALL;
|
||||
|
||||
if ((norm[0] & fN) < 0)
|
||||
{
|
||||
flipMap[faceI] = true;
|
||||
flipMap[facei] = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
flipMap[faceI] = false;
|
||||
flipMap[facei] = false;
|
||||
}
|
||||
|
||||
faceToSurface[faceI] = hitSurface[0];
|
||||
faceToSurface[facei] = hitSurface[0];
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -509,9 +509,9 @@ void Foam::conformalVoronoiMesh::calcFaceZones
|
||||
// {
|
||||
// forAll(pp, i)
|
||||
// {
|
||||
// label faceI = pp.start()+i;
|
||||
// label ownSurface = cellToSurface[faceOwner[faceI]];
|
||||
// neiCellSurface[faceI - mesh.nInternalFaces()] = ownSurface;
|
||||
// label facei = pp.start()+i;
|
||||
// label ownSurface = cellToSurface[faceOwner[facei]];
|
||||
// neiCellSurface[facei - mesh.nInternalFaces()] = ownSurface;
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
@ -525,15 +525,15 @@ void Foam::conformalVoronoiMesh::calcFaceZones
|
||||
// {
|
||||
// forAll(pp, i)
|
||||
// {
|
||||
// label faceI = pp.start()+i;
|
||||
// label ownSurface = cellToSurface[faceOwner[faceI]];
|
||||
// label facei = pp.start()+i;
|
||||
// label ownSurface = cellToSurface[faceOwner[facei]];
|
||||
// label neiSurface =
|
||||
// neiCellSurface[faceI-mesh.nInternalFaces()];
|
||||
// neiCellSurface[facei-mesh.nInternalFaces()];
|
||||
//
|
||||
// if (faceToSurface[faceI] == -1 && (ownSurface != neiSurface))
|
||||
// if (faceToSurface[facei] == -1 && (ownSurface != neiSurface))
|
||||
// {
|
||||
// // Give face the max cell zone
|
||||
// faceToSurface[faceI] = max(ownSurface, neiSurface);
|
||||
// faceToSurface[facei] = max(ownSurface, neiSurface);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
@ -617,13 +617,13 @@ void Foam::conformalVoronoiMesh::addZones
|
||||
// Topochange container
|
||||
polyTopoChange meshMod(mesh);
|
||||
|
||||
forAll(cellToSurface, cellI)
|
||||
forAll(cellToSurface, celli)
|
||||
{
|
||||
label surfaceI = cellToSurface[cellI];
|
||||
label surfacei = cellToSurface[celli];
|
||||
|
||||
if (surfaceI >= 0)
|
||||
if (surfacei >= 0)
|
||||
{
|
||||
label zoneI = surfaceToCellZone[surfaceI];
|
||||
label zoneI = surfaceToCellZone[surfacei];
|
||||
|
||||
if (zoneI >= 0)
|
||||
{
|
||||
@ -631,7 +631,7 @@ void Foam::conformalVoronoiMesh::addZones
|
||||
(
|
||||
polyModifyCell
|
||||
(
|
||||
cellI,
|
||||
celli,
|
||||
false, // removeFromZone
|
||||
zoneI
|
||||
)
|
||||
@ -643,55 +643,55 @@ void Foam::conformalVoronoiMesh::addZones
|
||||
const labelList& faceOwner = mesh.faceOwner();
|
||||
const labelList& faceNeighbour = mesh.faceNeighbour();
|
||||
|
||||
forAll(faceToSurface, faceI)
|
||||
forAll(faceToSurface, facei)
|
||||
{
|
||||
label surfaceI = faceToSurface[faceI];
|
||||
label surfacei = faceToSurface[facei];
|
||||
|
||||
if (surfaceI < 0)
|
||||
if (surfacei < 0)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
label patchID = mesh.boundaryMesh().whichPatch(faceI);
|
||||
label patchID = mesh.boundaryMesh().whichPatch(facei);
|
||||
|
||||
if (mesh.isInternalFace(faceI))
|
||||
if (mesh.isInternalFace(facei))
|
||||
{
|
||||
label own = faceOwner[faceI];
|
||||
label nei = faceNeighbour[faceI];
|
||||
label own = faceOwner[facei];
|
||||
label nei = faceNeighbour[facei];
|
||||
|
||||
meshMod.setAction
|
||||
(
|
||||
polyModifyFace
|
||||
(
|
||||
mesh.faces()[faceI], // modified face
|
||||
faceI, // label of face
|
||||
mesh.faces()[facei], // modified face
|
||||
facei, // label of face
|
||||
own, // owner
|
||||
nei, // neighbour
|
||||
false, // face flip
|
||||
-1, // patch for face
|
||||
false, // remove from zone
|
||||
surfaceToFaceZone[surfaceI], // zone for face
|
||||
flipMap[faceI] // face flip in zone
|
||||
surfaceToFaceZone[surfacei], // zone for face
|
||||
flipMap[facei] // face flip in zone
|
||||
)
|
||||
);
|
||||
}
|
||||
else if (patchID != -1 && mesh.boundaryMesh()[patchID].coupled())
|
||||
{
|
||||
label own = faceOwner[faceI];
|
||||
label own = faceOwner[facei];
|
||||
|
||||
meshMod.setAction
|
||||
(
|
||||
polyModifyFace
|
||||
(
|
||||
mesh.faces()[faceI], // modified face
|
||||
faceI, // label of face
|
||||
mesh.faces()[facei], // modified face
|
||||
facei, // label of face
|
||||
own, // owner
|
||||
-1, // neighbour
|
||||
false, // face flip
|
||||
patchID, // patch for face
|
||||
false, // remove from zone
|
||||
surfaceToFaceZone[surfaceI], // zone for face
|
||||
flipMap[faceI] // face flip in zone
|
||||
surfaceToFaceZone[surfacei], // zone for face
|
||||
flipMap[facei] // face flip in zone
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
@ -255,7 +255,7 @@ autoPtr<polyMesh> generateHexMesh
|
||||
cellShapeList cellShapes(nCells[0]*nCells[1]*nCells[2]);
|
||||
|
||||
labelList hexPoints(8);
|
||||
label cellI = 0;
|
||||
label celli = 0;
|
||||
for (label i = 0; i < nCells[0]; i++)
|
||||
{
|
||||
for (label j = 0; j < nCells[1]; j++)
|
||||
@ -270,7 +270,7 @@ autoPtr<polyMesh> generateHexMesh
|
||||
hexPoints[5] = vtxLabel(nCells, i+1, j, k+1);
|
||||
hexPoints[6] = vtxLabel(nCells, i+1, j+1, k+1);
|
||||
hexPoints[7] = vtxLabel(nCells, i, j+1, k+1);
|
||||
cellShapes[cellI++] = cellShape(hex, hexPoints);
|
||||
cellShapes[celli++] = cellShape(hex, hexPoints);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -627,11 +627,11 @@ int main(int argc, char *argv[])
|
||||
scalarField distSqr(cellDistance.size());
|
||||
|
||||
const labelList& cellLevel = backgroundMesh.cellLevel();
|
||||
forAll(cellLevel, cellI)
|
||||
forAll(cellLevel, celli)
|
||||
{
|
||||
// The largest edge of the cell will always be less than the
|
||||
// span of the bounding box of the cell.
|
||||
distSqr[cellI] = magSqr(cellSize)/pow(2, cellLevel[cellI]);
|
||||
distSqr[celli] = magSqr(cellSize)/pow(2, cellLevel[celli]);
|
||||
}
|
||||
|
||||
{
|
||||
@ -682,12 +682,12 @@ int main(int argc, char *argv[])
|
||||
);
|
||||
{
|
||||
scalarField pointDistSqr(fvm.nPoints(), -sqr(GREAT));
|
||||
for (label faceI = 0; faceI < fvm.nInternalFaces(); faceI++)
|
||||
for (label facei = 0; facei < fvm.nInternalFaces(); facei++)
|
||||
{
|
||||
label own = fvm.faceOwner()[faceI];
|
||||
label own = fvm.faceOwner()[facei];
|
||||
label ownDistSqr = distSqr[own];
|
||||
|
||||
const face& f = fvm.faces()[faceI];
|
||||
const face& f = fvm.faces()[facei];
|
||||
forAll(f, fp)
|
||||
{
|
||||
pointDistSqr[f[fp]] = max(pointDistSqr[f[fp]], ownDistSqr);
|
||||
|
||||
@ -243,9 +243,9 @@ Foam::shortEdgeFilter2D::filter()
|
||||
|
||||
// List of number of vertices in a face.
|
||||
labelList newFaceVertexCount(faces.size(), -1);
|
||||
forAll(faces, faceI)
|
||||
forAll(faces, facei)
|
||||
{
|
||||
newFaceVertexCount[faceI] = faces[faceI].size();
|
||||
newFaceVertexCount[facei] = faces[facei].size();
|
||||
}
|
||||
|
||||
// Check if the point is a boundary point. Flag if it is so that
|
||||
@ -456,9 +456,9 @@ Foam::shortEdgeFilter2D::filter()
|
||||
label newFaceSize = 0;
|
||||
|
||||
// Now need to iterate over the faces and remove points. Global index.
|
||||
forAll(faces, faceI)
|
||||
forAll(faces, facei)
|
||||
{
|
||||
const face& f = faces[faceI];
|
||||
const face& f = faces[facei];
|
||||
|
||||
newFace.clear();
|
||||
newFace.setSize(f.size());
|
||||
@ -526,7 +526,7 @@ Foam::shortEdgeFilter2D::filter()
|
||||
else
|
||||
{
|
||||
FatalErrorInFunction
|
||||
<< "Only " << newFace.size() << " in face " << faceI
|
||||
<< "Only " << newFace.size() << " in face " << facei
|
||||
<< exit(FatalError);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user