Classes | Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
face Class Reference

A face is a list of labels corresponding to mesh vertices. More...

Inheritance diagram for face:
Inheritance graph
[legend]
Collaboration diagram for face:
Collaboration graph
[legend]

Classes

struct  hasher
 
struct  symmHasher
 

Public Types

enum  proxType { NONE = 0, POINT, EDGE }
 
- Public Types inherited from List
typedef SubList< TsubList
 

Public Member Functions

constexpr face () noexcept=default
 
 face (const label sz)
 
 face (const labelUList &list)
 
 face (labelList &&list)
 
 face (std::initializer_list< label > list)
 
template<unsigned N>
 face (const FixedList< label, N > &list)
 
 face (const labelUList &list, const labelUList &indices)
 
template<unsigned N>
 face (const labelUList &list, const FixedList< label, N > &indices)
 
 face (const triFace &f)
 
 face (Istream &is)
 
label collapse ()
 
void flip ()
 
pointField points (const UList< point > &pts) const
 
point centre (const UList< point > &points) const
 
template<class Type >
Type average (const UList< point > &meshPoints, const Field< Type > &fld) const
 
vector areaNormal (const UList< point > &p) const
 
vector unitNormal (const UList< point > &p) const
 
 FOAM_DEPRECATED_FOR (2018-12, "areaNormal() or unitNormal()") vector normal(const UList< point > &p) const
 
scalar mag (const UList< point > &p) const
 
face reverseFace () const
 
label which (const label pointLabel) const
 
label thisLabel (const label i) const
 
label nextLabel (const label i) const
 
label prevLabel (const label i) const
 
scalar sweptVol (const UList< point > &oldPoints, const UList< point > &newPoints) const
 
tensor inertia (const UList< point > &p, const point &refPt=vector::zero, scalar density=1.0) const
 
pointHit ray (const point &p, const vector &n, const UList< point > &meshPoints, const intersection::algorithm alg=intersection::FULL_RAY, const intersection::direction dir=intersection::VECTOR) const
 
pointHit intersection (const point &p, const vector &q, const point &ctr, const UList< point > &meshPoints, const intersection::algorithm alg, const scalar tol=0.0) const
 
pointHit nearestPoint (const point &p, const UList< point > &meshPoints) const
 
pointHit nearestPointClassify (const point &p, const UList< point > &meshPoints, label &nearType, label &nearLabel) const
 
int sign (const point &p, const UList< point > &points, const scalar tol=SMALL) const
 
scalar contactSphereDiameter (const point &p, const vector &n, const UList< point > &meshPoints) const
 
scalar areaInContact (const UList< point > &meshPoints, const scalarField &v) const
 
label nEdges () const noexcept
 
Foam::edge edge (const label edgei) const
 
vector edge (const label edgei, const UList< point > &pts) const
 
Foam::edge rcEdge (const label edgei) const
 
vector rcEdge (const label edgei, const UList< point > &pts) const
 
edgeList edges () const
 
edgeList rcEdges () const
 
int edgeDirection (const Foam::edge &e) const
 
label longestEdge (const UList< point > &pts) const
 
label nTriangles () const
 
label nTriangles (const UList< point > &unused) const
 
label triangles (const UList< point > &points, label &triI, faceList &triFaces) const
 
template<int SizeMin>
label triangles (const UList< point > &points, DynamicList< face, SizeMin > &triFaces) const
 
label nTrianglesQuads (const UList< point > &points, label &nTris, label &nQuads) const
 
label trianglesQuads (const UList< point > &points, label &triI, label &quadI, faceList &triFaces, faceList &quadFaces) const
 
unsigned hash_code (unsigned seed=0) const
 
unsigned symmhash_code (unsigned seed=0) const
 
Foam::edge faceEdge (label edgei) const
 
template<int SizeMin>
Foam::label triangles (const UList< point > &points, DynamicList< face, SizeMin > &triFaces) const
 
- Public Member Functions inherited from List
constexpr List () noexcept
 
 List (const label len)
 
 List (const label len, const T &val)
 
 List (const label len, const Foam::zero)
 
 List (const Foam::one, const T &val)
 
 List (const Foam::one, T &&val)
 
 List (const Foam::one, const Foam::zero)
 
 List (const List< T > &a)
 
 List (const UList< T > &a)
 
 List (List< T > &a, bool reuse)
 
 List (const UList< T > &list, const labelUList &indices)
 
template<unsigned N>
 List (const UList< T > &list, const FixedList< label, N > &indices)
 
template<unsigned N>
 List (const FixedList< T, N > &list)
 
 List (const PtrList< T > &list)
 
 List (const SLList< T > &list)
 
template<class Addr >
 List (const IndirectListBase< T, Addr > &list)
 
 List (std::initializer_list< T > list)
 
 List (List< T > &&list)
 
template<int SizeMin>
 List (DynamicList< T, SizeMin > &&list)
 
 List (SortableList< T > &&list)
 
 List (SLList< T > &&list)
 
 List (Istream &is)
 
autoPtr< List< T > > clone () const
 
 ~List ()
 
void clear ()
 
void resize (const label len)
 
void resize (const label len, const T &val)
 
void resize_nocopy (const label len)
 
void setSize (const label n)
 
void setSize (const label n, const T &val)
 
void append (const T &val)
 
void append (T &&val)
 
void append (const UList< T > &list)
 
template<class Addr >
void append (const IndirectListBase< T, Addr > &list)
 
label appendUniq (const T &val)
 
void transfer (List< T > &list)
 
template<int SizeMin>
void transfer (DynamicList< T, SizeMin > &list)
 
void transfer (SortableList< T > &list)
 
TnewElmt (const label i)
 
void operator= (const UList< T > &a)
 
void operator= (const List< T > &list)
 
void operator= (const SLList< T > &list)
 
template<class Addr >
void operator= (const IndirectListBase< T, Addr > &list)
 
template<unsigned N>
void operator= (const FixedList< T, N > &list)
 
void operator= (std::initializer_list< T > list)
 
void operator= (const T &val)
 
void operator= (const Foam::zero)
 
void operator= (List< T > &&list)
 
template<int SizeMin>
void operator= (DynamicList< T, SizeMin > &&list)
 
void operator= (SortableList< T > &&list)
 
void operator= (SLList< T > &&list)
 
IstreamreadList (Istream &is)
 
void shallowCopy (const UList< T > &)=delete
 
template<class TypeT = T>
std::enable_if< std::is_same< bool, TypeT >::value, bool >::type set (const label i, bool val=true)
 
template<class T >
 List (const label len)
 
template<class T >
 List (const label len, const T &val)
 
template<class T >
 List (const label len, const Foam::zero)
 
template<class T >
 List (const Foam::one, const T &val)
 
template<class T >
 List (const Foam::one, T &&val)
 
template<class T >
 List (const Foam::one, const Foam::zero)
 
template<class T >
 List (const UList< T > &a)
 
template<class T >
 List (const List< T > &a)
 
template<class T >
 List (List< T > &a, bool reuse)
 
template<class T >
 List (const UList< T > &list, const labelUList &indices)
 
template<class T >
 List (const PtrList< T > &list)
 
template<class T >
 List (const SLList< T > &list)
 
template<class T >
 List (std::initializer_list< T > list)
 
template<class T >
 List (List< T > &&list)
 
template<class T >
 List (SortableList< T > &&list)
 
template<class T >
 List (SLList< T > &&list)
 
template<class T >
void transfer (List< T > &list)
 
template<class T >
void transfer (SortableList< T > &list)
 
template<class T >
void operator= (const UList< T > &a)
 
template<class T >
void operator= (const List< T > &list)
 
template<class T >
void operator= (const SLList< T > &list)
 
template<class T >
void operator= (std::initializer_list< T > list)
 
template<class T >
void operator= (List< T > &&list)
 
template<class T >
void operator= (SortableList< T > &&list)
 
template<class T >
void operator= (SLList< T > &&list)
 
IstreamreadList (Istream &is)
 
template<class T >
constexpr List () noexcept
 
void resize (const label newLen)
 
template<class T >
void append (const T &val)
 
template<class T >
void append (T &&val)
 
template<class T >
void append (const UList< T > &list)
 
template<class T >
void operator= (const T &val)
 
template<class T >
void operator= (const Foam::zero)
 
template<class T >
 List (Istream &is)
 
IstreamreadList (Istream &is)
 

Static Public Member Functions

static int compare (const face &a, const face &b)
 
static bool sameVertices (const face &a, const face &b)
 
static unsigned symmhash_code (const UList< label > &f, unsigned seed=0)
 
- Static Public Member Functions inherited from List
static const List< T > & null ()
 

Static Public Attributes

static const char *const typeName = "face"
 

Detailed Description

A face is a list of labels corresponding to mesh vertices.

See also
Foam::triFace
Source files

Definition at line 68 of file face.H.

Member Enumeration Documentation

◆ proxType

enum proxType
Enumerator
NONE 

Unknown proximity.

POINT 

Close to point.

EDGE 

Close to edge.

Definition at line 116 of file face.H.

Constructor & Destructor Documentation

◆ face() [1/10]

constexpr face ( )
constexprdefaultnoexcept

Referenced by cellShape::face().

Here is the caller graph for this function:

◆ face() [2/10]

face ( const label  sz)
inlineexplicit

Definition at line 24 of file faceI.H.

◆ face() [3/10]

face ( const labelUList list)
inlineexplicit

Definition at line 30 of file faceI.H.

◆ face() [4/10]

face ( labelList &&  list)
inlineexplicit

Definition at line 36 of file faceI.H.

◆ face() [5/10]

face ( std::initializer_list< label >  list)
inlineexplicit

Definition at line 42 of file faceI.H.

◆ face() [6/10]

face ( const FixedList< label, N > &  list)
inlineexplicit

Definition at line 49 of file faceI.H.

◆ face() [7/10]

face ( const labelUList list,
const labelUList indices 
)
inline

Definition at line 55 of file faceI.H.

◆ face() [8/10]

face ( const labelUList list,
const FixedList< label, N > &  indices 
)
inline

Definition at line 63 of file faceI.H.

◆ face() [9/10]

face ( const triFace f)

Definition at line 266 of file face.C.

◆ face() [10/10]

face ( Istream is)
inline

Definition at line 72 of file faceI.H.

Member Function Documentation

◆ collapse()

Foam::label collapse ( )

Definition at line 468 of file face.C.

References setSize().

Here is the call graph for this function:

◆ flip()

void flip ( )

Definition at line 493 of file face.C.

References n.

Referenced by createShellMesh::setRefinement().

Here is the caller graph for this function:

◆ points()

Foam::pointField points ( const UList< point > &  pts) const
inline

◆ centre()

Foam::point centre ( const UList< point > &  points) const

Definition at line 507 of file face.C.

References Foam::mag(), nPoints, points, and Foam::Zero.

Here is the call graph for this function:

◆ average()

Type average ( const UList< point > &  meshPoints,
const Field< Type > &  fld 
) const

Definition at line 46 of file faceTemplates.C.

References fld, Foam::mag(), nPoints, and Foam::Zero.

Here is the call graph for this function:

◆ areaNormal()

Foam::vector areaNormal ( const UList< point > &  p) const

Definition at line 571 of file face.C.

References n, nPoints, p, and Foam::Zero.

Referenced by face::FOAM_DEPRECATED_FOR().

Here is the caller graph for this function:

◆ unitNormal()

Foam::vector unitNormal ( const UList< point > &  p) const
inline

Definition at line 97 of file faceI.H.

References Foam::mag(), n, p, s, and Foam::Zero.

Here is the call graph for this function:

◆ FOAM_DEPRECATED_FOR()

FOAM_DEPRECATED_FOR ( 2018-  12,
"areaNormal() or unitNormal()"   
) const &
inline

Definition at line 196 of file face.H.

References face::areaNormal(), and p.

Here is the call graph for this function:

◆ mag()

Foam::scalar mag ( const UList< point > &  p) const
inline

Definition at line 105 of file faceI.H.

References Foam::mag(), and p.

Referenced by polyPatch::areaFraction(), face::areaInContact(), hexCellLooper::cut(), and cyclicACMIFvPatch::movePoints().

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

◆ reverseFace()

Foam::face reverseFace ( ) const

Definition at line 629 of file face.C.

References UList::size().

Referenced by polyMeshAdder::add(), and perfectInterface::setRefinement().

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

◆ which()

Foam::label which ( const label  pointLabel) const
inline

Definition at line 156 of file faceI.H.

References Foam::ListOps::find().

Here is the call graph for this function:

◆ thisLabel()

Foam::label thisLabel ( const label  i) const
inline

Definition at line 162 of file faceI.H.

◆ nextLabel()

Foam::label nextLabel ( const label  i) const
inline

Definition at line 168 of file faceI.H.

Referenced by combineFaces::getOutsideFace(), boundaryCutter::setRefinement(), and tetDecomposer::setRefinement().

Here is the caller graph for this function:

◆ prevLabel()

Foam::label prevLabel ( const label  i) const
inline

Definition at line 174 of file faceI.H.

Referenced by tetDecomposer::setRefinement().

Here is the caller graph for this function:

◆ sweptVol()

Foam::scalar sweptVol ( const UList< point > &  oldPoints,
const UList< point > &  newPoints 
) const

Definition at line 652 of file face.C.

References nPoints, and Foam::constant::mathematical::pi().

Here is the call graph for this function:

◆ inertia()

Foam::tensor inertia ( const UList< point > &  p,
const point refPt = vector::zero,
scalar  density = 1.0 
) const

Definition at line 731 of file face.C.

References forAll, p, and Foam::Zero.

◆ ray()

Foam::pointHit ray ( const point p,
const vector n,
const UList< point > &  meshPoints,
const intersection::algorithm  alg = intersection::FULL_RAY,
const intersection::direction  dir = intersection::VECTOR 
) const

◆ intersection()

Foam::pointHit intersection ( const point p,
const vector q,
const point ctr,
const UList< point > &  meshPoints,
const intersection::algorithm  alg,
const scalar  tol = 0.0 
) const

◆ nearestPoint()

Foam::pointHit nearestPoint ( const point p,
const UList< point > &  meshPoints 
) const

Definition at line 193 of file faceIntersection.C.

References p.

◆ nearestPointClassify()

Foam::pointHit nearestPointClassify ( const point p,
const UList< point > &  meshPoints,
label &  nearType,
label &  nearLabel 
) const

◆ sign()

int sign ( const point p,
const UList< point > &  points,
const scalar  tol = SMALL 
) const

Definition at line 308 of file faceIntersection.C.

References p, and points.

◆ contactSphereDiameter()

Foam::scalar contactSphereDiameter ( const point p,
const vector n,
const UList< point > &  meshPoints 
) const

Definition at line 30 of file faceContactSphere.C.

References Foam::mag(), n, and p.

Here is the call graph for this function:

◆ areaInContact()

Foam::scalar areaInContact ( const UList< point > &  meshPoints,
const scalarField v 
) const

Definition at line 28 of file faceAreaInContact.C.

References forAll, face::mag(), Foam::mag(), and List::setSize().

Here is the call graph for this function:

◆ nEdges()

Foam::label nEdges ( ) const
inlinenoexcept

Definition at line 111 of file faceI.H.

◆ edge() [1/2]

Foam::edge edge ( const label  edgei) const
inline

Definition at line 118 of file faceI.H.

Referenced by Foam::checkFireEdges(), and face::faceEdge().

Here is the caller graph for this function:

◆ edge() [2/2]

Foam::vector edge ( const label  edgei,
const UList< point > &  pts 
) const
inline

Definition at line 125 of file faceI.H.

◆ rcEdge() [1/2]

Foam::edge rcEdge ( const label  edgei) const
inline

Definition at line 134 of file faceI.H.

◆ rcEdge() [2/2]

Foam::vector rcEdge ( const label  edgei,
const UList< point > &  pts 
) const
inline

Definition at line 144 of file faceI.H.

◆ edges()

Foam::edgeList edges ( ) const

Definition at line 766 of file face.C.

Referenced by Foam::polyMeshZipUpCells().

Here is the caller graph for this function:

◆ rcEdges()

Foam::edgeList rcEdges ( ) const

Definition at line 787 of file face.C.

◆ edgeDirection()

int edgeDirection ( const Foam::edge e) const

Definition at line 808 of file face.C.

References Foam::constant::electromagnetic::e, and Foam::ListOps::find().

Here is the call graph for this function:

◆ longestEdge()

Foam::label longestEdge ( const UList< point > &  pts) const

Definition at line 869 of file face.C.

References edge::mag().

Here is the call graph for this function:

◆ nTriangles() [1/2]

Foam::label nTriangles ( ) const
inline

Definition at line 180 of file faceI.H.

◆ nTriangles() [2/2]

Foam::label nTriangles ( const UList< point > &  unused) const

Definition at line 822 of file face.C.

◆ triangles() [1/3]

Foam::label triangles ( const UList< point > &  points,
label &  triI,
faceList triFaces 
) const

Definition at line 829 of file face.C.

References points, and split().

Here is the call graph for this function:

◆ triangles() [2/3]

label triangles ( const UList< point > &  points,
DynamicList< face, SizeMin > &  triFaces 
) const

◆ nTrianglesQuads()

Foam::label nTrianglesQuads ( const UList< point > &  points,
label &  nTris,
label &  nQuads 
) const

Definition at line 843 of file face.C.

References points, and split().

Here is the call graph for this function:

◆ trianglesQuads()

Foam::label trianglesQuads ( const UList< point > &  points,
label &  triI,
label &  quadI,
faceList triFaces,
faceList quadFaces 
) const

Definition at line 857 of file face.C.

References points, and split().

Here is the call graph for this function:

◆ compare()

int compare ( const face a,
const face b 
)
static

◆ sameVertices()

bool sameVertices ( const face a,
const face b 
)
static

Definition at line 375 of file face.C.

References Foam::constant::physicoChemical::b, and forAll.

Referenced by blockFace::compare().

Here is the caller graph for this function:

◆ symmhash_code() [1/2]

unsigned symmhash_code ( const UList< label > &  f,
unsigned  seed = 0 
)
static

Definition at line 415 of file face.C.

References f().

Referenced by face::symmHasher::operator()(), and face::symmhash_code().

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

◆ hash_code()

unsigned hash_code ( unsigned  seed = 0) const
inline

Definition at line 443 of file face.H.

References Foam::Hasher().

Referenced by face::hasher::operator()().

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

◆ symmhash_code() [2/2]

unsigned symmhash_code ( unsigned  seed = 0) const
inline

Definition at line 451 of file face.H.

References face::symmhash_code().

Here is the call graph for this function:

◆ faceEdge()

Foam::edge faceEdge ( label  edgei) const
inline

Definition at line 478 of file face.H.

References face::edge().

Here is the call graph for this function:

◆ triangles() [3/3]

Foam::label triangles ( const UList< point > &  points,
DynamicList< face, SizeMin > &  triFaces 
) const

Definition at line 28 of file faceTemplates.C.

References points, DynamicList::setSize(), and split().

Here is the call graph for this function:

Member Data Documentation

◆ typeName

const char *const typeName = "face"
static

Definition at line 126 of file face.H.


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