1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright held by original author
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
35 \*---------------------------------------------------------------------------*/
37 #ifndef reducedUnits_H
38 #define reducedUnits_H
41 #include "IOdictionary.H"
43 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
48 /*---------------------------------------------------------------------------*\
49 Class reducedUnits Declaration
50 \*---------------------------------------------------------------------------*/
80 scalar refMassDensity_;
82 scalar refNumberDensity_;
85 // Private Member Functions
89 //- Disallow default bitwise copy construct
90 reducedUnits(const reducedUnits&);
92 //- Disallow default bitwise assignment
93 void operator=(const reducedUnits&);
98 // Static data members
100 //- Static data someStaticData
101 static const scalar kb;
106 //- Construct with no argument, uses default values:
108 // mass = 1.660538782eâ27kg (unified atomic mass unit)
109 // temperature = 1K (therefore, energy = 1*kb)
112 //- Construct from components
120 //- Construct from dictionary
121 reducedUnits(const IOdictionary& reducedUnitsDict);
138 void setRefValues(const IOdictionary& reducedUnitsDict);
143 inline scalar refLength() const;
145 inline scalar refTime() const;
147 inline scalar refMass() const;
149 inline scalar refTemp() const;
151 inline scalar refEnergy() const;
153 inline scalar refForce() const;
155 inline scalar refVelocity() const;
157 inline scalar refVolume() const;
159 inline scalar refPressure() const;
161 inline scalar refMassDensity() const;
163 inline scalar refNumberDensity() const;
166 // IOstream Operators
168 friend Ostream& operator<<(Ostream&, const reducedUnits&);
172 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
174 } // End namespace Foam
176 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
178 #include "reducedUnitsI.H"
180 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
184 // ************************************************************************* //