ENH: autoLayerDriver: better layering information message
[OpenFOAM-2.0.x.git] / src / OpenFOAM / fields / GeometricFields / GeometricScalarField / GeometricScalarField.H
blobfa3280ce74f22a7933077aff8377a802ea904e47
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 2011 OpenFOAM Foundation
6      \\/     M anipulation  |
7 -------------------------------------------------------------------------------
8 License
9     This file is part of OpenFOAM.
11     OpenFOAM is free software: you can redistribute it and/or modify it
12     under the terms of the GNU General Public License as published by
13     the Free Software Foundation, either version 3 of the License, or
14     (at your option) any later version.
16     OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17     ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18     FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
19     for more details.
21     You should have received a copy of the GNU General Public License
22     along with OpenFOAM.  If not, see <http://www.gnu.org/licenses/>.
24 InClass
25     Foam::GeometricScalarField
27 Description
28     Scalar specific part of the implementation of GeometricField.
30 SourceFiles
31     GeometricScalarField.C
33 \*---------------------------------------------------------------------------*/
35 #ifndef GeometricScalarField_H
36 #define GeometricScalarField_H
38 #include "GeometricField.H"
39 #include "DimensionedScalarField.H"
41 #define TEMPLATE template<template<class> class PatchField, class GeoMesh>
42 #include "GeometricFieldFunctionsM.H"
44 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46 namespace Foam
49 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
51 template<template<class> class PatchField, class GeoMesh>
52 void stabilise
54     GeometricField<scalar, PatchField, GeoMesh>&,
55     const GeometricField<scalar, PatchField, GeoMesh>&,
56     const dimensioned<scalar>&
59 template<template<class> class PatchField, class GeoMesh>
60 tmp<GeometricField<scalar, PatchField, GeoMesh> > stabilise
62     const GeometricField<scalar, PatchField, GeoMesh>&,
63     const dimensioned<scalar>&
66 template<template<class> class PatchField, class GeoMesh>
67 tmp<GeometricField<scalar, PatchField, GeoMesh> > stabilise
69     const tmp<GeometricField<scalar, PatchField, GeoMesh> >&,
70     const dimensioned<scalar>&
74 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
76 BINARY_TYPE_OPERATOR(scalar, scalar, scalar, +, '+', add)
77 BINARY_TYPE_OPERATOR(scalar, scalar, scalar, -, '-', subtract)
79 BINARY_OPERATOR(scalar, scalar, scalar, *, '*', multiply)
80 BINARY_OPERATOR(scalar, scalar, scalar, /, '|', divide)
82 BINARY_TYPE_OPERATOR_SF(scalar, scalar, scalar, /, '|', divide)
84 BINARY_FUNCTION(scalar, scalar, scalar, pow)
85 BINARY_TYPE_FUNCTION(scalar, scalar, scalar, pow)
88 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
90 UNARY_FUNCTION(scalar, scalar, pow3, pow3)
91 UNARY_FUNCTION(scalar, scalar, pow4, pow4)
92 UNARY_FUNCTION(scalar, scalar, pow5, pow5)
93 UNARY_FUNCTION(scalar, scalar, pow6, pow6)
94 UNARY_FUNCTION(scalar, scalar, pow025, pow025)
95 UNARY_FUNCTION(scalar, scalar, sqrt, sqrt)
96 UNARY_FUNCTION(scalar, scalar, sign, sign)
97 UNARY_FUNCTION(scalar, scalar, pos, pos)
98 UNARY_FUNCTION(scalar, scalar, neg, neg)
100 UNARY_FUNCTION(scalar, scalar, exp, trans)
101 UNARY_FUNCTION(scalar, scalar, log, trans)
102 UNARY_FUNCTION(scalar, scalar, log10, trans)
103 UNARY_FUNCTION(scalar, scalar, sin, trans)
104 UNARY_FUNCTION(scalar, scalar, cos, trans)
105 UNARY_FUNCTION(scalar, scalar, tan, trans)
106 UNARY_FUNCTION(scalar, scalar, asin, trans)
107 UNARY_FUNCTION(scalar, scalar, acos, trans)
108 UNARY_FUNCTION(scalar, scalar, atan, trans)
109 UNARY_FUNCTION(scalar, scalar, sinh, trans)
110 UNARY_FUNCTION(scalar, scalar, cosh, trans)
111 UNARY_FUNCTION(scalar, scalar, tanh, trans)
112 UNARY_FUNCTION(scalar, scalar, asinh, trans)
113 UNARY_FUNCTION(scalar, scalar, acosh, trans)
114 UNARY_FUNCTION(scalar, scalar, atanh, trans)
115 UNARY_FUNCTION(scalar, scalar, erf, trans)
116 UNARY_FUNCTION(scalar, scalar, erfc, trans)
117 UNARY_FUNCTION(scalar, scalar, lgamma, trans)
118 UNARY_FUNCTION(scalar, scalar, j0, trans)
119 UNARY_FUNCTION(scalar, scalar, j1, trans)
120 UNARY_FUNCTION(scalar, scalar, y0, trans)
121 UNARY_FUNCTION(scalar, scalar, y1, trans)
124 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
126 #define BesselFunc(func)                                                       \
127                                                                                \
128 template<template<class> class PatchField, class GeoMesh>                      \
129 void func                                                                      \
130 (                                                                              \
131     GeometricField<scalar, PatchField, GeoMesh>& Res,                          \
132     const int n,                                                               \
133     const GeometricField<scalar, PatchField, GeoMesh>& sf                      \
134 );                                                                             \
135                                                                                \
136 template<template<class> class PatchField, class GeoMesh>                      \
137 tmp<GeometricField<scalar, PatchField, GeoMesh> > func                         \
138 (                                                                              \
139     const int n,                                                               \
140     const GeometricField<scalar, PatchField, GeoMesh>&                         \
141 );                                                                             \
142                                                                                \
143 template<template<class> class PatchField, class GeoMesh>                      \
144 tmp<GeometricField<scalar, PatchField, GeoMesh> > func                         \
145 (                                                                              \
146     const int n,                                                               \
147     const tmp<GeometricField<scalar, PatchField, GeoMesh> >&                   \
150 BesselFunc(jn)
151 BesselFunc(yn)
153 #undef BesselFunc
156 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
158 } // End namespace Foam
160 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
162 #include "undefFieldFunctionsM.H"
164 #ifdef NoRepository
165 #   include "GeometricScalarField.C"
166 #endif
168 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
170 #endif
172 // ************************************************************************* //