diff --git a/applications/utilities/mesh/conversion/kivaToFoam/readKivaGrid.H b/applications/utilities/mesh/conversion/kivaToFoam/readKivaGrid.H index ca08396837c79040c257b1600a55cda6b2adf03f..3aabf9614af75a178aeead7e5ab8cc1198e096c8 100644 --- a/applications/utilities/mesh/conversion/kivaToFoam/readKivaGrid.H +++ b/applications/utilities/mesh/conversion/kivaToFoam/readKivaGrid.H @@ -42,7 +42,7 @@ for (label i=0; i<nPoints; i++) labelList i1tab(nPoints), i3tab(nPoints), i8tab(nPoints), idreg(nPoints), f(nPoints), bcl(nPoints), bcf(nPoints), bcb(nPoints); -label nBfaces = 0; +// label nBfaces = 0; for (label i=0; i<nPoints; i++) { @@ -65,9 +65,9 @@ for (label i=0; i<nPoints; i++) bcf[i] = label(fbcf); bcb[i] = label(fbcb); - if (bcl[i] > 0 && bcl[i] != 4) nBfaces++; - if (bcf[i] > 0 && bcf[i] != 4) nBfaces++; - if (bcb[i] > 0 && bcb[i] != 4) nBfaces++; + // if (bcl[i] > 0 && bcl[i] != 4) ++nBfaces; + // if (bcf[i] > 0 && bcf[i] != 4) ++nBfaces; + // if (bcb[i] > 0 && bcb[i] != 4) ++nBfaces; } diff --git a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/DelaunayMesh/DelaunayMeshIO.C b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/DelaunayMesh/DelaunayMeshIO.C index 2dc3f59928111077c2561c67a18b41e5021f3979..4f732312868d1a6aee518b4bd80087b50145de37 100644 --- a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/DelaunayMesh/DelaunayMeshIO.C +++ b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/DelaunayMesh/DelaunayMeshIO.C @@ -170,23 +170,23 @@ template<class Triangulation> void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const { label nInternal = 0; - label nInternalRef = 0; + //label nInternalRef = 0; label nUnassigned = 0; - label nUnassignedRef = 0; + //label nUnassignedRef = 0; label nInternalNearBoundary = 0; - label nInternalNearBoundaryRef = 0; + //label nInternalNearBoundaryRef = 0; label nInternalSurface = 0; - label nInternalSurfaceRef = 0; + //label nInternalSurfaceRef = 0; label nInternalFeatureEdge = 0; - label nInternalFeatureEdgeRef = 0; + //label nInternalFeatureEdgeRef = 0; label nInternalFeaturePoint = 0; - label nInternalFeaturePointRef = 0; + //label nInternalFeaturePointRef = 0; label nExternalSurface = 0; - label nExternalSurfaceRef = 0; + //label nExternalSurfaceRef = 0; label nExternalFeatureEdge = 0; - label nExternalFeatureEdgeRef = 0; + //label nExternalFeatureEdgeRef = 0; label nExternalFeaturePoint = 0; - label nExternalFeaturePointRef = 0; + //label nExternalFeaturePointRef = 0; label nFar = 0; label nReferred = 0; @@ -202,7 +202,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const if (vit->referred()) { nReferred++; - nInternalRef++; + //++nInternalRef; } nInternal++; @@ -212,7 +212,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const if (vit->referred()) { nReferred++; - nUnassignedRef++; + //++nUnassignedRef; } nUnassigned++; @@ -222,7 +222,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const if (vit->referred()) { nReferred++; - nInternalNearBoundaryRef++; + //++nInternalNearBoundaryRef; } nInternalNearBoundary++; @@ -232,7 +232,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const if (vit->referred()) { nReferred++; - nInternalSurfaceRef++; + //++nInternalSurfaceRef; } nInternalSurface++; @@ -242,7 +242,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const if (vit->referred()) { nReferred++; - nInternalFeatureEdgeRef++; + //++nInternalFeatureEdgeRef; } nInternalFeatureEdge++; @@ -252,7 +252,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const if (vit->referred()) { nReferred++; - nInternalFeaturePointRef++; + //++nInternalFeaturePointRef; } nInternalFeaturePoint++; @@ -262,7 +262,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const if (vit->referred()) { nReferred++; - nExternalSurfaceRef++; + //++nExternalSurfaceRef; } nExternalSurface++; @@ -272,7 +272,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const if (vit->referred()) { nReferred++; - nExternalFeatureEdgeRef++; + //++nExternalFeatureEdgeRef; } nExternalFeatureEdge++; @@ -282,7 +282,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const if (vit->referred()) { nReferred++; - nExternalFeaturePointRef++; + //++nExternalFeaturePointRef; } nExternalFeaturePoint++; diff --git a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/DelaunayMesh/DistributedDelaunayMesh.C b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/DelaunayMesh/DistributedDelaunayMesh.C index 01c14c7060eedb0ab261c1ced3b8e8a9ddacb27f..2c50d6c462b46a2cf659c1562d74fedb4f348c91 100644 --- a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/DelaunayMesh/DistributedDelaunayMesh.C +++ b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/DelaunayMesh/DistributedDelaunayMesh.C @@ -853,7 +853,7 @@ Foam::DistributedDelaunayMesh<Triangulation>::rangeInsertReferredWithInfo typename Triangulation::Locate_type lt; int li, lj; - label nNotInserted = 0; + //label nNotInserted = 0; labelPairHashSet uninserted ( @@ -979,7 +979,7 @@ Foam::DistributedDelaunayMesh<Triangulation>::rangeInsertReferredWithInfo else { uninserted.insert(labelPair(vert.procIndex(), vert.index())); - nNotInserted++; + //++nNotInserted; } } diff --git a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/cellShapeControl/cellShapeControl/cellShapeControl.C b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/cellShapeControl/cellShapeControl/cellShapeControl.C index 8b5d394e19e31683e276ac3d5b170c1ab858623b..cb7a6208c66c15132cd4b56d29e6e7a42defe7f2 100644 --- a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/cellShapeControl/cellShapeControl/cellShapeControl.C +++ b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/cellShapeControl/cellShapeControl/cellShapeControl.C @@ -104,7 +104,7 @@ Foam::scalar Foam::cellShapeControl::cellSize(const point& pt) const } else if (shapeControlMesh_.is_infinite(ch)) { -// if (nFarPoints != 0) +// if (nFarPoints) // { // for (label pI = 0; pI < 4; ++pI) // { @@ -136,11 +136,11 @@ Foam::scalar Foam::cellShapeControl::cellSize(const point& pt) const { if (ch->vertex(pI)->farPoint()) { - nFarPoints++; + ++nFarPoints; } } - if (nFarPoints != 0) + if (nFarPoints) { for (label pI = 0; pI < 4; ++pI) { @@ -179,16 +179,16 @@ Foam::tensor Foam::cellShapeControl::cellAlignment(const point& pt) const } else { - label nFarPoints = 0; - for (label pI = 0; pI < 4; ++pI) - { - if (ch->vertex(pI)->farPoint()) - { - nFarPoints++; - } - } - -// if (nFarPoints != 0) + // label nFarPoints = 0; + // for (label pI = 0; pI < 4; ++pI) + // { + // if (ch->vertex(pI)->farPoint()) + // { + // ++nFarPoints; + // } + // } + +// if (nFarPoints) // { // for (label pI = 0; pI < 4; ++pI) // { @@ -259,11 +259,11 @@ void Foam::cellShapeControl::cellSizeAndAlignment { if (ch->vertex(pI)->farPoint()) { - nFarPoints++; + ++nFarPoints; } } - if (nFarPoints != 0) + if (nFarPoints) { for (label pI = 0; pI < 4; ++pI) { diff --git a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/cellShapeControl/controlMeshRefinement/controlMeshRefinement.C b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/cellShapeControl/controlMeshRefinement/controlMeshRefinement.C index 313a039a7b1987c85df7e63090f0cee7dc233fc6..3aee2b34338cb13207e19169553d0ddce766894a 100644 --- a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/cellShapeControl/controlMeshRefinement/controlMeshRefinement.C +++ b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/cellShapeControl/controlMeshRefinement/controlMeshRefinement.C @@ -82,11 +82,11 @@ bool Foam::controlMeshRefinement::detectEdge Foam::point midPoint = (a + b)/2.0; - label nIterations = 0; + //label nIterations = 0; while (true) { - nIterations++; + //++nIterations; if ( diff --git a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/conformalVoronoiMesh/featurePointConformer/featurePointConformerSpecialisations.C b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/conformalVoronoiMesh/featurePointConformer/featurePointConformerSpecialisations.C index bd274824f34287ee1fe5b0d9d449a50705fe6d11..3f8d6f104a909939e2a61ea85ae8bc63b4d96679 100644 --- a/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/conformalVoronoiMesh/featurePointConformer/featurePointConformerSpecialisations.C +++ b/applications/utilities/mesh/generation/foamyMesh/conformalVoronoiMesh/conformalVoronoiMesh/featurePointConformer/featurePointConformerSpecialisations.C @@ -74,7 +74,7 @@ bool Foam::featurePointConformer::createSpecialisedFeaturePoint return false; } - label nVert = foamyHexMesh_.number_of_vertices(); + //label nVert = foamyHexMesh_.number_of_vertices(); const label initialNumOfPoints = pts.size(); @@ -267,7 +267,7 @@ bool Foam::featurePointConformer::createSpecialisedFeaturePoint // Remove points that have just been added before returning pts.pop_back(2); - nVert -= 2; + //nVert -= 2; return false; } @@ -503,7 +503,7 @@ bool Foam::featurePointConformer::createSpecialisedFeaturePoint return false; } - label nVert = foamyHexMesh_.number_of_vertices(); + //label nVert = foamyHexMesh_.number_of_vertices(); const label initialNumOfPoints = pts.size(); @@ -700,7 +700,7 @@ bool Foam::featurePointConformer::createSpecialisedFeaturePoint // Remove points that have just been added before returning pts.pop_back(2); - nVert -= 2; + //nVert -= 2; return false; } diff --git a/applications/utilities/postProcessing/dataConversion/foamToVTK/convertAreaFields.H b/applications/utilities/postProcessing/dataConversion/foamToVTK/convertAreaFields.H index bdfe96ceb5a2d7a6dc5baa9fa611a1f22a74fa3a..7d8f467ab7a779ba65480ed535be3d6018888935 100644 --- a/applications/utilities/postProcessing/dataConversion/foamToVTK/convertAreaFields.H +++ b/applications/utilities/postProcessing/dataConversion/foamToVTK/convertAreaFields.H @@ -81,7 +81,7 @@ if (doFiniteArea) labelList patchIds ( - areaMesh.mesh().boundaryMesh().patchID(areaMesh.faceLabels()) + pbm.patchID(areaMesh.faceLabels()) ); writer.writeCellData("patchID", patchIds); diff --git a/applications/utilities/surface/surfaceBooleanFeatures/surfaceBooleanFeatures.C b/applications/utilities/surface/surfaceBooleanFeatures/surfaceBooleanFeatures.C index 5cc5d909e5a50c1be9a2c2d5571a83a97ff4a02e..b7f2715b253ac96b1bae0d758899d97d6408fd67 100644 --- a/applications/utilities/surface/surfaceBooleanFeatures/surfaceBooleanFeatures.C +++ b/applications/utilities/surface/surfaceBooleanFeatures/surfaceBooleanFeatures.C @@ -1408,7 +1408,7 @@ autoPtr<extendedFeatureEdgeMesh> createEdgeMesh label nIntOrExt = 0; label nFlat = 0; label nOpen = 0; - label nMultiple = 0; + // label nMultiple = 0; forAll(edgeNormals, eI) { @@ -1432,10 +1432,10 @@ autoPtr<extendedFeatureEdgeMesh> createEdgeMesh nIntOrExt++; } } - else if (nEdNorms > 2) - { - nMultiple++; - } + // else if (nEdNorms > 2) + // { + // ++nMultiple; + // } } if (action == booleanSurface::UNION) diff --git a/applications/utilities/surface/surfaceClean/collapseBase.C b/applications/utilities/surface/surfaceClean/collapseBase.C index 5c5572c23b5bdf298a81a0baf14f043bfc20f3d9..7ba52a001062660b6d46b26ecca63d6c5105d139 100644 --- a/applications/utilities/surface/surfaceClean/collapseBase.C +++ b/applications/utilities/surface/surfaceClean/collapseBase.C @@ -775,7 +775,7 @@ label collapseBase { label nTotalSplit = 0; - label iter = 0; + // label iter = 0; while (true) { @@ -980,7 +980,7 @@ label collapseBase // surf.write(fName); //} - iter++; + // ++iter; } // Remove any unused vertices diff --git a/src/conversion/starcd/STARCDMeshReader.C b/src/conversion/starcd/STARCDMeshReader.C index b17252ac7d0924a06961be1b904e54fe5fc92884..d69fcdc46abe7e9953930e5a0a90ebe218ddd504 100644 --- a/src/conversion/starcd/STARCDMeshReader.C +++ b/src/conversion/starcd/STARCDMeshReader.C @@ -697,7 +697,8 @@ void Foam::fileFormats::STARCDMeshReader::readBoundary // keep empty patch region in reserve ++nPatches; Info<< "Number of patches = " << nPatches - << " (including extra for missing)" << endl; + << " (including extra for missing) with " + << nFaces << " faces" << endl; // resize origRegion.setSize(nPatches); diff --git a/src/fileFormats/vtk/part/foamVtuSizingImpl.C b/src/fileFormats/vtk/part/foamVtuSizingImpl.C index ea834692515b29b3a911ee621aff0cd6c2b6f561..b1d763d2c474a596850dac76d78040024bffacc4 100644 --- a/src/fileFormats/vtk/part/foamVtuSizingImpl.C +++ b/src/fileFormats/vtk/part/foamVtuSizingImpl.C @@ -756,7 +756,7 @@ void Foam::vtk::vtuSizing::populateArrays const label nInputCells = shapes.size(); - label nIgnored = 0; + // label nIgnored = 0; for ( @@ -852,7 +852,7 @@ void Foam::vtk::vtuSizing::populateArrays // Silent here. // - already complained (and skipped) during initial sizing --cellIndex; - ++nIgnored; + // ++nIgnored; } } diff --git a/src/finiteVolume/cfdTools/general/MRF/MRFZone.C b/src/finiteVolume/cfdTools/general/MRF/MRFZone.C index 90e91ede074224d16d1485a6227c5953a5f50e24..4244ee7f79df5c77d4aa540ecee89a56eb5fea9b 100644 --- a/src/finiteVolume/cfdTools/general/MRF/MRFZone.C +++ b/src/finiteVolume/cfdTools/general/MRF/MRFZone.C @@ -75,14 +75,14 @@ void Foam::MRFZone::setMRFFaces() } - label nZoneFaces = 0; + // label nZoneFaces = 0; for (label facei = 0; facei < mesh_.nInternalFaces(); facei++) { if (zoneCell[own[facei]] || zoneCell[nei[facei]]) { faceType[facei] = 1; - nZoneFaces++; + // ++nZoneFaces; } } @@ -102,7 +102,7 @@ void Foam::MRFZone::setMRFFaces() if (zoneCell[own[facei]]) { faceType[facei] = 2; - nZoneFaces++; + // ++nZoneFaces; } } } @@ -115,7 +115,7 @@ void Foam::MRFZone::setMRFFaces() if (zoneCell[own[facei]]) { faceType[facei] = 1; - nZoneFaces++; + // ++nZoneFaces; } } } diff --git a/src/functionObjects/field/regionSizeDistribution/regionSizeDistribution.C b/src/functionObjects/field/regionSizeDistribution/regionSizeDistribution.C index 3b55fda4d5d19752f4bb2bd8df9220a0ac4e7855..ebdf67cf7820e74e686ebafd162333b9d596dc1c 100644 --- a/src/functionObjects/field/regionSizeDistribution/regionSizeDistribution.C +++ b/src/functionObjects/field/regionSizeDistribution/regionSizeDistribution.C @@ -474,7 +474,7 @@ bool Foam::functionObjects::regionSizeDistribution::write() // Determine blocked faces boolList blockedFace(mesh_.nFaces(), false); - label nBlocked = 0; + // label nBlocked = 0; { for (label facei = 0; facei < mesh_.nInternalFaces(); facei++) @@ -489,7 +489,7 @@ bool Foam::functionObjects::regionSizeDistribution::write() ) { blockedFace[facei] = true; - nBlocked++; + // ++nBlocked; } } @@ -518,7 +518,7 @@ bool Foam::functionObjects::regionSizeDistribution::write() ) { blockedFace[start+i] = true; - nBlocked++; + // ++nBlocked; } } } diff --git a/src/functionObjects/utilities/vtkWrite/vtkWriteImpl.C b/src/functionObjects/utilities/vtkWrite/vtkWriteImpl.C index 450cd6fcef77d1b8b387ae5e9f8425694052d84e..66400af4bec8243a937918d492a21fa4812466ec 100644 --- a/src/functionObjects/utilities/vtkWrite/vtkWriteImpl.C +++ b/src/functionObjects/utilities/vtkWrite/vtkWriteImpl.C @@ -58,12 +58,10 @@ Foam::label Foam::functionObjects::vtkWrite::writeVolFieldsImpl } // Boundary - label writeri = 0; for (vtk::patchWriter& writer : patchWriters) { ok = true; writer.write(field); - ++writeri; } if (ok) diff --git a/src/fvAgglomerationMethods/MGridGenGamgAgglomeration/Make/options b/src/fvAgglomerationMethods/MGridGenGamgAgglomeration/Make/options index 7fd6b0ae76695ae3b2c5f2897ef5be4f24f2ad4b..a64d63749e25c7f7dc75c3f49473ff553b9cc2f3 100644 --- a/src/fvAgglomerationMethods/MGridGenGamgAgglomeration/Make/options +++ b/src/fvAgglomerationMethods/MGridGenGamgAgglomeration/Make/options @@ -1,6 +1,13 @@ EXE_INC = \ + -I$(LIB_SRC)/fileFormats/lnInclude \ + -I$(LIB_SRC)/surfMesh/lnInclude \ + -I$(LIB_SRC)/meshTools/lnInclude \ -I$(LIB_SRC)/finiteVolume/lnInclude \ -I$(MGRIDGEN_INC_DIR) LIB_LIBS = \ + -lfileFormats \ + -lsurfMesh \ + -lmeshTools \ + -lfiniteVolume \ -L$(MGRIDGEN_LIB_DIR) -lmgrid diff --git a/src/fvAgglomerationMethods/pairPatchAgglomeration/Make/options b/src/fvAgglomerationMethods/pairPatchAgglomeration/Make/options index 7063a63df5fa0e929a3390ece56ad706e6f3e6c9..440b98532ec739a46fd9e83ae325798e077a7507 100644 --- a/src/fvAgglomerationMethods/pairPatchAgglomeration/Make/options +++ b/src/fvAgglomerationMethods/pairPatchAgglomeration/Make/options @@ -1,9 +1,11 @@ EXE_INC = \ -I$(LIB_SRC)/fileFormats/lnInclude \ - -I$(LIB_SRC)/finiteVolume/lnInclude \ - -I$(LIB_SRC)/meshTools/lnInclude + -I$(LIB_SRC)/surfMesh/lnInclude \ + -I$(LIB_SRC)/meshTools/lnInclude \ + -I$(LIB_SRC)/finiteVolume/lnInclude LIB_LIBS = \ - -lOpenFOAM \ - -lfiniteVolume \ - -lmeshTools + -lfileFormats \ + -lsurfMesh \ + -lmeshTools \ + -lfiniteVolume diff --git a/src/fvAgglomerationMethods/pairPatchAgglomeration/pairPatchAgglomeration.H b/src/fvAgglomerationMethods/pairPatchAgglomeration/pairPatchAgglomeration.H index ac564b2b9152b14bab75dc0b274b503bb27c0081..9733c48f8f34b2822f046451b8793695af981806 100644 --- a/src/fvAgglomerationMethods/pairPatchAgglomeration/pairPatchAgglomeration.H +++ b/src/fvAgglomerationMethods/pairPatchAgglomeration/pairPatchAgglomeration.H @@ -35,8 +35,8 @@ SourceFiles \*---------------------------------------------------------------------------*/ -#ifndef pairPatchAgglomeration_H -#define pairPatchAgglomeration_H +#ifndef Foam_pairPatchAgglomeration_H +#define Foam_pairPatchAgglomeration_H #include "mathematicalConstants.H" #include "indirectPrimitivePatch.H" diff --git a/src/mesh/snappyHexMesh/externalDisplacementMeshMover/displacementMotionSolverMeshMover.C b/src/mesh/snappyHexMesh/externalDisplacementMeshMover/displacementMotionSolverMeshMover.C index 070d73e2c7c4a1ceddf2cae6f50028e4abe43ef0..89d08776ed211f42562e59e3b92a2dd11680c7a1 100644 --- a/src/mesh/snappyHexMesh/externalDisplacementMeshMover/displacementMotionSolverMeshMover.C +++ b/src/mesh/snappyHexMesh/externalDisplacementMeshMover/displacementMotionSolverMeshMover.C @@ -275,13 +275,13 @@ bool Foam::displacementMotionSolverMeshMover::move ); - scalar resid = 0; + // scalar resid = 0; forAll(displacement, patchPointI) { const label pointI(adaptPatchPtr_().meshPoints()[patchPointI]); - resid += mag(pointDisplacement()[pointI]-displacement[patchPointI]); + // resid += mag(pointDisplacement()[pointI]-displacement[patchPointI]); pointDisplacement()[pointI] = displacement[patchPointI]; } diff --git a/src/mesh/snappyHexMesh/meshRefinement/meshRefinementBaffles.C b/src/mesh/snappyHexMesh/meshRefinement/meshRefinementBaffles.C index c36580ced64cdff5832f67234cbf18c3003b3072..781dd60d091eb0a0d34f1e1b29f13c2026f4e16a 100644 --- a/src/mesh/snappyHexMesh/meshRefinement/meshRefinementBaffles.C +++ b/src/mesh/snappyHexMesh/meshRefinement/meshRefinementBaffles.C @@ -3941,14 +3941,14 @@ Foam::label Foam::meshRefinement::markPatchZones // Protect all non-manifold edges { - label nProtected = 0; + // label nProtected = 0; forAll(nMasterFacesPerEdge, edgeI) { if (nMasterFacesPerEdge[edgeI] > 2) { allEdgeInfo[edgeI] = edgeTopoDistanceData<label>(0, -2); - nProtected++; + // ++nProtected; } } //Info<< "Protected from visiting " @@ -4097,7 +4097,7 @@ void Foam::meshRefinement::consistentOrientation // - slaves of coupled faces // - non-manifold edges { - label nProtected = 0; + // label nProtected = 0; forAll(patch.addressing(), faceI) { @@ -4113,7 +4113,7 @@ void Foam::meshRefinement::consistentOrientation { // Slave side. Mark so doesn't get visited. allFaceInfo[faceI] = orientedSurface::NOFLIP; - nProtected++; + // ++nProtected; } } //Info<< "Protected from visiting " @@ -4128,7 +4128,7 @@ void Foam::meshRefinement::consistentOrientation if (nMasterFacesPerEdge[edgeI] > 2) { allEdgeInfo[edgeI] = orientedSurface::NOFLIP; - nProtected++; + ++nProtected; } } diff --git a/src/mesh/snappyHexMesh/meshRefinement/meshRefinementProblemCells.C b/src/mesh/snappyHexMesh/meshRefinement/meshRefinementProblemCells.C index 48f333495a0ba6e219cecc5da12f2578521a0bd9..0c1c50ba6954d1981817495313d3e955aa3cd554 100644 --- a/src/mesh/snappyHexMesh/meshRefinement/meshRefinementProblemCells.C +++ b/src/mesh/snappyHexMesh/meshRefinement/meshRefinementProblemCells.C @@ -655,7 +655,7 @@ void Foam::meshRefinement::markFacesOnProblemCells // Get number of anchor points (pointLevel <= cellLevel) label nBoundaryAnchors = 0; - label nNonAnchorBoundary = 0; + // label nNonAnchorBoundary = 0; label nonBoundaryAnchor = -1; for (const label pointi : cPoints) @@ -673,10 +673,10 @@ void Foam::meshRefinement::markFacesOnProblemCells nonBoundaryAnchor = pointi; } } - else if (isBoundaryPoint[pointi]) - { - nNonAnchorBoundary++; - } + // else if (isBoundaryPoint[pointi]) + // { + // ++nNonAnchorBoundary; + // } } if (nBoundaryAnchors == 8) @@ -684,15 +684,15 @@ void Foam::meshRefinement::markFacesOnProblemCells const cell& cFaces = mesh_.cells()[celli]; // Count boundary faces. - label nBfaces = 0; - - forAll(cFaces, cFacei) - { - if (isBoundaryFace[cFaces[cFacei]]) - { - nBfaces++; - } - } + // label nBfaces = 0; + // + // forAll(cFaces, cFacei) + // { + // if (isBoundaryFace[cFaces[cFacei]]) + // { + // ++nBfaces; + // } + // } // If nBfaces > 1 make all non-boundary non-baffle faces baffles. // We assume that this situation is where there is a single diff --git a/src/mesh/snappyHexMesh/refinementSurfaces/refinementSurfaces.C b/src/mesh/snappyHexMesh/refinementSurfaces/refinementSurfaces.C index 29c101a33cc9688931d147bad71625c4419bae9e..8c31035de5399d7a7e4ed5809e302a041e47ae25 100644 --- a/src/mesh/snappyHexMesh/refinementSurfaces/refinementSurfaces.C +++ b/src/mesh/snappyHexMesh/refinementSurfaces/refinementSurfaces.C @@ -64,13 +64,13 @@ Foam::labelList Foam::refinementSurfaces::findHigherLevel // 3. uncached : use region 0 value DynamicList<label> retestSet; - label nHits = 0; + // label nHits = 0; forAll(intersectionInfo, i) { if (intersectionInfo[i].hit()) { - nHits++; + // ++nHits; // Check if minLevelField for this surface. if (minLevelField.size()) diff --git a/src/meshTools/edgeMesh/extendedEdgeMesh/extendedEdgeMesh.C b/src/meshTools/edgeMesh/extendedEdgeMesh/extendedEdgeMesh.C index f65587e9f7ea3b32ba51b7531cc66a71d06433f4..4b71f44950e8b1242118cc95419e2bdc1a0c8aa7 100644 --- a/src/meshTools/edgeMesh/extendedEdgeMesh/extendedEdgeMesh.C +++ b/src/meshTools/edgeMesh/extendedEdgeMesh/extendedEdgeMesh.C @@ -2109,7 +2109,7 @@ void Foam::extendedEdgeMesh::sortedOrder label nConvex = 0; label nConcave = 0; label nMixed = 0; - label nNonFeat = 0; + // label nNonFeat = 0; forAll(pointStat, pointI) { @@ -2128,7 +2128,7 @@ void Foam::extendedEdgeMesh::sortedOrder break; case extendedEdgeMesh::NONFEATURE: - nNonFeat++; + // ++nNonFeat; break; default: @@ -2179,7 +2179,7 @@ void Foam::extendedEdgeMesh::sortedOrder label nInternal = 0; label nFlat = 0; label nOpen = 0; - label nMultiple = 0; + // label nMultiple = 0; forAll(edgeStat, edgeI) { @@ -2202,7 +2202,7 @@ void Foam::extendedEdgeMesh::sortedOrder break; case extendedEdgeMesh::MULTIPLE: - nMultiple++; + // ++nMultiple; break; case extendedEdgeMesh::NONE: diff --git a/src/meshTools/regionSplit/localPointRegion.C b/src/meshTools/regionSplit/localPointRegion.C index 36e8eaadce3cca0c6a10adf2de6941f28d882905..02d2e8aea3c3125aa0b9be55658bd143b4b5a1af 100644 --- a/src/meshTools/regionSplit/localPointRegion.C +++ b/src/meshTools/regionSplit/localPointRegion.C @@ -554,7 +554,7 @@ Foam::labelList Foam::localPointRegion::findDuplicateFaces ); labelList duplicateFace(allPatch.size(), -1); - label nDuplicateFaces = 0; + // label nDuplicateFaces = 0; // Find all duplicate faces. forAll(allPatch, bFacei) @@ -611,7 +611,7 @@ Foam::labelList Foam::localPointRegion::findDuplicateFaces duplicateFace[bFacei] = otherFacei; duplicateFace[otherFacei] = bFacei; - nDuplicateFaces++; + // ++nDuplicateFaces; } } } diff --git a/src/meshTools/topoSet/cellSources/regionToCell/regionToCell.C b/src/meshTools/topoSet/cellSources/regionToCell/regionToCell.C index 45d6c987096195f96d5566a09553d52a3ead7d63..0089668c738eaa70c28a1acd8b0fe35a8003635c 100644 --- a/src/meshTools/topoSet/cellSources/regionToCell/regionToCell.C +++ b/src/meshTools/topoSet/cellSources/regionToCell/regionToCell.C @@ -232,14 +232,13 @@ void Foam::regionToCell::shrinkRegions if (selectedCell[celli]) { selectedCell[celli] = false; - nChanged++; + ++nChanged; } } } } Info<< " Eroded " - << returnReduce(nChanged, sumOp<label>()) - << " cells." << endl; + << returnReduce(nChanged, sumOp<label>()) << " cells." << endl; } @@ -308,7 +307,7 @@ void Foam::regionToCell::erode // Select all cells using these points - label nChanged = 0; + // label nChanged = 0; forAll(boundaryPoint, pointi) { if (boundaryPoint[pointi]) @@ -320,7 +319,7 @@ void Foam::regionToCell::erode if (!removeCell[celli]) { removeCell[celli] = true; - nChanged++; + // ++nChanged; } } } diff --git a/src/overset/cellCellStencil/inverseDistance/inverseDistanceCellCellStencil.C b/src/overset/cellCellStencil/inverseDistance/inverseDistanceCellCellStencil.C index a6eeba364a8dec714eb09b8ef214ebb06ea1d799..530b5ac21530e5bdd928a852680de26548210c06 100644 --- a/src/overset/cellCellStencil/inverseDistance/inverseDistanceCellCellStencil.C +++ b/src/overset/cellCellStencil/inverseDistance/inverseDistanceCellCellStencil.C @@ -1166,14 +1166,14 @@ void Foam::cellCellStencils::inverseDistance::findHoles // See which regions have not been visited (regionType == 1) - label count = 0; + // label count = 0; forAll(cellRegion, cellI) { label type = regionType[cellRegion[cellI]]; if (type == 1 && cellTypes[cellI] != HOLE) { cellTypes[cellI] = HOLE; - count++; + // ++count; } } } diff --git a/src/overset/oversetAdjustPhi/oversetAdjustPhi.C b/src/overset/oversetAdjustPhi/oversetAdjustPhi.C index d25999f62098578e51a5149b1b8da5ef54535b22..4b858ab40c6ea91b74550edb48692b80ccda3bbe 100644 --- a/src/overset/oversetAdjustPhi/oversetAdjustPhi.C +++ b/src/overset/oversetAdjustPhi/oversetAdjustPhi.C @@ -244,6 +244,7 @@ bool Foam::oversetAdjustPhi // Check correction + #ifdef FULLDEBUG if (fv::debug) { scalar massOutCheck = 0; @@ -287,7 +288,10 @@ bool Foam::oversetAdjustPhi } } } + + Info<< "mass in:" << massInCheck << " out:" << massOutCheck << nl; } + #endif /* FULLDEBUG */ return true; } diff --git a/src/overset/oversetFvMesh/oversetFvMeshBase.C b/src/overset/oversetFvMesh/oversetFvMeshBase.C index 8182a1f9277bc931a14038924d3f3b8f4eab4ead..bdf08b1fbb23b68e567fe76fdc196aadb94ee468 100644 --- a/src/overset/oversetFvMesh/oversetFvMeshBase.C +++ b/src/overset/oversetFvMesh/oversetFvMeshBase.C @@ -372,8 +372,7 @@ Foam::scalar Foam::oversetFvMeshBase::cellAverage const cell& cFaces = mesh_.cells()[celli]; scalar avg = 0.0; - label n = 0; - label nFront = 0; + label nTotal = 0; for (const label facei : cFaces) { if (mesh_.isInternalFace(facei)) @@ -382,38 +381,32 @@ Foam::scalar Foam::oversetFvMeshBase::cellAverage if (norm[nbrCelli] == -GREAT) { // Invalid neighbour. Add to front - if (isFront.set(facei)) - { - nFront++; - } + isFront.set(facei); } else { // Valid neighbour. Add to average avg += norm[nbrCelli]; - n++; + ++nTotal; } } else { if (nbrNorm[facei-mesh_.nInternalFaces()] == -GREAT) { - if (isFront.set(facei)) - { - nFront++; - } + isFront.set(facei); } else { avg += nbrNorm[facei-mesh_.nInternalFaces()]; - n++; + ++nTotal; } } } - if (n > 0) + if (nTotal) { - return avg/n; + return avg/nTotal; } else { diff --git a/src/overset/oversetFvMesh/oversetFvMeshBaseTemplates.C b/src/overset/oversetFvMesh/oversetFvMeshBaseTemplates.C index 4805fec67e163a0d341acc2af08cf4ba95374e22..faa741cafea17a5a42f8f71df404057b744569db 100644 --- a/src/overset/oversetFvMesh/oversetFvMeshBaseTemplates.C +++ b/src/overset/oversetFvMesh/oversetFvMeshBaseTemplates.C @@ -165,14 +165,14 @@ Foam::tmp<Foam::scalarField> Foam::oversetFvMeshBase::normalisation const cellCellStencilObject& overlap = Stencil::New(mesh_); const labelUList& types = overlap.cellTypes(); - label nHoles = 0; + // label nHoles = 0; scalarField extrapolatedNorm(norm); forAll(types, celli) { if (types[celli] == cellCellStencil::HOLE) { extrapolatedNorm[celli] = -GREAT; - nHoles++; + // ++nHoles; } } diff --git a/src/overset/regionsToCell/regionsToCell.C b/src/overset/regionsToCell/regionsToCell.C index b3e71e810f606afc9f721825fa821610dbb668df..996743d394a0c72d8f0a2b49e86f9dcbca32ec22 100644 --- a/src/overset/regionsToCell/regionsToCell.C +++ b/src/overset/regionsToCell/regionsToCell.C @@ -261,13 +261,13 @@ void Foam::regionsToCell::shrinkRegions if (selectedCell[cellI]) { selectedCell[cellI] = false; - nChanged++; + ++nChanged; } } } } - Info<< " Eroded " << returnReduce(nChanged, sumOp<label>()) - << " cells." << endl; + Info<< " Eroded " + << returnReduce(nChanged, sumOp<label>()) << " cells." << endl; } @@ -338,7 +338,7 @@ void Foam::regionsToCell::erode // Select all cells using these points - label nChanged = 0; + // label nChanged = 0; forAll(boundaryPoint, pointI) { if (boundaryPoint[pointI]) @@ -350,7 +350,7 @@ void Foam::regionsToCell::erode if (!removeCell[cellI]) { removeCell[cellI] = true; - nChanged++; + // ++nChanged; } } } diff --git a/src/parallel/distributed/distributedTriSurfaceMesh/distributedTriSurfaceMesh.C b/src/parallel/distributed/distributedTriSurfaceMesh/distributedTriSurfaceMesh.C index c338498f015da5abf6bbb28ec4983652d1fa0060..1c77ad3f961e10ba30bf1a588274710a654b4b70 100644 --- a/src/parallel/distributed/distributedTriSurfaceMesh/distributedTriSurfaceMesh.C +++ b/src/parallel/distributed/distributedTriSurfaceMesh/distributedTriSurfaceMesh.C @@ -3297,7 +3297,7 @@ void Foam::distributedTriSurfaceMesh::findNearest // Work array - whether processor bb overlaps the bounding sphere. boolList procBbOverlaps(Pstream::nProcs()); - label nFound = 0; + // label nFound = 0; forAll(nearestInfo, samplei) { @@ -3305,10 +3305,10 @@ void Foam::distributedTriSurfaceMesh::findNearest const nearestAndDist& ni = nearestInfo[samplei]; const pointIndexHit& info = ni.first(); - if (info.hit()) - { - nFound++; - } + // if (info.hit()) + // { + // nFound++; + // } scalar d2 = ( diff --git a/src/parallel/distributed/patchDistMethods/exact/exactPatchDistMethod.C b/src/parallel/distributed/patchDistMethods/exact/exactPatchDistMethod.C index 991a43b162fedcf51b3b6e8f692aae0c2e4bf16d..73fe2e15fe4d2750c286255c0922fe4d31ff62eb 100644 --- a/src/parallel/distributed/patchDistMethods/exact/exactPatchDistMethod.C +++ b/src/parallel/distributed/patchDistMethods/exact/exactPatchDistMethod.C @@ -170,14 +170,14 @@ bool Foam::patchDistMethods::exact::correct ); // Take over hits - label nHits = 0; + // label nHits = 0; forAll(info, celli) { if (info[celli].hit()) { const point& cc = mesh_.cellCentres()[celli]; y[celli] = info[celli].point().dist(cc); - nHits++; + // ++nHits; } //else //{