33 const word& entryName,
46 is.putBack(firstToken);
47 if (firstToken == token::BEGIN_SQR)
49 is >> this->dimensions_;
58 "PolynomialEntry<Type>::" 59 "PolynomialEntry(const word&, const dictionary&)" 60 ) <<
"PolynomialEntry coefficients for entry " << this->name_
68 canIntegrate_ =
false;
79 "PolynomialEntry<Type>::PolynomialEntry" 80 "(const word&, const dictionary&)" 81 ) <<
"PolynomialEntry " << this->name_ <<
" cannot be integrated" 91 const word& entryName,
104 "Foam::PolynomialEntry<Type>::PolynomialEntry" 105 "(const word&, const List<Tuple2<Type, Type> >&)" 106 ) <<
"PolynomialEntry coefficients for entry " << this->name_
112 if (
mag(coeffs_[i].second() + 1) < ROOTVSMALL)
114 canIntegrate_ =
false;
125 "Foam::PolynomialEntry<Type>::PolynomialEntry" 126 "(const word&, const List<Tuple2<Type, Type> >&)" 127 ) <<
"PolynomialEntry " << this->name_ <<
" cannot be integrated" 138 coeffs_(poly.coeffs_),
139 canIntegrate_(poly.canIntegrate_),
140 dimensions_(poly.dimensions_)
158 Type
value = coeffs_[i].first();
159 for (
direction cmpt = 0; cmpt < pTraits<Type>::nComponents; cmpt++)
A 2-tuple for storing two objects of different types.
Scalar cmptPow(const Scalar s1, const Scalar s2)
dimensioned< scalar > mag(const dimensioned< Type > &)
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
label & setComponent(label &l, const direction)
Type integrate(const scalar x1, const scalar x2) const
Integrate between two (scalar) values.
dimensioned< Type > dimValue(const scalar) const
Return dimensioned constant value.
A class for handling words, derived from string.
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...
virtual scalar userTimeToTime(const scalar theta) const
Convert the user-time (e.g. CA deg) to real-time (s).
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
Class to control time during OpenFOAM simulations that is also the top-level objectRegistry.
PolynomialEntry(const word &entryName, const dictionary &dict)
Generic dimensioned Type class.
Ostream & endl(Ostream &os)
Add newline and flush stream.
#define WarningIn(functionName)
Report a warning using Foam::Warning.
virtual ~PolynomialEntry()
Destructor.
dimensioned< Type > cmptDivide(const dimensioned< Type > &, const dimensioned< Type > &)
void component(FieldField< Field, typename FieldField< Field, Type >::cmptType > &sf, const FieldField< Field, Type > &f, const direction d)
Type value(const scalar x) const
Return PolynomialEntry value.
A token holds items read from Istream.
virtual void convertTimeBase(const Time &t)
Convert time.
#define FatalErrorIn(functionName)
Report an error message using Foam::FatalError.
dimensioned< Type > dimIntegrate(const scalar x1, const scalar x2) const
Integrate between two values and return dimensioned type.
PolynomialEntry container data entry for scalars. Items are stored in a list of Tuple2's. Data is input in the form, e.g. for an entry <entryName> that describes y = x^2 + 2x^3.
Traits class for primitives.
dimensioned< Type > cmptMultiply(const dimensioned< Type > &, const dimensioned< Type > &)
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
const dimensionSet dimless(0, 0, 0, 0, 0, 0, 0)
Top level data entry class for use in dictionaries. Provides a mechanism to specify a variable as a c...