OpenFOAM logo
The Open Source CFD Toolbox
  Source Guide OpenCFD Solutions Contact OpenFOAM

triSurface Class Reference

Triangulated surface description with patch information. More...

Inheritance diagram for triSurface:
Collaboration diagram for triSurface:

List of all members.


Public Types

typedef bool BoundaryMesh
 Placeholder only, but do not remove - it is needed for GeoMesh.

Public Member Functions

 ClassName ("triSurface")
 Runtime type information.
 triSurface ()
 Construct null.
 triSurface (const List< labelledTri > &, const geometricSurfacePatchList &, const pointField &)
 Construct from triangles, patches, points.
 triSurface (List< labelledTri > &, const geometricSurfacePatchList &, pointField &, const bool reUse)
 Construct from triangles, patches, points. Reuse storage.
 triSurface (const List< labelledTri > &, const pointField &)
 Construct from triangles, points. Set patchnames to default.
 triSurface (const triFaceList &, const pointField &)
 Construct from triangles, points. Set region to 0 and default.
 triSurface (const fileName &)
 Construct from file name (uses extension to determine type).
 triSurface (Istream &)
 Construct from Istream.
 triSurface (const Time &d)
 Construct from objectRegistry.
 triSurface (const triSurface &)
 Construct as copy.
 ~triSurface ()
void clearOut ()
void clearTopology ()
void clearPatchMeshAddr ()
const geometricSurfacePatchList & patches () const
geometricSurfacePatchList & patches ()
const labelListList & sortedEdgeFaces () const
 Return edge-face addressing sorted (for edges with more than.
const labelList & edgeOwner () const
 If 2 face neighbours: label of face where ordering of edge.
virtual void movePoints (const pointField &)
 Move points.
virtual void scalePoints (const scalar &)
 Scale points. A non-positive factor is ignored.
void checkTriangles (const bool verbose)
 Check/remove duplicate/degenerate triangles.
void checkEdges (const bool verbose)
 Check triply (or more) connected edges.
void cleanup (const bool verbose)
 Remove non-valid triangles.
void markZone (const boolList &borderEdge, const label faceI, const label currentZone, labelList &faceZone) const
 Fill faceZone with currentZone for every face reachable.
label markZones (const boolList &borderEdge, labelList &faceZone) const
 (size and) fills faceZone with zone of face. Zone is area
void subsetMeshMap (const boolList &include, labelList &pointMap, labelList &faceMap) const
 'Create' sub mesh, including only faces for which
triSurface subsetMesh (const boolList &include, labelList &pointMap, labelList &faceMap) const
 Return new surface. Returns pointMap, faceMap from.
void write (Ostream &) const
 Write to Ostream in simple FOAM format.
void write (const fileName &, const bool sortByRegion=false) const
 Generic write routine. Chooses writer based on extension.
void write (const Time &) const
 Write to database.
void writeDX (const scalarField &, Ostream &) const
 Write to Ostream in OpenDX format.
void writeDX (const vectorField &, Ostream &) const
void writeStats (Ostream &) const
 Write some statistics.
void operator= (const triSurface &)

Static Public Member Functions

static fileName triSurfInstance (const Time &)
 Name of triSurface directory to use.

Protected Member Functions

pointField & storedPoints ()
 Non-const access to global points.
List< Face > & storedFaces ()
 Non-const access to the faces.

Friends

Ostream & operator<< (Ostream &, const triSurface &)

Detailed Description

Triangulated surface description with patch information.

Source files

Definition at line 53 of file triSurface.H.


Member Typedef Documentation

typedef bool BoundaryMesh

Placeholder only, but do not remove - it is needed for GeoMesh.

Definition at line 240 of file triSurface.H.


Constructor & Destructor Documentation

triSurface (  ) 

Construct null.

Definition at line 594 of file triSurface.C.

Referenced by Foam::parseNASCoord().

Here is the caller graph for this function:

triSurface ( const List< labelledTri > &  triangles,
const geometricSurfacePatchList &  patches,
const pointField &  points 
)

Construct from triangles, patches, points.

Definition at line 605 of file triSurface.C.

triSurface ( List< labelledTri > &  triangles,
const geometricSurfacePatchList &  patches,
pointField &  points,
const bool  reUse 
)

Construct from triangles, patches, points. Reuse storage.

Definition at line 619 of file triSurface.C.

triSurface ( const List< labelledTri > &  triangles,
const pointField &  points 
)

Construct from triangles, points. Set patchnames to default.

Definition at line 634 of file triSurface.C.

triSurface ( const triFaceList &  triangles,
const pointField &  points 
)

Construct from triangles, points. Set region to 0 and default.

patchName.

Definition at line 649 of file triSurface.C.

triSurface ( const fileName &  name  ) 

Construct from file name (uses extension to determine type).

Definition at line 663 of file triSurface.C.

triSurface ( Istream &  is  ) 

Construct from Istream.

Definition at line 678 of file triSurface.C.

References fileName::ext().

Here is the call graph for this function:

triSurface ( const Time &  d  ) 

Construct from objectRegistry.

Definition at line 691 of file triSurface.C.

triSurface ( const triSurface &  ts  ) 

Construct as copy.

Definition at line 710 of file triSurface.C.

~triSurface (  ) 

Definition at line 721 of file triSurface.C.


Member Function Documentation

pointField& storedPoints (  )  [inline, protected]

Non-const access to global points.

Definition at line 224 of file triSurface.H.

List<Face>& storedFaces (  )  [inline, protected]

Non-const access to the faces.

Definition at line 230 of file triSurface.H.

ClassName ( "triSurface"   ) 

Runtime type information.

Foam::fileName triSurfInstance ( const Time &  d  )  [static]

Name of triSurface directory to use.

Definition at line 36 of file triSurface.C.

References Foam::defineTypeNameAndDebug().

Here is the call graph for this function:

void clearOut (  ) 

Reimplemented from PrimitivePatch< labelledTri,::Foam::List, pointField, point >.

Reimplemented in distributedTriSurfaceMesh, and triSurfaceMesh.

Definition at line 743 of file triSurface.C.

Referenced by triSurface::clearTopology().

Here is the caller graph for this function:

void clearTopology (  ) 

Reimplemented from PrimitivePatch< labelledTri,::Foam::List, pointField, point >.

Definition at line 729 of file triSurface.C.

References triSurface::clearOut().

Referenced by triSurface::sortedEdgeFaces().

Here is the call graph for this function:

Here is the caller graph for this function:

void clearPatchMeshAddr (  ) 

Reimplemented from PrimitivePatch< labelledTri,::Foam::List, pointField, point >.

Definition at line 737 of file triSurface.C.

References PrimitivePatch< labelledTri,::Foam::List, pointField, point >::clearTopology(), and Foam::deleteDemandDrivenData().

Referenced by triSurface::sortedEdgeFaces().

Here is the call graph for this function:

Here is the caller graph for this function:

const geometricSurfacePatchList& patches (  )  const [inline]

Definition at line 313 of file triSurface.H.

Referenced by triSurfaceMesh::hasVolumeType(), and Foam::parseNASCoord().

Here is the caller graph for this function:

geometricSurfacePatchList& patches (  )  [inline]

Definition at line 318 of file triSurface.H.

const Foam::labelListList & sortedEdgeFaces (  )  const

Return edge-face addressing sorted (for edges with more than.

2 faces) according to the angle around the edge. Orientation is anticlockwise looking from edge.vec(localPoints())

Definition at line 752 of file triSurface.C.

References PrimitivePatch< labelledTri,::Foam::List, pointField, point >::clearOut(), triSurface::clearPatchMeshAddr(), and triSurface::clearTopology().

Here is the call graph for this function:

const Foam::labelList & edgeOwner (  )  const

If 2 face neighbours: label of face where ordering of edge.

is consistent with righthand walk. If 1 neighbour: label of only face. If >2 neighbours: undetermined.

Definition at line 763 of file triSurface.C.

void movePoints ( const pointField &  newPoints  )  [virtual]

Move points.

Reimplemented in triSurfaceMesh.

Definition at line 775 of file triSurface.C.

void scalePoints ( const scalar &  scaleFactor  )  [virtual]

Scale points. A non-positive factor is ignored.

Definition at line 789 of file triSurface.C.

void checkTriangles ( const bool  verbose  ) 

Check/remove duplicate/degenerate triangles.

Definition at line 179 of file triSurface.C.

void checkEdges ( const bool  verbose  ) 

Check triply (or more) connected edges.

Definition at line 313 of file triSurface.C.

void cleanup ( const bool  verbose  ) 

Remove non-valid triangles.

Definition at line 806 of file triSurface.C.

void markZone ( const boolList &  borderEdge,
const label  faceI,
const label  currentZone,
labelList &  faceZone 
) const

Fill faceZone with currentZone for every face reachable.

from faceI without crossing edge marked in borderEdge. Note: faceZone has to be sized nFaces before calling this fun.

Definition at line 823 of file triSurface.C.

Foam::label markZones ( const boolList &  borderEdge,
labelList &  faceZone 
) const

(size and) fills faceZone with zone of face. Zone is area

reachable by edge crossing without crossing borderEdge (bool for every edge in surface). Returns number of zones.

Definition at line 892 of file triSurface.C.

void subsetMeshMap ( const boolList &  include,
labelList &  pointMap,
labelList &  faceMap 
) const

'Create' sub mesh, including only faces for which

boolList entry is true Sets: pointMap: from new to old localPoints faceMap: new to old faces

Definition at line 941 of file triSurface.C.

Foam::triSurface subsetMesh ( const boolList &  include,
labelList &  pointMap,
labelList &  faceMap 
) const

Return new surface. Returns pointMap, faceMap from.

subsetMeshMap

Definition at line 999 of file triSurface.C.

void write ( Ostream &  os  )  const

Write to Ostream in simple FOAM format.

Definition at line 1050 of file triSurface.C.

References fileName::ext().

Here is the call graph for this function:

void write ( const fileName &  name,
const bool  sortByRegion = false 
) const

Generic write routine. Chooses writer based on extension.

Definition at line 1041 of file triSurface.C.

void write ( const Time &  d  )  const

Write to database.

Definition at line 1063 of file triSurface.C.

void writeDX ( const scalarField &  field,
Ostream &  os 
) const

Write to Ostream in OpenDX format.

Definition at line 158 of file writeDX.C.

void writeDX ( const vectorField &  field,
Ostream &  os 
) const

Definition at line 203 of file writeDX.C.

void writeStats ( Ostream &  os  )  const

Write some statistics.

Reimplemented in distributedTriSurfaceMesh.

Definition at line 1075 of file triSurface.C.

void operator= ( const triSurface &  ts  ) 

Definition at line 1108 of file triSurface.C.


Friends And Related Function Documentation

Ostream& operator<< ( Ostream &  ,
const triSurface &   
) [friend]


The documentation for this class was generated from the following files:
Copyright © 2000-2009 OpenCFD Ltd