Main Page   Class Hierarchy   Alphabetical List   Compound List   Compound Members   Related Pages  

vtkPLOT3DReader Class Reference

read PLOT3D data files. More...

#include <vtkPLOT3DReader.h>

Inheritance diagram for vtkPLOT3DReader:

Inheritance graph
[legend]
Collaboration diagram for vtkPLOT3DReader:

Collaboration graph
[legend]
List of all members.

Public Methods

virtual const char * GetClassName ()
virtual int IsA (const char *type)
void PrintSelf (ostream &os, vtkIndent indent)
virtual void SetFileFormat (int)
virtual int GetFileFormat ()
virtual void SetXYZFileName (const char *)
virtual char * GetXYZFileName ()
virtual void SetQFileName (const char *)
virtual char * GetQFileName ()
virtual void SetFunctionFileName (const char *)
virtual char * GetFunctionFileName ()
virtual void SetVectorFunctionFileName (const char *)
virtual char * GetVectorFunctionFileName ()
virtual void SetGridNumber (int)
virtual int GetGridNumber ()
virtual void SetScalarFunctionNumber (int)
virtual int GetScalarFunctionNumber ()
virtual void SetVectorFunctionNumber (int)
virtual int GetVectorFunctionNumber ()
virtual float GetFsmach ()
virtual float GetAlpha ()
virtual float GetRe ()
virtual float GetTime ()
virtual void SetR (float)
virtual float GetR ()
virtual void SetGamma (float)
virtual float GetGamma ()
virtual void SetUvinf (float)
virtual float GetUvinf ()
virtual void SetVvinf (float)
virtual float GetVvinf ()
virtual void SetWvinf (float)
virtual float GetWvinf ()
virtual int GetNumberOfGrids ()

Static Public Methods

vtkPLOT3DReader * New ()
int IsTypeOf (const char *type)
vtkPLOT3DReader * SafeDownCast (vtkObject *o)

Protected Methods

 vtkPLOT3DReader ()
 ~vtkPLOT3DReader ()
 vtkPLOT3DReader (const vtkPLOT3DReader &)
void operator= (const vtkPLOT3DReader &)
void ExecuteInformation ()
void Execute ()
int GetFileType (FILE *fp)
void MapFunction (int fNumber, vtkPointData *outputPD)
int ReadBinaryGrid (FILE *fp, vtkStructuredGrid *output)
int ReadBinaryGridDimensions (FILE *fp, vtkStructuredGrid *output)
int ReadBinarySolution (FILE *fp, vtkStructuredGrid *output)
int ReadBinaryFunctionFile (FILE *fp, vtkStructuredGrid *output)
int ReadBinaryVectorFunctionFile (FILE *fp, vtkStructuredGrid *output)
void ComputeDensity (vtkPointData *outputPD)
void ComputePressure (vtkPointData *outputPD)
void ComputeTemperature (vtkPointData *outputPD)
void ComputeEnthalpy (vtkPointData *outputPD)
void ComputeInternalEnergy (vtkPointData *outputPD)
void ComputeKineticEnergy (vtkPointData *outputPD)
void ComputeVelocityMagnitude (vtkPointData *outputPD)
void ComputeStagnationEnergy (vtkPointData *outputPD)
void ComputeEntropy (vtkPointData *outputPD)
void ComputeSwirl (vtkPointData *outputPD)
void ComputeVelocity (vtkPointData *outputPD)
void ComputeVorticity (vtkPointData *outputPD)
void ComputeMomentum (vtkPointData *outputPD)
void ComputePressureGradient (vtkPointData *outputPD)

Protected Attributes

int FileFormat
char * XYZFileName
char * QFileName
char * FunctionFileName
char * VectorFunctionFileName
int GridNumber
int ScalarFunctionNumber
int VectorFunctionNumber
int FunctionFileFunctionNumber
float * TempStorage
int NumberOfPoints
int NumberOfGrids
float Fsmach
float Alpha
float Re
float Time
float R
float Gamma
float Uvinf
float Vvinf
float Wvinf
vtkPointsGrid
vtkScalarsDensity
vtkScalarsEnergy
vtkVectorsMomentum

Detailed Description

read PLOT3D data files.

Date:
2000/12/10 20:08:46
Revision:
1.41

vtkPLOT3DReader is a reader object that reads PLOT3D formatted files and generates a structured grid on output. PLOT3D is a computer graphics program designed to visualize the grids and solutions of computational fluid dynamics. Please see the "PLOT3D User's Manual" available from NASA Ames Research Center, Moffett Field CA.

PLOT3D files consist of a grid file (also known as XYZ file), an optional solution file (also known as a Q file), and an optional function file that contains user created data. The Q file contains solution information as follows: the four parameters free stream mach number (Fsmach), angle of attack (Alpha), Reynolds number (Re), and total integration time (Time). In addition, the solution file contains the flow density (scalar), flow momentum (vector), and flow energy (scalar).

The reader can generate additional scalars and vectors (or "functions") from this information. To use vtkPLOT3DReader, you must specify the particular function number for the scalar and vector you want to visualize. This implementation of the reader provides the following functions. The scalar functions are: -1 - don't read or compute any scalars 100 - density 110 - pressure 120 - temperature 130 - enthalpy 140 - internal energy 144 - kinetic energy 153 - velocity magnitude 163 - stagnation energy 170 - entropy 184 - swirl.

The vector functions are: -1 - don't read or compute any vectors 200 - velocity 201 - vorticity 202 - momentum 210 - pressure gradient.

(Other functions are described in the PLOT3D spec, but only those listed are implemented here.) Note that by default, this reader creates the density scalar (100) and momentum vector (202) as output. (These are just read in from the solution file.) Please note that the validity of computation is a function of this class's gas constants (R, Gamma) and the equations used. They may not be suitable for your computational domain.

The format of the function file is as follows. An integer indicating number of grids, then an integer specifying number of functions per each grid. This is followed by the (integer) dimensions of each grid in the file. Finally, for each grid, and for each function, a float value per each point in the current grid. Note: if both a function from the function file is specified, as well as a scalar from the solution file (or derived from the solution file), the function file takes precedence.

Examples:
vtkPLOT3DReader (examples)


Member Function Documentation

virtual float vtkPLOT3DReader::GetAlpha   [virtual]
 

Get the angle of attack.

virtual const char* vtkPLOT3DReader::GetClassName   [virtual]
 

Return the class name as a string. This method is defined in all subclasses of vtkObject with the vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkStructuredGridSource.

virtual float vtkPLOT3DReader::GetFsmach   [virtual]
 

Get the free-stream mach number.

virtual int vtkPLOT3DReader::GetNumberOfGrids   [virtual]
 

Get the number of grids. This is valid only after a read has been performed.

virtual float vtkPLOT3DReader::GetRe   [virtual]
 

Get the Reynold's number.

virtual float vtkPLOT3DReader::GetTime   [virtual]
 

Get the total integration time.

virtual int vtkPLOT3DReader::IsA const char *    type [virtual]
 

Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkStructuredGridSource.

int vtkPLOT3DReader::IsTypeOf const char *    type [static]
 

Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkStructuredGridSource.

vtkPLOT3DReader* vtkPLOT3DReader::New   [static]
 

Instantiate object with no start, end, or progress methods.

Reimplemented from vtkStructuredGridSource.

void vtkPLOT3DReader::PrintSelf ostream &    os,
vtkIndent    indent
[virtual]
 

Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from vtkSource.

vtkPLOT3DReader* vtkPLOT3DReader::SafeDownCast vtkObject   o [static]
 

Will cast the supplied object to vtkObject* is this is a safe operation (i.e., a safe downcast); otherwise NULL is returned. This method is defined in all subclasses of vtkObject with the vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkStructuredGridSource.

virtual void vtkPLOT3DReader::SetFileFormat int    [virtual]
 

Specify the PLOT3D file format to use

virtual void vtkPLOT3DReader::SetFunctionFileName const char *    [virtual]
 

Set/Get the PLOT3D function FileName.

virtual void vtkPLOT3DReader::SetGamma float    [virtual]
 

Set/Get the ratio of specific heats.

virtual void vtkPLOT3DReader::SetGridNumber int    [virtual]
 

Specify the grid to read.

virtual void vtkPLOT3DReader::SetQFileName const char *    [virtual]
 

Set/Get the PLOT3D solution FileName.

virtual void vtkPLOT3DReader::SetR float    [virtual]
 

Set/Get the gas constant.

virtual void vtkPLOT3DReader::SetScalarFunctionNumber int    [virtual]
 

Specify the scalar function to extract. If ==(-1), then no scalar function is extracted.

virtual void vtkPLOT3DReader::SetUvinf float    [virtual]
 

Set/Get the x-component of the free-stream velocity.

virtual void vtkPLOT3DReader::SetVectorFunctionFileName const char *    [virtual]
 

Set/Get the PLOT3D vector FileName.

virtual void vtkPLOT3DReader::SetVectorFunctionNumber int    [virtual]
 

Specify the vector function to extract. If ==(-1), then no vector function is extracted.

virtual void vtkPLOT3DReader::SetVvinf float    [virtual]
 

Set/Get the y-component of the free-stream velocity.

virtual void vtkPLOT3DReader::SetWvinf float    [virtual]
 

Set/Get the z-component of the free-stream velocity.

virtual void vtkPLOT3DReader::SetXYZFileName const char *    [virtual]
 

Set/Get the PLOT3D geometry FileName.


The documentation for this class was generated from the following file:
Generated on Tue Mar 19 13:30:56 2002 for VTK by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002