Commit 2a9a899d authored by mattijs's avatar mattijs
Browse files

BUG: polyMesh: update pointMesh objects

parent 4d420577
......@@ -34,7 +34,7 @@ License
#include "indexedOctree.H"
#include "treeDataCell.H"
#include "MeshObject.H"
#include "pointMesh.H"
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
......@@ -1160,6 +1160,7 @@ Foam::tmp<Foam::scalarField> Foam::polyMesh::movePoints
solutionD_ = Vector<label>::zero;
meshObject::movePoints<polyMesh>(*this);
meshObject::movePoints<pointMesh>(*this);
const_cast<Time&>(time()).functionObjects().movePoints(*this);
......
......@@ -29,6 +29,7 @@ License
#include "MeshObject.H"
#include "indexedOctree.H"
#include "treeDataCell.H"
#include "pointMesh.H"
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
......@@ -61,6 +62,7 @@ void Foam::polyMesh::clearGeom()
}
// Clear all geometric mesh objects
meshObject::clear<pointMesh, GeometricMeshObject>(*this);
meshObject::clear<polyMesh, GeometricMeshObject>(*this);
primitiveMesh::clearGeom();
......@@ -108,6 +110,15 @@ void Foam::polyMesh::clearAddressing(const bool isMeshUpdate)
// Part of a mesh update. Keep meshObjects that have an updateMesh
// callback
meshObject::clearUpto
<
pointMesh,
TopologicalMeshObject,
UpdateableMeshObject
>
(
*this
);
meshObject::clearUpto
<
polyMesh,
TopologicalMeshObject,
......@@ -119,6 +130,7 @@ void Foam::polyMesh::clearAddressing(const bool isMeshUpdate)
}
else
{
meshObject::clear<pointMesh, TopologicalMeshObject>(*this);
meshObject::clear<polyMesh, TopologicalMeshObject>(*this);
}
......
......@@ -92,6 +92,7 @@ void Foam::polyMesh::updateMesh(const mapPolyMesh& mpm)
}
meshObject::updateMesh<polyMesh>(*this, mpm);
meshObject::updateMesh<pointMesh>(*this, mpm);
// Reset valid directions (could change by faces put into empty patches)
geometricD_ = Vector<label>::zero;
......
......@@ -48,7 +48,7 @@ void pointConstraints::makePatchPatchAddressing()
{
Pout<< "pointConstraints::makePatchPatchAddressing() : "
<< "constructing boundary addressing"
<< endl;
<< endl << incrIndent;
}
const pointMesh& pMesh = mesh();
......@@ -72,7 +72,7 @@ void pointConstraints::makePatchPatchAddressing()
if (debug)
{
Pout<< "On patch:" << pbm[patchi].name()
Pout<< indent << "On patch:" << pbm[patchi].name()
<< " nBoundaryPoints:" << bp.size() << endl;
}
}
......@@ -80,7 +80,8 @@ void pointConstraints::makePatchPatchAddressing()
if (debug)
{
Pout<< "Found nPatchPatchPoints:" << nPatchPatchPoints << endl;
Pout<< indent << "Found nPatchPatchPoints:" << nPatchPatchPoints
<< endl;
}
......@@ -137,7 +138,7 @@ void pointConstraints::makePatchPatchAddressing()
if (debug)
{
Pout<< "Have (local) constrained points:"
Pout<< indent << "Have (local) constrained points:"
<< nPatchPatchPoints << endl;
}
......@@ -224,7 +225,7 @@ void pointConstraints::makePatchPatchAddressing()
if (iter == patchPatchPointSet.end())
{
//Pout<< "on meshpoint:" << meshPointI
//Pout<< indent << "on meshpoint:" << meshPointI
// << " coupled:" << coupledPointI
// << " at:" << mesh.points()[meshPointI]
// << " have new constraint:"
......@@ -242,7 +243,7 @@ void pointConstraints::makePatchPatchAddressing()
}
else
{
//Pout<< "on meshpoint:" << meshPointI
//Pout<< indent << "on meshpoint:" << meshPointI
// << " coupled:" << coupledPointI
// << " at:" << mesh.points()[meshPointI]
// << " have possibly extended constraint:"
......@@ -271,7 +272,7 @@ void pointConstraints::makePatchPatchAddressing()
if (debug)
{
Pout<< "Have (global) constrained points:"
Pout<< indent << "Have (global) constrained points:"
<< nPatchPatchPoints << endl;
}
......@@ -303,7 +304,7 @@ void pointConstraints::makePatchPatchAddressing()
if (debug)
{
Pout<< "Have non-trivial constrained points:"
Pout<< indent << "Have non-trivial constrained points:"
<< nConstraints << endl;
}
......@@ -314,7 +315,8 @@ void pointConstraints::makePatchPatchAddressing()
if (debug)
{
Pout<< "pointConstraints::makePatchPatchAddressing() : "
Pout<< decrIndent
<< "pointConstraints::makePatchPatchAddressing() : "
<< "finished constructing boundary addressing"
<< endl;
}
......@@ -327,6 +329,13 @@ pointConstraints::pointConstraints(const pointMesh& pm)
:
MeshObject<pointMesh, Foam::UpdateableMeshObject, pointConstraints>(pm)
{
if (debug)
{
Pout<< "pointConstraints::pointConstraints(const pointMesh&): "
<< "Constructing from pointMesh " << pm.name()
<< endl;
}
makePatchPatchAddressing();
}
......
Supports Markdown
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