1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 2009-2009 OpenCFD Ltd.
7 -------------------------------------------------------------------------------
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
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
26 Foam::WallInteractionModel
29 Templated wall interaction model class
32 WallInteractionModel.C
33 NewWallInteractionModel.C
35 \*---------------------------------------------------------------------------*/
37 #ifndef WallInteractionModel_H
38 #define WallInteractionModel_H
40 #include "IOdictionary.H"
42 #include "runTimeSelectionTables.H"
44 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
49 /*---------------------------------------------------------------------------*\
50 Class WallInteractionModel Declaration
51 \*---------------------------------------------------------------------------*/
53 template<class CloudType>
54 class WallInteractionModel
58 //- The cloud dictionary
59 const dictionary& dict_;
61 // reference to the owner cloud class
64 //- The coefficients dictionary
65 const dictionary coeffDict_;
70 //- Runtime type information
71 TypeName("WallInteractionModel");
73 //- Declare runtime constructor selection table
74 declareRunTimeSelectionTable
80 const dictionary& dict,
89 //- Construct from components
92 const dictionary& dict,
99 virtual ~WallInteractionModel();
103 static autoPtr<WallInteractionModel<CloudType> > New
105 const dictionary& dict,
112 //- Return the owner cloud object
113 const CloudType& owner() const;
115 //- Return non-const access to the owner cloud object
118 //- Return the dictionary
119 const dictionary& dict() const;
121 //- Return the coefficients dictionary
122 const dictionary& coeffDict() const;
127 //- Apply wall correction
130 const wallPolyPatch& wpp,
139 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
141 } // End namespace Foam
143 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
145 #define makeWallInteractionModel(CloudType) \
147 defineNamedTemplateTypeNameAndDebug(WallInteractionModel<CloudType>, 0); \
149 defineTemplateRunTimeSelectionTable \
151 WallInteractionModel<CloudType>, \
156 #define makeWallInteractionModelType(SS, CloudType, ParcelType) \
158 defineNamedTemplateTypeNameAndDebug(SS<CloudType<ParcelType> >, 0); \
160 WallInteractionModel<CloudType<ParcelType> >:: \
161 adddictionaryConstructorToTable<SS<CloudType<ParcelType> > > \
162 add##SS##CloudType##ParcelType##ConstructorToTable_;
165 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
168 # include "WallInteractionModel.C"
171 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
175 // ************************************************************************* //