31#define TEMPLATE template<class GeoMesh>
41template<
class GeoMesh>
53 "stabilise(" + dsf.
name() +
',' + ds.
name() +
')',
67template<
class GeoMesh>
79 "stabilise(" + dsf.
name() +
',' + ds.
name() +
')',
103template<
class GeoMesh>
113 <<
"Base field is not dimensionless: " << dsf1.
dimensions()
120 <<
"Exponent field is not dimensionless: " << dsf2.
dimensions()
129 "pow(" + dsf1.
name() +
',' + dsf2.
name() +
')',
143template<
class GeoMesh>
155 <<
"Base field is not dimensionless: " << dsf1.
dimensions()
162 <<
"Exponent field is not dimensionless: " << dsf2.
dimensions()
169 "pow(" + dsf1.
name() +
',' + dsf2.
name() +
')',
181template<
class GeoMesh>
193 <<
"Base field is not dimensionless: " << dsf1.
dimensions()
200 <<
"Exponent field is not dimensionless: " << dsf2.
dimensions()
207 "pow(" + dsf1.
name() +
',' + dsf2.
name() +
')',
219template<
class GeoMesh>
232 <<
"Base field is not dimensionless: " << dsf1.
dimensions()
239 <<
"Exponent field is not dimensionless: " << dsf2.
dimensions()
249 "pow(" + dsf1.
name() +
',' + dsf2.
name() +
')',
262template<
class GeoMesh>
272 <<
"Exponent is not dimensionless: " << ds.
dimensions()
281 "pow(" + dsf.
name() +
',' + ds.
name() +
')',
295template<
class GeoMesh>
305 <<
"Exponent is not dimensionless: " << ds.
dimensions()
314 "pow(" + dsf.
name() +
',' + ds.
name() +
')',
326template<
class GeoMesh>
337template<
class GeoMesh>
348template<
class GeoMesh>
358 <<
"Base scalar is not dimensionless: " << ds.
dimensions()
365 <<
"Exponent field is not dimensionless: " << dsf.
dimensions()
374 "pow(" + ds.
name() +
',' + dsf.
name() +
')',
388template<
class GeoMesh>
400 <<
"Base scalar is not dimensionless: " << ds.
dimensions()
407 <<
"Exponent field is not dimensionless: " << dsf.
dimensions()
414 "pow(" + ds.
name() +
',' + dsf.
name() +
')',
425template<
class GeoMesh>
435template<
class GeoMesh>
448template<
class GeoMesh>
460 "atan2(" + dsf1.
name() +
',' + dsf2.
name() +
')',
474template<
class GeoMesh>
486 "atan2(" + dsf1.
name() +
',' + dsf2.
name() +
')',
498template<
class GeoMesh>
510 "atan2(" + dsf1.
name() +
',' + dsf2.
name() +
')',
521template<
class GeoMesh>
537 "atan2(" + dsf1.
name() +
',' + dsf2.
name() +
')',
550template<
class GeoMesh>
562 "atan2(" + dsf.
name() +
',' + ds.
name() +
')',
575template<
class GeoMesh>
587 "atan2(" + dsf.
name() +
',' + ds.
name() +
')',
598template<
class GeoMesh>
608template<
class GeoMesh>
619template<
class GeoMesh>
631 "atan2(" + ds.
name() +
',' + dsf.
name() +
')',
645template<
class GeoMesh>
657 "atan2(" + ds.
name() +
',' + dsf.
name() +
')',
668template<
class GeoMesh>
678template<
class GeoMesh>
732#define BesselFunc(func) \
734template<class GeoMesh> \
735tmp<DimensionedField<scalar, GeoMesh>> func \
738 const DimensionedField<scalar, GeoMesh>& dsf \
741 if (!dsf.dimensions().dimensionless()) \
743 FatalErrorInFunction \
744 << "dsf not dimensionless" \
745 << abort(FatalError); \
749 tmp<DimensionedField<scalar, GeoMesh>>::New \
753 #func "(" + name(n) + ',' + dsf.name() + ')', \
761 func(tres.ref().field(), n, dsf.field()); \
767template<class GeoMesh> \
768tmp<DimensionedField<scalar, GeoMesh>> func \
771 const tmp<DimensionedField<scalar, GeoMesh>>& tdsf \
774 const DimensionedField<scalar, GeoMesh>& dsf = tdsf(); \
776 if (!dsf.dimensions().dimensionless()) \
778 FatalErrorInFunction \
779 << " : dsf not dimensionless" \
780 << abort(FatalError); \
783 tmp<DimensionedField<scalar, GeoMesh>> tres \
788 #func "(" + name(n) + ',' + dsf.name() + ')', \
793 func(tres.ref().field(), n, dsf.field()); \
#define BINARY_TYPE_OPERATOR(ReturnType, Type1, Type2, Op, OpName, OpFunc)
#define BINARY_OPERATOR(ReturnType, Type1, Type2, Op, OpName, OpFunc)
#define BINARY_TYPE_OPERATOR_SF(ReturnType, Type1, Type2, Op, OpName, OpFunc)
#define UNARY_FUNCTION(ReturnType, Type1, Func, Dfunc)
Scalar specific part of the implementation of DimensionedField.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
const dimensionSet & dimensions() const
Return dimensions.
const Mesh & mesh() const
Return mesh.
const Field< Type > & field() const
Return field.
Defines the attributes of an object for which implicit objectRegistry management is supported,...
const word & name() const noexcept
Return the object name.
const objectRegistry & db() const noexcept
Return the local objectRegistry.
const fileName & instance() const noexcept
Read access to instance path component.
static autoPtr< Time > New()
Construct (dummy) Time - no functionObjects or libraries.
bool dimensionless() const
Return true if it is dimensionless.
Generic dimensioned Type class.
const dimensionSet & dimensions() const
Return const reference to dimensions.
const Type & value() const
Return const reference to value.
const word & name() const
Return const reference to name.
A class for managing temporary objects.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
gmvFile<< "tracers "<< particles.size()<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().x()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.position().y()<< " ";}gmvFile<< nl;for(const passiveParticle &p :particles){ gmvFile<< p.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))
dimensionedScalar pow6(const dimensionedScalar &ds)
dimensioned< scalar > dimensionedScalar
Dimensioned scalar obtained from generic dimensioned type.
dimensionedScalar pos(const dimensionedScalar &ds)
dimensionedScalar pow5(const dimensionedScalar &ds)
dimensionedScalar erfc(const dimensionedScalar &ds)
dimensionedScalar asin(const dimensionedScalar &ds)
dimensionedScalar exp(const dimensionedScalar &ds)
const dimensionSet dimless
Dimensionless.
dimensionedScalar tan(const dimensionedScalar &ds)
dimensionedScalar pos0(const dimensionedScalar &ds)
dimensionedScalar sign(const dimensionedScalar &ds)
dimensionedScalar lgamma(const dimensionedScalar &ds)
dimensionedScalar j1(const dimensionedScalar &ds)
dimensionedScalar pow3(const dimensionedScalar &ds)
dimensionedScalar y0(const dimensionedScalar &ds)
dimensionedScalar cosh(const dimensionedScalar &ds)
void subtract(FieldField< Field1, typename typeOfSum< Type1, Type2 >::type > &f, const FieldField< Field1, Type1 > &f1, const FieldField< Field2, Type2 > &f2)
dimensionedScalar sin(const dimensionedScalar &ds)
dimensionedScalar tanh(const dimensionedScalar &ds)
dimensionedScalar erf(const dimensionedScalar &ds)
dimensionedScalar sinh(const dimensionedScalar &ds)
dimensionedScalar log10(const dimensionedScalar &ds)
dimensionedScalar yn(const int n, const dimensionedScalar &ds)
dimensionedScalar log(const dimensionedScalar &ds)
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
dimensionedScalar atan2(const dimensionedScalar &x, const dimensionedScalar &y)
dimensionedScalar y1(const dimensionedScalar &ds)
dimensionedScalar negPart(const dimensionedScalar &ds)
dimensionedScalar acosh(const dimensionedScalar &ds)
dimensionedScalar sqrt(const dimensionedScalar &ds)
void add(FieldField< Field1, typename typeOfSum< Type1, Type2 >::type > &f, const FieldField< Field1, Type1 > &f1, const FieldField< Field2, Type2 > &f2)
dimensionedScalar pow4(const dimensionedScalar &ds)
dimensionedScalar jn(const int n, const dimensionedScalar &ds)
void multiply(FieldField< Field, Type > &f, const FieldField< Field, Type > &f1, const FieldField< Field, scalar > &f2)
dimensionSet trans(const dimensionSet &ds)
Check the argument is dimensionless (for transcendental functions)
dimensionedScalar neg(const dimensionedScalar &ds)
dimensionedScalar atanh(const dimensionedScalar &ds)
dimensionedScalar stabilise(const dimensionedScalar &x, const dimensionedScalar &y)
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh > > &tdf1, const word &name, const dimensionSet &dimensions)
Global function forwards to reuseTmpDimensionedField::New.
dimensionedScalar neg0(const dimensionedScalar &ds)
dimensionedScalar cbrt(const dimensionedScalar &ds)
dimensionedScalar atan(const dimensionedScalar &ds)
errorManipArg< error, int > exit(error &err, const int errNo=1)
void divide(FieldField< Field, Type > &f, const FieldField< Field, Type > &f1, const FieldField< Field, scalar > &f2)
dimensionedScalar cos(const dimensionedScalar &ds)
dimensionedScalar posPart(const dimensionedScalar &ds)
dimensionedScalar acos(const dimensionedScalar &ds)
dimensionedScalar j0(const dimensionedScalar &ds)
dimensionedScalar pow025(const dimensionedScalar &ds)
dimensionedScalar asinh(const dimensionedScalar &ds)