functionObjects リスト2016年12月10日 | |
はじめにfunctionObjects リストの表示について。 使用バージョンOpenFOAM 4.x (blueCFD) モデルリストOpenFOAM に用意されている functionObjects とその説明のリストが必要な場合がある。各 functionObjects の説明はソースコードのコメントの Discription に書かれているので、それを並べられればよい。以下のようなスクリプトでリストが得られる (抜けや余分なものがあるかも)。 show_functionObjects
#!/bin/sh
COUNT=0
cd $FOAM_SRC
for OBJECTS_PATH in `find functionObjects | sort -f | grep -v lnInclude | grep "\.H$" | xargs -I {} dirname {} | sed -e "s%^./%%" | uniq` ; do
FILES=$OBJECTS_PATH/`basename $OBJECTS_PATH`*.H
for FILE in $FILES ; do
if [ -f $FILE ] ; then
echo $OBJECTS_PATH
echo
cat $OBJECTS_PATH/*.H | awk '
/\\\*/ {exit}
/SourceFiles/ {exit}
a == 1 {print}
/Description/ {a = 1}
'
echo
echo
COUNT=`expr $COUNT + 1`
break
fi
done
done
echo Total $COUNT
実行結果
functionObjects/field/blendingFactor
This function object calculates and outputs the blendingFactor as used by
the bended convection schemes. The output is a volume field (cells) whose
value is calculated via the maximum blending factor for any cell face.
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/components
This function object calculates the components of a field.
The operation can be applied to any volume or surface fields generating a
volume or surface scalar fields for each component.
See also
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/CourantNo
This function object calculates and outputs the Courant number as a
volScalarField. The field is stored on the mesh database so that it can
be retrieved and used for other applications.
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/div
This function object calculates the divergence of a field. The operation is
limited to surfaceScalarFields and volVectorFields, and the output is a
volScalarField.
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/enstrophy
This function object calculates the enstrophy of the velocity.
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/fieldAverage
This function object calculates average quantities for a user-specified
selection of volumetric and surface fields. Fields are entered as a list
of sub-dictionaries, which indicate the type of averages to perform, and
can be updated during the calculation. The current options include:
- \c mean: arithmetic mean:
\f[
\overline{x} = \frac{1}{N}\displaystyle\sum\limits_{i=0}^N x_i
\f]
- \c prime2Mean: prime-squared mean
\f[
\overline{x'}^2 = \frac{1}{N}\displaystyle\sum\limits_{i=0}^N
(x_i - \overline{x})^2
\f]
- base: average over 'time', or 'iteration' (\f$N\f$ in the above)
- window: optional averaging window, specified in 'base' units
Average field names are constructed by concatenating the base field with
the averaging type, e.g. when averaging field 'U', the resultant fields
are:
- arithmetic mean field, UMean
- prime-squared field, UPrime2Mean
Information regarding the number of averaging steps, and total averaging
time are written on a per-field basis to the
\c "<functionObject name>Properties" dictionary, located in \<time\>/uniform
When restarting form a previous calculation, the averaging is continuous or
may be restarted using the \c restartOnRestart option.
The averaging process may be restarted after each calculation output time
using the \c restartOnOutput option or restarted periodically using the \c
periodicRestart option and setting \c restartPeriod to the required
averaging period.
Example of function object specification:
\verbatim
fieldAverage1
{
type fieldAverage;
libs ("libfieldFunctionObjects.so");
...
restartOnRestart false;
restartOnOutput false;
periodicRestart false;
restartPeriod 0.002;
fields
(
U
{
mean on;
prime2Mean on;
base time;
window 10.0;
windowName w1;
}
p
{
mean on;
prime2Mean on;
base time;
}
);
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: fieldAverage | yes |
restartOnRestart | Restart the averaging on restart | no | no
restartOnOutput | Restart the averaging on output | no | no
periodicRestart | Periodically restart the averaging | no | no
restartPeriod | Periodic restart period | conditional |
fields | list of fields and averaging options | yes |
\endtable
Note
To employ the \c prime2Mean option, the \c mean option must be selecetd.
See also
Foam::functionObjects::fvMeshFunctionObject
Foam::functionObject
functionObjects/field/fieldAverage/fieldAverageItem
Helper class to describe what form of averaging to apply. A set will be
applied to each base field in Foam::fieldAverage, of the form:
\verbatim
{
mean on;
prime2Mean on;
base time; // iteration
window 200; // optional averaging window
windowName w1; // optional window name (default = "")
}
\endverbatim
The averaging window corresponds to the averaging interval (iters or time)
If not specified, the averaging is over 'all iters/time'
functionObjects/field/fieldCoordinateSystemTransform
This function object transforms a user-specified selection of fields from
global Cartesian co-ordinates to a local co-ordinate system. The fields
are run-time modifiable.
Example of function object specification:
\verbatim
fieldCoordinateSystemTransform1
{
type fieldCoordinateSystemTransform;
libs ("libfieldFunctionObjects.so");
...
fields
(
U
UMean
UPrime2Mean
);
coordinateSystem
{
origin (0.001 0 0);
e1 (1 0.15 0);
e3 (0 0 -1);
}
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: fieldCoordinateSystemTransform | yes |
fields | list of fields to be transformed |yes |
coordinateSystem | local co-ordinate system | yes |
\endtable
See also
Foam::functionObjects::fvMeshFunctionObject
Foam::coordinateSystem
functionObjects/field/fieldExpression
See also
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/fieldMinMax
This function object calculates the value and location of scalar minimim
and maximum for a list of user-specified fields. For variables with a rank
greater than zero, either the min/max of a component value or the magnitude
is reported. When operating in parallel, the processor owning the value
is also given.
Example of function object specification:
\verbatim
fieldMinMax1
{
type fieldMinMax;
libs ("libfieldFunctionObjects.so");
...
write yes;
log yes;
location yes;
mode magnitude;
fields
(
U
p
);
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: fieldMinMax | yes |
write | write min/max data to file | no | yes
log | write min/max data to standard output | no | no
location | write location of the min/max value | no | yes
mode | calculation mode: magnitude or component | no | magnitude
\endtable
Output data is written to the file \<timeDir\>/fieldMinMax.dat
See also
Foam::functionObject
Foam::functionObjects::writeFiles
functionObjects/field/fieldValues/fieldValue
Base class for field value -based function objects.
functionObjects/field/fieldValues/fieldValueDelta
This function object provides a differencing option between two 'field
value' function objects.
Example of function object specification:
\verbatim
fieldValueDelta1
{
type fieldValueDelta;
libs ("libfieldFunctionObjects.so");
operation subtract;
fieldValue1
{
...
}
fieldValue2
{
...
}
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: fieldValueDelta | yes |
\endtable
The \c operation is one of:
\plaintable
add | add
subtract | subtract
min | minimum
max | maximum
average | average
\endplaintable
See also
Foam::fieldValue
functionObjects/field/fieldValues/surfaceRegion
This function object provides a 'face regionType' variant of the fieldValues
function object. Given a list of user-specified fields and a selection
of mesh (or general surface) faces, a number of operations can be
performed, such as sums, averages and integrations.
For example, to calculate the volumetric or mass flux across a patch,
apply the 'sum' operator to the flux field (typically \c phi)
Example of function object specification:
\verbatim
surfaceRegion1
{
type surfaceRegion;
libs ("libfieldFunctionObjects.so");
...
log yes;
writeFields true;
surfaceFormat none;
regionType faceZone;
name f0;
operation sum;
weightField alpha1;
fields
(
p
phi
U
);
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: surfaceRegion | yes |
log | write data to standard output | no | no
writeFields | Write the region field values | yes |
writeArea | Write the area of the surfaceRegion | no |
surfaceFormat | output value format | no |
regionType | face regionType: see below | yes |
name | name of face regionType if required | no |
operation | operation to perform | yes |
weightField | name of field to apply weighting | no |
orientedWeightField | name of oriented field to apply weighting | no |
scaleFactor | scale factor | no | 1
fields | list of fields to operate on | yes |
orientedFields | list of oriented fields to operate on | no |
\endtable
Where \c regionType is defined by
\plaintable
faceZone | requires a 'name' entry to specify the faceZone
patch | requires a 'name' entry to specify the patch
sampledSurface | requires a 'sampledSurfaceDict' sub-dictionary
\endplaintable
The \c operation is one of:
\plaintable
none | no operation
sum | sum
sumMag | sum of component magnitudes
sumDirection | sum values which are positive in given direction
sumDirectionBalance | sum of balance of values in given direction
average | ensemble average
weightedAverage | weighted average
areaAverage | area weighted average
weightedAreaAverage | weighted area average
areaIntegrate | area integral
min | minimum
max | maximum
CoV | coefficient of variation: standard deviation/mean
areaNormalAverage| area weighted average in face normal direction
areaNormalIntegrate | area weighted integral in face normal directon
\endplaintable
Note
- The values reported by the areaNormalAverage and areaNormalIntegrate
operations are written as the first component of a field with the same
rank as the input field.
- faces on empty patches get ignored
- if the field is a volField the \c faceZone can only consist of boundary
faces
- the `oriented' entries relate to mesh-oriented fields, such as the
flux, phi. These fields will be oriented according to the face normals.
- using \c sampledSurfaces:
- not available for surface fields
- if interpolate=true they use \c interpolationCellPoint
otherwise they use cell values
- each triangle in \c sampledSurface is logically only in one cell
so interpolation will be wrong when triangles are larger than
cells. This can only happen for sampling on a \c triSurfaceMesh
- take care when using isoSurfaces - these might have duplicate
triangles and so integration might be wrong
See also
Foam::fieldValues
Foam::functionObject
functionObjects/field/fieldValues/volRegion
This function object provides a 'cell region' variant of the fieldValues
function object. Given a list of user-specified fields and a selection
of mesh cells, a number of operations can be performed, such as sums,
averages and integrations.
Example of function object specification:
\verbatim
volRegion1
{
type volRegion;
libs ("libfieldFunctionObjects.so");
...
log true;
writeFields true;
regionType cellZone;
name c0;
operation volAverage;
weightField alpha1;
fields
(
p
U
);
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | Type name: volRegion | yes |
log | Write data to standard output | no | no
writeFields | Write the region field values | yes |
writeVolume | Write the volume of the volRegion | no |
regionType | cell regionType: see below | yes |
name | name of cell regionType if required | no |
operation | operation to perform | yes |
weightField | name of field to apply weighting | no |
fields | list of fields to operate on | yes |
\endtable
Where \c regionType is defined by
\plaintable
cellZone | requires a 'name' entry to specify the cellZone
all | all cells
\endplaintable
The \c operation is one of:
\plaintable
none | no operation
sum | sum
sumMag | sum of component magnitudes
average | ensemble average
weightedAverage | weighted average
volAverage | volume weighted average
weightedVolAverage | weighted volume average
volIntegrate | volume integral
min | minimum
max | maximum
CoV | coefficient of variation: standard deviation/mean
\endplaintable
See also
Foam::fieldValues
Foam::functionObject
functionObjects/field/flowType
This function object calculates and writes the flowType of a velocity field.
The flow type parameter is obtained according to the following equation:
\verbatim
|D| - |Omega|
lambda = -------------
|D| + |Omega|
-1 = rotational flow
0 = simple shear flow
1 = planar extensional flow
\endverbatim
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/grad
This function object calculates the gradient of a field. The operation is
limited to scalar and vector volume or surface fields, and the output is a
volume vector or tensor field.
See also
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/histogram
Write the volume-weighted histogram of a volScalarField.
Example:
\verbatim
histogram1
{
type histogram;
libs ("libfieldFunctionObjects.so");
field p;
nBins 100;
min -5;
max 5;
setFormat gnuplot;
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: histogram | yes |
field | Field to analyse | yes |
nBins | Number of bins for the histogram | yes|
max | Maximum value sampled | yes |
min | minimum value sampled | no | 0
setFormat | Output format | yes |
\endtable
See also
Foam::functionObject
Foam::functionObjects::writeFile
functionObjects/field/Lambda2
This function object calculates and outputs the second largest eigenvalue
of the sum of the square of the symmetrical and anti-symmetrical parts of
the velocity gradient tensor.
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/MachNo
This function object calculates and writes the Mach number as a
volScalarField.
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/mag
This function object calculates the magnitude of a field.
The operation can be applied to any volume or surface fields generating a
volume or surface scalar field.
See also
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/magSqr
This function object calculates the magnitude of the sqr of a field.
The operation can be applied to any volume or surface field generating a
volume or surface scalar field.
See also
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/nearWallFields
Particle class that finds cells by tracking
functionObjects/field/PecletNo
This function object calculates and outputs the Peclet number as a
surfaceScalarField.
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/pressure
This function object includes tools to manipulate the pressure into
different forms. These currently include:
- static pressure
\f[
p = \rho p_k
\f]
- total pressure
\f[
p_0 = p_{ref} + p + 0.5 \rho |U|^2
\f]
- static pressure coefficient
\f[
Cp = \frac{p - p_{\inf}}{0.5 \rho_{\inf} |U_{\inf}|^2}
\f]
- total pressure coefficient
\f[
Cp_0 = \frac{p_0 - p_{\inf}}{0.5 \rho_{\inf} |U_{\inf}|^2}
\f]
where
\vartable
\rho | Density [kg/m3]
U | Velocity [m/s]
\rho_{\inf} | Freestream density [kg/m3]
p_{\inf} | Freestream pressure [Pa]
U_{\inf} | Freestream velocity [m/s]
p_k | Kinematic pressure (p/rho)[m2/s2]
p | Pressure [Pa]
p_0 | Total pressure [Pa]
p_{ref} | Reference pressure level [Pa]
Cp | Pressure coefficient
Cp_0 | Total pressure coefficient
\endvartable
The function object will operate on both kinematic (\f$ p_k \f$) and static
pressure (\f$ p \f$) fields, and the result is written as a
volScalarField.
The modes of operation are:
\table
Mode | calcTotal | calcCoeff
Static pressure | no | no
Total pressure | yes | no
Pressure coefficient | no | yes
Total pressure coefficient | yes | yes
\endtable
Example of function object specification to calculate pressure coefficient:
\verbatim
pressure1
{
type pressure;
libs ("libfieldFunctionObjects.so");
...
calcTotal no;
calcCoeff yes;
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: pressure | yes |
field | Name of the pressure field | no | p
U | Name of the velocity field | no | U
rho | Name of the density field | no | rho
result | Name of the resulting field | no | derived from p
calcTotal | Calculate total coefficient | yes |
pRef | Reference pressure for total pressure | no | 0
calcCoeff | Calculate pressure coefficient | yes |
pInf | Freestream pressure for coefficient calculation | no |
UInf | Freestream velocity for coefficient calculation | no |
rhoInf | Freestream density for coefficient calculation | no |
\endtable
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/processorField
This function object writes a scalar field whose value is the local
processor ID. The output field name is 'processorID'.
Example of function object specification:
\verbatim
processorField1
{
type processorField;
libs ("libfieldFunctionObjects.so");
...
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: processorField | yes |
\endtable
See also
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/Q
This function object calculates and outputs the second invariant of the
velocity gradient tensor [1/s^2].
\f[
Q = 0.5(sqr(tr(\nabla U)) - tr(((\nabla U) \cdot (\nabla U))))
\f]
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/randomise
This function object adds a random component to a field,
with a specified perturbation magnitude.
The operation can be applied to any volume field.
See also
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/readFields
This function object reads fields from the time directories and adds them to
the mesh database for further post-processing.
Example of function object specification:
\verbatim
readFields1
{
type readFields;
libs ("libfieldFunctionObjects.so");
...
fields
(
U
p
);
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: readFields | yes |
fields | list of fields to read | no |
\endtable
See also
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/regionSizeDistribution
This function object creates a size distribution via interrogating a
continuous phase fraction field.
Looks up a phase-fraction (alpha) field and splits the mesh into regions
based on where the field is below the threshold value. These
regions ("droplets") can now be analysed.
Regions:
- print the regions connected to a user-defined set of patches.
(in spray calculation these form the liquid core)
- print the regions with too large volume. These are the 'background'
regions.
- (debug) write regions as a volScalarField
- (debug) print for all regions the sum of volume and alpha*volume
Output (volume scalar) fields include:
- alpha_liquidCore : alpha with outside liquid core set to 0
- alpha_background : alpha with outside background set to 0.
%Histogram:
- determine histogram of diameter (given minDiameter, maxDiameter, nBins)
- write graph of number of droplets per bin
- write graph of sum, average and deviation of droplet volume per bin
- write graph of sum, average and deviation of user-defined fields. For
volVectorFields these are those of the 3 components and the magnitude.
Example of function object specification:
\verbatim
regionSizeDistribution1
{
type regionSizeDistribution;
libs ("libfieldFunctionObjects.so");
...
field alpha;
patches (inlet);
threshold 0.4;
fields (p U);
nBins 100;
maxDiameter 0.5e-4;
minDiameter 0;
setFormat gnuplot;
coordinateSystem
{
type cartesian;
origin (0 0 0);
e3 (0 1 1);
e1 (1 0 0);
}
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: regionSizeDistribution |yes|
field | phase field to interrogate | yes |
patches | patches from which the liquid core is identified | yes|
threshold | phase fraction applied to delimit regions | yes |
fields | fields to sample | yes |
nBins | number of bins for histogram | yes |
maxDiameter | maximum region equivalent diameter | yes |
minDiameter | minimum region equivalent diameter | no | 0
setFormat | writing format | yes |
coordinateSystem | transformation for vector fields | no |
\endtable
See also
Foam::functionObject
Foam::functionObjects::writeFile
functionObjects/field/streamLine
This function object generates streamline data by sampling a set of
user-specified fields along a particle track, transported by a
user-specified velocity field.
Example of function object specification:
\verbatim
streamLine1
{
type streamLine;
libs ("libfieldFunctionObjects.so");
...
setFormat vtk;
trackForward yes;
fields
(
U
p
);
lifeTime 10000;
trackLength 1e-3;
nSubCycle 5;
cloudName particleTracks;
seedSampleSet uniform;
uniformCoeffs
{
type uniform;
axis x; //distance;
start (-0.0205 0.0001 0.00001);
end (-0.0205 0.0005 0.00001);
nPoints 100;
}
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | Type name: streamLine | yes |
setFormat | Output data type | yes |
U | Tracking velocity field name | yes |
fields | Fields to sample | yes |
lifetime | Maximum number of particle tracking steps | yes |
trackLength | Tracking segment length | no |
nSubCycle | Number of tracking steps per cell | no|
cloudName | Cloud name to use | yes |
seedSampleSet| Seeding method (see below)| yes |
\endtable
Where \c seedSampleSet is typically one of
\plaintable
uniform | uniform particle seeding
cloud | cloud of points
triSurfaceMeshPointSet | points according to a tri-surface mesh
\endplaintable
Note
When specifying the track resolution, the \c trackLength OR \c nSubCycle
option should be used
See also
Foam::functionObject
Foam::functionObjects::timeControl
Foam::sampledSet
Foam::wallBoundedStreamLine
functionObjects/field/surfaceInterpolate
This function object linearly interpolates volume fields to generate
surface fields
Fields are stored
- every time step the field is updated with new values
- at output it writes the fields
This functionObject can either be used
- to calculate a new field as a post-processing step or
- since the fields are registered, used in another functionObject
Example of function object specification:
\verbatim
surfaceInterpolate1
{
type surfaceInterpolate;
libs ("libfieldFunctionObjects.so");
...
fields ((p pNear)(U UNear));
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: nearWallFields | yes |
fields | list of fields with correspoding output field names | yes |
\endtable
See also
Foam::functionObjects::fvMeshFunctionObject
Foam::functionObjects::timeControl
functionObjects/field/turbulenceFields
This function object stores turbulence fields on the mesh database for
further manipulation.
Fields are stored as copies of the original, with the prefix
"tubulenceModel:", e.g.:
\verbatim
turbulenceModel:R
\endverbatim
Example of function object specification:
\verbatim
turbulenceFields1
{
type turbulenceFields;
libs ("libfieldFunctionObjects.so");
...
fields
(
R
devRhoReff
);
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: processorField | yes |
fields | fields to store (see below) | yes |
\endtable
Where \c fields can include:
\plaintable
k | turbulence kinetic energy
epsilon | turbulence kinetic energy dissipation rate
omega | turbulence specific dissipation rate
nut | turbulence viscosity (incompressible)
nuEff | effective turbulence viscosity (incompressible)
mut | turbulence viscosity (compressible)
muEff | effective turbulence viscosity (compressible)
alphat | turbulence thermal diffusivity (compressible)
alphaEff | effective turbulence thermal diffusivity (compressible)
R | Reynolds stress tensor
devReff | Deviatoric part of the effective Reynolds stress
devRhoReff | Divergence of the Reynolds stress
\endplaintable
See also
Foam::functionObjects::fvMeshFunctionObject
Foam::functionObjects::timeControl
functionObjects/field/vorticity
This function object calculates the vorticity, the curl of the velocity.
See also
Foam::functionObjects::fieldExpression
Foam::functionObjects::fvMeshFunctionObject
functionObjects/field/wallBoundedStreamLine
Particle class that tracks on triangles of boundary faces. Use
trackToEdge similar to trackToFace on particle.
functionObjects/field/wallShearStress
This function object evaluates and outputs the shear stress at wall
patches. The result is written as a volVectorField to time directories as
field 'wallShearStress'
\f[
Stress = R \dot n
\f]
where
\vartable
R | stress tensor
n | patch normal vector (into the domain)
\endvartable
The shear stress (symmetrical) tensor field is retrieved from the
turbulence model. All wall patches are included by default; to restrict
the calculation to certain patches, use the optional 'patches' entry.
Example of function object specification:
\verbatim
wallShearStress1
{
type wallShearStress;
libs ("libfieldFunctionObjects.so");
...
patches (".*Wall");
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: wallShearStress | yes |
patches | list of patches to process | no | all wall patches
\endtable
See also
Foam::functionObject
Foam::functionObjects::writeFiles
Foam::functionObjects::pressureTools
Foam::functionObjects::timeControl
functionObjects/field/yPlus
Evaluates and outputs turbulence y+ for models. Values written to
time directories as field 'yPlus'
See also
Foam::functionObject
Foam::functionObjects::writeFiles
Foam::functionObjects::timeControl
functionObjects/forces/forceCoeffs
This function object extends the Foam::forces function object by providing
lift, drag and moment coefficients. The data can optionally be output into
bins, defined in a given direction.
Example of function object specification:
\verbatim
forceCoeffs1
{
type forceCoeffs;
libs ("libforces.so");
...
log yes;
patches (walls);
liftDir (0 1 0);
dragDir (-1 0 0);
pitchAxis (0 0 1);
magUInf 100;
lRef 3.5;
Aref 2.2;
binData
{
nBin 20;
direction (1 0 0);
cumulative yes;
}
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: forces | yes |
log | write force data to standard output | no | no
patches | patches included in the forces calculation | yes |
liftDir | lift direction | yes |
dragDir | drag direction | yes |
pitchAxis | picth axis | yes |
magUInf | free stream velocity magnitude | yes |
lRef | reference length scale for moment calculations | yes |
Aref | reference area | yes |
\endtable
Bin data is optional, but if the dictionary is present, the entries must
be defined according o
\table
nBin | number of data bins | yes |
direction | direction along which bins are defined | yes |
cumulative | bin data accumulated with incresing distance | yes |
\endtable
See also
Foam::functionObject
Foam::functionObjects::timeControl
Foam::functionObjects::forces
functionObjects/forces/forces
This function object calculates the forces and moments by integrating the
pressure and skin-friction forces over a given list of patches.
Member function forces::write() calculates the forces/moments and
writes the forces/moments into the file \<timeDir\>/forces.dat and bin
data (if selected) to the file \<timeDir\>/forces_bin.dat
Example of function object specification:
\verbatim
forces1
{
type forces;
libs ("libforces.so");
...
log yes;
patches (walls);
binData
{
nBin 20;
direction (1 0 0);
cumulative yes;
}
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | Type name: forces | yes |
log | Write force data to standard output | no | no
patches | Patches included in the forces calculation | yes |
p | Pressure field name | no | p
U | Velocity field name | no | U
rho | Density field name (see below) | no | rho
CofR | Centre of rotation (see below) | no |
directForceDensity | Force density supplied directly (see below)|no|no
fD | Name of force density field (see below) | no | fD
\endtable
Bin data is optional, but if the dictionary is present, the entries must
be defined according o
\table
nBin | number of data bins | yes |
direction | direction along which bins are defined | yes |
cumulative | bin data accumulated with incresing distance | yes |
\endtable
Note
- For incompressible cases, set \c rho to \c rhoInf. You will then be
required to provide a \c rhoInf value corresponding to the free-stream
constant density.
- If the force density is supplied directly, set the \c directForceDensity
flag to 'yes', and supply the force density field using the \c
fDName entry
- The centre of rotation (CofR) for moment calculations can either be
specified by an \c CofR entry, or be taken from origin of the local
coordinate system. For example,
\verbatim
CofR (0 0 0);
\endverbatim
or
\verbatim
coordinateSystem
{
origin (0 0 0);
e3 (0 0 1);
e1 (1 0 0);
}
\endverbatim
See also
Foam::functionObject
Foam::functionObjects::writeFiles
Foam::functionObjects::timeControl
Foam::forceCoeffs
functionObjects/forces
functionObjects/lagrangian/cloudInfo
This function object outputs Lagrangian cloud information to a file. The
current outputs include:
- total current number of parcels
- total current mass of parcels
Example of function object specification:
\verbatim
cloudInfo1
{
type cloudInfo;
libs ("libcloudFunctionObjects.so");
...
clouds
(
kinematicCloud1
thermoCloud1
);
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: cloudInfo | yes |
clouds | list of clouds names to process |yes |
\endtable
The output data of each cloud is written to a file named \<cloudName\>.dat
See also
Foam::functionObject
Foam::functionObjects::writeFiles
functionObjects/lagrangian/dsmcFields
Calculate intensive fields:
- UMean
- translationalT
- internalT
- overallT
from averaged extensive fields from a DSMC calculation.
functionObjects/lagrangian/icoUncoupledKinematicCloud
This functionObject tracks a uncoupled kinematic particle cloud in the
specified velocity field of an incompressible flow (laminar, RANS or LES).
It may be used in conjunction with any transient single-phase incompressible
flow solver such as pisoFoam or pimpleFoam and tracks the particles or
parcels without affecting the the flow-field.
The kinematicCloud requires the the density of the fluid which is looked-up
from constant/transportProperties dictionary and the acceleration due to
gravity which is read from the constant/g file if present or defaults to
zero.
The kinematicCloud properties are read from the
constant/kinematicCloudProperties dictionary in the usual manner.
Example of function object specification:
\verbatim
tracks
{
libs ("liblagrangianFunctionObjects.so");
type icoUncoupledKinematicCloud;
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | Type name: icoUncoupledKinematicCloud | yes |
U | Name of the velocity field | no | U
kinematicCloud | Name of the kinematicCloud | no | kinematicCloud
\endtable
See also
Foam::functionObjects::fvMeshFunctionObject
functionObjects/lagrangian
functionObjects/solvers/scalarTransport
This function object evolves a passive scalar transport equation.
- To specify the field name set the 'field' entry
- To employ the same numerical schemes as another field set
the 'schemesField' entry,
- The diffusivity can be set manually using the 'D' entry, or retrieved
from the turbulence model (if applicable).
See also
Foam::functionObjects::fvMeshFunctionObject
functionObjects/utilities/abort
Watches for presence of the named file in the $FOAM_CASE directory
and aborts the calculation if it is present.
Currently the following action types are supported:
- noWriteNow
- writeNow
- nextWrite
functionObjects/utilities/codedFunctionObject
This function object provides a general interface to enable dynamic code
compilation.
The entries are
codeInclude : include files
codeOptions : include paths; inserted into EXE_INC in Make/options
codeLibs : link line; inserted into LIB_LIBS in Make/options
codeData : c++; local member data (null constructed);
localCode : c++; local static functions
codeRead : c++; upon functionObject::read();
codeExecute : c++;upon functionObject::execute();
codeWrite : c++; upon functionObject::write()
codeEnd : c++; upon functionObject::end();
Example of function object specification:
\verbatim
difference
{
libs ("libutilityFunctionObjects.so");
type coded;
// Name of on-the-fly generated functionObject
name writeMagU;
codeWrite
#{
// Lookup U
const volVectorField& U = mesh().lookupObject<volVectorField>("U");
// Write
mag(U).write();
}
}
\endverbatim
See also
Foam::functionObject
Foam::codedBase
functionObjects/utilities/removeRegisteredObject
Removes registered objects if present in the database.
Example of function object specification:
\verbatim
removeRegisteredObject1
{
type removeRegisteredObject;
libs ("libutilityFunctionObjects.so");
...
objects (obj1 obj2);
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: removeRegisteredObject | yes |
objects | objects to remove | yes |
\endtable
See also
Foam::functionObject
functionObjects/utilities/residuals
This function object writes out the initial residual for specified fields.
Example of function object specification:
\verbatim
residuals
{
type residuals;
writeControl timeStep;
writeInterval 1;
fields
(
U
p
);
}
\endverbatim
Output data is written to the dir postProcessing/residuals/\<timeDir\>/
For vector/tensor fields, e.g. U, where an equation is solved for each
component, the largest residual of each component is written out.
See also
Foam::functionObject
Foam::functionObjects::writeFiles
Foam::functionObjects::timeControl
functionObjects/utilities/setTimeStep
Overrides the timeStep. Can only be used with
solvers with adjustTimeStep control (e.g. pimpleFoam). Makes no attempt
to cooperate with other timeStep 'controllers' (maxCo, other
functionObjects). Supports 'enabled' flag but none of othe other ones
'timeStart', 'timeEnd', 'writeControl' etc.
functionObjects/utilities/systemCall
This function object executes system calls, entered in the form of a
string lists. Calls can be made at the following points in the
calculation:
- every time step
- every output time
- end of the calculation
Example of function object specification:
\verbatim
systemCall1
{
type systemCall;
libs ("libutilityFunctionObjects.so");
...
executeCalls
(
"echo execute"
);
writeCalls
(
functionObjects/utilities/timeActivatedFileUpdate
Performs a file copy/replacement once a specified time has been reached.
Example usage to update the fvSolution dictionary at various times
throughout the calculation:
\verbatim
fileUpdate1
{
type timeActivatedFileUpdate;
libs ("libutilityFunctionObjects.so");
writeControl timeStep;
writeInterval 1;
fileToUpdate "$FOAM_CASE/system/fvSolution";
timeVsFile
(
(-1 "$FOAM_CASE/system/fvSolution.0")
(0.10 "$FOAM_CASE/system/fvSolution.10")
(0.20 "$FOAM_CASE/system/fvSolution.20")
(0.35 "$FOAM_CASE/system/fvSolution.35")
);
}
\endverbatim
functionObjects/utilities/writeDictionary
This function object writes dictionaries on start-up, and on change
functionObjects/utilities/writeObjects
Allows specification of different writing frequency of objects registered to
the database.
It has similar functionality as the main time database through the
writeControl setting:
- timeStep
- writeTime
- adjustableRunTime
- runTime
- clockTime
- cpuTime
Example of function object specification:
\verbatim
writeObjects1
{
type writeObjects;
libs ("libutilityFunctionObjects.so");
exclusiveWriting true;
...
objects (obj1 obj2);
}
\endverbatim
Usage
\table
Property | Description | Required | Default value
type | type name: writeObjects | yes |
objects | objects to write | yes |
exclusiveWriting | Takes over object writing | no | yes
\endtable
\c exclusiveWriting disables automatic writing (i.e through database) of the
objects to avoid duplicate writing.
See also
Foam::functionObject
Foam::functionObjects::timeControl
Total 53
| |
| PENGUINITIS | |