dragModel.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-2015 OpenFOAM Foundation
9 Copyright (C) 2022 OpenCFD Ltd.
10-------------------------------------------------------------------------------
11License
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
27Class
28 Foam::multiphaseEuler::dragModel
29
30Description
31
32SourceFiles
33 dragModel.C
34
35\*---------------------------------------------------------------------------*/
36
37#ifndef Foam_multiphaseEuler_dragModel_H
38#define Foam_multiphaseEuler_dragModel_H
39
40// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
41
42#include "dictionary.H"
43#include "phaseModel.H"
45
46namespace Foam
47{
48namespace multiphaseEuler
49{
50
51/*---------------------------------------------------------------------------*\
52 Class dragModel Declaration
53\*---------------------------------------------------------------------------*/
55class dragModel
56{
57protected:
58
59 // Protected Data
66
67public:
68
69 //- Runtime type information
70 TypeName("dragModel");
71
72
73 // Declare runtime construction
76 (
77 autoPtr,
80 (
81 const dictionary& interfaceDict,
82 const phaseModel& phase1,
83 const phaseModel& phase2
84 ),
85 (interfaceDict, phase1, phase2)
86 );
87
88
89 // Constructors
90
92 (
93 const dictionary& dict,
94 const phaseModel& phase1,
95 const phaseModel& phase2
96 );
97
98
99 //- Destructor
100 virtual ~dragModel() = default;
101
102
103 // Selectors
104
106 (
107 const dictionary& dict,
108 const phaseModel& phase1,
109 const phaseModel& phase2
110 );
111
112
113 // Member Functions
115 const phaseModel& phase1() const
116 {
117 return phase1_;
118 }
120 const phaseModel& phase2() const
121 {
122 return phase2_;
123 }
126 {
128 }
130 const dimensionedScalar& residualSlip() const
131 {
132 return residualSlip_;
133 }
134
135 //- The drag function K used in the momentum eq.
136 // ddt(alpha1*rho1*U1) + ... = ... alpha1*alpha2*K*(U1-U2)
137 // ddt(alpha2*rho2*U2) + ... = ... alpha1*alpha2*K*(U2-U1)
138 // ********************************** NB! *****************************
139 // for numerical reasons alpha1 and alpha2 has been
140 // extracted from the dragFunction K,
141 // so you MUST divide K by alpha1*alpha2 when implementing the drag
142 // function
143 // ********************************** NB! *****************************
144 virtual tmp<volScalarField> K(const volScalarField& Ur) const = 0;
145};
146
147
148// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
149
150} // End namespace multiphaseEuler
151} // End namespace Foam
152
153// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
154
155#endif
156
157// ************************************************************************* //
CGAL::Exact_predicates_exact_constructions_kernel K
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
Definition: autoPtr.H:66
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
const phaseModel & phase2() const
Definition: dragModel.H:119
dimensionedScalar residualSlip_
Definition: dragModel.H:64
const dimensionedScalar & residualSlip() const
Definition: dragModel.H:129
const phaseModel & phase2_
Definition: dragModel.H:62
declareRunTimeSelectionTable(autoPtr, dragModel, dictionary,(const dictionary &interfaceDict, const phaseModel &phase1, const phaseModel &phase2),(interfaceDict, phase1, phase2))
virtual ~dragModel()=default
Destructor.
TypeName("dragModel")
Runtime type information.
const dictionary & interfaceDict_
Definition: dragModel.H:60
static autoPtr< dragModel > New(const dictionary &dict, const phaseModel &phase1, const phaseModel &phase2)
Definition: dragModel.C:64
dimensionedScalar residualPhaseFraction_
Definition: dragModel.H:63
const phaseModel & phase1_
Definition: dragModel.H:61
const phaseModel & phase1() const
Definition: dragModel.H:114
const dimensionedScalar & residualPhaseFraction() const
Definition: dragModel.H:124
Single incompressible phase derived from the phase-fraction. Used as part of the multiPhaseMixture fo...
Definition: phaseModel.H:61
A class for managing temporary objects.
Definition: tmp.H:65
Namespace for OpenFOAM.
Macros to ease declaration of run-time selection tables.
#define declareRunTimeSelectionTable(ptrWrapper, baseType, argNames, argList, parList)
Declare a run-time selection (variables and adder classes)
dictionary dict
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73