fixed writing out entries in advective bc
[OpenFOAM-1.6-ext.git] / src / VectorN / OpenFOAM / Fields / TensorNFields.H
blob7c78647f25a2b25507f6538cbe5ec9b274ca0926
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright held by original author
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 the
13     Free Software Foundation; either version 2 of the License, or (at your
14     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, write to the Free Software Foundation,
23     Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
25 Class
26     tensorNFields
28 Description
29     Specialisation of Field<T> for TensorN.
31 SourceFiles
32     TensorNFields.C
34 \*---------------------------------------------------------------------------*/
36 #ifndef TensorNFields_H
37 #define TensorNFields_H
39 #include "VectorTensorNFieldsFwd.H"
40 #include "Field.H"
42 #define TEMPLATE
43 #include "FieldFunctionsM.H"
45 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47 #define TensorN_FieldFunctions(tensorType,diagTensorType,                    \
48                                sphericalTensorType,vectorType,CmptType,      \
49                                args...)                                      \
50                                                                              \
51 UNARY_FUNCTION(tensorType, tensorType, inv)                                  \
52 UNARY_FUNCTION(diagTensorType, tensorType, diag)                             \
53 UNARY_FUNCTION(tensorType, tensorType, negSumDiag)                           \
54                                                                              \
55 BINARY_OPERATOR(tensorType, CmptType, tensorType, /, divide)                 \
56 BINARY_TYPE_OPERATOR(tensorType, CmptType, tensorType, /, divide)            \
57                                                                              \
58 BINARY_OPERATOR(vectorType, vectorType, tensorType, /, divide)               \
59 BINARY_TYPE_OPERATOR(vectorType, vectorType, tensorType, /, divide)          \
60                                                                              \
61 BINARY_OPERATOR(tensorType, tensorType, tensorType, /, divide)               \
62 BINARY_TYPE_OPERATOR(tensorType, tensorType, tensorType, /, divide)          \
63                                                                              \
64 BINARY_OPERATOR(tensorType, tensorType, diagTensorType, /, divide)           \
65 BINARY_TYPE_OPERATOR(tensorType, tensorType, diagTensorType, /, divide)      \
66                                                                              \
67 BINARY_OPERATOR(tensorType, diagTensorType, tensorType, /, divide)           \
68 BINARY_TYPE_OPERATOR(tensorType, diagTensorType, tensorType, /, divide)      \
69                                                                              \
70 BINARY_OPERATOR(tensorType, sphericalTensorType, tensorType, /, divide)      \
71 BINARY_TYPE_OPERATOR(tensorType, sphericalTensorType, tensorType, /, divide) \
72                                                                              \
73 BINARY_OPERATOR(tensorType, tensorType, sphericalTensorType, /, divide)      \
74 BINARY_TYPE_OPERATOR(tensorType, tensorType, sphericalTensorType, /, divide) \
75                                                                              \
76 BINARY_OPERATOR(tensorType, tensorType, tensorType, +, add)                  \
77 BINARY_OPERATOR(tensorType, tensorType, tensorType, -, subtract)             \
78                                                                              \
79 BINARY_TYPE_OPERATOR(tensorType, tensorType, tensorType, +, add)             \
80 BINARY_TYPE_OPERATOR(tensorType, tensorType, tensorType, -, subtract)        \
81                                                                              \
82 BINARY_OPERATOR(tensorType, diagTensorType, tensorType, +, add)              \
83 BINARY_OPERATOR(tensorType, diagTensorType, tensorType, -, subtract)         \
84                                                                              \
85 BINARY_TYPE_OPERATOR(tensorType, diagTensorType, tensorType, +, add)         \
86 BINARY_TYPE_OPERATOR(tensorType, diagTensorType, tensorType, -, subtract)    \
87                                                                              \
88 BINARY_OPERATOR(tensorType, tensorType, diagTensorType, +, add)              \
89 BINARY_OPERATOR(tensorType, tensorType, diagTensorType, -, subtract)         \
90                                                                              \
91 BINARY_TYPE_OPERATOR(tensorType, tensorType, diagTensorType, +, add)         \
92 BINARY_TYPE_OPERATOR(tensorType, tensorType, diagTensorType, -, subtract)    \
93                                                                              \
94 BINARY_OPERATOR(tensorType, sphericalTensorType, tensorType, +, add)         \
95 BINARY_OPERATOR(tensorType, sphericalTensorType, tensorType, -, subtract)    \
96                                                                              \
97 BINARY_TYPE_OPERATOR(tensorType, sphericalTensorType, tensorType, +, add)    \
98 BINARY_TYPE_OPERATOR(tensorType, sphericalTensorType, tensorType, -, subtract) \
99                                                                              \
100 BINARY_OPERATOR(tensorType, tensorType, sphericalTensorType, +, add)         \
101 BINARY_OPERATOR(tensorType, tensorType, sphericalTensorType, -, subtract)    \
102                                                                              \
103 BINARY_TYPE_OPERATOR(tensorType, tensorType, sphericalTensorType, +, add)    \
104 BINARY_TYPE_OPERATOR(tensorType, tensorType, sphericalTensorType, -, subtract)
106 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
108 namespace Foam
111 forAllVectorTensorNTypes(TensorN_FieldFunctions)
115 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
117 #undef TensorN_FieldFunctions
119 #include "undefFieldFunctionsM.H"
121 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
123 #endif
125 // ************************************************************************* //