Public Member Functions | Static Public Attributes | Protected Attributes | Static Protected Attributes | Private Member Functions
meshWriter Class Referenceabstract

write OpenFOAM meshes and/or results to another CFD format More...

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

Public Member Functions

 meshWriter (const polyMesh &, const scalar scaleFactor=1.0)
 Create a writer obejct. More...
 
virtual ~meshWriter ()
 Destructor. More...
 
void scaleFactor (const scalar scaling)
 Set points scaling. More...
 
void noBoundary ()
 Suppress writing bnd file. More...
 
virtual bool write (const fileName &timeName=fileName::null) const =0
 Write volume mesh. Subclass must supply this method. More...
 

Static Public Attributes

static string defaultMeshName = "meshExport"
 Specify a default mesh name. More...
 

Protected Attributes

const polyMeshmesh_
 Mesh reference. More...
 
scalar scaleFactor_
 Scaling factor for points (eg, [m] -> [mm]) More...
 
bool writeBoundary_
 Write bnd file. More...
 
boundaryRegion boundaryRegion_
 boundaryRegion persistent data saved as a dictionary More...
 
cellTable cellTable_
 cellTable persistent data saved as a dictionary More...
 
labelList cellTableId_
 cellTable IDs for each cell More...
 

Static Protected Attributes

static const cellModelunknownModel
 Pointers to cell shape models. More...
 
static const cellModeltetModel
 
static const cellModelpyrModel
 
static const cellModelprismModel
 
static const cellModelhexModel
 

Private Member Functions

 meshWriter (const meshWriter &)
 Disallow default bitwise copy construct. More...
 
void operator= (const meshWriter &)
 Disallow default bitwise assignment. More...
 

Detailed Description

write OpenFOAM meshes and/or results to another CFD format

- currently just STAR-CD

Files

"constant/boundaryRegion" is an IOMap<dictionary> that contains the boundary type and names. eg,

        (
            0
            {
                BoundaryType    wall;
                Label           Default_Boundary_Region;
            }

            1
            {
                BoundaryType    inlet;
                Label           inlet_1;
            }

            ...

            4
            {
                BoundaryType    pressure;
                Label           outlet;
            }
        )
Source files

Definition at line 89 of file meshWriter.H.

Constructor & Destructor Documentation

◆ meshWriter() [1/2]

meshWriter ( const meshWriter )
private

Disallow default bitwise copy construct.

◆ meshWriter() [2/2]

meshWriter ( const polyMesh mesh,
const scalar  scaleFactor = 1.0 
)

Create a writer obejct.

Definition at line 71 of file meshWriter.C.

◆ ~meshWriter()

~meshWriter ( )
virtual

Destructor.

Definition at line 84 of file meshWriter.C.

Member Function Documentation

◆ operator=()

void operator= ( const meshWriter )
private

Disallow default bitwise assignment.

◆ scaleFactor()

void scaleFactor ( const scalar  scaling)
inline

Set points scaling.

Definition at line 156 of file meshWriter.H.

References meshWriter::scaleFactor_.

◆ noBoundary()

void noBoundary ( )
inline

Suppress writing bnd file.

Definition at line 162 of file meshWriter.H.

References meshWriter::writeBoundary_.

◆ write()

virtual bool write ( const fileName timeName = fileName::null) const
pure virtual

Write volume mesh. Subclass must supply this method.

Implemented in STARCD.

Field Documentation

◆ mesh_

const polyMesh& mesh_
protected

Mesh reference.

Definition at line 105 of file meshWriter.H.

Referenced by STARCD::findDefaultBoundary().

◆ scaleFactor_

scalar scaleFactor_
protected

Scaling factor for points (eg, [m] -> [mm])

Definition at line 108 of file meshWriter.H.

Referenced by meshWriter::scaleFactor().

◆ writeBoundary_

bool writeBoundary_
protected

Write bnd file.

Definition at line 111 of file meshWriter.H.

Referenced by meshWriter::noBoundary().

◆ boundaryRegion_

boundaryRegion boundaryRegion_
protected

boundaryRegion persistent data saved as a dictionary

Definition at line 114 of file meshWriter.H.

◆ cellTable_

cellTable cellTable_
protected

cellTable persistent data saved as a dictionary

Definition at line 117 of file meshWriter.H.

◆ cellTableId_

labelList cellTableId_
protected

cellTable IDs for each cell

Definition at line 120 of file meshWriter.H.

◆ unknownModel

const Foam::cellModel * unknownModel
staticprotected
Initial value:
(
"unknown"
)

Pointers to cell shape models.

Definition at line 123 of file meshWriter.H.

◆ tetModel

const Foam::cellModel * tetModel
staticprotected
Initial value:

Definition at line 124 of file meshWriter.H.

◆ pyrModel

const Foam::cellModel * pyrModel
staticprotected
Initial value:

Definition at line 125 of file meshWriter.H.

◆ prismModel

const Foam::cellModel * prismModel
staticprotected
Initial value:

Definition at line 126 of file meshWriter.H.

◆ hexModel

const Foam::cellModel * hexModel
staticprotected
Initial value:

Definition at line 127 of file meshWriter.H.

◆ defaultMeshName

Foam::string defaultMeshName = "meshExport"
static

Specify a default mesh name.

Definition at line 135 of file meshWriter.H.

Referenced by STARCD::write().


The documentation for this class was generated from the following files:
Foam::cellModeller::lookup
static const cellModel * lookup(const word &)
Look up a model by name and return a pointer to the model or NULL.
Definition: cellModeller.C:91