CrossPowerLaw.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) 2018-2020 OpenFOAM Foundation
9 Copyright (C) 2020 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::laminarModels::generalizedNewtonianViscosityModels::CrossPowerLaw
29
30Description
31 Cross-Power law generalized Newtonian viscosity model
32
33 The strain rate coefficient can be specified either as the constant \c m or
34 the critical stress level at the transition to shear thinning \c
35 tauStar if \c tauStar is provided:
36
37 Kinematic viscosity [m^2/s]
38
39 \f[
40 \nu = \nu_\infty + \frac{(\nu_0 - \nu_\infty)}{1 + (m\gamma)^n}
41 \f]
42
43 or
44
45 \f[
46 \nu = \nu_\infty
47 + \frac{(\nu_0 - \nu_\infty)}
48 {1 + \left(\frac{\nu_0\gamma}{\tau^*}\right)^n}
49 \f]
50
51 Example specification:
52 \verbatim
53 viscosityModel CrossPowerLaw;
54
55 nuInf 10;
56 m 0.4;
57 n 3;
58 \endverbatim
59
60SourceFiles
61 CrossPowerLaw.C
62
63\*---------------------------------------------------------------------------*/
64
65#ifndef CrossPowerLaw_H
66#define CrossPowerLaw_H
67
69#include "dimensionedScalar.H"
70
71// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
72
73namespace Foam
74{
75namespace laminarModels
76{
77namespace generalizedNewtonianViscosityModels
78{
79
80/*---------------------------------------------------------------------------*\
81 Class CrossPowerLaw Declaration
82\*---------------------------------------------------------------------------*/
84class CrossPowerLaw
85:
87{
88 // Private Data
89
90 dictionary CrossPowerLawCoeffs_;
91
92 dimensionedScalar nuInf_;
95 dimensionedScalar tauStar_;
96
97
98public:
99
100 //- Runtime type information
101 TypeName("CrossPowerLaw");
102
103
104 // Constructors
105
106 //- Construct from dictionary (components)
108
109
110 //- Destructor
111 virtual ~CrossPowerLaw() = default;
112
113
114 // Member Functions
115
116 //- Read transportProperties dictionary
117 virtual bool read(const dictionary& viscosityProperties);
118
119 //- Return the laminar viscosity
120 virtual tmp<volScalarField> nu
121 (
122 const volScalarField& nu0,
123 const volScalarField& strainRate
124 ) const;
125};
126
127
128// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
129
130} // End namespace generalizedNewtonianViscosityModels
131} // End namespace laminarModels
132} // End namespace Foam
133
134// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
135
136#endif
137
138// ************************************************************************* //
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Definition: dictionary.H:126
An abstract base class for generalized Newtonian viscosity models.
const dictionary & viscosityProperties() const
Return the phase transport properties dictionary.
Cross-Power law generalized Newtonian viscosity model.
Definition: CrossPowerLaw.H:86
virtual bool read(const dictionary &viscosityProperties)
Read transportProperties dictionary.
Definition: CrossPowerLaw.C:78
A class for managing temporary objects.
Definition: tmp.H:65
Namespace for OpenFOAM.
volScalarField & nu
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.
Definition: typeInfo.H:73