mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
COMP: fix library linkage (#2784), silence some unused variable warnings
This commit is contained in:
@ -42,7 +42,7 @@ for (label i=0; i<nPoints; i++)
|
|||||||
labelList i1tab(nPoints), i3tab(nPoints), i8tab(nPoints), idreg(nPoints),
|
labelList i1tab(nPoints), i3tab(nPoints), i8tab(nPoints), idreg(nPoints),
|
||||||
f(nPoints), bcl(nPoints), bcf(nPoints), bcb(nPoints);
|
f(nPoints), bcl(nPoints), bcf(nPoints), bcb(nPoints);
|
||||||
|
|
||||||
label nBfaces = 0;
|
// label nBfaces = 0;
|
||||||
|
|
||||||
for (label i=0; i<nPoints; i++)
|
for (label i=0; i<nPoints; i++)
|
||||||
{
|
{
|
||||||
@ -65,9 +65,9 @@ for (label i=0; i<nPoints; i++)
|
|||||||
bcf[i] = label(fbcf);
|
bcf[i] = label(fbcf);
|
||||||
bcb[i] = label(fbcb);
|
bcb[i] = label(fbcb);
|
||||||
|
|
||||||
if (bcl[i] > 0 && bcl[i] != 4) nBfaces++;
|
// if (bcl[i] > 0 && bcl[i] != 4) ++nBfaces;
|
||||||
if (bcf[i] > 0 && bcf[i] != 4) nBfaces++;
|
// if (bcf[i] > 0 && bcf[i] != 4) ++nBfaces;
|
||||||
if (bcb[i] > 0 && bcb[i] != 4) nBfaces++;
|
// if (bcb[i] > 0 && bcb[i] != 4) ++nBfaces;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -170,23 +170,23 @@ template<class Triangulation>
|
|||||||
void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
||||||
{
|
{
|
||||||
label nInternal = 0;
|
label nInternal = 0;
|
||||||
label nInternalRef = 0;
|
//label nInternalRef = 0;
|
||||||
label nUnassigned = 0;
|
label nUnassigned = 0;
|
||||||
label nUnassignedRef = 0;
|
//label nUnassignedRef = 0;
|
||||||
label nInternalNearBoundary = 0;
|
label nInternalNearBoundary = 0;
|
||||||
label nInternalNearBoundaryRef = 0;
|
//label nInternalNearBoundaryRef = 0;
|
||||||
label nInternalSurface = 0;
|
label nInternalSurface = 0;
|
||||||
label nInternalSurfaceRef = 0;
|
//label nInternalSurfaceRef = 0;
|
||||||
label nInternalFeatureEdge = 0;
|
label nInternalFeatureEdge = 0;
|
||||||
label nInternalFeatureEdgeRef = 0;
|
//label nInternalFeatureEdgeRef = 0;
|
||||||
label nInternalFeaturePoint = 0;
|
label nInternalFeaturePoint = 0;
|
||||||
label nInternalFeaturePointRef = 0;
|
//label nInternalFeaturePointRef = 0;
|
||||||
label nExternalSurface = 0;
|
label nExternalSurface = 0;
|
||||||
label nExternalSurfaceRef = 0;
|
//label nExternalSurfaceRef = 0;
|
||||||
label nExternalFeatureEdge = 0;
|
label nExternalFeatureEdge = 0;
|
||||||
label nExternalFeatureEdgeRef = 0;
|
//label nExternalFeatureEdgeRef = 0;
|
||||||
label nExternalFeaturePoint = 0;
|
label nExternalFeaturePoint = 0;
|
||||||
label nExternalFeaturePointRef = 0;
|
//label nExternalFeaturePointRef = 0;
|
||||||
label nFar = 0;
|
label nFar = 0;
|
||||||
label nReferred = 0;
|
label nReferred = 0;
|
||||||
|
|
||||||
@ -202,7 +202,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
|||||||
if (vit->referred())
|
if (vit->referred())
|
||||||
{
|
{
|
||||||
nReferred++;
|
nReferred++;
|
||||||
nInternalRef++;
|
//++nInternalRef;
|
||||||
}
|
}
|
||||||
|
|
||||||
nInternal++;
|
nInternal++;
|
||||||
@ -212,7 +212,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
|||||||
if (vit->referred())
|
if (vit->referred())
|
||||||
{
|
{
|
||||||
nReferred++;
|
nReferred++;
|
||||||
nUnassignedRef++;
|
//++nUnassignedRef;
|
||||||
}
|
}
|
||||||
|
|
||||||
nUnassigned++;
|
nUnassigned++;
|
||||||
@ -222,7 +222,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
|||||||
if (vit->referred())
|
if (vit->referred())
|
||||||
{
|
{
|
||||||
nReferred++;
|
nReferred++;
|
||||||
nInternalNearBoundaryRef++;
|
//++nInternalNearBoundaryRef;
|
||||||
}
|
}
|
||||||
|
|
||||||
nInternalNearBoundary++;
|
nInternalNearBoundary++;
|
||||||
@ -232,7 +232,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
|||||||
if (vit->referred())
|
if (vit->referred())
|
||||||
{
|
{
|
||||||
nReferred++;
|
nReferred++;
|
||||||
nInternalSurfaceRef++;
|
//++nInternalSurfaceRef;
|
||||||
}
|
}
|
||||||
|
|
||||||
nInternalSurface++;
|
nInternalSurface++;
|
||||||
@ -242,7 +242,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
|||||||
if (vit->referred())
|
if (vit->referred())
|
||||||
{
|
{
|
||||||
nReferred++;
|
nReferred++;
|
||||||
nInternalFeatureEdgeRef++;
|
//++nInternalFeatureEdgeRef;
|
||||||
}
|
}
|
||||||
|
|
||||||
nInternalFeatureEdge++;
|
nInternalFeatureEdge++;
|
||||||
@ -252,7 +252,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
|||||||
if (vit->referred())
|
if (vit->referred())
|
||||||
{
|
{
|
||||||
nReferred++;
|
nReferred++;
|
||||||
nInternalFeaturePointRef++;
|
//++nInternalFeaturePointRef;
|
||||||
}
|
}
|
||||||
|
|
||||||
nInternalFeaturePoint++;
|
nInternalFeaturePoint++;
|
||||||
@ -262,7 +262,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
|||||||
if (vit->referred())
|
if (vit->referred())
|
||||||
{
|
{
|
||||||
nReferred++;
|
nReferred++;
|
||||||
nExternalSurfaceRef++;
|
//++nExternalSurfaceRef;
|
||||||
}
|
}
|
||||||
|
|
||||||
nExternalSurface++;
|
nExternalSurface++;
|
||||||
@ -272,7 +272,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
|||||||
if (vit->referred())
|
if (vit->referred())
|
||||||
{
|
{
|
||||||
nReferred++;
|
nReferred++;
|
||||||
nExternalFeatureEdgeRef++;
|
//++nExternalFeatureEdgeRef;
|
||||||
}
|
}
|
||||||
|
|
||||||
nExternalFeatureEdge++;
|
nExternalFeatureEdge++;
|
||||||
@ -282,7 +282,7 @@ void Foam::DelaunayMesh<Triangulation>::printVertexInfo(Ostream& os) const
|
|||||||
if (vit->referred())
|
if (vit->referred())
|
||||||
{
|
{
|
||||||
nReferred++;
|
nReferred++;
|
||||||
nExternalFeaturePointRef++;
|
//++nExternalFeaturePointRef;
|
||||||
}
|
}
|
||||||
|
|
||||||
nExternalFeaturePoint++;
|
nExternalFeaturePoint++;
|
||||||
|
|||||||
@ -853,7 +853,7 @@ Foam::DistributedDelaunayMesh<Triangulation>::rangeInsertReferredWithInfo
|
|||||||
typename Triangulation::Locate_type lt;
|
typename Triangulation::Locate_type lt;
|
||||||
int li, lj;
|
int li, lj;
|
||||||
|
|
||||||
label nNotInserted = 0;
|
//label nNotInserted = 0;
|
||||||
|
|
||||||
labelPairHashSet uninserted
|
labelPairHashSet uninserted
|
||||||
(
|
(
|
||||||
@ -979,7 +979,7 @@ Foam::DistributedDelaunayMesh<Triangulation>::rangeInsertReferredWithInfo
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
uninserted.insert(labelPair(vert.procIndex(), vert.index()));
|
uninserted.insert(labelPair(vert.procIndex(), vert.index()));
|
||||||
nNotInserted++;
|
//++nNotInserted;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -104,7 +104,7 @@ Foam::scalar Foam::cellShapeControl::cellSize(const point& pt) const
|
|||||||
}
|
}
|
||||||
else if (shapeControlMesh_.is_infinite(ch))
|
else if (shapeControlMesh_.is_infinite(ch))
|
||||||
{
|
{
|
||||||
// if (nFarPoints != 0)
|
// if (nFarPoints)
|
||||||
// {
|
// {
|
||||||
// for (label pI = 0; pI < 4; ++pI)
|
// 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())
|
if (ch->vertex(pI)->farPoint())
|
||||||
{
|
{
|
||||||
nFarPoints++;
|
++nFarPoints;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (nFarPoints != 0)
|
if (nFarPoints)
|
||||||
{
|
{
|
||||||
for (label pI = 0; pI < 4; ++pI)
|
for (label pI = 0; pI < 4; ++pI)
|
||||||
{
|
{
|
||||||
@ -179,16 +179,16 @@ Foam::tensor Foam::cellShapeControl::cellAlignment(const point& pt) const
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
label nFarPoints = 0;
|
// label nFarPoints = 0;
|
||||||
for (label pI = 0; pI < 4; ++pI)
|
// for (label pI = 0; pI < 4; ++pI)
|
||||||
{
|
// {
|
||||||
if (ch->vertex(pI)->farPoint())
|
// if (ch->vertex(pI)->farPoint())
|
||||||
{
|
// {
|
||||||
nFarPoints++;
|
// ++nFarPoints;
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
|
||||||
// if (nFarPoints != 0)
|
// if (nFarPoints)
|
||||||
// {
|
// {
|
||||||
// for (label pI = 0; pI < 4; ++pI)
|
// for (label pI = 0; pI < 4; ++pI)
|
||||||
// {
|
// {
|
||||||
@ -259,11 +259,11 @@ void Foam::cellShapeControl::cellSizeAndAlignment
|
|||||||
{
|
{
|
||||||
if (ch->vertex(pI)->farPoint())
|
if (ch->vertex(pI)->farPoint())
|
||||||
{
|
{
|
||||||
nFarPoints++;
|
++nFarPoints;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (nFarPoints != 0)
|
if (nFarPoints)
|
||||||
{
|
{
|
||||||
for (label pI = 0; pI < 4; ++pI)
|
for (label pI = 0; pI < 4; ++pI)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -82,11 +82,11 @@ bool Foam::controlMeshRefinement::detectEdge
|
|||||||
|
|
||||||
Foam::point midPoint = (a + b)/2.0;
|
Foam::point midPoint = (a + b)/2.0;
|
||||||
|
|
||||||
label nIterations = 0;
|
//label nIterations = 0;
|
||||||
|
|
||||||
while (true)
|
while (true)
|
||||||
{
|
{
|
||||||
nIterations++;
|
//++nIterations;
|
||||||
|
|
||||||
if
|
if
|
||||||
(
|
(
|
||||||
|
|||||||
@ -74,7 +74,7 @@ bool Foam::featurePointConformer::createSpecialisedFeaturePoint
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
label nVert = foamyHexMesh_.number_of_vertices();
|
//label nVert = foamyHexMesh_.number_of_vertices();
|
||||||
|
|
||||||
const label initialNumOfPoints = pts.size();
|
const label initialNumOfPoints = pts.size();
|
||||||
|
|
||||||
@ -267,7 +267,7 @@ bool Foam::featurePointConformer::createSpecialisedFeaturePoint
|
|||||||
|
|
||||||
// Remove points that have just been added before returning
|
// Remove points that have just been added before returning
|
||||||
pts.pop_back(2);
|
pts.pop_back(2);
|
||||||
nVert -= 2;
|
//nVert -= 2;
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -503,7 +503,7 @@ bool Foam::featurePointConformer::createSpecialisedFeaturePoint
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
label nVert = foamyHexMesh_.number_of_vertices();
|
//label nVert = foamyHexMesh_.number_of_vertices();
|
||||||
|
|
||||||
const label initialNumOfPoints = pts.size();
|
const label initialNumOfPoints = pts.size();
|
||||||
|
|
||||||
@ -700,7 +700,7 @@ bool Foam::featurePointConformer::createSpecialisedFeaturePoint
|
|||||||
|
|
||||||
// Remove points that have just been added before returning
|
// Remove points that have just been added before returning
|
||||||
pts.pop_back(2);
|
pts.pop_back(2);
|
||||||
nVert -= 2;
|
//nVert -= 2;
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -81,7 +81,7 @@ if (doFiniteArea)
|
|||||||
|
|
||||||
labelList patchIds
|
labelList patchIds
|
||||||
(
|
(
|
||||||
areaMesh.mesh().boundaryMesh().patchID(areaMesh.faceLabels())
|
pbm.patchID(areaMesh.faceLabels())
|
||||||
);
|
);
|
||||||
|
|
||||||
writer.writeCellData("patchID", patchIds);
|
writer.writeCellData("patchID", patchIds);
|
||||||
|
|||||||
@ -1408,7 +1408,7 @@ autoPtr<extendedFeatureEdgeMesh> createEdgeMesh
|
|||||||
label nIntOrExt = 0;
|
label nIntOrExt = 0;
|
||||||
label nFlat = 0;
|
label nFlat = 0;
|
||||||
label nOpen = 0;
|
label nOpen = 0;
|
||||||
label nMultiple = 0;
|
// label nMultiple = 0;
|
||||||
|
|
||||||
forAll(edgeNormals, eI)
|
forAll(edgeNormals, eI)
|
||||||
{
|
{
|
||||||
@ -1432,10 +1432,10 @@ autoPtr<extendedFeatureEdgeMesh> createEdgeMesh
|
|||||||
nIntOrExt++;
|
nIntOrExt++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (nEdNorms > 2)
|
// else if (nEdNorms > 2)
|
||||||
{
|
// {
|
||||||
nMultiple++;
|
// ++nMultiple;
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
if (action == booleanSurface::UNION)
|
if (action == booleanSurface::UNION)
|
||||||
|
|||||||
@ -775,7 +775,7 @@ label collapseBase
|
|||||||
{
|
{
|
||||||
label nTotalSplit = 0;
|
label nTotalSplit = 0;
|
||||||
|
|
||||||
label iter = 0;
|
// label iter = 0;
|
||||||
|
|
||||||
while (true)
|
while (true)
|
||||||
{
|
{
|
||||||
@ -980,7 +980,7 @@ label collapseBase
|
|||||||
// surf.write(fName);
|
// surf.write(fName);
|
||||||
//}
|
//}
|
||||||
|
|
||||||
iter++;
|
// ++iter;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Remove any unused vertices
|
// Remove any unused vertices
|
||||||
|
|||||||
@ -697,7 +697,8 @@ void Foam::fileFormats::STARCDMeshReader::readBoundary
|
|||||||
// keep empty patch region in reserve
|
// keep empty patch region in reserve
|
||||||
++nPatches;
|
++nPatches;
|
||||||
Info<< "Number of patches = " << nPatches
|
Info<< "Number of patches = " << nPatches
|
||||||
<< " (including extra for missing)" << endl;
|
<< " (including extra for missing) with "
|
||||||
|
<< nFaces << " faces" << endl;
|
||||||
|
|
||||||
// resize
|
// resize
|
||||||
origRegion.setSize(nPatches);
|
origRegion.setSize(nPatches);
|
||||||
|
|||||||
@ -756,7 +756,7 @@ void Foam::vtk::vtuSizing::populateArrays
|
|||||||
|
|
||||||
const label nInputCells = shapes.size();
|
const label nInputCells = shapes.size();
|
||||||
|
|
||||||
label nIgnored = 0;
|
// label nIgnored = 0;
|
||||||
|
|
||||||
for
|
for
|
||||||
(
|
(
|
||||||
@ -852,7 +852,7 @@ void Foam::vtk::vtuSizing::populateArrays
|
|||||||
// Silent here.
|
// Silent here.
|
||||||
// - already complained (and skipped) during initial sizing
|
// - already complained (and skipped) during initial sizing
|
||||||
--cellIndex;
|
--cellIndex;
|
||||||
++nIgnored;
|
// ++nIgnored;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -75,14 +75,14 @@ void Foam::MRFZone::setMRFFaces()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
label nZoneFaces = 0;
|
// label nZoneFaces = 0;
|
||||||
|
|
||||||
for (label facei = 0; facei < mesh_.nInternalFaces(); facei++)
|
for (label facei = 0; facei < mesh_.nInternalFaces(); facei++)
|
||||||
{
|
{
|
||||||
if (zoneCell[own[facei]] || zoneCell[nei[facei]])
|
if (zoneCell[own[facei]] || zoneCell[nei[facei]])
|
||||||
{
|
{
|
||||||
faceType[facei] = 1;
|
faceType[facei] = 1;
|
||||||
nZoneFaces++;
|
// ++nZoneFaces;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -102,7 +102,7 @@ void Foam::MRFZone::setMRFFaces()
|
|||||||
if (zoneCell[own[facei]])
|
if (zoneCell[own[facei]])
|
||||||
{
|
{
|
||||||
faceType[facei] = 2;
|
faceType[facei] = 2;
|
||||||
nZoneFaces++;
|
// ++nZoneFaces;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -115,7 +115,7 @@ void Foam::MRFZone::setMRFFaces()
|
|||||||
if (zoneCell[own[facei]])
|
if (zoneCell[own[facei]])
|
||||||
{
|
{
|
||||||
faceType[facei] = 1;
|
faceType[facei] = 1;
|
||||||
nZoneFaces++;
|
// ++nZoneFaces;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -474,7 +474,7 @@ bool Foam::functionObjects::regionSizeDistribution::write()
|
|||||||
|
|
||||||
// Determine blocked faces
|
// Determine blocked faces
|
||||||
boolList blockedFace(mesh_.nFaces(), false);
|
boolList blockedFace(mesh_.nFaces(), false);
|
||||||
label nBlocked = 0;
|
// label nBlocked = 0;
|
||||||
|
|
||||||
{
|
{
|
||||||
for (label facei = 0; facei < mesh_.nInternalFaces(); facei++)
|
for (label facei = 0; facei < mesh_.nInternalFaces(); facei++)
|
||||||
@ -489,7 +489,7 @@ bool Foam::functionObjects::regionSizeDistribution::write()
|
|||||||
)
|
)
|
||||||
{
|
{
|
||||||
blockedFace[facei] = true;
|
blockedFace[facei] = true;
|
||||||
nBlocked++;
|
// ++nBlocked;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -518,7 +518,7 @@ bool Foam::functionObjects::regionSizeDistribution::write()
|
|||||||
)
|
)
|
||||||
{
|
{
|
||||||
blockedFace[start+i] = true;
|
blockedFace[start+i] = true;
|
||||||
nBlocked++;
|
// ++nBlocked;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -58,12 +58,10 @@ Foam::label Foam::functionObjects::vtkWrite::writeVolFieldsImpl
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Boundary
|
// Boundary
|
||||||
label writeri = 0;
|
|
||||||
for (vtk::patchWriter& writer : patchWriters)
|
for (vtk::patchWriter& writer : patchWriters)
|
||||||
{
|
{
|
||||||
ok = true;
|
ok = true;
|
||||||
writer.write(field);
|
writer.write(field);
|
||||||
++writeri;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ok)
|
if (ok)
|
||||||
|
|||||||
@ -1,6 +1,13 @@
|
|||||||
EXE_INC = \
|
EXE_INC = \
|
||||||
|
-I$(LIB_SRC)/fileFormats/lnInclude \
|
||||||
|
-I$(LIB_SRC)/surfMesh/lnInclude \
|
||||||
|
-I$(LIB_SRC)/meshTools/lnInclude \
|
||||||
-I$(LIB_SRC)/finiteVolume/lnInclude \
|
-I$(LIB_SRC)/finiteVolume/lnInclude \
|
||||||
-I$(MGRIDGEN_INC_DIR)
|
-I$(MGRIDGEN_INC_DIR)
|
||||||
|
|
||||||
LIB_LIBS = \
|
LIB_LIBS = \
|
||||||
|
-lfileFormats \
|
||||||
|
-lsurfMesh \
|
||||||
|
-lmeshTools \
|
||||||
|
-lfiniteVolume \
|
||||||
-L$(MGRIDGEN_LIB_DIR) -lmgrid
|
-L$(MGRIDGEN_LIB_DIR) -lmgrid
|
||||||
|
|||||||
@ -1,9 +1,11 @@
|
|||||||
EXE_INC = \
|
EXE_INC = \
|
||||||
-I$(LIB_SRC)/fileFormats/lnInclude \
|
-I$(LIB_SRC)/fileFormats/lnInclude \
|
||||||
-I$(LIB_SRC)/finiteVolume/lnInclude \
|
-I$(LIB_SRC)/surfMesh/lnInclude \
|
||||||
-I$(LIB_SRC)/meshTools/lnInclude
|
-I$(LIB_SRC)/meshTools/lnInclude \
|
||||||
|
-I$(LIB_SRC)/finiteVolume/lnInclude
|
||||||
|
|
||||||
LIB_LIBS = \
|
LIB_LIBS = \
|
||||||
-lOpenFOAM \
|
-lfileFormats \
|
||||||
-lfiniteVolume \
|
-lsurfMesh \
|
||||||
-lmeshTools
|
-lmeshTools \
|
||||||
|
-lfiniteVolume
|
||||||
|
|||||||
@ -35,8 +35,8 @@ SourceFiles
|
|||||||
|
|
||||||
\*---------------------------------------------------------------------------*/
|
\*---------------------------------------------------------------------------*/
|
||||||
|
|
||||||
#ifndef pairPatchAgglomeration_H
|
#ifndef Foam_pairPatchAgglomeration_H
|
||||||
#define pairPatchAgglomeration_H
|
#define Foam_pairPatchAgglomeration_H
|
||||||
|
|
||||||
#include "mathematicalConstants.H"
|
#include "mathematicalConstants.H"
|
||||||
#include "indirectPrimitivePatch.H"
|
#include "indirectPrimitivePatch.H"
|
||||||
|
|||||||
@ -275,13 +275,13 @@ bool Foam::displacementMotionSolverMeshMover::move
|
|||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
scalar resid = 0;
|
// scalar resid = 0;
|
||||||
|
|
||||||
forAll(displacement, patchPointI)
|
forAll(displacement, patchPointI)
|
||||||
{
|
{
|
||||||
const label pointI(adaptPatchPtr_().meshPoints()[patchPointI]);
|
const label pointI(adaptPatchPtr_().meshPoints()[patchPointI]);
|
||||||
|
|
||||||
resid += mag(pointDisplacement()[pointI]-displacement[patchPointI]);
|
// resid += mag(pointDisplacement()[pointI]-displacement[patchPointI]);
|
||||||
|
|
||||||
pointDisplacement()[pointI] = displacement[patchPointI];
|
pointDisplacement()[pointI] = displacement[patchPointI];
|
||||||
}
|
}
|
||||||
|
|||||||
@ -3941,14 +3941,14 @@ Foam::label Foam::meshRefinement::markPatchZones
|
|||||||
|
|
||||||
// Protect all non-manifold edges
|
// Protect all non-manifold edges
|
||||||
{
|
{
|
||||||
label nProtected = 0;
|
// label nProtected = 0;
|
||||||
|
|
||||||
forAll(nMasterFacesPerEdge, edgeI)
|
forAll(nMasterFacesPerEdge, edgeI)
|
||||||
{
|
{
|
||||||
if (nMasterFacesPerEdge[edgeI] > 2)
|
if (nMasterFacesPerEdge[edgeI] > 2)
|
||||||
{
|
{
|
||||||
allEdgeInfo[edgeI] = edgeTopoDistanceData<label>(0, -2);
|
allEdgeInfo[edgeI] = edgeTopoDistanceData<label>(0, -2);
|
||||||
nProtected++;
|
// ++nProtected;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//Info<< "Protected from visiting "
|
//Info<< "Protected from visiting "
|
||||||
@ -4097,7 +4097,7 @@ void Foam::meshRefinement::consistentOrientation
|
|||||||
// - slaves of coupled faces
|
// - slaves of coupled faces
|
||||||
// - non-manifold edges
|
// - non-manifold edges
|
||||||
{
|
{
|
||||||
label nProtected = 0;
|
// label nProtected = 0;
|
||||||
|
|
||||||
forAll(patch.addressing(), faceI)
|
forAll(patch.addressing(), faceI)
|
||||||
{
|
{
|
||||||
@ -4113,7 +4113,7 @@ void Foam::meshRefinement::consistentOrientation
|
|||||||
{
|
{
|
||||||
// Slave side. Mark so doesn't get visited.
|
// Slave side. Mark so doesn't get visited.
|
||||||
allFaceInfo[faceI] = orientedSurface::NOFLIP;
|
allFaceInfo[faceI] = orientedSurface::NOFLIP;
|
||||||
nProtected++;
|
// ++nProtected;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//Info<< "Protected from visiting "
|
//Info<< "Protected from visiting "
|
||||||
@ -4128,7 +4128,7 @@ void Foam::meshRefinement::consistentOrientation
|
|||||||
if (nMasterFacesPerEdge[edgeI] > 2)
|
if (nMasterFacesPerEdge[edgeI] > 2)
|
||||||
{
|
{
|
||||||
allEdgeInfo[edgeI] = orientedSurface::NOFLIP;
|
allEdgeInfo[edgeI] = orientedSurface::NOFLIP;
|
||||||
nProtected++;
|
++nProtected;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -655,7 +655,7 @@ void Foam::meshRefinement::markFacesOnProblemCells
|
|||||||
// Get number of anchor points (pointLevel <= cellLevel)
|
// Get number of anchor points (pointLevel <= cellLevel)
|
||||||
|
|
||||||
label nBoundaryAnchors = 0;
|
label nBoundaryAnchors = 0;
|
||||||
label nNonAnchorBoundary = 0;
|
// label nNonAnchorBoundary = 0;
|
||||||
label nonBoundaryAnchor = -1;
|
label nonBoundaryAnchor = -1;
|
||||||
|
|
||||||
for (const label pointi : cPoints)
|
for (const label pointi : cPoints)
|
||||||
@ -673,10 +673,10 @@ void Foam::meshRefinement::markFacesOnProblemCells
|
|||||||
nonBoundaryAnchor = pointi;
|
nonBoundaryAnchor = pointi;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (isBoundaryPoint[pointi])
|
// else if (isBoundaryPoint[pointi])
|
||||||
{
|
// {
|
||||||
nNonAnchorBoundary++;
|
// ++nNonAnchorBoundary;
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
if (nBoundaryAnchors == 8)
|
if (nBoundaryAnchors == 8)
|
||||||
@ -684,15 +684,15 @@ void Foam::meshRefinement::markFacesOnProblemCells
|
|||||||
const cell& cFaces = mesh_.cells()[celli];
|
const cell& cFaces = mesh_.cells()[celli];
|
||||||
|
|
||||||
// Count boundary faces.
|
// Count boundary faces.
|
||||||
label nBfaces = 0;
|
// label nBfaces = 0;
|
||||||
|
//
|
||||||
forAll(cFaces, cFacei)
|
// forAll(cFaces, cFacei)
|
||||||
{
|
// {
|
||||||
if (isBoundaryFace[cFaces[cFacei]])
|
// if (isBoundaryFace[cFaces[cFacei]])
|
||||||
{
|
// {
|
||||||
nBfaces++;
|
// ++nBfaces;
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
|
|
||||||
// If nBfaces > 1 make all non-boundary non-baffle faces baffles.
|
// If nBfaces > 1 make all non-boundary non-baffle faces baffles.
|
||||||
// We assume that this situation is where there is a single
|
// We assume that this situation is where there is a single
|
||||||
|
|||||||
@ -64,13 +64,13 @@ Foam::labelList Foam::refinementSurfaces::findHigherLevel
|
|||||||
// 3. uncached : use region 0 value
|
// 3. uncached : use region 0 value
|
||||||
|
|
||||||
DynamicList<label> retestSet;
|
DynamicList<label> retestSet;
|
||||||
label nHits = 0;
|
// label nHits = 0;
|
||||||
|
|
||||||
forAll(intersectionInfo, i)
|
forAll(intersectionInfo, i)
|
||||||
{
|
{
|
||||||
if (intersectionInfo[i].hit())
|
if (intersectionInfo[i].hit())
|
||||||
{
|
{
|
||||||
nHits++;
|
// ++nHits;
|
||||||
|
|
||||||
// Check if minLevelField for this surface.
|
// Check if minLevelField for this surface.
|
||||||
if (minLevelField.size())
|
if (minLevelField.size())
|
||||||
|
|||||||
@ -2109,7 +2109,7 @@ void Foam::extendedEdgeMesh::sortedOrder
|
|||||||
label nConvex = 0;
|
label nConvex = 0;
|
||||||
label nConcave = 0;
|
label nConcave = 0;
|
||||||
label nMixed = 0;
|
label nMixed = 0;
|
||||||
label nNonFeat = 0;
|
// label nNonFeat = 0;
|
||||||
|
|
||||||
forAll(pointStat, pointI)
|
forAll(pointStat, pointI)
|
||||||
{
|
{
|
||||||
@ -2128,7 +2128,7 @@ void Foam::extendedEdgeMesh::sortedOrder
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case extendedEdgeMesh::NONFEATURE:
|
case extendedEdgeMesh::NONFEATURE:
|
||||||
nNonFeat++;
|
// ++nNonFeat;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
@ -2179,7 +2179,7 @@ void Foam::extendedEdgeMesh::sortedOrder
|
|||||||
label nInternal = 0;
|
label nInternal = 0;
|
||||||
label nFlat = 0;
|
label nFlat = 0;
|
||||||
label nOpen = 0;
|
label nOpen = 0;
|
||||||
label nMultiple = 0;
|
// label nMultiple = 0;
|
||||||
|
|
||||||
forAll(edgeStat, edgeI)
|
forAll(edgeStat, edgeI)
|
||||||
{
|
{
|
||||||
@ -2202,7 +2202,7 @@ void Foam::extendedEdgeMesh::sortedOrder
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case extendedEdgeMesh::MULTIPLE:
|
case extendedEdgeMesh::MULTIPLE:
|
||||||
nMultiple++;
|
// ++nMultiple;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case extendedEdgeMesh::NONE:
|
case extendedEdgeMesh::NONE:
|
||||||
|
|||||||
@ -554,7 +554,7 @@ Foam::labelList Foam::localPointRegion::findDuplicateFaces
|
|||||||
);
|
);
|
||||||
|
|
||||||
labelList duplicateFace(allPatch.size(), -1);
|
labelList duplicateFace(allPatch.size(), -1);
|
||||||
label nDuplicateFaces = 0;
|
// label nDuplicateFaces = 0;
|
||||||
|
|
||||||
// Find all duplicate faces.
|
// Find all duplicate faces.
|
||||||
forAll(allPatch, bFacei)
|
forAll(allPatch, bFacei)
|
||||||
@ -611,7 +611,7 @@ Foam::labelList Foam::localPointRegion::findDuplicateFaces
|
|||||||
|
|
||||||
duplicateFace[bFacei] = otherFacei;
|
duplicateFace[bFacei] = otherFacei;
|
||||||
duplicateFace[otherFacei] = bFacei;
|
duplicateFace[otherFacei] = bFacei;
|
||||||
nDuplicateFaces++;
|
// ++nDuplicateFaces;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -232,14 +232,13 @@ void Foam::regionToCell::shrinkRegions
|
|||||||
if (selectedCell[celli])
|
if (selectedCell[celli])
|
||||||
{
|
{
|
||||||
selectedCell[celli] = false;
|
selectedCell[celli] = false;
|
||||||
nChanged++;
|
++nChanged;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Info<< " Eroded "
|
Info<< " Eroded "
|
||||||
<< returnReduce(nChanged, sumOp<label>())
|
<< returnReduce(nChanged, sumOp<label>()) << " cells." << endl;
|
||||||
<< " cells." << endl;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -308,7 +307,7 @@ void Foam::regionToCell::erode
|
|||||||
|
|
||||||
// Select all cells using these points
|
// Select all cells using these points
|
||||||
|
|
||||||
label nChanged = 0;
|
// label nChanged = 0;
|
||||||
forAll(boundaryPoint, pointi)
|
forAll(boundaryPoint, pointi)
|
||||||
{
|
{
|
||||||
if (boundaryPoint[pointi])
|
if (boundaryPoint[pointi])
|
||||||
@ -320,7 +319,7 @@ void Foam::regionToCell::erode
|
|||||||
if (!removeCell[celli])
|
if (!removeCell[celli])
|
||||||
{
|
{
|
||||||
removeCell[celli] = true;
|
removeCell[celli] = true;
|
||||||
nChanged++;
|
// ++nChanged;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1166,14 +1166,14 @@ void Foam::cellCellStencils::inverseDistance::findHoles
|
|||||||
|
|
||||||
|
|
||||||
// See which regions have not been visited (regionType == 1)
|
// See which regions have not been visited (regionType == 1)
|
||||||
label count = 0;
|
// label count = 0;
|
||||||
forAll(cellRegion, cellI)
|
forAll(cellRegion, cellI)
|
||||||
{
|
{
|
||||||
label type = regionType[cellRegion[cellI]];
|
label type = regionType[cellRegion[cellI]];
|
||||||
if (type == 1 && cellTypes[cellI] != HOLE)
|
if (type == 1 && cellTypes[cellI] != HOLE)
|
||||||
{
|
{
|
||||||
cellTypes[cellI] = HOLE;
|
cellTypes[cellI] = HOLE;
|
||||||
count++;
|
// ++count;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -244,6 +244,7 @@ bool Foam::oversetAdjustPhi
|
|||||||
|
|
||||||
|
|
||||||
// Check correction
|
// Check correction
|
||||||
|
#ifdef FULLDEBUG
|
||||||
if (fv::debug)
|
if (fv::debug)
|
||||||
{
|
{
|
||||||
scalar massOutCheck = 0;
|
scalar massOutCheck = 0;
|
||||||
@ -287,7 +288,10 @@ bool Foam::oversetAdjustPhi
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Info<< "mass in:" << massInCheck << " out:" << massOutCheck << nl;
|
||||||
}
|
}
|
||||||
|
#endif /* FULLDEBUG */
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -372,8 +372,7 @@ Foam::scalar Foam::oversetFvMeshBase::cellAverage
|
|||||||
const cell& cFaces = mesh_.cells()[celli];
|
const cell& cFaces = mesh_.cells()[celli];
|
||||||
|
|
||||||
scalar avg = 0.0;
|
scalar avg = 0.0;
|
||||||
label n = 0;
|
label nTotal = 0;
|
||||||
label nFront = 0;
|
|
||||||
for (const label facei : cFaces)
|
for (const label facei : cFaces)
|
||||||
{
|
{
|
||||||
if (mesh_.isInternalFace(facei))
|
if (mesh_.isInternalFace(facei))
|
||||||
@ -382,38 +381,32 @@ Foam::scalar Foam::oversetFvMeshBase::cellAverage
|
|||||||
if (norm[nbrCelli] == -GREAT)
|
if (norm[nbrCelli] == -GREAT)
|
||||||
{
|
{
|
||||||
// Invalid neighbour. Add to front
|
// Invalid neighbour. Add to front
|
||||||
if (isFront.set(facei))
|
isFront.set(facei);
|
||||||
{
|
|
||||||
nFront++;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// Valid neighbour. Add to average
|
// Valid neighbour. Add to average
|
||||||
avg += norm[nbrCelli];
|
avg += norm[nbrCelli];
|
||||||
n++;
|
++nTotal;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (nbrNorm[facei-mesh_.nInternalFaces()] == -GREAT)
|
if (nbrNorm[facei-mesh_.nInternalFaces()] == -GREAT)
|
||||||
{
|
{
|
||||||
if (isFront.set(facei))
|
isFront.set(facei);
|
||||||
{
|
|
||||||
nFront++;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
avg += nbrNorm[facei-mesh_.nInternalFaces()];
|
avg += nbrNorm[facei-mesh_.nInternalFaces()];
|
||||||
n++;
|
++nTotal;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (n > 0)
|
if (nTotal)
|
||||||
{
|
{
|
||||||
return avg/n;
|
return avg/nTotal;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@ -165,14 +165,14 @@ Foam::tmp<Foam::scalarField> Foam::oversetFvMeshBase::normalisation
|
|||||||
const cellCellStencilObject& overlap = Stencil::New(mesh_);
|
const cellCellStencilObject& overlap = Stencil::New(mesh_);
|
||||||
const labelUList& types = overlap.cellTypes();
|
const labelUList& types = overlap.cellTypes();
|
||||||
|
|
||||||
label nHoles = 0;
|
// label nHoles = 0;
|
||||||
scalarField extrapolatedNorm(norm);
|
scalarField extrapolatedNorm(norm);
|
||||||
forAll(types, celli)
|
forAll(types, celli)
|
||||||
{
|
{
|
||||||
if (types[celli] == cellCellStencil::HOLE)
|
if (types[celli] == cellCellStencil::HOLE)
|
||||||
{
|
{
|
||||||
extrapolatedNorm[celli] = -GREAT;
|
extrapolatedNorm[celli] = -GREAT;
|
||||||
nHoles++;
|
// ++nHoles;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -261,13 +261,13 @@ void Foam::regionsToCell::shrinkRegions
|
|||||||
if (selectedCell[cellI])
|
if (selectedCell[cellI])
|
||||||
{
|
{
|
||||||
selectedCell[cellI] = false;
|
selectedCell[cellI] = false;
|
||||||
nChanged++;
|
++nChanged;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Info<< " Eroded " << returnReduce(nChanged, sumOp<label>())
|
Info<< " Eroded "
|
||||||
<< " cells." << endl;
|
<< returnReduce(nChanged, sumOp<label>()) << " cells." << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -338,7 +338,7 @@ void Foam::regionsToCell::erode
|
|||||||
|
|
||||||
// Select all cells using these points
|
// Select all cells using these points
|
||||||
|
|
||||||
label nChanged = 0;
|
// label nChanged = 0;
|
||||||
forAll(boundaryPoint, pointI)
|
forAll(boundaryPoint, pointI)
|
||||||
{
|
{
|
||||||
if (boundaryPoint[pointI])
|
if (boundaryPoint[pointI])
|
||||||
@ -350,7 +350,7 @@ void Foam::regionsToCell::erode
|
|||||||
if (!removeCell[cellI])
|
if (!removeCell[cellI])
|
||||||
{
|
{
|
||||||
removeCell[cellI] = true;
|
removeCell[cellI] = true;
|
||||||
nChanged++;
|
// ++nChanged;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -3297,7 +3297,7 @@ void Foam::distributedTriSurfaceMesh::findNearest
|
|||||||
// Work array - whether processor bb overlaps the bounding sphere.
|
// Work array - whether processor bb overlaps the bounding sphere.
|
||||||
boolList procBbOverlaps(Pstream::nProcs());
|
boolList procBbOverlaps(Pstream::nProcs());
|
||||||
|
|
||||||
label nFound = 0;
|
// label nFound = 0;
|
||||||
|
|
||||||
forAll(nearestInfo, samplei)
|
forAll(nearestInfo, samplei)
|
||||||
{
|
{
|
||||||
@ -3305,10 +3305,10 @@ void Foam::distributedTriSurfaceMesh::findNearest
|
|||||||
const nearestAndDist& ni = nearestInfo[samplei];
|
const nearestAndDist& ni = nearestInfo[samplei];
|
||||||
const pointIndexHit& info = ni.first();
|
const pointIndexHit& info = ni.first();
|
||||||
|
|
||||||
if (info.hit())
|
// if (info.hit())
|
||||||
{
|
// {
|
||||||
nFound++;
|
// nFound++;
|
||||||
}
|
// }
|
||||||
|
|
||||||
scalar d2 =
|
scalar d2 =
|
||||||
(
|
(
|
||||||
|
|||||||
@ -170,14 +170,14 @@ bool Foam::patchDistMethods::exact::correct
|
|||||||
);
|
);
|
||||||
|
|
||||||
// Take over hits
|
// Take over hits
|
||||||
label nHits = 0;
|
// label nHits = 0;
|
||||||
forAll(info, celli)
|
forAll(info, celli)
|
||||||
{
|
{
|
||||||
if (info[celli].hit())
|
if (info[celli].hit())
|
||||||
{
|
{
|
||||||
const point& cc = mesh_.cellCentres()[celli];
|
const point& cc = mesh_.cellCentres()[celli];
|
||||||
y[celli] = info[celli].point().dist(cc);
|
y[celli] = info[celli].point().dist(cc);
|
||||||
nHits++;
|
// ++nHits;
|
||||||
}
|
}
|
||||||
//else
|
//else
|
||||||
//{
|
//{
|
||||||
|
|||||||
Reference in New Issue
Block a user