transformFieldField.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration |
5  \\ / A nd | www.openfoam.com
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8  Copyright (C) 2011-2016 OpenFOAM Foundation
9  Copyright (C) 2018 OpenCFD Ltd.
10 -------------------------------------------------------------------------------
11 License
12  This file is part of OpenFOAM.
13 
14  OpenFOAM is free software: you can redistribute it and/or modify it
15  under the terms of the GNU General Public License as published by
16  the Free Software Foundation, either version 3 of the License, or
17  (at your option) any later version.
18 
19  OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
20  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
21  FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22  for more details.
23 
24  You should have received a copy of the GNU General Public License
25  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
26 
27 InNamespace
28  Foam
29 
30 Description
31  transformFieldField
32  Spatial transformation functions for FieldField.
33 
34 SourceFiles
35  transformFieldField.C
36 
37 \*---------------------------------------------------------------------------*/
38 
39 #ifndef transformFieldField_H
40 #define transformFieldField_H
41 
42 #include "transform.H"
43 #include "tensorFieldField.H"
44 
45 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46 
47 namespace Foam
48 {
49 
50 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
51 
52 // transform()
53 
54 template<template<class> class Field, class Type>
55 void transform
56 (
57  FieldField<Field, Type>& result,
58  const tensor& rot,
59  const FieldField<Field, Type>& fld
60 );
61 
62 template<template<class> class Field, class Type>
63 void transform
64 (
65  FieldField<Field, Type>& result,
66  const FieldField<Field, tensor>& rot,
67  const FieldField<Field, Type>& fld
68 );
69 
70 template<template<class> class Field, class Type>
71 tmp<FieldField<Field, Type>> transform
72 (
73  const FieldField<Field, tensor>& rot,
74  const FieldField<Field, Type>& fld
75 );
76 
77 template<template<class> class Field, class Type>
78 tmp<FieldField<Field, Type>> transform
79 (
80  const FieldField<Field, tensor>& rot,
81  const tmp<FieldField<Field, Type>>& tfld
82 );
83 
84 template<template<class> class Field, class Type>
85 tmp<FieldField<Field, Type>> transform
86 (
87  const tmp<FieldField<Field, tensor>>& trot,
88  const FieldField<Field, Type>& fld
89 );
90 
91 template<template<class> class Field, class Type>
92 tmp<FieldField<Field, Type>> transform
93 (
94  const tmp<FieldField<Field, tensor>>& trot,
95  const tmp<FieldField<Field, Type>>& tfld
96 );
97 
98 
99 template<template<class> class Field, class Type>
100 tmp<FieldField<Field, Type>> transform
101 (
102  const tensor& rot,
103  const FieldField<Field, Type>& fld
104 );
105 
106 template<template<class> class Field, class Type>
107 tmp<FieldField<Field, Type>> transform
108 (
109  const tensor& rot,
110  const tmp<FieldField<Field, Type>>& tfld
111 );
112 
113 
114 // invTransform()
115 
116 template<template<class> class Field, class Type>
117 void invTransform
118 (
119  FieldField<Field, Type>& result,
120  const tensor& rot,
121  const FieldField<Field, Type>& fld
122 );
123 
124 template<template<class> class Field, class Type>
125 void invTransform
126 (
127  FieldField<Field, Type>& result,
128  const FieldField<Field, tensor>& rot,
129  const FieldField<Field, Type>& fld
130 );
131 
132 template<template<class> class Field, class Type>
133 tmp<FieldField<Field, Type>> invTransform
134 (
135  const FieldField<Field, tensor>& rot,
136  const FieldField<Field, Type>& fld
137 );
138 
139 template<template<class> class Field, class Type>
140 tmp<FieldField<Field, Type>> invTransform
141 (
142  const FieldField<Field, tensor>& rot,
143  const tmp<FieldField<Field, Type>>& tfld
144 );
145 
146 template<template<class> class Field, class Type>
147 tmp<FieldField<Field, Type>> invTransform
148 (
149  const tmp<FieldField<Field, tensor>>& trot,
150  const FieldField<Field, Type>& fld
151 );
152 
153 template<template<class> class Field, class Type>
154 tmp<FieldField<Field, Type>> invTransform
155 (
156  const tmp<FieldField<Field, tensor>>& trot,
157  const tmp<FieldField<Field, Type>>& tfld
158 );
159 
160 
161 template<template<class> class Field, class Type>
162 tmp<FieldField<Field, Type>> invTransform
163 (
164  const tensor& rot,
165  const FieldField<Field, Type>& fld
166 );
167 
168 template<template<class> class Field, class Type>
169 tmp<FieldField<Field, Type>> invTransform
170 (
171  const tensor& rot,
172  const tmp<FieldField<Field, Type>>& tfld
173 );
174 
175 
176 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
177 
178 } // End namespace Foam
179 
180 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
181 
182 #ifdef NoRepository
183  #include "transformFieldField.C"
184 #endif
185 
186 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
187 
188 #endif
189 
190 // ************************************************************************* //
tensorFieldField.H
Specialisation of FieldField<T> for tensor.
Foam::transform
dimensionSet transform(const dimensionSet &ds)
Return the argument; transformations do not change the dimensions.
Definition: dimensionSet.C:521
fld
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;for(const word &name :lagrangianScalarNames){ IOField< scalar > fld(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
Definition: gmvOutputLagrangian.H:23
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Foam::invTransform
dimensionSet invTransform(const dimensionSet &ds)
Return the argument; transformations do not change the dimensions.
Definition: dimensionSet.C:527
transformFieldField.C
transform.H
3D tensor transformation operations.
Foam::tensor
Tensor< scalar > tensor
Tensor of scalars, i.e. Tensor<scalar>.
Definition: symmTensor.H:61