Clean-up of post-processing with topo changes
This commit is contained in:
parent
f047b418ba
commit
f0dfd66dd6
7 changed files with 52 additions and 16 deletions
|
@ -82,13 +82,13 @@ void Foam::printMeshStats(const polyMesh& mesh, const bool allTopology)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
reduce(nHex,sumOp<label>());
|
reduce(nHex, sumOp<label>());
|
||||||
reduce(nPrism,sumOp<label>());
|
reduce(nPrism, sumOp<label>());
|
||||||
reduce(nWedge,sumOp<label>());
|
reduce(nWedge, sumOp<label>());
|
||||||
reduce(nPyr,sumOp<label>());
|
reduce(nPyr, sumOp<label>());
|
||||||
reduce(nTetWedge,sumOp<label>());
|
reduce(nTetWedge, sumOp<label>());
|
||||||
reduce(nTet,sumOp<label>());
|
reduce(nTet, sumOp<label>());
|
||||||
reduce(nUnknown,sumOp<label>());
|
reduce(nUnknown, sumOp<label>());
|
||||||
|
|
||||||
Info<< "Overall number of cells of each type:" << nl
|
Info<< "Overall number of cells of each type:" << nl
|
||||||
<< " hexahedra: " << nHex << nl
|
<< " hexahedra: " << nHex << nl
|
||||||
|
|
|
@ -192,7 +192,11 @@ void Foam::vtkPV3Foam::convertPointFields
|
||||||
}
|
}
|
||||||
|
|
||||||
// Construct interpolation on the raw mesh
|
// Construct interpolation on the raw mesh
|
||||||
pointMesh pMesh(mesh);
|
|
||||||
|
// HJ, bug fix? Point mesh handled by objectRegistry
|
||||||
|
// HJ, 11/Nov/2010
|
||||||
|
const pointMesh& pMesh = pointMesh::New(mesh);
|
||||||
|
// pointMesh pMesh(mesh);
|
||||||
|
|
||||||
|
|
||||||
convertPointFields<scalar>
|
convertPointFields<scalar>
|
||||||
|
|
|
@ -29,6 +29,7 @@ License
|
||||||
#include "globalMeshData.H"
|
#include "globalMeshData.H"
|
||||||
#include "demandDrivenData.H"
|
#include "demandDrivenData.H"
|
||||||
#include "meshObjectBase.H"
|
#include "meshObjectBase.H"
|
||||||
|
#include "pointMesh.H"
|
||||||
|
|
||||||
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
|
||||||
|
|
||||||
|
@ -93,7 +94,9 @@ void Foam::polyMesh::clearGeom()
|
||||||
solutionD_ = Vector<label>::zero;
|
solutionD_ = Vector<label>::zero;
|
||||||
|
|
||||||
// Move points all mesh objects. HJ, 13/Oct/2010
|
// Move points all mesh objects. HJ, 13/Oct/2010
|
||||||
meshObjectBase::allMovePoints(*this);
|
// This is a problem, because it is called in a destructor.
|
||||||
|
meshObjectBase::allDelete(*this);
|
||||||
|
// meshObjectBase::allMovePoints(*this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -260,7 +260,6 @@ Foam::polyMesh::readUpdateState Foam::polyMesh::readUpdate()
|
||||||
initMesh(cells);
|
initMesh(cells);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Even if number of patches stayed same still recalculate boundary
|
// Even if number of patches stayed same still recalculate boundary
|
||||||
// data.
|
// data.
|
||||||
|
|
||||||
|
|
|
@ -36,9 +36,34 @@ void Foam::polyMesh::initMesh()
|
||||||
<< "initialising primitiveMesh" << endl;
|
<< "initialising primitiveMesh" << endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// For backward compatibility check if the owner array is the same
|
||||||
|
// length as the number of allFaces and shrink to remove the -1s padding
|
||||||
|
if (min(owner_) < 0)
|
||||||
|
{
|
||||||
|
label nActiveFaces = 0;
|
||||||
|
|
||||||
|
forAll(owner_, faceI)
|
||||||
|
{
|
||||||
|
if (owner_[faceI] == -1)
|
||||||
|
{
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
nActiveFaces++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
InfoIn("void polyMesh::initMesh()")
|
||||||
|
<< "Truncating owner list at " << nActiveFaces
|
||||||
|
<< " for backward compatibility" << endl;
|
||||||
|
|
||||||
|
owner_.setSize(nActiveFaces);
|
||||||
|
}
|
||||||
|
|
||||||
// For backward compatibility check if the neighbour array is the same
|
// For backward compatibility check if the neighbour array is the same
|
||||||
// length as the owner and shrink to remove the -1s padding
|
// length as the owner and shrink to remove the -1s padding
|
||||||
if (neighbour_.size() == owner_.size())
|
if (min(neighbour_) < 0)
|
||||||
{
|
{
|
||||||
label nIntFaces = 0;
|
label nIntFaces = 0;
|
||||||
|
|
||||||
|
@ -54,6 +79,10 @@ void Foam::polyMesh::initMesh()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
InfoIn("void polyMesh::initMesh()")
|
||||||
|
<< "Truncating neighbour list at " << nIntFaces
|
||||||
|
<< " for backward compatibility" << endl;
|
||||||
|
|
||||||
neighbour_.setSize(nIntFaces);
|
neighbour_.setSize(nIntFaces);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -42,7 +42,7 @@ void Foam::primitiveMesh::calcCells
|
||||||
{
|
{
|
||||||
nCells = -1;
|
nCells = -1;
|
||||||
|
|
||||||
forAll(own, faceI)
|
forAll (own, faceI)
|
||||||
{
|
{
|
||||||
nCells = max(nCells, own[faceI]);
|
nCells = max(nCells, own[faceI]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -86,7 +86,8 @@ public:
|
||||||
|
|
||||||
// Constructors
|
// Constructors
|
||||||
|
|
||||||
//- Constructor given fvMesh and pointMesh.
|
//- Constructor given fvMesh. pointMesh will be created or
|
||||||
|
// looked up from objectRegistry
|
||||||
explicit volPointInterpolation(const fvMesh&);
|
explicit volPointInterpolation(const fvMesh&);
|
||||||
|
|
||||||
|
|
||||||
|
|
Reference in a new issue