FreeFOAM The Cross-Platform CFD Toolkit
motionDiffusivity.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 | Copyright (C) 1991-2010 OpenCFD Ltd.
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
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.
15 
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.
20 
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/>.
23 
24 Class
25  Foam::motionDiffusivity
26 
27 Description
28  Abstract base class for cell-centre mesh motion diffusivity.
29 
30 SourceFiles
31  motionDiffusivity.C
32 
33 \*---------------------------------------------------------------------------*/
34 
35 #ifndef motionDiffusivity_H
36 #define motionDiffusivity_H
37 
40 
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
42 
43 namespace Foam
44 {
45 
46 /*---------------------------------------------------------------------------*\
47  Class motionDiffusivity Declaration
48 \*---------------------------------------------------------------------------*/
49 
51 {
52  // Private data
53 
54  //- Motion solver reference
55  const fvMotionSolver& mSolver_;
56 
57 public:
58 
59  //- Runtime type information
60  TypeName("motionDiffusivity");
61 
62 
63  // Declare run-time constructor selection tables
64 
66  (
67  autoPtr,
69  Istream,
70  (
71  const fvMotionSolver& mSolver,
72  Istream& mdData
73  ),
74  (mSolver, mdData)
75  );
76 
77 
78  // Selectors
79 
80  //- Select null constructed
82  (
83  const fvMotionSolver& mSolver,
84  Istream& mdData
85  );
86 
87 
88  // Constructors
89 
90  //- Construct for the given fvMotionSolver
91  motionDiffusivity(const fvMotionSolver& mSolver);
92 
93 
94  // Destructor
95 
96  virtual ~motionDiffusivity();
97 
98 
99  // Member Functions
100 
101  //- Return reference to the motion solver
102  const fvMotionSolver& mSolver() const
103  {
104  return mSolver_;
105  }
106 
107  //- Return diffusivity field
108  virtual tmp<surfaceScalarField> operator()() const = 0;
109 
110  //- Correct the motion diffusivity
111  virtual void correct() = 0;
112 };
113 
114 
115 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
116 
117 } // End namespace Foam
118 
119 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
120 
121 #endif
122 
123 // ************************ vim: set sw=4 sts=4 et: ************************ //