src/OpenFOAM logo
The Open Source CFD Toolbox
  Search
  
  Back to OpenFOAM Home
 
  OpenCFD®
  Company profile
  OpenFOAM support
  OpenFOAM development
  OpenFOAM training
  Solutions
  Contact OpenCFD
  Recruitment
  Recommended links
 
  OpenFOAM®
  Features
  Download
  Documentation
  * User Guide
  * C++ Source Guide
  * README file
  * Release notes
  * Upgrading to 1.5
 
  Our trade mark policy
 
  © 2000-2008 OpenCFD Ltd
SourceForge.net Logo
OpenCFD® Solutions Contact OpenFOAM®
OpenFOAM 1.5 User Guide © 2000-2008 OpenCFD Ltd

3.6 Standard utilities

The utilities with the OpenFOAM distribution are in the $FOAM_APP/utilities directory, reached quickly by typing util at the command line. Again the names are reasonably descriptive, e.g.magU calculates the magnitude of velocity from velocity field data, ideasToFoam converts mesh data from the format written by I-DEAS to the OpenFOAM format. The current list of utilities distributed with OpenFOAM is given in 3.6.

Pre-processing


boxTurb

Makes a box of turbulence which conforms to a given energy spectrum and is divergence free

engineSwirl

Generates a swirling flow for engine calulations

FoamX

(Description not found)

mapFields

Maps volume fields from one mesh to another, reading and interpolating all fields present in the time directory of both cases. Parallel and non-parallel cases are handled without the need to reconstruct them first

setFields

Selects a cell set through a dictionary

Mesh generation -- see 5.3


blockMesh

Mesh generator: blockOffsets_(createBlockOffsets()), mergeList_(createMergeList()), points_(createPoints()), cells_(createCells()), patches_(createPatches())

extrudeMesh

Extrude mesh from existing patch or from patch read from file

Mesh conversion -- see 5.5


ansysToFoam

Converts an ANSYS input mesh file, exported from I-DEAS, to OpenFOAM format

ccm26ToFoam

CCM mesh converter using CCM version 2.6 library

cfxToFoam

Converts a CFX mesh to OpenFOAM format

fluentMeshToFoam

Converts a Fluent mesh to OpenFOAM format including multiple region and region boundary handling

foamMeshToFluent

Writes out the OpenFOAM mesh in Fluent mesh format

gambitToFoam

Converts a GAMBIT mesh to OpenFOAM format

gmshToFoam

Reads .msh file as written by Gmsh

ideasUnvToFoam

Converts meshes from I-DEAS .unv format to OpenFOAM format

kivaToFoam

Converts a KIVA3v grid to OpenFOAM format

mshToFoam

Reads .msh format generated by the Adventure system

netgenNeutralToFoam

read Neutral file format as written by Netgen4.4

plot3dToFoam

Plot3d mesh (ascii format) converter

polyDualMesh

(Currently no description)

sammToFoam

Converts a STAR-CDSAMM mesh to OpenFOAM format

starToFoam

Converts a STAR-CDPROSTAR mesh into OpenFOAM format

tetgenToFoam

Reads .ele and .node and .face files as written by tetgen

writeMeshObj

For mesh debugging: writes mesh as three separate OBJ files which can be viewed with e.g. javaview

Mesh manipulation


attachMesh

Attach topologically detached mesh using prescribed mesh modifiers

autoPatch

Divides external faces into patches based on (user supplied) feature angle

cellSet

Selects a cell set through a dictionary

checkMesh

Checks validity of a mesh

couplePatches

Utility to reorder cyclic and processor patches

createPatch

Utility to create patches out of selected boundary faces. Faces come either from existing patches or from a faceSet

deformedGeom

Deforms a polyMesh using a displacement field U and a scaling factor supplied as an argument

faceSet

Selects a face set through a dictionary

flattenMesh

Flatten the front and back planes of a 2D Cartesian mesh

insideCells

Pick up cells with cell centre ‘inside’ of surface. Requires surface to be closed and singly connected

mergeMeshes

Merge two meshes

mirrorMesh

(Currently no description)

moveDynamicMesh

Mesh motion and topological mesh changes utility

moveEngineMesh

Solver for moving meshes for engine calculations.

moveMesh

Solver for moving meshes

objToVTK

Read obj line (not surface!) file and convert into vtk

patchTool

(Description not found)

pointSet

Selects a point set through a dictionary

refineMesh

Utility to refine cells in multiple directions. Either supply -all option to refine all cells (3D refinement for 3D cases; 2D for 2D cases) or reads a refineMeshDict with - cellSet to refine - directions to refine

renumberMesh

Renumbers the cell list in order to reduce the bandwidth, reading and renumbering all fields from all the time directories

rotateMesh

Rotates the mesh and fields from the direction n1 to the direction n2

splitMesh

Splits mesh by making internal faces external. Uses attachDetach

splitMeshRegions

Splits mesh into multiple regions and writes them to consecutive time directories. Each region is defined as a domain whose cells can all be reached by cell-face-cell walking. Uses meshWave. Could work in parallel but never tested

stitchMesh

‘Stitches’ a mesh

subsetMesh

Selects a section of mesh based on a cellSet

tetDecomposition

Takes a mesh and decomposes it into tetrahedra using a face-cell centre decomposition

transformPoints

Transforms the mesh points in the polyMesh directory according to the options:

zipUpMesh

Reads in a mesh with hanging vertices and zips up the cells to guarantee that all polyhedral cells of valid shape are closed

Post-processing graphics -- see 6


ensight76FoamExec

Module for EnSight 7.6 to read OpenFOAM data directly without translation

paraFoam

(Description not found)

Post-processing data converters -- see 6


foamDataToFluent

Translates OpenFOAM data to Fluent format

foamToEnsight

Translates OpenFOAM data to EnSight format

foamToFieldview9

Write out the OpenFOAM mesh in Version 3.0 Fieldview-UNS format (binary). See Fieldview Release 9 Reference Manual - Appendix D (Unstructured Data Format) Borrows various from uns/write_binary_uns.c from FieldView dist

foamToGMV

Translates foam output to GMV readable files. A free post-processor with available binaries from http://www-xdiv.lanl.gov/XCM/gmv/

foamToVTK

legacy VTK file format writer. - handles volScalar, volVector, pointScalar, pointVector, surfaceScalar fields. - mesh topo changes. - both ascii and binary. - single time step writing. - write subset only. - automatic decomposition of cells; polygons on boundary undecomposed since handled by vtk

smapToFoam

Translates a STAR-CD SMAP data file into OpenFOAM field format

Post-processing velocity fields


Co

Configurable graph drawing program

divU

Calculates and writes the divergence of velocity field U at each time

enstrophy

Calculates and writes the enstrophy of velocity field U at each time

flowType

Calculates and writes the flowType of velocity field U at each time

Lambda2

Calculates and writes the second largest eigenvalue of the sum of the square of the symmetrical and anti-symmetrical parts of the velocity gradient tensor, for each time

Mach

Calculates and writes the local Mach number from the velocity field U at each time

magGradU

Calculates and writes the scalar magnitude of velocity field U at each time

magU

Calculates and writes the scalar magnitude of the gradient of the velocity field U for each time

Pe

Calculates and writes the Pe number as a surfaceScalarField obtained from field phi for each time

Q

Calculates and writes the second invariant of the velocity gradient tensor for each time

streamFunction

Calculates and writes the stream function of velocity field U at each time

Ucomponents

Writes the three scalar fields, Ux, Uy and Uz, for each component of the velocity field U for each time

uprime

Calculates and writes the scalar field of uprime ( V~  ---
   2k
   3  \special {t4ht=) at each time

vorticity

Calculates and writes the vorticity of velocity field U at each time

Post-processing stress fields


R

Calculates and writes the Reynolds stress R for the current time step

Rcomponents

Calculates and writes the scalar fields of the six components of the Reynolds stress R for each time

stressComponents

Calculates and writes the scalar fields of the six components of the stress tensor sigma for each time

Post-processing at walls


checkYPlus

Calculates and reports yPlus for all wall patches, for each time in a database

wallGradU

Calculates and writes the gradient of U at the wall

wallHeatFlux

Calculates and writes the heat flux for all patches as the boundary field of a volScalarField and also prints the integrated flux for all wall patches

wallShearStress

Calculates and writes the wall shear stress for the current time step

yPlusLES

Calculates the yPlus of the near-wall cells for an LES

Post-processing at patches


patchAverage

Calculate average of fields over all patches

patchIntegrate

Integrates fields over all patches

Miscellaneous post-processing


engineCompRatio

Calculate the geometric compression ratio. Note that if you have valves and/or extra volumes it will not work, since it calculates the volume at BDC and TCD

postChannel

Post-processes data from channel flow calculations

ptot

For each time: calculate the total pressure

sample

Sample field data with a choice of interpolation schemes, sampling options and write formats

sampleSurface

Surface sampling. Runs in parallel (but does not merge points)

wdot

Calculates and writes wdot for each time

writeCellCentres

Write the three components of the cell centres as volScalarFields so they can be used in postprocessing in thresholding

Parallel processing -- see 3.4


decomposePar

Automatically decomposes a mesh and fields of a case for parallel execution of OpenFOAM

reconstructPar

Reconstructs a mesh and fields of a case that is decomposed for parallel execution of OpenFOAM

reconstructParMesh

Reconstructs a mesh using geometric information only. Writes point/face/cell procAddressing so afterwards reconstructPar can be used to reconstruct fields

Thermophysical-related utilities



adiabaticFlameT

Calculates the adiabatic flame temperature for a given fuel over a range of unburnt temperatures and equivalence ratios

chemkinToFoam

Converts CHEMKIN 3 thermodynamics and reaction data files into OpenFOAM format

equilibriumCO

Calculates the equilibrium level of carbon monoxide

equilibriumFlameT

Calculates the equilibrium flame temperature for a given fuel and pressure for a range of unburnt gas temperatures and equivalence ratios; the effects of dissociation on O2   \special {t4ht=, H2O  \special {t4ht= and CO2   \special {t4ht= are included

mixtureAdiabaticFlameT

Calculates the adiabatic flame temperature for a given mixture at a given temperature

Error estimation


estimateScalarError

Estimates the error in the solution for a scalar transport equation in the standard form

icoErrorEstimate

Estimates error for the incompressible laminar CFD application icoFoam

icoMomentError

Estimates error for the incompressible laminar CFD application icoFoam

momentScalarError

Estimates the error in the solution for a scalar transport equation in the standard form

Miscellaneous utilities


foamDebugSwitches

Write out all library debug switches

foamInfoExec

Interrogates a case and prints information to screen

Table 3.6: Standard library utilities.