Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
nearWallFields Class Reference

This function object samples near-patch volume fields. More...

Collaboration diagram for nearWallFields:
Collaboration graph
[legend]

Public Member Functions

 TypeName ("nearWallFields")
 Runtime type information. More...
 
 nearWallFields (const word &name, const objectRegistry &, const dictionary &, const bool loadFromFiles=false)
 Construct for given objectRegistry and dictionary. More...
 
virtual ~nearWallFields ()
 Destructor. More...
 
virtual const wordname () const
 Return name of the nearWallFields object. More...
 
virtual void read (const dictionary &)
 Read the field min/max data. More...
 
virtual void execute ()
 Execute, currently does nothing. More...
 
virtual void end ()
 Execute at the final time-loop, currently does nothing. More...
 
virtual void timeSet ()
 Called when time was set at the end of the Time::operator++. More...
 
virtual void write ()
 Write. More...
 
virtual void updateMesh (const mapPolyMesh &)
 Update for changes of mesh. More...
 
virtual void movePoints (const polyMesh &)
 Update for changes of mesh. More...
 

Protected Member Functions

void calcAddressing ()
 Calculate addressing from cells back to patch faces. More...
 
template<class Type >
void createFields (PtrList< GeometricField< Type, fvPatchField, volMesh > > &) const
 
template<class Type >
void sampleBoundaryField (const interpolationCellPoint< Type > &interpolator, GeometricField< Type, fvPatchField, volMesh > &fld) const
 Override boundary fields with sampled values. More...
 
template<class Type >
void sampleFields (PtrList< GeometricField< Type, fvPatchField, volMesh > > &) const
 

Protected Attributes

word name_
 Name of this set of nearWallFields object. More...
 
const objectRegistryobr_
 
bool active_
 on/off switch More...
 
List< Tuple2< word, word > > fieldSet_
 Fields to process. More...
 
labelHashSet patchSet_
 Patches to sample. More...
 
scalar distance_
 Distance away from wall. More...
 
HashTable< wordfieldMap_
 From original field to sampled result. More...
 
HashTable< wordreverseFieldMap_
 From resulting back to original field. More...
 
labelListList cellToWalls_
 From cell to seed patch faces. More...
 
List< List< point > > cellToSamples_
 From cell to tracked end point. More...
 
autoPtr< mapDistributegetPatchDataMapPtr_
 Map from cell based data back to patch based data. More...
 
PtrList< volScalarFieldvsf_
 
PtrList< volVectorFieldvvf_
 
PtrList< volSphericalTensorFieldvSpheretf_
 
PtrList< volSymmTensorFieldvSymmtf_
 
PtrList< volTensorFieldvtf_
 

Detailed Description

This function object samples near-patch volume fields.

Fields are stored

This functionObject can either be used

Example of function object specification:

nearWallFields1
{
    type        nearWallFields;
    functionObjectLibs ("libfieldFunctionObjects.so");
    ...
    fields      ((p pNear)(U UNear));
    patches     (movingWall);
    distance    0.13;
}


Function object usage

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
See also
Foam::functionObject Foam::OutputFilterFunctionObject
Source files

Definition at line 119 of file nearWallFields.H.

Constructor & Destructor Documentation

nearWallFields ( const word name,
const objectRegistry obr,
const dictionary dict,
const bool  loadFromFiles = false 
)

Construct for given objectRegistry and dictionary.

Allow the possibility to load fields from files

Definition at line 225 of file nearWallFields.C.

References Foam::endl(), Foam::read(), and WarningIn.

Here is the call graph for this function:

~nearWallFields ( )
virtual

Destructor.

Definition at line 263 of file nearWallFields.C.

References Foam::endl(), and Foam::Info.

Here is the call graph for this function:

Member Function Documentation

void calcAddressing ( )
protected
void createFields ( PtrList< GeometricField< Type, fvPatchField, volMesh > > &  sflds) const
protected
void sampleBoundaryField ( const interpolationCellPoint< Type > &  interpolator,
GeometricField< Type, fvPatchField, volMesh > &  fld 
) const
protected

Override boundary fields with sampled values.

Definition at line 76 of file nearWallFieldsTemplates.C.

References GeometricField< Type, PatchField, GeoMesh >::boundaryField(), forAll, forAllConstIter(), interpolationCellPoint< Type >::interpolate(), nearWallFields::sampleFields(), and List< Type >::size().

Referenced by nearWallFields::createFields().

Here is the call graph for this function:

Here is the caller graph for this function:

void sampleFields ( PtrList< GeometricField< Type, fvPatchField, volMesh > > &  sflds) const
protected

Definition at line 123 of file nearWallFieldsTemplates.C.

References fld(), and forAll.

Referenced by nearWallFields::sampleBoundaryField().

Here is the call graph for this function:

Here is the caller graph for this function:

TypeName ( "nearWallFields"  )

Runtime type information.

virtual const word& name ( ) const
inlinevirtual

Return name of the nearWallFields object.

Definition at line 232 of file nearWallFields.H.

References nearWallFields::end(), nearWallFields::execute(), nearWallFields::name_, nearWallFields::read(), nearWallFields::timeSet(), and nearWallFields::write().

Here is the call graph for this function:

void read ( const dictionary dict)
virtual

Read the field min/max data.

Definition at line 274 of file nearWallFields.C.

References polyMesh::boundaryMesh(), Foam::endl(), forAll, Foam::Info, dictionary::lookup(), mesh, polyBoundaryMesh::patchSet(), Foam::readScalar(), and Foam::type().

Referenced by nearWallFields::name().

Here is the call graph for this function:

Here is the caller graph for this function:

void execute ( )
virtual

Execute, currently does nothing.

Definition at line 324 of file nearWallFields.C.

References Foam::endl(), Foam::Info, Foam::nl, and Foam::type().

Referenced by nearWallFields::name().

Here is the call graph for this function:

Here is the caller graph for this function:

void end ( )
virtual

Execute at the final time-loop, currently does nothing.

Definition at line 370 of file nearWallFields.C.

References Foam::endl(), and Foam::Info.

Referenced by nearWallFields::name().

Here is the call graph for this function:

Here is the caller graph for this function:

void timeSet ( )
virtual

Called when time was set at the end of the Time::operator++.

Definition at line 384 of file nearWallFields.C.

Referenced by nearWallFields::name().

Here is the caller graph for this function:

void write ( )
virtual

Write.

Definition at line 390 of file nearWallFields.C.

References Foam::endl(), forAll, and Foam::Info.

Referenced by nearWallFields::name().

Here is the call graph for this function:

Here is the caller graph for this function:

virtual void updateMesh ( const mapPolyMesh )
inlinevirtual

Update for changes of mesh.

Definition at line 253 of file nearWallFields.H.

virtual void movePoints ( const polyMesh )
inlinevirtual

Update for changes of mesh.

Definition at line 257 of file nearWallFields.H.

Member Data Documentation

word name_
protected

Name of this set of nearWallFields object.

Definition at line 126 of file nearWallFields.H.

Referenced by nearWallFields::name().

const objectRegistry& obr_
protected

Definition at line 128 of file nearWallFields.H.

bool active_
protected

on/off switch

Definition at line 131 of file nearWallFields.H.

List<Tuple2<word, word> > fieldSet_
protected

Fields to process.

Definition at line 136 of file nearWallFields.H.

labelHashSet patchSet_
protected

Patches to sample.

Definition at line 139 of file nearWallFields.H.

scalar distance_
protected

Distance away from wall.

Definition at line 142 of file nearWallFields.H.

HashTable<word> fieldMap_
protected

From original field to sampled result.

Definition at line 145 of file nearWallFields.H.

HashTable<word> reverseFieldMap_
protected

From resulting back to original field.

Definition at line 148 of file nearWallFields.H.

labelListList cellToWalls_
protected

From cell to seed patch faces.

Definition at line 154 of file nearWallFields.H.

List<List<point> > cellToSamples_
protected

From cell to tracked end point.

Definition at line 157 of file nearWallFields.H.

autoPtr<mapDistribute> getPatchDataMapPtr_
protected

Map from cell based data back to patch based data.

Definition at line 160 of file nearWallFields.H.

PtrList<volScalarField> vsf_
protected

Definition at line 165 of file nearWallFields.H.

PtrList<volVectorField> vvf_
protected

Definition at line 166 of file nearWallFields.H.

PtrList<volSphericalTensorField> vSpheretf_
protected

Definition at line 167 of file nearWallFields.H.

PtrList<volSymmTensorField> vSymmtf_
protected

Definition at line 168 of file nearWallFields.H.

PtrList<volTensorField> vtf_
protected

Definition at line 169 of file nearWallFields.H.


The documentation for this class was generated from the following files: