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

STARCD Class Reference

Read pro-STAR vrt/cel/bnd files. The protected data in meshReader are filled. More...

Inheritance diagram for STARCD:
Collaboration diagram for STARCD:

List of all members.


Public Member Functions

 STARCD (const fileName &prefix, const objectRegistry &, const scalar scaleFactor=1.0)
 Construct from case name.
virtual ~STARCD ()
 Destructor.

Static Public Attributes

static bool keepSolids = false
 Keep solids (default false).

Protected Types

enum  cellType {
  starcdFluidType = 1, starcdSolidType = 2, starcdBaffleType = 3, starcdShellType = 4,
  starcdLineType = 5, starcdPointType = 6
}
enum  shapeType {
  starcdPoint = 1, starcdLine = 2, starcdShell = 3, starcdHex = 11,
  starcdPrism = 12, starcdTet = 13, starcdPyr = 14, starcdPoly = 255
}

Protected Member Functions

 STARCD (const STARCD &)
 Disallow default bitwise copy construct.
void operator= (const STARCD &)
 Disallow default bitwise assignment.
virtual bool readGeometry (const scalar scaleFactor=1.0)
 Read the mesh from the file(s).
void readPoints (const fileName &, const scalar scaleFactor)
 Read points from file.
virtual void readCells (const fileName &)
 Read cell connectivities from file.
void cullPoints ()
 Remove unused points.
void readBoundary (const fileName &)
 Read boundary (cell/face) definitions.
void readAux (const objectRegistry &)
 Read auxiliary data from constant/{boundaryRegion,cellTable}.

Static Protected Member Functions

static void readToNewline (IFstream &)
 Read and discard to newline.
static bool readHeader (IFstream &, word fileSignature)
 Read header.

Protected Attributes

cellShapeList cellShapes_
 Cell shapes.
labelList mapToFoamPointId_
 Point labels (imported Point numbering not necessarily contiguous).
labelList mapToFoamCellId_
 Cell labels (imported Cell numbering not necessarily contiguous).
boundaryRegion boundaryRegion_
 Boundary region data.

Static Protected Attributes

static const char * defaultBoundaryName
static const char * defaultSolidBoundaryName
static const int starToFoamFaceAddr [4][6]
 Face addressing from pro-STAR faces -> OpenFOAM faces.

Detailed Description

Read pro-STAR vrt/cel/bnd files. The protected data in meshReader are filled.

Starting with pro-STAR version 4, the files have become easier to read.

  • vertices are space-delimited.
  • the cell format is logical.
  • trimmed and degenerate cells are saved as polyhedral.
  • the boundaries corresponds to cells and their faces.

Source files

Definition at line 57 of file STARCDMeshReader.H.


Member Enumeration Documentation

enum cellType [protected]

Enumerator:
starcdFluidType 
starcdSolidType 
starcdBaffleType 
starcdShellType 
starcdLineType 
starcdPointType 

Definition at line 120 of file STARCDMeshReader.H.

enum shapeType [protected]

Enumerator:
starcdPoint 
starcdLine 
starcdShell 
starcdHex 
starcdPrism 
starcdTet 
starcdPyr 
starcdPoly 

Definition at line 130 of file STARCDMeshReader.H.


Constructor & Destructor Documentation

STARCD ( const STARCD &   )  [protected]

Disallow default bitwise copy construct.

STARCD ( const fileName &  prefix,
const objectRegistry &  registry,
const scalar  scaleFactor = 1.0 
)

Construct from case name.

Definition at line 1052 of file STARCDMeshReader.C.

~STARCD (  )  [virtual]

Destructor.

Definition at line 1069 of file STARCDMeshReader.C.


Member Function Documentation

void operator= ( const STARCD &   )  [protected]

Disallow default bitwise assignment.

bool readGeometry ( const scalar  scaleFactor = 1.0  )  [protected, virtual]

Read the mesh from the file(s).

Implements meshReader.

Definition at line 1036 of file STARCDMeshReader.C.

void readPoints ( const fileName &  inputName,
const scalar  scaleFactor 
) [protected]

Read points from file.

original Point number for a given vertex

might need again in the future labelList origPointId(nPoints); origPointId = -1;

Definition at line 112 of file STARCDMeshReader.C.

References Foam::abort(), Foam::endl(), Foam::FatalError, FatalErrorIn, Foam::Info, STARCD::mapToFoamPointId_, Foam::max(), nPoints, meshReader::points_, STARCD::readHeader(), and y.

Here is the call graph for this function:

void cullPoints (  )  [protected]

Remove unused points.

Definition at line 976 of file STARCDMeshReader.C.

void readAux ( const objectRegistry &  registry  )  [protected]

Read auxiliary data from constant/{boundaryRegion,cellTable}.

Definition at line 91 of file STARCDMeshReader.C.

void readToNewline ( IFstream &  is  )  [static, protected]

Read and discard to newline.

Definition at line 49 of file STARCDMeshReader.C.

Referenced by STARCD::readCells().

Here is the caller graph for this function:

bool readHeader ( IFstream &  is,
word  fileSignature 
) [static, protected]

Read header.

Definition at line 60 of file STARCDMeshReader.C.

Referenced by STARCD::readBoundary(), STARCD::readCells(), and STARCD::readPoints().

Here is the caller graph for this function:


Member Data Documentation

const char * defaultBoundaryName [static, protected]

Initial value:

    "Default_Boundary_Region"

Definition at line 66 of file STARCDMeshReader.H.

Referenced by STARCD::readBoundary().

const char * defaultSolidBoundaryName [static, protected]

Initial value:

    "Default_Boundary_Solid"

Definition at line 67 of file STARCDMeshReader.H.

const int starToFoamFaceAddr [static, protected]

Initial value:

{
    { 4, 5, 2, 3, 0, 1 },     
    { 0, 1, 4, -1, 2, 3 },    
    { 3, -1, 2, -1, 1, 0 },   
    { 0, -1, 4, 2, 1, 3 }     
}
Face addressing from pro-STAR faces -> OpenFOAM faces.

Definition at line 70 of file STARCDMeshReader.H.

Referenced by STARCD::readBoundary().

Cell shapes.

Definition at line 73 of file STARCDMeshReader.H.

Referenced by STARCD::readBoundary(), and STARCD::readCells().

Point labels (imported Point numbering not necessarily contiguous).

Definition at line 76 of file STARCDMeshReader.H.

Referenced by STARCD::readCells(), and STARCD::readPoints().

Cell labels (imported Cell numbering not necessarily contiguous).

Definition at line 79 of file STARCDMeshReader.H.

Referenced by STARCD::readBoundary(), and STARCD::readCells().

Boundary region data.

Definition at line 82 of file STARCDMeshReader.H.

Referenced by STARCD::readBoundary().

bool keepSolids = false [static]

Keep solids (default false).

Definition at line 148 of file STARCDMeshReader.H.

Referenced by STARCD::readCells().


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