40 void Foam::sampledSurface::makeSf()
const 46 <<
"face area vectors already exist" 56 values[facei] = theFaces[facei].area(
points());
61 void Foam::sampledSurface::makeMagSf()
const 67 <<
"mag face areas already exist" 77 values[facei] = theFaces[facei].mag(
points());
82 void Foam::sampledSurface::makeCf()
const 88 <<
"face centres already exist" 98 values[facei] = theFaces[facei].centre(
points());
127 Info<<
"Selecting sampledType " << sampleType <<
endl;
130 wordConstructorTable::iterator cstrIter =
131 wordConstructorTablePtr_->find(sampleType);
133 if (cstrIter == wordConstructorTablePtr_->end())
136 <<
"Unknown sample type " 137 << sampleType <<
nl <<
nl 138 <<
"Valid sample types : " <<
endl 139 << wordConstructorTablePtr_->sortedToc()
153 const bool interpolate
158 interpolate_(interpolate),
232 area_ =
sum(magSf());
298 res[facei] = field[facei];
352 os.
check(
"Ostream& operator<<(Ostream&, const sampledSurface&");
#define forAll(list, i)
Loop across all elements in list.
virtual ~sampledSurface()
Destructor.
errorManipArg< error, int > exit(error &err, const int errNo=1)
A list of keyword definitions, which are a keyword followed by any number of values (e...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
virtual bool check(const char *operation) const
Check IOstream status for given operation.
An abstract class for surfaces with sampling.
T & ref() const
Return non-const reference or generate a fatal error.
Ostream & endl(Ostream &os)
Add newline and flush stream.
virtual void print(Ostream &) const
Write.
Macros for easy insertion into run-time selection tables.
dimensioned< Type > sum(const DimensionedField< Type, GeoMesh > &df)
gmvFile<< "tracers "<< particles.size()<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().x()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().y()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
virtual void clearGeom() const
A class for handling words, derived from string.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
sampledSurface(const word &name, const polyMesh &, const bool interpolate=false)
Construct from name, mesh.
bool readIfPresent(const word &, T &, bool recursive=false, bool patternMatch=true) const
Find an entry if present, and assign to T.
scalar area() const
The total surface area.
static autoPtr< sampledSurface > New(const word &name, const polyMesh &, const dictionary &)
Return a reference to the selected surface.
errorManip< error > abort(error &err)
An Ostream is an abstract base class for all output systems (streams, files, token lists...
defineRunTimeSelectionTable(reactionRateFlameArea, dictionary)
defineTypeNameAndDebug(combustionModel, 0)
virtual const vectorField & Sf() const
Return face area vectors.
void reduce(const List< UPstream::commsStruct > &comms, T &Value, const BinaryOp &bop, const int tag, const label comm)
word name(const complex &)
Return a string representation of a complex.
tmp< Field< vector > > project(const Field< sphericalTensor > &) const
Project field onto surface.
T lookupOrDefault(const word &, const T &, bool recursive=false, bool patternMatch=true) const
Find and return a T,.
virtual const vectorField & Cf() const
Return face centres as vectorField.
virtual const scalarField & magSf() const
Return face area magnitudes.
Ostream & operator<<(Ostream &, const ensightPart &)
fileType type(const fileName &, const bool checkVariants=true, const bool followLink=true)
Return the file type: directory or file.
Field< vector > vectorField
Specialisation of Field<T> for vector.
Mesh consisting of general polyhedral cells.
A class for managing temporary objects.
void deleteDemandDrivenData(DataPtr &dataPtr)
#define NotImplemented
Issue a FatalErrorIn for a function not currently implemented.
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
virtual tmp< scalarField > sample(const volScalarField &) const =0
Sample field on surface.