Nektar++
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Classes | Typedefs | Enumerations | Functions | Variables
Nektar::Utilities Namespace Reference

Classes

struct  FieldPts
struct  Field
class  InputFld
class  InputPts
class  InputXml
struct  ConfigOption
 Represents a command-line configuration option. More...
class  Module
class  InputModule
 Abstract base class for input modules. More...
class  ProcessModule
 Abstract base class for processing modules. More...
class  OutputModule
 Abstract base class for output modules. More...
class  FieldConvertComm
class  OutputFld
 Converter from fld to vtk. More...
class  OutputInfo
class  OutputTecplot
 Converter from fld to dat. More...
class  OutputVtk
 Converter from fld to vtk. More...
class  ProcessAddFld
 This processing module scales the input fld file. More...
class  ProcessBoundaryExtract
 This processing module sets up for the boundary field to be extracted. More...
class  ProcessC0Projection
 This processing module calculates the Q Criterion and adds it as an extra-field to the output file. More...
class  ProcessConcatenateFld
 This processing module sets up for the boundary field to be extracted. More...
class  ProcessInterpField
 This processing module interpolates one field to another. More...
class  ProcessInterpPointDataToFld
 This processing module interpolates one field to another. More...
class  ProcessInterpPoints
 This processing module interpolates one field to another. More...
class  ProcessQCriterion
 This processing module calculates the Q Criterion and adds it as an extra-field to the output file. More...
class  ProcessScaleInFld
 This processing module scales the input fld file. More...
class  ProcessVorticity
 This processing module calculates the vorticity and adds it as an extra-field to the output file. More...
class  InputGmsh
struct  HOSurf
struct  HOSurfHash
class  InputNek
class  InputNekpp
class  InputPly
 Converter for Ply files. More...
class  InputSem
class  InputTec
 Converter for VTK files. More...
class  InputSwan
 Converter for Swansea mesh format. More...
class  InputVtk
 Converter for VTK files. More...
struct  TetOrient
struct  TetOrientHash
class  Node
 Represents a point in the domain. More...
struct  NodeHash
 Defines a hash function for nodes. More...
class  Edge
 Represents an edge which joins two points. More...
struct  EdgeHash
 Defines a hash function for edges. More...
class  Face
 Represents a face comprised of three or more edges. More...
struct  FaceHash
struct  ElmtConfig
 Basic information about an element. More...
class  Element
 Base class for element definitions. More...
struct  element_id_less_than
 Define element ordering based on ID. More...
class  Composite
 A composite is a collection of elements. More...
struct  Condition
 Defines a boundary condition. More...
class  Mesh
class  Point
 A 0-dimensional vertex. More...
class  Line
 A 1-dimensional line between two vertex nodes. More...
class  Triangle
 A 2-dimensional three-sided element. More...
class  Quadrilateral
 A 2-dimensional four-sided element. More...
class  Tetrahedron
 A 3-dimensional four-faced element. More...
class  Pyramid
 A 3-dimensional square-based pyramidic element. More...
class  Prism
 A 3-dimensional five-faced element (2 triangles, 3 quadrilaterals). More...
class  Hexahedron
 A 3-dimensional six-faced element. More...
struct  ElmtConfigHash
class  OutputGmsh
 Converter for Gmsh files. More...
class  OutputNekpp
 Converter for Gmsh files. More...
class  ProcessBL
 This processing module calculates the Jacobian of elements using SpatialDomains::GeomFactors and the Element::GetGeom method. For now it simply prints a list of elements which have negative Jacobian. More...
class  ProcessCyl
struct  EdgeInfo
class  ProcessDetectSurf
 This processing module calculates the Jacobian of elements using SpatialDomains::GeomFactors and the Element::GetGeom method. For now it simply prints a list of elements which have negative Jacobian. More...
class  ProcessExtractSurf
 This processing module calculates the Jacobian of elements using SpatialDomains::GeomFactors and the Element::GetGeom method. For now it simply prints a list of elements which have negative Jacobian. More...
class  ProcessJac
 This processing module calculates the Jacobian of elements using SpatialDomains::GeomFactors and the Element::GetGeom method. For now it simply prints a list of elements which have negative Jacobian. More...
class  ProcessPerAlign
class  ProcessSpherigon
class  ProcessTetSplit
 This processing module calculates the Jacobian of elements using SpatialDomains::GeomFactors and the Element::GetGeom method. For now it simply prints a list of elements which have negative Jacobian. More...

Typedefs

typedef boost::shared_ptr
< FieldPts
FieldPtsSharedPtr
typedef boost::shared_ptr< FieldFieldSharedPtr
typedef boost::shared_ptr
< InputModule
InputModuleSharedPtr
typedef pair< ModuleType, string > ModuleKey
typedef boost::shared_ptr< ModuleModuleSharedPtr
typedef
LibUtilities::NekFactory
< ModuleKey, Module,
FieldSharedPtr
ModuleFactory
typedef boost::shared_ptr< HOSurfHOSurfSharedPtr
typedef boost::unordered_set
< HOSurfSharedPtr, HOSurfHash
HOSurfSet
typedef boost::shared_ptr
< InputPly
InputPlySharedPtr
typedef boost::unordered_set
< struct TetOrient,
TetOrientHash
TetOrientSet
typedef boost::shared_ptr
< Element
ElementSharedPtr
 Shared pointer to an element.
typedef boost::shared_ptr< NodeNodeSharedPtr
 Shared pointer to a Node.
typedef boost::unordered_set
< NodeSharedPtr, NodeHash
NodeSet
typedef boost::shared_ptr< EdgeEdgeSharedPtr
 Shared pointer to an edge.
typedef boost::unordered_set
< EdgeSharedPtr, EdgeHash
EdgeSet
typedef boost::shared_ptr< FaceFaceSharedPtr
 Shared pointer to a face.
typedef boost::unordered_set
< FaceSharedPtr, FaceHash
FaceSet
typedef std::map< unsigned int,
std::vector< ElementSharedPtr > > 
ElementMap
 Container for elements; key is expansion dimension, value is vector of elements of that dimension.
typedef
Nektar::LibUtilities::NekFactory
< LibUtilities::ShapeType,
Element, ElmtConfig,
std::vector< NodeSharedPtr >
, std::vector< int > > 
ElementFactory
 Element factory definition.
typedef boost::shared_ptr
< Composite
CompositeSharedPtr
 Shared pointer to a composite.
typedef std::map< unsigned int,
CompositeSharedPtr
CompositeMap
 Container of composites; key is the composite id, value is the composite.
typedef boost::shared_ptr
< Condition
ConditionSharedPtr
typedef std::map< int,
ConditionSharedPtr
ConditionMap
typedef boost::shared_ptr< MeshMeshSharedPtr
 Shared pointer to a mesh.
typedef map< int, pair
< FaceSharedPtr, vector< int > > > 
PerMap
typedef std::pair< int, int > ipair

Enumerations

enum  PtsType { ePtsFile, ePtsLine, ePtsPlane, ePtsBlock }
enum  ModuleType {
  eInputModule, eProcessModule, eOutputModule, SIZE_ModuleType,
  eInputModule, eProcessModule, eOutputModule, SIZE_ModuleType
}
enum  NekCurve { eFile, eRecon }
enum  ConditionType {
  eDirichlet, eNeumann, eRobin, ePeriodic,
  eHOPCondition, SIZE_ConditionType
}
enum  ModuleType {
  eInputModule, eProcessModule, eOutputModule, SIZE_ModuleType,
  eInputModule, eProcessModule, eOutputModule, SIZE_ModuleType
}

Functions

ModuleFactoryGetModuleFactory ()
std::ostream & operator<< (std::ostream &os, const ModuleKey &rhs)
bool operator== (HOSurfSharedPtr const &p1, HOSurfSharedPtr const &p2)
 Compares two HOSurf objects referred to as shared pointers.
void PrismLineFaces (int prismid, map< int, int > &facelist, vector< vector< int > > &FacesToPrisms, vector< vector< int > > &PrismsToFaces, vector< bool > &PrismDone)
ElementFactoryGetElementFactory ()
bool operator== (ConditionSharedPtr const &c1, ConditionSharedPtr const &c2)
 Test equality of two conditions - i.e. compare types, fields and values but not composite ids.
bool operator== (NodeSharedPtr const &p1, NodeSharedPtr const &p2)
 Defines equality between two NodeSharedPtr objects.
bool operator< (NodeSharedPtr const &p1, NodeSharedPtr const &p2)
 Defines ordering between two NodeSharedPtr objects.
std::ostream & operator<< (std::ostream &os, const NodeSharedPtr &n)
bool operator== (EdgeSharedPtr const &p1, EdgeSharedPtr const &p2)
 Defines equality of two edges (equal if IDs of end nodes match in either ordering).
bool operator< (EdgeSharedPtr const &p1, EdgeSharedPtr const &p2)
 Defines ordering between two edges (based on ID of edges).
bool operator== (FaceSharedPtr const &p1, FaceSharedPtr const &p2)
 Defines equality of two faces (equal if IDs of vertices are the same.)
bool operator< (FaceSharedPtr const &p1, FaceSharedPtr const &p2)
 Defines ordering between two faces (depending on ID of faces).
bool operator== (const struct TetOrient &a, const struct TetOrient &b)
bool operator== (ElmtConfig const &p1, ElmtConfig const &p2)

Variables

static FieldPtsSharedPtr NullFieldPts
const char *const ModuleTypeMap []

Typedef Documentation

typedef std::map<unsigned int, CompositeSharedPtr> Nektar::Utilities::CompositeMap

Container of composites; key is the composite id, value is the composite.

Definition at line 1127 of file MeshElements.h.

Shared pointer to a composite.

Definition at line 1124 of file MeshElements.h.

Definition at line 1159 of file MeshElements.h.

Definition at line 1158 of file MeshElements.h.

typedef boost::unordered_set<EdgeSharedPtr, EdgeHash> Nektar::Utilities::EdgeSet

Definition at line 342 of file MeshElements.h.

typedef boost::shared_ptr<Edge> Nektar::Utilities::EdgeSharedPtr

Shared pointer to an edge.

Definition at line 318 of file MeshElements.h.

Element factory definition.

Definition at line 1074 of file MeshElements.h.

typedef std::map<unsigned int, std::vector<ElementSharedPtr> > Nektar::Utilities::ElementMap

Container for elements; key is expansion dimension, value is vector of elements of that dimension.

Definition at line 1071 of file MeshElements.h.

typedef boost::shared_ptr<Element> Nektar::Utilities::ElementSharedPtr

Shared pointer to an element.

Definition at line 63 of file MeshElements.h.

typedef boost::unordered_set<FaceSharedPtr, FaceHash> Nektar::Utilities::FaceSet

Definition at line 574 of file MeshElements.h.

typedef boost::shared_ptr<Face> Nektar::Utilities::FaceSharedPtr

Shared pointer to a face.

Definition at line 550 of file MeshElements.h.

typedef boost::shared_ptr<FieldPts> Nektar::Utilities::FieldPtsSharedPtr

Definition at line 167 of file Field.hpp.

typedef boost::shared_ptr<Field> Nektar::Utilities::FieldSharedPtr

Definition at line 769 of file Field.hpp.

Definition at line 105 of file InputNek.h.

typedef boost::shared_ptr<HOSurf> Nektar::Utilities::HOSurfSharedPtr

Definition at line 73 of file InputNek.h.

Definition at line 184 of file PostProcessing/FieldConvert/Module.h.

typedef boost::shared_ptr<InputPly> Nektar::Utilities::InputPlySharedPtr

Definition at line 65 of file InputPly.h.

typedef std::pair<int,int> Nektar::Utilities::ipair

Definition at line 54 of file ProcessTetSplit.cpp.

typedef boost::shared_ptr<Mesh> Nektar::Utilities::MeshSharedPtr

Shared pointer to a mesh.

Definition at line 1205 of file MeshElements.h.

Definition at line 220 of file PostProcessing/FieldConvert/Module.h.

typedef std::pair< ModuleType, std::string > Nektar::Utilities::ModuleKey

Definition at line 215 of file PostProcessing/FieldConvert/Module.h.

typedef boost::shared_ptr< Module > Nektar::Utilities::ModuleSharedPtr

Definition at line 218 of file PostProcessing/FieldConvert/Module.h.

typedef boost::unordered_set<NodeSharedPtr, NodeHash> Nektar::Utilities::NodeSet

Definition at line 218 of file MeshElements.h.

typedef boost::shared_ptr<Node> Nektar::Utilities::NodeSharedPtr

Shared pointer to a Node.

Definition at line 195 of file MeshElements.h.

typedef map<int, pair<FaceSharedPtr, vector<int> > > Nektar::Utilities::PerMap

Definition at line 67 of file PreProcessing/MeshConvert/Module.h.

typedef boost::unordered_set<struct TetOrient, TetOrientHash> Nektar::Utilities::TetOrientSet

Definition at line 1104 of file MeshElements.cpp.

Enumeration Type Documentation

Enumeration of condition types (Dirichlet, Neumann, etc).

Enumerator:
eDirichlet 
eNeumann 
eRobin 
ePeriodic 
eHOPCondition 
SIZE_ConditionType 

Definition at line 1132 of file MeshElements.h.

Denotes different types of mesh converter modules: so far only input, output and process modules are defined.

Enumerator:
eInputModule 
eProcessModule 
eOutputModule 
SIZE_ModuleType 
eInputModule 
eProcessModule 
eOutputModule 
SIZE_ModuleType 

Definition at line 53 of file PreProcessing/MeshConvert/Module.h.

Denotes different types of mesh converter modules: so far only input, output and process modules are defined.

Enumerator:
eInputModule 
eProcessModule 
eOutputModule 
SIZE_ModuleType 
eInputModule 
eProcessModule 
eOutputModule 
SIZE_ModuleType 

Definition at line 63 of file PostProcessing/FieldConvert/Module.h.

Enumerator:
eFile 
eRecon 

Definition at line 75 of file InputNek.h.

{
};
Enumerator:
ePtsFile 
ePtsLine 
ePtsPlane 
ePtsBlock 

Definition at line 65 of file Field.hpp.

Function Documentation

ElementFactory & Nektar::Utilities::GetElementFactory ( )
ModuleFactory & Nektar::Utilities::GetModuleFactory ( )

Returns an instance of the module factory, held as a singleton.

Definition at line 49 of file PostProcessing/FieldConvert/Module.cpp.

Referenced by main().

{
typedef Loki::SingletonHolder<ModuleFactory,
Loki::CreateUsingNew,
Loki::NoDestroy > Type;
return Type::Instance();
}
bool Nektar::Utilities::operator< ( NodeSharedPtr const &  p1,
NodeSharedPtr const &  p2 
)

Defines ordering between two NodeSharedPtr objects.

Definition at line 162 of file MeshElements.cpp.

{
return *p1 < *p2;
}
bool Nektar::Utilities::operator< ( EdgeSharedPtr const &  p1,
EdgeSharedPtr const &  p2 
)

Defines ordering between two edges (based on ID of edges).

Definition at line 186 of file MeshElements.cpp.

{
return p1->m_id < p2->m_id;
}
bool Nektar::Utilities::operator< ( FaceSharedPtr const &  p1,
FaceSharedPtr const &  p2 
)

Defines ordering between two faces (depending on ID of faces).

Definition at line 213 of file MeshElements.cpp.

{
return p1->m_id < p2->m_id;
}
std::ostream & Nektar::Utilities::operator<< ( std::ostream &  os,
const ModuleKey &  rhs 
)

Prints a given module key to a stream.

Definition at line 60 of file PostProcessing/FieldConvert/Module.cpp.

References ModuleTypeMap.

{
return os << ModuleTypeMap[rhs.first] << ": " << rhs.second;
}
std::ostream & Nektar::Utilities::operator<< ( std::ostream &  os,
const NodeSharedPtr &  n 
)

Definition at line 167 of file MeshElements.cpp.

{
os << n->m_x << " " << n->m_y << " " << n->m_z;
return os;
}
bool Nektar::Utilities::operator== ( ElmtConfig const &  p1,
ElmtConfig const &  p2 
)

Definition at line 60 of file OutputGmsh.h.

References Nektar::Utilities::ElmtConfig::m_e, Nektar::Utilities::ElmtConfig::m_faceNodes, Nektar::Utilities::ElmtConfig::m_order, and Nektar::Utilities::ElmtConfig::m_volumeNodes.

{
return p1.m_e == p2.m_e &&
p1.m_faceNodes == p2.m_faceNodes &&
p1.m_volumeNodes == p2.m_volumeNodes &&
p1.m_order == p2.m_order;
}
bool Nektar::Utilities::operator== ( ConditionSharedPtr const &  c1,
ConditionSharedPtr const &  c2 
)

Test equality of two conditions - i.e. compare types, fields and values but not composite ids.

Definition at line 126 of file MeshElements.cpp.

{
int i, n = c1->type.size();
if (n != c2->type.size())
{
return false;
}
for (i = 0; i < n; ++i)
{
if (c1->type[i] != c2->type[i])
{
return false;
}
if (c1->field[i] != c2->field[i] || c1->value[i] != c2->value[i])
{
return false;
}
}
return true;
}
bool Nektar::Utilities::operator== ( NodeSharedPtr const &  p1,
NodeSharedPtr const &  p2 
)

Defines equality between two NodeSharedPtr objects.

Definition at line 154 of file MeshElements.cpp.

{
return *p1 == *p2;
}
bool Nektar::Utilities::operator== ( EdgeSharedPtr const &  p1,
EdgeSharedPtr const &  p2 
)

Defines equality of two edges (equal if IDs of end nodes match in either ordering).

Definition at line 177 of file MeshElements.cpp.

{
return ( ((*(p1->m_n1) == *(p2->m_n1)) && (*(p1->m_n2) == *(p2->m_n2)))
|| ((*(p1->m_n2) == *(p2->m_n1)) && (*(p1->m_n1) == *(p2->m_n2))));
}
bool Nektar::Utilities::operator== ( FaceSharedPtr const &  p1,
FaceSharedPtr const &  p2 
)

Defines equality of two faces (equal if IDs of vertices are the same.)

Definition at line 195 of file MeshElements.cpp.

References Nektar::StdRegions::find(), and Nektar::iterator.

{
for (it1 = p1->m_vertexList.begin(); it1 != p1->m_vertexList.end(); ++it1)
{
if (find(p2->m_vertexList.begin(), p2->m_vertexList.end(), *it1)
== p2->m_vertexList.end())
{
return false;
}
}
return true;
}
bool Nektar::Utilities::operator== ( const struct TetOrient &  a,
const struct TetOrient &  b 
)

Definition at line 1106 of file MeshElements.cpp.

References Nektar::Utilities::TetOrient::nid.

{
if (a.nid.size() != b.nid.size())
{
return false;
}
for (int i = 0; i < a.nid.size(); ++i)
{
if (a.nid[i] != b.nid[i])
{
return false;
}
}
return true;
}
bool Nektar::Utilities::operator== ( HOSurfSharedPtr const &  p1,
HOSurfSharedPtr const &  p2 
)

Compares two HOSurf objects referred to as shared pointers.

Two HOSurf objects are defined to be equal if they contain identical vertex ids contained in HOSurf::vertId.

Definition at line 1108 of file InputNek.cpp.

{
if (p1->vertId.size() != p2->vertId.size())
{
return false;
}
vector<unsigned int> ids1 = p1->vertId;
vector<unsigned int> ids2 = p2->vertId;
sort(ids1.begin(), ids1.end());
sort(ids2.begin(), ids2.end());
for (int i = 0; i < ids1.size(); ++i)
{
if (ids1[i] != ids2[i])
return false;
}
return true;
}
void Nektar::Utilities::PrismLineFaces ( int  prismid,
map< int, int > &  facelist,
vector< vector< int > > &  FacesToPrisms,
vector< vector< int > > &  PrismsToFaces,
vector< bool > &  PrismDone 
)

Definition at line 647 of file InputStarTec.cpp.

Referenced by Nektar::Utilities::InputTec::ResetNodes().

{
if(PrismDone[prismid] == false)
{
PrismDone[prismid] = true;
// Add faces0
int face = PrismToFaces[prismid][0];
facelist[face] = face;
for(int i = 0; i < FaceToPrisms[face].size(); ++i)
{
PrismLineFaces(FaceToPrisms[face][i], facelist, FaceToPrisms,
PrismToFaces, PrismDone);
}
// Add faces1
face = PrismToFaces[prismid][1];
facelist[face] = face;
for(int i = 0; i < FaceToPrisms[face].size(); ++i)
{
PrismLineFaces(FaceToPrisms[face][i], facelist, FaceToPrisms,
PrismToFaces, PrismDone);
}
}
}

Variable Documentation

const char *const Nektar::Utilities::ModuleTypeMap
Initial value:
{
"Input",
"Process",
"Output"
}

Definition at line 70 of file PostProcessing/FieldConvert/Module.h.

Referenced by operator<<().

FieldPtsSharedPtr Nektar::Utilities::NullFieldPts
static