diff --git a/bin/tools/doxyFilter-table.awk b/bin/tools/doxyFilter-table.awk index df08cab6e18977f34f383214d21b9e8988cd1798..bfbd80785ba1951c882eb10cd40cab8c3cdbdb7b 100644 --- a/bin/tools/doxyFilter-table.awk +++ b/bin/tools/doxyFilter-table.awk @@ -48,6 +48,26 @@ BEGIN { } +/\\plaintable/ { + flag = 3; + firstRow = 1; + next; +} + + +/\\endplaintable/ { + if (data != "") + { + printf "<table border="0">\n"; + printf data; + printf "</table>\n"; + } + + data = ""; + flag = 0; + next; +} + { if (flag > 0) { @@ -88,6 +108,21 @@ BEGIN { } } } + else if (flag == 3) + { + for (i = 0; i <= NF; i++) + { + if (i == 1) + { + data = (data " <td style=\"padding-left: 10px\">"$i"</td>\n"); + data = (data " <td style=\"padding-left: 10px; padding-right: 10px;\">:</td>\n"); + } + else if (i > 1) + { + data = (data " <td>"$i"</td>\n"); + } + } + } data = (data "</tr>\n"); firstRow = 0; } diff --git a/bin/tools/doxyFilter.sed b/bin/tools/doxyFilter.sed index 9fd65302d1936809a7b6798d95cd0a3857ca784d..a0e6e4ff403556181d752c2f5f2ca50a9ab38b19 100644 --- a/bin/tools/doxyFilter.sed +++ b/bin/tools/doxyFilter.sed @@ -165,6 +165,9 @@ s/.*\*\//\*\// # convert /heading in source files to bold font and add some space s#\\heading \(.*\)#<br><b>\1</b>#g +# add a linebreak +s#\\linebreak#<br>#g + } # ----------------------------------------------------------------------------- diff --git a/src/postProcessing/functionObjects/cloud/cloudInfo/cloudInfo.H b/src/postProcessing/functionObjects/cloud/cloudInfo/cloudInfo.H index 4dd82e6b548c6661a875ec35b56eb48117d0b1a4..bf75dcacc4e719d33675b739bbb4da4efdd54ff7 100644 --- a/src/postProcessing/functionObjects/cloud/cloudInfo/cloudInfo.H +++ b/src/postProcessing/functionObjects/cloud/cloudInfo/cloudInfo.H @@ -28,7 +28,7 @@ Group grpCloudFunctionObjects Description - This function object outputs lagrangian cloud information to a file. The + This function object outputs Lagrangian cloud information to a file. The current outputs include: - total current number of parcels - total current mass of parcels @@ -37,13 +37,9 @@ Description \verbatim cloudInfo1 { - // Type of functionObject - type cloudInfo; - - // Where to load it from (if not already in solver) + type cloudInfo; functionObjectLibs ("libcloudFunctionObjects.so"); - - // Clouds to process + ... clouds ( kinematicCloud1 @@ -52,6 +48,21 @@ Description } \endverbatim + + \heading Function object 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 + +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject + SourceFiles cloudInfo.C IOcloudInfo.H diff --git a/src/postProcessing/functionObjects/doc/functionObjects.dox b/src/postProcessing/functionObjects/doc/functionObjects.dox index d6ae894685490f9096ccc33132266a521e91b3ac..b3ea86de52ab795b041a1cc3bc5bc27bcd320ca7 100644 --- a/src/postProcessing/functionObjects/doc/functionObjects.dox +++ b/src/postProcessing/functionObjects/doc/functionObjects.dox @@ -27,9 +27,15 @@ License \section secFunctionObjects Function objects -OpenFOAM includes a variety of \ref grpFunctionObjects that can be applied during -the calculation, or afterwards using the execFlowFunctionObjects utility. The -range of uses include: +OpenFOAM includes a collection of \ref grpFunctionObjects that offer users the +opportunity to closely manage their computational analyses. These objects can +be applied to manipulate the workflow process, and provide a mechanism to +extract predicted field and derived quantities at run-time. Alternatively, +the actions can be executed afterwards using the \c execFlowFunctionObjects +utility. + +<br> +The current range of features comprises of: - \ref grpCloudFunctionObjects - \ref grpFieldFunctionObjects - \ref grpForcesFunctionObjects @@ -40,31 +46,47 @@ range of uses include: <br> \subsection secFieldFunctionObjectUsage Using function objects -To employ function objects, additional entries are required in the +Function objects are defined by additional entries in the $FOAM_CASE/system/controlDict input dictionary. Each object is listed in a -\c functions sub-dictionary entry, e.g. +\c functions sub-dictionary entry, e.g. for `output' type objects: \verbatim functions { - myFunctionObject + myFunctionObject // user-defined name of function object entry { type functionObjectType; libs ("libMyFunctionObjectlib.so"); - active yes; // active by default - outputControl outputTime; // output or timeStep - outputInterval 1; // only necessary for outputControl=timeStep + region defaultRegion; + enabled yes; + timeStart 0; + timeEnd 10; + outputControl outputTime; + outputInterval 1; ... } } \endverbatim +Where: +\table + Property | Description | Required | Default value + type | type of function object | yes | + libs | libraries containing object implementation | yes | + region | name of region for multi-region cases | no | + enabled | on/off switch | no | yes + timeStart| start time | no | + timeEnd | end time | no | + outputControl | when to output: either 'outputTime' or 'timeStep'| no | timeStep + outputInterval| steps between output when outputControl=timeStep | no | 1 +\endtable + The sub-dictionary name \c myFunctionObject is chosen by the user, and is -often used as the name of the output folder of any generated data. The \c type -entry defines the type of function object properties that follow. Since the -function objects are packaged into separate libraries, the user must tell the -code where to find the function object implementation, identified using the -\c libs entry. +typically used as the name of the output folder for any derived data. The +\c type entry defines the type of function object properties that follow. +Since the function objects are packaged into separate libraries, the user must +tell the code where to find the function object implementation, identified +using the \c libs entry. \*---------------------------------------------------------------------------*/ diff --git a/src/postProcessing/functionObjects/field/fieldAverage/fieldAverage/fieldAverage.C b/src/postProcessing/functionObjects/field/fieldAverage/fieldAverage/fieldAverage.C index be8b03a5b5157f9a1e58af3df0afae64fd18095c..5d63cced6c714f1c11c266bc973cab777b314414 100644 --- a/src/postProcessing/functionObjects/field/fieldAverage/fieldAverage/fieldAverage.C +++ b/src/postProcessing/functionObjects/field/fieldAverage/fieldAverage/fieldAverage.C @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -245,7 +245,7 @@ void Foam::fieldAverage::writeAveragingProperties() const void Foam::fieldAverage::readAveragingProperties() { - if (cleanRestart_) + if (resetOnRestart_) { Info<< "fieldAverage: starting averaging at time " << obr_.time().timeName() << nl << endl; @@ -306,7 +306,7 @@ Foam::fieldAverage::fieldAverage obr_(obr), active_(true), prevTimeIndex_(-1), - cleanRestart_(false), + resetOnRestart_(false), resetOnOutput_(false), faItems_(), meanScalarFields_(), @@ -354,7 +354,7 @@ void Foam::fieldAverage::read(const dictionary& dict) { if (active_) { - dict.readIfPresent("cleanRestart", cleanRestart_); + dict.readIfPresent("resetOnRestart", resetOnRestart_); dict.readIfPresent("resetOnOutput", resetOnOutput_); dict.lookup("fields") >> faItems_; diff --git a/src/postProcessing/functionObjects/field/fieldAverage/fieldAverage/fieldAverage.H b/src/postProcessing/functionObjects/field/fieldAverage/fieldAverage/fieldAverage.H index db35e35d5c41c85c6b9404bc703f9569f8c32875..f1883b1b7d21862a92035697006db7f97254719b 100644 --- a/src/postProcessing/functionObjects/field/fieldAverage/fieldAverage/fieldAverage.H +++ b/src/postProcessing/functionObjects/field/fieldAverage/fieldAverage/fieldAverage.H @@ -55,29 +55,21 @@ Description \c fieldAveragingProperties dictionary, located in \<time\>/uniform When restarting form a previous calculation, the averaging is continuous. - However, the averaging process can be restarted using the \c cleanRestart + However, the averaging process can be restarted using the \c resetOnRestart option. - To restart the averaging process after each calculation output time, - the \c resetOnOutput option can be applied. + To restart the averaging process after each calculation output time, use + the \c resetOnOutput option. Example of function object specification: \verbatim fieldAverage1 { - // Type of functionObject type fieldAverage; - - // Where to load it from (if not already in solver) functionObjectLibs ("libfieldFunctionObjects.so"); - - // Perform a clean restart? - cleanRestart true; - - // Reset the averaged fields after they have been written? + ... + resetOnRestart true; resetOnOutput false; - - // Fields to be averaged fields ( U @@ -96,9 +88,23 @@ Description } \endverbatim + \heading Function object usage + \table + Property | Description | Required | Default value + type | type name: fieldAverage | yes | + resetOnRestart | flag to reset the averaging on restart | yes | + resetOnOutput| flag to reset the averaging on output | yes | + fields | list of fields and averaging options | yes | + \endtable + + Note To employ the \c prime2Mean option, the \c mean option must be selecetd. +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject + SourceFiles fieldAverage.C fieldAverageTemplates.C @@ -158,10 +164,10 @@ protected: //- Time at last call, prevents repeated averaging label prevTimeIndex_; - //- Clean restart flag - Switch cleanRestart_; + //- Reset the averaging process on restart flag + Switch resetOnRestart_; - //- resetOnOutput flag + //- Reset the averaging process on output flag Switch resetOnOutput_; //- List of field average items, describing what averages to be diff --git a/src/postProcessing/functionObjects/field/fieldCoordinateSystemTransform/fieldCoordinateSystemTransform.H b/src/postProcessing/functionObjects/field/fieldCoordinateSystemTransform/fieldCoordinateSystemTransform.H index ace8c48bfb78a61183213eddee741ea7ede86a11..e583e6b168cae3c2d9162a171100ab9c62240e82 100644 --- a/src/postProcessing/functionObjects/field/fieldCoordinateSystemTransform/fieldCoordinateSystemTransform.H +++ b/src/postProcessing/functionObjects/field/fieldCoordinateSystemTransform/fieldCoordinateSystemTransform.H @@ -36,21 +36,15 @@ Description \verbatim fieldCoordinateSystemTransform1 { - // Type of functionObject - type fieldCoordinateSystemTransform; - - // Where to load it from (if not already in solver) + type fieldCoordinateSystemTransform; functionObjectLibs ("libfieldFunctionObjects.so"); - - // Fields to be transformed + ... fields ( U UMean UPrime2Mean ); - - // Co-ordinate system coordinateSystem { origin (0.001 0 0); @@ -60,7 +54,17 @@ Description } \endverbatim + \heading Function object 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 + SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject Foam::coordinateSystem SourceFiles diff --git a/src/postProcessing/functionObjects/field/fieldMinMax/fieldMinMax.H b/src/postProcessing/functionObjects/field/fieldMinMax/fieldMinMax.H index 96e87b5ff314a26c899042cbf374830a0f4efbe1..a2fbb10f710f8d3a5a6393ada49898dbc5fd380c 100644 --- a/src/postProcessing/functionObjects/field/fieldMinMax/fieldMinMax.H +++ b/src/postProcessing/functionObjects/field/fieldMinMax/fieldMinMax.H @@ -28,13 +28,44 @@ Group grpFieldFunctionObjects Description - Calculates scalar minimim and maximum field values. - - For variables with rank > 0, computes the magnitude of the min/max - values. - - Data written to the file \<timeDir\>/fieldMinMax.dat - + This function object calculates the value and position 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; + functionObjectLibs ("libfieldFunctionObjects.so"); + ... + write yes; + log yes; + mode magnitude; + fields + ( + U + p + ); + } + \endverbatim + + \heading Function object 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 + mode | calculation mode: magnitude or component | no | magnitude + \endtable + + Output data is written to the file \<timeDir\>/fieldMinMax.dat + +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject SourceFiles fieldMinMax.C diff --git a/src/postProcessing/functionObjects/field/fieldValues/cellSource/cellSource.H b/src/postProcessing/functionObjects/field/fieldValues/cellSource/cellSource.H index 5e857e02f28db804e0a63b5efeb9045eecadb116..7548f0e2a820c2b3af4bb0a6ad52b999bd38aeca 100644 --- a/src/postProcessing/functionObjects/field/fieldValues/cellSource/cellSource.H +++ b/src/postProcessing/functionObjects/field/fieldValues/cellSource/cellSource.H @@ -24,39 +24,75 @@ License Class Foam::fieldValues::cellSource +Group + grpFieldFunctionObjects + Description - Cell source variant of field value function object. Values of user- - specified fields reported for collections of cells. + This function object provides a 'cell source' 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. + - cellObj1 // Name also used to identify output folder + Example of function object specification: + \verbatim + cellSource1 { type cellSource; functionObjectLibs ("libfieldFunctionObjects.so"); - enabled true; - outputControl outputTime; - log true; // log to screen? - valueOutput true; // Write values at run-time output times? - source cellZone; // Type of cell source + ... + log true; + valueOutput true; + source cellZone; sourceName c0; operation volAverage; - weightField alpha1; // optional weight field + weightField alpha1; fields ( p U ); } - - where operation is one of: - - none - - sum - - average - - weightedAverage - - volAverage - - volIntegrate - - CoV (Coefficient of variation: standard deviation/mean) - - min - - max + \endverbatim + + \heading Function object usage + \table + Property | Description | Required | Default value + type | type name: cellSource | yes | + log | write data to standard output | no | no + valueOutput | write the raw output values | yes | + source | cell source: see below | yes | + sourceName | name of cell source 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 + + \linebreak + Where \c source is defined by + \plaintable + cellZone | requires a 'sourceName' entry to specify the cellZone + all | all cells + \endplaintable + + \linebreak + The \c operation is one of: + \plaintable + none | no operation + sum | sum + average | ensemble average + weightedAverage | weighted average + volAverage | volume weighted average + volIntegrate | volume integral + min | minimum + max | maximum + CoV | coefficient of variation: standard deviation/mean + \endplaintable + +SeeAlso + Foam::fieldValues + Foam::functionObject + Foam::OutputFilterFunctionObject SourceFiles cellSource.C diff --git a/src/postProcessing/functionObjects/field/fieldValues/faceSource/faceSource.H b/src/postProcessing/functionObjects/field/fieldValues/faceSource/faceSource.H index f9199f451a48947f85f8dab945b079ec3570e173..43eb0d35ad16994ae7d79b78a13ee64ca1e1bd52 100644 --- a/src/postProcessing/functionObjects/field/fieldValues/faceSource/faceSource.H +++ b/src/postProcessing/functionObjects/field/fieldValues/faceSource/faceSource.H @@ -24,24 +24,32 @@ License Class Foam::fieldValues::faceSource +Group + grpFieldFunctionObjects + Description - Face source variant of field value function object. Values of user- - specified fields reported for collections of faces. + This function object provides a 'face source' 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. + + \linebreak + 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 - faceObj1 // Name also used to identify output folder + faceSource1 { type faceSource; functionObjectLibs ("libfieldFunctionObjects.so"); - enabled true; - outputControl outputTime; - log true; // log to screen? - valueOutput true; // Write values at run-time output times? - source faceZone; // Type of face source: - // faceZone,patch,sampledSurface - sourceName f0; // faceZone name, see below + ... + log yes; + valueOutput yes; + source faceZone; + sourceName f0; operation sum; - weightField alpha1; // optional weight field + weightField alpha1; fields ( p @@ -51,44 +59,66 @@ Description } \endverbatim - source: - - faceZone : requires a 'sourceName' entry to specify the faceZone - - patch : "" patch - - sampledSurface : requires a 'sampledSurfaceDict' subdictionary. See e.g. - sampleDict. - - operation is one of: - - none - - sum - - average (ensemble) - - weightedAverage - - areaAverage - - areaIntegrate - - min - - max - - CoV (Coefficient of variation: standard deviation/mean) - - areaNormalAverage (vector with first component (average of) inproduct - of value and face area vector) - - areaNormalIntegrate ( ,, ,, (sum of) ,, - - For example, to calculate the volumetric or mass flux across a patch, - apply the 'sum' operator to the flux field (typically \c phi) + \heading Function object usage + \table + Property | Description | Required | Default value + type | type name: faceSource | yes | + log | write data to standard output | no | no + valueOutput | write the raw output values | yes | + source | face source: see below | yes | + sourceName | name of face source 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 + + \linebreak + Where \c source is defined by + \plaintable + faceZone | requires a 'sourceName' entry to specify the faceZone + patch | requires a 'sourceName' entry to specify the patch + sampledSurface | requires a 'sampledSurfaceDict' sub-dictionary + \endplaintable + + \linebreak + The \c operation is one of: + \plaintable + none | no operation + sum | sum + average | ensemble average + weightedAverage | weighted average + areaAverage | area weighted 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 - - all fields get oriented according to the \c faceZone (so you might + - all fields are oriented according to the \c faceZone (so you might e.g. see negative pressure) - using \c sampledSurfaces: - - they do not do surface fields + - 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 \c triSurfaceMesh + cells. This can only happen for sampling on a \c triSurfaceMesh - take care when using isoSurfaces - these might have duplicate - triangles so integration might be wrong + triangles and so integration might be wrong + +SeeAlso + Foam::fieldValues + Foam::functionObject + Foam::OutputFilterFunctionObject SourceFiles faceSource.C diff --git a/src/postProcessing/functionObjects/field/nearWallFields/nearWallFields.H b/src/postProcessing/functionObjects/field/nearWallFields/nearWallFields.H index 21c5bc7b09618249d3d9a85e8e8695d17d4c9b92..e6be5d7948ee44e1ef2bbcef3544e843bcb36c1a 100644 --- a/src/postProcessing/functionObjects/field/nearWallFields/nearWallFields.H +++ b/src/postProcessing/functionObjects/field/nearWallFields/nearWallFields.H @@ -28,30 +28,41 @@ Group grpFieldFunctionObjects Description - Samples near-patch volFields + This function object samples near-patch volume fields - Holds fields - - every timestep the field get updated with new values - - at write it writes the fields - so this functionObject can either be used to calculate a new field - as a postprocessing step or (since the fields are registered) - use these in another functionObject (e.g. faceSource). + Fields are stored + - every time step the field is updated with new values + - at output it writes the fields - surfaceValues + 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 + nearWallFields1 { type nearWallFields; - .. - enabled true; - outputControl outputTime; - .. - // Name of volField and corresponding surfaceField + functionObjectLibs ("libfieldFunctionObjects.so"); + ... fields ((p pNear)(U UNear)); - // Name of patch to sample patches (movingWall); - // Distance away from the wall - distance 0.13; // distance away from wall + distance 0.13; } + \endverbatim + + \heading Function object usage + \table + Property | Description | Required | Default value + type | type name: nearWallFields | yes | + fields | list of fields with correspoding output field names | yes | + patches | list of patches to sample | yes | + distance | distance from patch to sample | yes | + \endtable +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject SourceFiles nearWallFields.C @@ -77,7 +88,7 @@ class dictionary; class mapPolyMesh; /*---------------------------------------------------------------------------*\ - Class nearWallFields Declaration + Class nearWallFields Declaration \*---------------------------------------------------------------------------*/ class nearWallFields diff --git a/src/postProcessing/functionObjects/field/processorField/processorField.H b/src/postProcessing/functionObjects/field/processorField/processorField.H index 3be2dbe298b1f4544e1594ccf0eafdcc941c7b57..b1ecdb65f5cebbc7acc84a811ae32c09823adcf9 100644 --- a/src/postProcessing/functionObjects/field/processorField/processorField.H +++ b/src/postProcessing/functionObjects/field/processorField/processorField.H @@ -28,8 +28,28 @@ Group grpFieldFunctionObjects Description - Writes a scalar field whose value is the local processor ID. Output - field name is processorID. + 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; + functionObjectLibs ("libfieldFunctionObjects.so"); + ... + } + \endverbatim + + \heading Function object usage + \table + Property | Description | Required | Default value + type | type name: processorField | yes | + \endtable + +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject SourceFiles processorField.C @@ -57,7 +77,7 @@ class dictionary; class mapPolyMesh; /*---------------------------------------------------------------------------*\ - Class processorField Declaration + Class processorField Declaration \*---------------------------------------------------------------------------*/ class processorField diff --git a/src/postProcessing/functionObjects/field/readFields/readFields.H b/src/postProcessing/functionObjects/field/readFields/readFields.H index 8cf5b7be2916809d39e6b2f8be8d0abaac10f846..8a26b89f5688af7b6caba7980966534fe8ee51be 100644 --- a/src/postProcessing/functionObjects/field/readFields/readFields.H +++ b/src/postProcessing/functionObjects/field/readFields/readFields.H @@ -28,8 +28,34 @@ Group grpFieldFunctionObjects Description - Reads fields from the time folders and adds them to the mesh database - for further post-processing. + This function object reads fields from the time folders and adds them to + the mesh database for further post-processing. + + Example of function object specification: + \verbatim + readFields1 + { + type readFields; + functionObjectLibs ("libfieldFunctionObjects.so"); + ... + fields + ( + U + p + ); + } + \endverbatim + + \heading Function object usage + \table + Property | Description | Required | Default value + type | type name: readFields | yes | + fields | list of fields to read | no | + \endtable + +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject SourceFiles readFields.C diff --git a/src/postProcessing/functionObjects/field/regionSizeDistribution/regionSizeDistribution.H b/src/postProcessing/functionObjects/field/regionSizeDistribution/regionSizeDistribution.H index 077d13f93d0ae87d25deb7b604299e5044eca4af..ce4174162eb12ec92ef492bc86ea353fcb609561 100644 --- a/src/postProcessing/functionObjects/field/regionSizeDistribution/regionSizeDistribution.H +++ b/src/postProcessing/functionObjects/field/regionSizeDistribution/regionSizeDistribution.H @@ -28,67 +28,67 @@ Group grpFieldFunctionObjects Description - Droplet size distribution calculation. + This function object creates a size distribution via interrogating a + continuous phase fraction field. - Looks up a void-fraction (alpha) field and splits the mesh into regions - based on where the field is below the threshold value. These + 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: - - (debug) write regions as a volScalarField - - (debug) print for all regions the sum of volume and alpha*volume - 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' + - 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 - Fields: - - write volScalarField alpha_liquidCore : alpha with outside liquid core - set to 0. - alpha_background : alpha with outside background - set to 0. + 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 + - write graph of sum, average and deviation of user-defined fields. For volVectorFields these are those of the 3 components and the magnitude. - Sample input: - - functions + Example of function object specification: + \verbatim + regionSizeDistribution1 { - regionSizeDistribution - { - type regionSizeDistribution; - - outputControl timeStep; - outputInterval 1; - - // Field to determine regions from - field alpha; - // Patches that provide the liquid core - patches (inlet); - // Delimit alpha regions - threshold 0.4; - - // Fields to sample (no need to include alpha) - fields (p U); - - // Number of bins for histogram - nBins 100; - // Max droplet diameter - maxDiameter 0.5e-4; - //// Min droplet diameter (default is 0) - //minDiameter 0; - - // Writing format - setFormat gnuplot; - } + type regionSizeDistribution; + functionObjectLibs ("libfieldFunctionObjects.so"); + ... + field alpha; + patches (inlet); + threshold 0.4; + fields (p U); + nBins 100; + maxDiameter 0.5e-4; + minDiameter 0; + setFormat gnuplot; } - - + \endverbatim + + \heading Function object 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 | + \endtable + +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject SourceFiles regionSizeDistribution.C @@ -117,7 +117,7 @@ class regionSplit; class polyMesh; /*---------------------------------------------------------------------------*\ - Class regionSizeDistribution Declaration + Class regionSizeDistribution Declaration \*---------------------------------------------------------------------------*/ class regionSizeDistribution diff --git a/src/postProcessing/functionObjects/field/streamLine/streamLine.H b/src/postProcessing/functionObjects/field/streamLine/streamLine.H index e17f8cedf01c2a1dcec215ad4bf02a8196925777..08f01e45194d80c80fa9052722da70a361929a60 100644 --- a/src/postProcessing/functionObjects/field/streamLine/streamLine.H +++ b/src/postProcessing/functionObjects/field/streamLine/streamLine.H @@ -28,7 +28,72 @@ Group grpFieldFunctionObjects Description - Generation of streamlines. Samples along track of passive particle. + 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; + functionObjectLibs ("libfieldFunctionObjects.so"); + ... + setFormat vtk; + UName U; + 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 + + \heading Function object usage + \table + Property | Description | Required | Default value + type | type name: streamLine | yes | + setFormat | output data type | yes | + UName | 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 + + \linebreak + 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 + +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject + Foam::sampledSet + Foam::wallBoundedStreamLine SourceFiles streamLine.C @@ -83,7 +148,6 @@ class streamLine //- On/off switch bool active_; - //- List of fields to sample wordList fields_; @@ -130,9 +194,10 @@ class streamLine //- Axis of the sampled points to output word sampledSetAxis_; - //- File output writer + //- File writer for scalar data autoPtr<writer<scalar> > scalarFormatterPtr_; + //- File writer for vector data autoPtr<writer<vector> > vectorFormatterPtr_; diff --git a/src/postProcessing/functionObjects/field/surfaceInterpolateFields/surfaceInterpolateFields.H b/src/postProcessing/functionObjects/field/surfaceInterpolateFields/surfaceInterpolateFields.H index 44c0d54608a374d7c143b75529701b040f5b7846..61d8724d698bb6fb4c410b6c3fbe608b8a15d013 100644 --- a/src/postProcessing/functionObjects/field/surfaceInterpolateFields/surfaceInterpolateFields.H +++ b/src/postProcessing/functionObjects/field/surfaceInterpolateFields/surfaceInterpolateFields.H @@ -2,7 +2,7 @@ ========= | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox \\ / O peration | - \\ / A nd | Copyright (C) 2011 OpenFOAM Foundation + \\ / A nd | Copyright (C) 2011-2012 OpenFOAM Foundation \\/ M anipulation | ------------------------------------------------------------------------------- License @@ -27,26 +27,39 @@ Class Group grpFieldFunctionObjects Description - Linear interpolates volFields to surfaceFields + This function object linearly interpolates volume fields to generate + surface fields - - at write it writes the fields - - it executes every time step + Fields are stored + - every time step the field is updated with new values + - at output it writes the fields - so it can either be used to calculate and write the interpolate or - (since the interpolates are registered) use some other functionObject - to work on them. + 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 - sampleSomeFields + Example of function object specification: + \verbatim + surfaceInterpolateFields1 { - type surfaceInterpolateFields; - .. - enabled true; - outputControl outputTime; - .. - // Name of volField and corresponding surfaceField - fields ((p pInterpolate)(U UInterpolate)); + type surfaceInterpolateFields; + functionObjectLibs ("libfieldFunctionObjects.so"); + ... + fields ((p pNear)(U UNear)); } + \endverbatim + \heading Function object usage + \table + Property | Description | Required | Default value + type | type name: nearWallFields | yes | + fields | list of fields with correspoding output field names | yes | + \endtable + + +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject SourceFiles surfaceInterpolateFields.C @@ -72,7 +85,7 @@ class dictionary; class mapPolyMesh; /*---------------------------------------------------------------------------*\ - Class surfaceInterpolateFields Declaration + Class surfaceInterpolateFields Declaration \*---------------------------------------------------------------------------*/ class surfaceInterpolateFields diff --git a/src/postProcessing/functionObjects/field/turbulenceFields/turbulenceFields.H b/src/postProcessing/functionObjects/field/turbulenceFields/turbulenceFields.H index 3148b5448b3110284d2c7992aea150e78f2a296a..527f332c4687aef2dfc9851170bddb97e593af15 100644 --- a/src/postProcessing/functionObjects/field/turbulenceFields/turbulenceFields.H +++ b/src/postProcessing/functionObjects/field/turbulenceFields/turbulenceFields.H @@ -28,13 +28,53 @@ Group grpFieldFunctionObjects Description - Stores turbulence fields on the mesh database for further manipulation. + 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. turbulenceModel::R + Example of function object specification: + \verbatim + turbulenceFields1 + { + type turbulenceFields; + functionObjectLibs ("libfieldFunctionObjects.so"); + ... + fields + ( + R + devRhoReff + ); + } + \endverbatim + + \heading Function object 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 + R | Stress tensor + devRhoReff | + mut | turbulence viscosity (compressible) + muEff | effective turbulence viscosity (compressible) + alphat | turbulence thermal diffusivity (compressible) + alphaEff | effective turbulence thermal diffusivity (compressible) + devReff | + nut | turbulence viscosity (incompressible) + nuEff | effective turbulence viscosity (incompressible) + \endplaintable + +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject + SourceFiles turbulenceFields.C @@ -60,7 +100,7 @@ class dictionary; class mapPolyMesh; /*---------------------------------------------------------------------------*\ - Class turbulenceFields Declaration + Class turbulenceFields Declaration \*---------------------------------------------------------------------------*/ class turbulenceFields diff --git a/src/postProcessing/functionObjects/field/wallBoundedStreamLine/wallBoundedStreamLine.H b/src/postProcessing/functionObjects/field/wallBoundedStreamLine/wallBoundedStreamLine.H index 14ab62724ed6218046b2e33e41867fa8995c6a13..e7dceed8bb6697a51d7b8f3112b7a0a0e2e9de28 100644 --- a/src/postProcessing/functionObjects/field/wallBoundedStreamLine/wallBoundedStreamLine.H +++ b/src/postProcessing/functionObjects/field/wallBoundedStreamLine/wallBoundedStreamLine.H @@ -28,7 +28,72 @@ Group grpFieldFunctionObjects Description - Generation of streamlines. Samples along track of passive particle. + 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, constrained to a patch. + + Example of function object specification: + \verbatim + wallBoundedStreamLine1 + { + type wallBoundedStreamLine; + functionObjectLibs ("libfieldFunctionObjects.so"); + ... + setFormat vtk; + UName UNear; + trackForward yes; + fields + ( + UNear + p + ); + lifeTime 10000; + trackLength 1e-3; + nSubCycle 5; + cloudName particleTracks; + seedSampleSet patchSeed; + patchSeedCoeffs + { + type patchSeed; + patches (wall); + axis x; + maxPoints 20000; + } + } + \endverbatim + + \heading Function object usage + \table + Property | Description | Required | Default value + type | type name: wallBoundedStreamLine| yes | + setFormat | output data type | yes | + UName | 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 + + \linebreak + Where \c seedSampleSet is typically one of + \plaintable + uniform | uniform particle seeding + cloud | cloud of points + patchSeed | seeding via patch faces + 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 + +SeeAlso + Foam::functionObject + Foam::OutputFilterFunctionObject + Foam::sampledSet + Foam::streamLine SourceFiles wallBoundedStreamLine.C @@ -63,7 +128,7 @@ class meshSearch; class sampledSet; /*---------------------------------------------------------------------------*\ - Class wallBoundedStreamLine Declaration + Class wallBoundedStreamLine Declaration \*---------------------------------------------------------------------------*/ class wallBoundedStreamLine