43 class fieldInterpolator
73 selectedFields_(selectedFields),
76 interpolator_(interpolator),
77 timeNames_(timeNames),
81 template<
class GeoFieldType>
86 template<
class GeoFieldType>
95 Info<<
" " << fieldClassName <<
"s:";
101 selectedFields_.empty()
102 || selectedFields_.found(fieldIter()->
name())
105 Info<<
" " << fieldIter()->name() <<
'(';
107 scalar deltaT = (ti1_.value() - ti_.value())/(divisions_ + 1);
109 for (
int j=0; j<divisions_; j++)
117 if (j < divisions_-1)
125 interpolator_.valueWeights
138 ReadFields<GeoFieldType>
147 uniformInterpolate<GeoFieldType>
178 int main(
int argc,
char *argv[])
186 "specify a list of fields to be interpolated. Eg, '(U T p)' - "
187 "regular expressions not currently supported"
193 "specify number of temporal sub-divisions to create (default = 1)."
199 "specify type of interpolation (linear or spline)"
210 if (selectedFields.
size())
212 Info<<
"Interpolating fields " << selectedFields <<
nl <<
endl;
216 Info<<
"Interpolating all fields" <<
nl <<
endl;
225 Info<<
"Using " << divisions <<
" per time interval" <<
nl <<
endl;
233 Info<<
"Using interpolation " << interpolationType <<
nl <<
endl;
257 Info<<
"Interpolating fields for times:" <<
endl;
261 runTime.setTime(
timeDirs[timei], timei);
266 fieldInterpolator interpolator
Field reading functions for post-processing utilities.
#define forAll(list, i)
Loop across all elements in list.
#define forAllConstIter(Container, container, iter)
Iterate across all elements in the container object of type.
Generic GeometricField class.
A HashTable with keys but without contents.
label size() const
Return number of elements in table.
List of IOobjects with searching and retrieving facilities.
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
void size(const label)
Override size to be inconsistent with allocated storage.
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
A List with indirect addressing.
static void addOption(const word &opt, const string ¶m="", const string &usage="")
Add to an option to validOptions with usage information.
bool optionFound(const word &opt) const
Return true if the named option is found.
IStringStream optionLookup(const word &opt) const
Return an IStringStream from the named option.
T optionLookupOrDefault(const word &opt, const T &deflt) const
Read a value from the named option if present.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
Mesh data needed to do the Finite Volume discretisation.
const word & name() const
Return reference to name.
An instant of time. Contains the time value and name.
const word & name() const
Name (const access)
Abstract base class for interpolating in 1D.
static autoPtr< interpolationWeights > New(const word &type, const scalarField &samples)
Return a reference to the selected interpolationWeights.
static void addOptions(const bool constant=true, const bool withZero=false)
Add the options handled by timeSelector to argList::validOptions.
static instantList select0(Time &runTime, const argList &args)
Return the set of times selected based on the argList options.
A class for handling words, derived from string.
Foam::fvMesh mesh(Foam::IOobject(regionName, runTime.name(), runTime, Foam::IOobject::MUST_READ), false)
int main(int argc, char *argv[])
static instantList timeDirs
Info<< "Calculating turbulent flame speed field St\n"<< endl;volScalarField St(IOobject("St", runTime.name(), mesh, IOobject::NO_READ, IOobject::AUTO_WRITE), flameWrinkling->Xi() *Su);multivariateSurfaceInterpolationScheme< scalar >::fieldTable fields
static tmp< SurfaceField< Type > > interpolate(const VolField< Type > &tvf, const surfaceScalarField &faceFlux, Istream &schemeData)
Interpolate field onto faces using scheme given by Istream.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Ostream & endl(Ostream &os)
Add newline and flush stream.
String typeName(const std::type_info &info)
Return the un-mangled name given the standard type info.
word name(const LagrangianState state)
Return a string representation of a Lagrangian state enumeration.
Foam::argList args(argc, argv)