Public Member Functions | Private Member Functions | Private Attributes
meshSurfaceMapper2D Class Reference
Collaboration diagram for meshSurfaceMapper2D:
Collaboration graph
[legend]

Public Member Functions

 meshSurfaceMapper2D (const meshSurfaceEngine &, const meshOctree &)
 Construct from meshSurfaceEngine and octree. More...
 
 ~meshSurfaceMapper2D ()
 
void adjustZCoordinates ()
 adjust z coordinates of the mesh to the ones in the surface mesh More...
 
void mapVerticesOntoSurface ()
 
void mapVerticesOntoSurface (const labelLongList &edgesToMap)
 
void mapCorners ()
 
void mapCorners (const labelLongList &edgesToMap)
 
void mapVerticesOntoSurfacePatches ()
 
void mapVerticesOntoSurfacePatches (const labelLongList &edgesToMap)
 
void preMapVertices (const label nIterations=2)
 

Private Member Functions

void findActiveBoundaryEdges ()
 find active boundary edges More...
 
void create2DEngine () const
 create a 2D engine More...
 
const polyMeshGen2DEnginemesh2DEngine () const
 create and return mesh 2D engine More...
 
void createTriSurfacePartitioner () const
 create surface partitioner More...
 
const triSurfacePartitionersurfacePartitioner () const
 create and reurn surface partitioner More...
 
void createMeshSurfacePartitioner () const
 create mesh surface partitioner More...
 
const meshSurfacePartitionermeshPartitioner () const
 create and return mesh surface partitioner More...
 
void clearOut ()
 delete dynamically allocated data More...
 
void findMappingDistance (const labelLongList &, std::map< label, scalar > &) const
 find mapping distance for corner points More...
 
void mapToSmallestDistance (LongList< parMapperHelper > &)
 map to the location with the smallest distance More...
 
 meshSurfaceMapper2D (const meshSurfaceMapper2D &)
 Disallow default bitwise copy construct. More...
 
void operator= (const meshSurfaceMapper2D &)
 Disallow default bitwise assignment. More...
 

Private Attributes

const meshSurfaceEnginesurfaceEngine_
 reference to mesh surface More...
 
const meshOctreemeshOctree_
 reference to the octree More...
 
polyMeshGen2DEnginemesh2DEnginePtr_
 mesh 2D engine More...
 
triSurfacePartitionersurfPartitionerPtr_
 triSurface partitioner More...
 
meshSurfacePartitionermeshPartitionerPtr_
 mesh surface partitioner More...
 
labelLongList activeBoundaryEdges_
 

Detailed Description

Definition at line 62 of file meshSurfaceMapper2D.H.

Constructor & Destructor Documentation

◆ meshSurfaceMapper2D() [1/2]

Disallow default bitwise copy construct.

◆ meshSurfaceMapper2D() [2/2]

meshSurfaceMapper2D ( const meshSurfaceEngine mse,
const meshOctree octree 
)

Construct from meshSurfaceEngine and octree.

allocate bpAtProcs and other addressing this is done here to prevent possible deadlocks

Definition at line 132 of file meshSurfaceMapper2D.C.

References UPstream::parRun().

Here is the call graph for this function:

◆ ~meshSurfaceMapper2D()

Definition at line 157 of file meshSurfaceMapper2D.C.

References meshSurfaceMapper2D::clearOut().

Here is the call graph for this function:

Member Function Documentation

◆ findActiveBoundaryEdges()

void findActiveBoundaryEdges ( )
private

◆ create2DEngine()

void create2DEngine ( ) const
private

create a 2D engine

Definition at line 106 of file meshSurfaceMapper2D.C.

References mesh, meshSurfaceEngine::mesh(), meshSurfaceMapper2D::mesh2DEnginePtr_, and meshSurfaceMapper2D::surfaceEngine_.

Referenced by meshSurfaceMapper2D::mesh2DEngine().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ mesh2DEngine()

const polyMeshGen2DEngine& mesh2DEngine ( ) const
inlineprivate

create and return mesh 2D engine

Definition at line 92 of file meshSurfaceMapper2D.H.

References meshSurfaceMapper2D::create2DEngine(), and meshSurfaceMapper2D::mesh2DEnginePtr_.

Referenced by meshSurfaceMapper2D::adjustZCoordinates(), and meshSurfaceMapper2D::findActiveBoundaryEdges().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ createTriSurfacePartitioner()

void createTriSurfacePartitioner ( ) const
private

create surface partitioner

Definition at line 112 of file meshSurfaceMapper2D.C.

References meshSurfaceMapper2D::meshOctree_, meshOctree::surface(), and meshSurfaceMapper2D::surfPartitionerPtr_.

Referenced by meshSurfaceMapper2D::surfacePartitioner().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ surfacePartitioner()

const triSurfacePartitioner& surfacePartitioner ( ) const
inlineprivate

create and reurn surface partitioner

Definition at line 104 of file meshSurfaceMapper2D.H.

References meshSurfaceMapper2D::createTriSurfacePartitioner(), and meshSurfaceMapper2D::surfPartitionerPtr_.

Here is the call graph for this function:

◆ createMeshSurfacePartitioner()

void createMeshSurfacePartitioner ( ) const
private

create mesh surface partitioner

Definition at line 117 of file meshSurfaceMapper2D.C.

References meshSurfaceMapper2D::meshPartitionerPtr_, and meshSurfaceMapper2D::surfaceEngine_.

Referenced by meshSurfaceMapper2D::meshPartitioner().

Here is the caller graph for this function:

◆ meshPartitioner()

const meshSurfacePartitioner& meshPartitioner ( ) const
inlineprivate

create and return mesh surface partitioner

Definition at line 116 of file meshSurfaceMapper2D.H.

References meshSurfaceMapper2D::createMeshSurfacePartitioner(), and meshSurfaceMapper2D::meshPartitionerPtr_.

Referenced by meshSurfaceMapper2D::mapCorners().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ clearOut()

void clearOut ( )
private

delete dynamically allocated data

Definition at line 122 of file meshSurfaceMapper2D.C.

References Foam::deleteDemandDrivenData(), meshSurfaceMapper2D::mesh2DEnginePtr_, meshSurfaceMapper2D::meshPartitionerPtr_, and meshSurfaceMapper2D::surfPartitionerPtr_.

Referenced by meshSurfaceMapper2D::~meshSurfaceMapper2D().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ findMappingDistance()

void findMappingDistance ( const labelLongList edgesToMap,
std::map< label, scalar > &  mappingDistance 
) const
private

find mapping distance for corner points

generate search distance for corner edges

safety factor

make sure that corner edges at parallel boundaries have the same range in which they accept the corners

create the map for exchanging data

exchange data between processors

select the maximum mapping distance for processor points

choose the maximum value for the mapping distance

Definition at line 56 of file meshSurfaceMapper2DMapVertices.C.

References Foam::help::exchangeMap(), forAll, forAllRow, Foam::magSqr(), Foam::max(), UPstream::myProcNo(), p, UPstream::parRun(), points, labelledScalar::scalarLabel(), and labelledScalar::value().

Referenced by meshSurfaceMapper2D::mapCorners().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ mapToSmallestDistance()

void mapToSmallestDistance ( LongList< parMapperHelper > &  parE)
private

◆ operator=()

void operator= ( const meshSurfaceMapper2D )
private

Disallow default bitwise assignment.

◆ adjustZCoordinates()

void adjustZCoordinates ( )

◆ mapVerticesOntoSurface() [1/2]

void mapVerticesOntoSurface ( )

projects surface vertices onto their nearest location on the surface mesh

Definition at line 262 of file meshSurfaceMapper2DMapVertices.C.

References meshSurfaceMapper2D::activeBoundaryEdges_, LongList< T, Offset >::append(), and forAll.

Referenced by cartesian2DMeshGenerator::mapMeshToSurface().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ mapVerticesOntoSurface() [2/2]

void mapVerticesOntoSurface ( const labelLongList edgesToMap)

◆ mapCorners() [1/2]

void mapCorners ( )

projects edges with corners onto their nearest location on the surface mesh

Definition at line 354 of file meshSurfaceMapper2DMapVertices.C.

References meshSurfaceMapper2D::activeBoundaryEdges_, LongList< T, Offset >::append(), meshSurfacePartitioner::corners(), Foam::e, meshSurfaceEngine::edges(), forAll, HashTable::found(), meshSurfaceMapper2D::meshPartitioner(), and meshSurfaceMapper2D::surfaceEngine_.

Here is the call graph for this function:

◆ mapCorners() [2/2]

void mapCorners ( const labelLongList edgesToMap)

◆ mapVerticesOntoSurfacePatches() [1/2]

void mapVerticesOntoSurfacePatches ( )

projects surface edges onto the surface with respect to the surface patch they belong to. Corners are respected

Definition at line 490 of file meshSurfaceMapper2DMapVertices.C.

References meshSurfaceMapper2D::activeBoundaryEdges_, LongList< T, Offset >::append(), and forAll.

Referenced by meshSurfaceOptimizer::optimizeSurface2D(), and meshSurfaceEdgeExtractor2D::remapBoundaryPoints().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ mapVerticesOntoSurfacePatches() [2/2]

void mapVerticesOntoSurfacePatches ( const labelLongList edgesToMap)

projects selected surface edges onto the surface with respect to the surface patch they belong to. Corners are respected

map the selected edges on their patches

update geometry at moved vertices

Definition at line 501 of file meshSurfaceMapper2DMapVertices.C.

References LongList< T, Offset >::append(), LongList< T, Offset >::clear(), Foam::e, Foam::endl(), forAll, Foam::Info, meshSurfaceEngineModifier::moveBoundaryVertexNoUpdate(), p, UPstream::parRun(), points, LongList< T, Offset >::size(), VRWGraph::sizeOfRow(), meshSurfaceEngineModifier::updateGeometry(), and Vector< Cmpt >::z().

Here is the call graph for this function:

◆ preMapVertices()

void preMapVertices ( const label  nIterations = 2)

a combination of mapping and smoothing intended for better feature capturing

use the shrinking laplace first

store the information

collect data to be sent to other processors

exchange data with other processors

combine collected data with the available data

calculate coordinates of points for searching

create the surface modifier and move the surface points

Definition at line 49 of file meshSurfaceMapper2DPremapVertices.C.

References meshSurfaceMapper2D::activeBoundaryEdges_, LongList< T, Offset >::append(), meshSurfaceEngine::beAtProcs(), meshSurfaceEngine::beNeiProcs(), meshSurfaceEngine::bp(), coordinates(), labelledPoint::coordinates(), Foam::e, meshSurfaceEngine::edgeFaces(), meshSurfaceEngine::edges(), Foam::endl(), Foam::help::exchangeMap(), meshSurfaceEngine::faceCentres(), meshOctree::findNearestSurfacePoint(), Foam::flush(), forAll, forAllRow, meshSurfaceEngine::globalBoundaryEdgeLabel(), meshSurfaceEngine::globalToLocalBndEdgeAddressing(), Foam::Info, refLabelledPoint::lPoint(), meshSurfaceMapper2D::meshOctree_, meshSurfaceEngineModifier::moveBoundaryVertexNoUpdate(), UPstream::myProcNo(), refLabelledPoint::objectLabel(), p, UPstream::parRun(), labelledPoint::pointLabel(), points, meshSurfaceEngine::points(), LongList< T, Offset >::size(), VRWGraph::sizeOfRow(), meshSurfaceMapper2D::surfaceEngine_, meshSurfaceEngineModifier::syncVerticesAtParallelBoundaries(), meshSurfaceEngineModifier::updateGeometry(), Foam::Warning, Vector< Cmpt >::z(), and Vector< scalar >::zero.

Referenced by cartesian2DMeshGenerator::mapMeshToSurface().

Here is the call graph for this function:
Here is the caller graph for this function:

Field Documentation

◆ surfaceEngine_

const meshSurfaceEngine& surfaceEngine_
private

◆ meshOctree_

const meshOctree& meshOctree_
private

◆ mesh2DEnginePtr_

polyMeshGen2DEngine* mesh2DEnginePtr_
mutableprivate

◆ surfPartitionerPtr_

triSurfacePartitioner* surfPartitionerPtr_
mutableprivate

◆ meshPartitionerPtr_

meshSurfacePartitioner* meshPartitionerPtr_
mutableprivate

◆ activeBoundaryEdges_

labelLongList activeBoundaryEdges_
private

The documentation for this class was generated from the following files: