initial commit for version 1.6.x patch release
[OpenFOAM-1.6.x.git] / src / finiteVolume / fvMesh / extendedStencil / faceToCell / extendedFaceToCellStencil.H
blob5c334786c6051427ac3927f4f13788890211dce7
1 /*---------------------------------------------------------------------------*\
2   =========                 |
3   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
4    \\    /   O peration     |
5     \\  /    A nd           | Copyright (C) 1991-2009 OpenCFD Ltd.
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     Foam::extendedFaceToCellStencil
28 Description
29     Note: transformations on coupled patches not supported. Problem is the
30     positions of cells reachable through these patches.
32 SourceFiles
33     extendedFaceToCellStencil.C
34     extendedFaceToCellStencilTemplates.C
36 \*---------------------------------------------------------------------------*/
38 #ifndef extendedFaceToCellStencil_H
39 #define extendedFaceToCellStencil_H
41 #include "mapDistribute.H"
42 #include "volFields.H"
43 #include "surfaceFields.H"
45 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47 namespace Foam
50 class globalIndex;
52 /*---------------------------------------------------------------------------*\
53                            Class extendedFaceToCellStencil Declaration
54 \*---------------------------------------------------------------------------*/
56 class extendedFaceToCellStencil
58 protected:
60     // Protected data
62         const polyMesh& mesh_;
64 private:
66     // Private Member Functions
68         //- Disallow default bitwise copy construct
69         extendedFaceToCellStencil(const extendedFaceToCellStencil&);
71         //- Disallow default bitwise assignment
72         void operator=(const extendedFaceToCellStencil&);
75 public:
77     // Constructors
79         //- Construct from mesh
80         explicit extendedFaceToCellStencil(const polyMesh&);
83     // Member Functions
85         //- Use map to get the data into stencil order
86         template<class T>
87         static void collectData
88         (
89             const mapDistribute& map,
90             const labelListList& stencil,
91             const GeometricField<T, fvsPatchField, surfaceMesh>& fld,
92             List<List<T> >& stencilFld
93         );
95         //- Sum surface field contributions to create cell values
96         template<class Type>
97         static tmp<GeometricField<Type, fvPatchField, volMesh> > weightedSum
98         (
99             const mapDistribute& map,
100             const labelListList& stencil,
101             const GeometricField<Type, fvsPatchField, surfaceMesh>& fld,
102             const List<List<scalar> >& stencilWeights
103         );
107 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
109 } // End namespace Foam
111 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
113 #ifdef NoRepository
114 #   include "extendedFaceToCellStencilTemplates.C"
115 #endif
117 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
119 #endif
121 // ************************************************************************* //