powerLawUniformBinary.C
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) 2017-2018 OpenFOAM Foundation
9  Copyright (C) 2020 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 \*---------------------------------------------------------------------------*/
28 
29 #include "powerLawUniformBinary.H"
31 
32 // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
33 
34 namespace Foam
35 {
36 namespace diameterModels
37 {
38 namespace binaryBreakupModels
39 {
40  defineTypeNameAndDebug(powerLawUniformBinary, 0);
42  (
43  binaryBreakupModel,
44  powerLawUniformBinary,
45  dictionary
46  );
47 }
48 }
49 }
50 
51 
52 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
53 
56 (
57  const populationBalanceModel& popBal,
58  const dictionary& dict
59 )
60 :
61  binaryBreakupModel(popBal, dict),
62  power_(dict.get<scalar>("power"))
63 {}
64 
65 
66 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
67 
68 void
71 (
72  volScalarField& binaryBreakupRate,
73  const label i,
74  const label j
75 )
76 {
77  const sizeGroup& fj = popBal_.sizeGroups()[j];
78 
79  binaryBreakupRate.primitiveFieldRef() +=
80  pow(fj.x().value(), power_)*2.0/fj.x().value();
81 }
82 
83 
84 // ************************************************************************* //
Foam::diameterModels::binaryBreakupModels::addToRunTimeSelectionTable
addToRunTimeSelectionTable(binaryBreakupModel, LehrMilliesMewes, dictionary)
Foam::dimensioned::value
const Type & value() const
Return const reference to value.
Definition: dimensionedType.C:434
Foam::pow
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
Definition: dimensionedScalar.C:75
Foam::diameterModels::sizeGroup
This class represents a single sizeGroup belonging to a velocityGroup. The main property of a sizeGro...
Definition: sizeGroup.H:96
dict
dictionary dict
Definition: searchingEngine.H:14
Foam::dictionary
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:121
Foam::diameterModels::populationBalanceModel
Class that solves the univariate population balance equation by means of a class method (also called ...
Definition: populationBalanceModel.H:179
addToRunTimeSelectionTable.H
Macros for easy insertion into run-time selection tables.
Foam::diameterModels::binaryBreakupModels::powerLawUniformBinary::powerLawUniformBinary
powerLawUniformBinary(const populationBalanceModel &popBal, const dictionary &dict)
Definition: powerLawUniformBinary.C:56
Foam
Namespace for OpenFOAM.
Definition: atmBoundaryLayer.C:33
Foam::diameterModels::binaryBreakupModels::defineTypeNameAndDebug
defineTypeNameAndDebug(LehrMilliesMewes, 0)
Foam::GeometricField::primitiveFieldRef
Internal::FieldType & primitiveFieldRef(const bool updateAccessTime=true)
Return a reference to the internal field.
Definition: GeometricField.C:766
Foam::diameterModels::binaryBreakupModels::powerLawUniformBinary::addToBinaryBreakupRate
virtual void addToBinaryBreakupRate(volScalarField &binaryBreakupRate, const label i, const label j)
Add to binary breakupRate.
Definition: powerLawUniformBinary.C:71
Foam::diameterModels::binaryBreakupModel
Base class for binary breakup models which give the breakup rate between a sizeGroup pair directly,...
Definition: binaryBreakupModel.H:54
powerLawUniformBinary.H
Foam::GeometricField< scalar, fvPatchField, volMesh >
Foam::diameterModels::sizeGroup::x
const dimensionedScalar & x() const
Return representative volume of the sizeGroup.
Definition: sizeGroupI.H:59