38 #ifndef Foam_tensorFieldField_H 39 #define Foam_tensorFieldField_H 45 #define TEMPLATE template<template<class> class Field> 56 template<
template<
class>
class Field,
class Cmpt>
59 FieldField<Field, Tensor<Cmpt>>& result,
60 const FieldField<Field, Cmpt>& xx,
61 const FieldField<Field, Cmpt>& xy,
62 const FieldField<Field, Cmpt>& xz,
63 const FieldField<Field, Cmpt>& yx,
64 const FieldField<Field, Cmpt>& yy,
65 const FieldField<Field, Cmpt>& yz,
66 const FieldField<Field, Cmpt>& zx,
67 const FieldField<Field, Cmpt>& zy,
68 const FieldField<Field, Cmpt>& zz
72 template<
template<
class>
class Field,
class Cmpt>
75 const FieldField<Field, Tensor<Cmpt>>&
input,
76 FieldField<Field, Cmpt>& xx,
77 FieldField<Field, Cmpt>& xy,
78 FieldField<Field, Cmpt>& xz,
79 FieldField<Field, Cmpt>& yx,
80 FieldField<Field, Cmpt>& yy,
81 FieldField<Field, Cmpt>& yz,
82 FieldField<Field, Cmpt>& zx,
83 FieldField<Field, Cmpt>& zy,
84 FieldField<Field, Cmpt>& zz
89 template<
template<
class>
class Field,
class Cmpt>
92 FieldField<Field, Tensor<Cmpt>>& result,
93 const FieldField<Field, Vector<Cmpt>>&
x,
94 const FieldField<Field, Vector<Cmpt>>&
y,
95 const FieldField<Field, Vector<Cmpt>>& z
99 template<
template<
class>
class Field,
class Cmpt>
102 FieldField<Field, Tensor<Cmpt>>& result,
103 const FieldField<Field, Vector<Cmpt>>&
x,
104 const FieldField<Field, Vector<Cmpt>>&
y,
105 const FieldField<Field, Vector<Cmpt>>& z
110 template<
template<
class>
class Field,
class Cmpt>
113 const FieldField<Field, Tensor<Cmpt>>&
input,
114 FieldField<Field, Vector<Cmpt>>&
x,
115 FieldField<Field, Vector<Cmpt>>&
y,
116 FieldField<Field, Vector<Cmpt>>& z
120 template<
template<
class>
class Field,
class Cmpt>
123 const FieldField<Field, Tensor<Cmpt>>&
input,
124 FieldField<Field, Vector<Cmpt>>&
x,
125 FieldField<Field, Vector<Cmpt>>&
y,
126 FieldField<Field, Vector<Cmpt>>& z
131 template<
template<
class>
class Field,
class Cmpt>
134 const FieldField<Field, Tensor<Cmpt>>&
input,
136 FieldField<Field, Vector<Cmpt>>& result
140 template<
template<
class>
class Field,
class Cmpt>
143 const FieldField<Field, Tensor<Cmpt>>&
input,
145 FieldField<Field, Vector<Cmpt>>& result
149 template<
template<
class>
class Field,
class Cmpt>
152 const FieldField<Field, Tensor<Cmpt>>&
input,
153 FieldField<Field, Vector<Cmpt>>& result
#define BINARY_OPERATOR(ReturnType, Type1, Type2, Op, OpName, OpFunc)
void divide(DimensionedField< Type, GeoMesh > &result, const DimensionedField< Type, GeoMesh > &f1, const DimensionedField< scalar, GeoMesh > &f2)
Specialisation of FieldField<T> for symmTensor.
void unzipCols(const FieldField< Field, SymmTensor< Cmpt >> &input, FieldField< Field, Vector< Cmpt >> &x, FieldField< Field, Vector< Cmpt >> &y, FieldField< Field, Vector< Cmpt >> &z)
Extract symmTensor field field columns.
#define UNARY_FUNCTION(ReturnType, Type1, Func, Dfunc)
dimensionedTensor skew(const dimensionedTensor &dt)
dimensionedSphericalTensor inv(const dimensionedSphericalTensor &dt)
void zip(FieldField< Field, SphericalTensor< Cmpt >> &result, const FieldField< Field, Cmpt > &ii)
Zip together sphericalTensor field field from components.
void zipCols(FieldField< Field, SymmTensor< Cmpt >> &result, const FieldField< Field, Vector< Cmpt >> &x, const FieldField< Field, Vector< Cmpt >> &y, const FieldField< Field, Vector< Cmpt >> &z)
Zip together symmTensor field from column components.
void unzipRow(const FieldField< Field, SymmTensor< Cmpt >> &input, const direction idx, FieldField< Field, Vector< Cmpt >> &result)
Extract a symmTensor field field row (x,y,z) == (0,1,2)
SymmTensor< Cmpt > devSymm(const SymmTensor< Cmpt > &st)
Return the deviatoric part of the symmetric part of a SymmTensor.
dimensionedScalar det(const dimensionedSphericalTensor &dt)
SphericalTensor< Cmpt > sph(const DiagTensor< Cmpt > &dt)
Return the spherical part of a DiagTensor as a SphericalTensor.
void unzipRows(const FieldField< Field, SymmTensor< Cmpt >> &input, FieldField< Field, Vector< Cmpt >> &x, FieldField< Field, Vector< Cmpt >> &y, FieldField< Field, Vector< Cmpt >> &z)
Extract symmTensor field field rows.
void zipRows(FieldField< Field, SymmTensor< Cmpt >> &result, const FieldField< Field, Vector< Cmpt >> &x, const FieldField< Field, Vector< Cmpt >> &y, const FieldField< Field, Vector< Cmpt >> &z)
Zip together symmTensor field field from row components.
dimensionedSymmTensor twoSymm(const dimensionedSymmTensor &dt)
dimensionedTensor eigenVectors(const dimensionedSymmTensor &dt)
void unzip(const FieldField< Field, SphericalTensor< Cmpt >> &input, FieldField< Field, Cmpt > &ii)
Unzip sphericalTensor field field into components.
void unzipDiag(const FieldField< Field, SymmTensor< Cmpt >> &input, FieldField< Field, Vector< Cmpt >> &result)
Extract a symmTensor field field diagonal.
dimensionedSymmTensor dev(const dimensionedSymmTensor &dt)
SymmTensor< scalar > symmTensor
SymmTensor of scalars, i.e. SymmTensor<scalar>.
static Istream & input(Istream &is, IntRange< T > &range)
dimensionedScalar tr(const dimensionedSphericalTensor &dt)
void hdual(pointPatchField< vector > &, const pointPatchField< tensor > &)
Specialisation of FieldField<Field, T> for sphericalTensor.
void unzipCol(const FieldField< Field, SymmTensor< Cmpt >> &input, const direction idx, FieldField< Field, Vector< Cmpt >> &result)
Extract a symmTensor field field column (x,y,z) == (0,1,2)
Macro functions for FieldField<Type> algebra.
dimensionedSymmTensor dev2(const dimensionedSymmTensor &dt)
dimensionedSymmTensor symm(const dimensionedSymmTensor &dt)
dimensionedVector eigenValues(const dimensionedSymmTensor &dt)
#define UNARY_OPERATOR(ReturnType, Type1, Op, OpFunc, Dfunc)
SphericalTensor< scalar > sphericalTensor
SphericalTensor of scalars, i.e. SphericalTensor<scalar>.
#define BINARY_TYPE_OPERATOR(ReturnType, Type1, Type2, Op, OpName, OpFunc)
dimensionedSymmTensor cof(const dimensionedSymmTensor &dt)
SymmTensor< Cmpt > devTwoSymm(const SymmTensor< Cmpt > &st)
Return the deviatoric part of twice the symmetric part of a SymmTensor.