diff --git a/src/dynamicMesh/polyTopoChange/polyTopoChange/addPatchCellLayer.C b/src/dynamicMesh/polyTopoChange/polyTopoChange/addPatchCellLayer.C index 9232458ffb..536f7296b2 100644 --- a/src/dynamicMesh/polyTopoChange/polyTopoChange/addPatchCellLayer.C +++ b/src/dynamicMesh/polyTopoChange/polyTopoChange/addPatchCellLayer.C @@ -3,7 +3,7 @@ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | \\ / A nd | Copyright (C) 2011-2016 OpenFOAM Foundation - \\/ M anipulation | Copyright (C) 2015 OpenCFD Ltd. + \\/ M anipulation | Copyright (C) 2015-2017 OpenCFD Ltd. ------------------------------------------------------------------------------- License This file is part of OpenFOAM. @@ -495,13 +495,18 @@ void Foam::addPatchCellLayer::setFaceProps if (!found) { - FatalErrorInFunction + //FatalErrorInFunction + WarningInFunction << "Problem: cannot find patch edge " << ppEdgeI << " with mesh vertices " << patchEdge << " at " << patchEdge.line(mesh.points()) - << " is not in face " << faceI << " with mesh vertices " + << " in face " << faceI << " with mesh vertices " << f - << exit(FatalError); + << " at " << pointField(mesh.points(), f) + << endl + << "Continuing with potentially incorrect faceZone orientation" + //<< exit(FatalError); + << endl; } } } diff --git a/src/mesh/snappyHexMesh/snappyHexMeshDriver/snappyLayerDriver.C b/src/mesh/snappyHexMesh/snappyHexMeshDriver/snappyLayerDriver.C index 0c02195ad3..a8ebbcd9ea 100644 --- a/src/mesh/snappyHexMesh/snappyHexMeshDriver/snappyLayerDriver.C +++ b/src/mesh/snappyHexMesh/snappyHexMeshDriver/snappyLayerDriver.C @@ -3,7 +3,7 @@ \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | \\ / A nd | Copyright (C) 2011-2015 OpenFOAM Foundation - \\/ M anipulation | Copyright (C) 2015-2016 OpenCFD Ltd. + \\/ M anipulation | Copyright (C) 2015-2017 OpenCFD Ltd. ------------------------------------------------------------------------------- License This file is part of OpenFOAM. @@ -272,6 +272,267 @@ bool Foam::snappyLayerDriver::unmarkExtrusion } +Foam::label Foam::snappyLayerDriver::constrainFp(const label sz, const label fp) +{ + if (fp >= sz) + { + return 0; + } + else if (fp < 0) + { + return sz-1; + } + else + { + return fp; + } +} + + +void Foam::snappyLayerDriver::countCommonPoints +( + const indirectPrimitivePatch& pp, + const label facei, + + Map