Commit e63b58b6 authored by andy's avatar andy
Browse files

Merge branch 'master' of /home/dm4/OpenFOAM/OpenFOAM-dev

parents 8b2f5696 b264b92a
......@@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
\\/ M anispulation |
-------------------------------------------------------------------------------
License
......@@ -494,7 +494,13 @@ autoPtr<mapPolyMesh> reorderMesh
newFlipMap[i] = fZone.flipMap()[i];
}
}
fZone.resetAddressing(newAddressing, newFlipMap);
labelList newToOld;
sortedOrder(newAddressing, newToOld);
fZone.resetAddressing
(
UIndirectList<label>(newAddressing, newToOld)(),
UIndirectList<bool>(newFlipMap, newToOld)()
);
}
}
// Re-do the cellZones
......@@ -508,6 +514,7 @@ autoPtr<mapPolyMesh> reorderMesh
reverseCellOrder,
cellZones[zoneI]
)();
Foam::sort(cellZones[zoneI]);
}
}
......
......@@ -77,10 +77,12 @@ Foam::PatchTools::sortedEdgeFaces
{
if (f0[fpI] != e.start())
{
const vector faceEdgeDir = localPoints[f0[fpI]] - edgePt;
const scalar angle = faceEdgeDir & e2;
vector faceEdgeDir = localPoints[f0[fpI]] - edgePt;
faceEdgeDir /= mag(faceEdgeDir) + VSMALL;
if (angle < maxAngle)
const scalar angle = e2 & faceEdgeDir;
if (mag(angle) < maxAngle)
{
maxAngle = angle;
maxAngleEdgeDir = faceEdgeDir;
......@@ -114,10 +116,12 @@ Foam::PatchTools::sortedEdgeFaces
{
if (f[fpI] != e.start())
{
const vector faceEdgeDir = localPoints[f[fpI]] - edgePt;
const scalar angle = faceEdgeDir & e2;
vector faceEdgeDir = localPoints[f[fpI]] - edgePt;
faceEdgeDir /= mag(faceEdgeDir) + VSMALL;
const scalar angle = e2 & faceEdgeDir;
if (angle < maxAngle)
if (mag(angle) < maxAngle)
{
maxAngle = angle;
maxAngleEdgeDir = faceEdgeDir;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment