mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: refinementFeatures: use extendedEdgeMesh feature points
This commit is contained in:
@ -35,7 +35,6 @@ License
|
||||
#include "fvMeshDistribute.H"
|
||||
#include "polyTopoChange.H"
|
||||
#include "mapDistributePolyMesh.H"
|
||||
#include "featureEdgeMesh.H"
|
||||
#include "Cloud.H"
|
||||
//#include "globalIndex.H"
|
||||
#include "OBJstream.H"
|
||||
@ -358,7 +357,7 @@ void Foam::meshRefinement::markFeatureCellLevel
|
||||
|
||||
forAll(features_, featI)
|
||||
{
|
||||
const featureEdgeMesh& featureMesh = features_[featI];
|
||||
const edgeMesh& featureMesh = features_[featI];
|
||||
const label featureLevel = features_.levels()[featI][0];
|
||||
const labelListList& pointEdges = featureMesh.pointEdges();
|
||||
|
||||
@ -505,7 +504,7 @@ void Foam::meshRefinement::markFeatureCellLevel
|
||||
label featI = startTp.i();
|
||||
label pointI = startTp.j();
|
||||
|
||||
const featureEdgeMesh& featureMesh = features_[featI];
|
||||
const edgeMesh& featureMesh = features_[featI];
|
||||
const labelList& pEdges = featureMesh.pointEdges()[pointI];
|
||||
|
||||
// Now shoot particles down all pEdges.
|
||||
@ -561,7 +560,7 @@ void Foam::meshRefinement::markFeatureCellLevel
|
||||
label featI = tp.i();
|
||||
label pointI = tp.j();
|
||||
|
||||
const featureEdgeMesh& featureMesh = features_[featI];
|
||||
const edgeMesh& featureMesh = features_[featI];
|
||||
const labelList& pEdges = featureMesh.pointEdges()[pointI];
|
||||
|
||||
// Particle now at pointI. Check connected edges to see which one
|
||||
|
||||
@ -186,7 +186,7 @@ void Foam::refinementFeatures::read
|
||||
set(featI, new extendedFeatureEdgeMesh(featObj, eeMesh));
|
||||
}
|
||||
|
||||
const edgeMesh& eMesh = operator[](featI);
|
||||
const extendedEdgeMesh& eMesh = operator[](featI);
|
||||
|
||||
//eMesh.mergePoints(meshRefiner_.mergeDistance());
|
||||
|
||||
@ -258,13 +258,9 @@ void Foam::refinementFeatures::read
|
||||
}
|
||||
|
||||
|
||||
void Foam::refinementFeatures::buildTrees
|
||||
(
|
||||
const label featI,
|
||||
const labelList& featurePoints
|
||||
)
|
||||
void Foam::refinementFeatures::buildTrees(const label featI)
|
||||
{
|
||||
const edgeMesh& eMesh = operator[](featI);
|
||||
const extendedEdgeMesh& eMesh = operator[](featI);
|
||||
const pointField& points = eMesh.points();
|
||||
const edgeList& edges = eMesh.edges();
|
||||
|
||||
@ -299,6 +295,9 @@ void Foam::refinementFeatures::buildTrees
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
labelList featurePoints(identity(eMesh.nonFeatureStart()));
|
||||
|
||||
pointTrees_.set
|
||||
(
|
||||
featI,
|
||||
@ -408,24 +407,7 @@ Foam::refinementFeatures::refinementFeatures
|
||||
// Search engines
|
||||
forAll(*this, i)
|
||||
{
|
||||
const extendedEdgeMesh& eMesh = operator[](i);
|
||||
const labelListList& pointEdges = eMesh.pointEdges();
|
||||
|
||||
DynamicList<label> featurePoints;
|
||||
forAll(pointEdges, pointI)
|
||||
{
|
||||
if (pointEdges[pointI].size() > 2)
|
||||
{
|
||||
featurePoints.append(pointI);
|
||||
}
|
||||
}
|
||||
|
||||
Info<< "Detected " << featurePoints.size()
|
||||
<< " featurePoints out of " << pointEdges.size()
|
||||
<< " points on feature " << operator[](i).name()
|
||||
<< endl;
|
||||
|
||||
buildTrees(i, featurePoints);
|
||||
buildTrees(i);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -76,7 +76,7 @@ private:
|
||||
void read(const objectRegistry&, const PtrList<dictionary>&);
|
||||
|
||||
//- Build edge tree and feature point tree
|
||||
void buildTrees(const label, const labelList&);
|
||||
void buildTrees(const label);
|
||||
|
||||
//- Find shell level higher than ptLevel
|
||||
void findHigherLevel
|
||||
|
||||
Reference in New Issue
Block a user