OpenFOAM logo
The Open Source CFD Toolbox
  Source Guide OpenCFD Solutions Contact OpenFOAM

DimensionedScalarField.H

Go to the documentation of this file.
00001 /*---------------------------------------------------------------------------*\
00002   =========                 |
00003   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
00004    \\    /   O peration     |
00005     \\  /    A nd           | Copyright (C) 1991-2009 OpenCFD Ltd.
00006      \\/     M anipulation  |
00007 -------------------------------------------------------------------------------
00008 License
00009     This file is part of OpenFOAM.
00010 
00011     OpenFOAM is free software; you can redistribute it and/or modify it
00012     under the terms of the GNU General Public License as published by the
00013     Free Software Foundation; either version 2 of the License, or (at your
00014     option) any later version.
00015 
00016     OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
00017     ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00018     FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
00019     for more details.
00020 
00021     You should have received a copy of the GNU General Public License
00022     along with OpenFOAM; if not, write to the Free Software Foundation,
00023     Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
00024 
00025 InClass
00026     Foam::DimensionedScalarField
00027 
00028 Description
00029     Scalar specific part of the implementation of DimensionedField.
00030 
00031 SourceFiles
00032     DimensionedScalarField.C
00033 
00034 \*---------------------------------------------------------------------------*/
00035 
00036 #ifndef DimensionedScalarField_H
00037 #define DimensionedScalarField_H
00038 
00039 #include "DimensionedField.H"
00040 #include "scalar.H"
00041 
00042 #define TEMPLATE template<class GeoMesh>
00043 #include "DimensionedFieldFunctionsM.H"
00044 
00045 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00046 
00047 namespace Foam
00048 {
00049 
00050 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00051 
00052 template<class GeoMesh>
00053 tmp<DimensionedField<scalar, GeoMesh> > stabilise
00054 (
00055     const DimensionedField<scalar, GeoMesh>&,
00056     const dimensioned<scalar>&
00057 );
00058 
00059 template<class GeoMesh>
00060 tmp<DimensionedField<scalar, GeoMesh> > stabilise
00061 (
00062     const tmp<DimensionedField<scalar, GeoMesh> >&,
00063     const dimensioned<scalar>&
00064 );
00065 
00066 
00067 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00068 
00069 BINARY_TYPE_OPERATOR(scalar, scalar, scalar, +, '+', add)
00070 BINARY_TYPE_OPERATOR(scalar, scalar, scalar, -, '-', subtract)
00071 
00072 BINARY_OPERATOR(scalar, scalar, scalar, *, '*', multiply)
00073 BINARY_OPERATOR(scalar, scalar, scalar, /, '|', divide)
00074 
00075 BINARY_TYPE_OPERATOR_SF(scalar, scalar, scalar, /, '|', divide)
00076 
00077 BINARY_FUNCTION(scalar, scalar, scalar, pow)
00078 BINARY_TYPE_FUNCTION(scalar, scalar, scalar, pow)
00079 
00080 
00081 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00082 
00083 UNARY_FUNCTION(scalar, scalar, pow3, pow3)
00084 UNARY_FUNCTION(scalar, scalar, pow4, pow4)
00085 UNARY_FUNCTION(scalar, scalar, pow5, pow5)
00086 UNARY_FUNCTION(scalar, scalar, pow6, pow6)
00087 UNARY_FUNCTION(scalar, scalar, sqrt, sqrt)
00088 UNARY_FUNCTION(scalar, scalar, sign, sign)
00089 UNARY_FUNCTION(scalar, scalar, pos, pos)
00090 UNARY_FUNCTION(scalar, scalar, neg, neg)
00091 
00092 UNARY_FUNCTION(scalar, scalar, exp, trans)
00093 UNARY_FUNCTION(scalar, scalar, log, trans)
00094 UNARY_FUNCTION(scalar, scalar, log10, trans)
00095 UNARY_FUNCTION(scalar, scalar, sin, trans)
00096 UNARY_FUNCTION(scalar, scalar, cos, trans)
00097 UNARY_FUNCTION(scalar, scalar, tan, trans)
00098 UNARY_FUNCTION(scalar, scalar, asin, trans)
00099 UNARY_FUNCTION(scalar, scalar, acos, trans)
00100 UNARY_FUNCTION(scalar, scalar, atan, trans)
00101 UNARY_FUNCTION(scalar, scalar, sinh, trans)
00102 UNARY_FUNCTION(scalar, scalar, cosh, trans)
00103 UNARY_FUNCTION(scalar, scalar, tanh, trans)
00104 UNARY_FUNCTION(scalar, scalar, asinh, trans)
00105 UNARY_FUNCTION(scalar, scalar, acosh, trans)
00106 UNARY_FUNCTION(scalar, scalar, atanh, trans)
00107 UNARY_FUNCTION(scalar, scalar, erf, trans)
00108 UNARY_FUNCTION(scalar, scalar, erfc, trans)
00109 UNARY_FUNCTION(scalar, scalar, lgamma, trans)
00110 UNARY_FUNCTION(scalar, scalar, j0, trans)
00111 UNARY_FUNCTION(scalar, scalar, j1, trans)
00112 UNARY_FUNCTION(scalar, scalar, y0, trans)
00113 UNARY_FUNCTION(scalar, scalar, y1, trans)
00114 
00115 
00116 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00117 
00118 #define BesselFunc(func)                                                       \
00119                                                                                \
00120 template<class GeoMesh>                                                        \
00121 tmp<DimensionedField<scalar, GeoMesh> > func                                   \
00122 (                                                                              \
00123     const int n,                                                               \
00124     const DimensionedField<scalar, GeoMesh>&                                   \
00125 );                                                                             \
00126                                                                                \
00127 template<class GeoMesh>                                                        \
00128 tmp<DimensionedField<scalar, GeoMesh> > func                                   \
00129 (                                                                              \
00130     const int n,                                                               \
00131     const tmp<DimensionedField<scalar, GeoMesh> >&                             \
00132 );
00133 
00134 BesselFunc(jn)
00135 BesselFunc(yn)
00136 
00137 #undef BesselFunc
00138 
00139 
00140 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00141 
00142 } // End namespace Foam
00143 
00144 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00145 
00146 #include "undefFieldFunctionsM.H"
00147 
00148 #ifdef NoRepository
00149 #   include "DimensionedScalarField.C"
00150 #endif
00151 
00152 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00153 
00154 #endif
00155 
00156 // ************************************************************************* //
Copyright © 2000-2009 OpenCFD Ltd