FreeFOAM The Cross-Platform CFD Toolkit
Hosted by SourceForge:
Get FreeFOAM at SourceForge.net.
            Fast, secure and Free Open Source software downloads

turbulentMixingLengthDissipationRateInletFvPatchScalarField.H

Go to the documentation of this file.
00001 /*---------------------------------------------------------------------------*\
00002   =========                 |
00003   \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox
00004    \\    /   O peration     |
00005     \\  /    A nd           | Copyright (C) 2006-2011 OpenCFD Ltd.
00006      \\/     M anipulation  |
00007 -------------------------------------------------------------------------------
00008 License
00009     This file is part of OpenFOAM.
00010 
00011     OpenFOAM is free software: you can redistribute it and/or modify it
00012     under the terms of the GNU General Public License as published by
00013     the Free Software Foundation, either version 3 of the License, or
00014     (at your option) any later version.
00015 
00016     OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
00017     ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
00018     FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
00019     for more details.
00020 
00021     You should have received a copy of the GNU General Public License
00022     along with OpenFOAM.  If not, see <http://www.gnu.org/licenses/>.
00023 
00024 Class
00025     Foam::incompressible::turbulentMixingLengthDissipationRateInletFvPatchScalarField
00026 
00027 Description
00028     Calculate epsilon via the mixing length [m]
00029 
00030     Example of the boundary condition specification:
00031     @verbatim
00032         inlet
00033         {
00034             type            turbulentMixingLengthDissipationRateInlet;
00035             mixingLength    0.005;         // 5 mm
00036             value           uniform 200;   // placeholder
00037         }
00038     @endverbatim
00039 
00040 SourceFiles
00041     turbulentMixingLengthDissipationRateInletFvPatchScalarField.C
00042 
00043 \*---------------------------------------------------------------------------*/
00044 
00045 #ifndef incompressibleturbulentMixingLengthDissipationRateInlet_H
00046 #define incompressibleturbulentMixingLengthDissipationRateInlet_H
00047 
00048 #include <finiteVolume/inletOutletFvPatchFields.H>
00049 
00050 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00051 
00052 namespace Foam
00053 {
00054 namespace incompressible
00055 {
00056 
00057 /*---------------------------------------------------------------------------*\
00058        Class turbulentMixingLengthDissipationRateInletFvPatch Declaration
00059 \*---------------------------------------------------------------------------*/
00060 
00061 class turbulentMixingLengthDissipationRateInletFvPatchScalarField
00062 :
00063     public inletOutletFvPatchScalarField
00064 {
00065     // Private data
00066 
00067         //- turbulent length scale
00068         scalar mixingLength_;
00069 
00070         //- Name of the flux field
00071         word phiName_;
00072 
00073         //- Name of the turbulent kinetic energy field
00074         word kName_;
00075 
00076 
00077 public:
00078 
00079     //- Runtime type information
00080     TypeName("turbulentMixingLengthDissipationRateInlet");
00081 
00082 
00083     // Constructors
00084 
00085         //- Construct from patch and internal field
00086         turbulentMixingLengthDissipationRateInletFvPatchScalarField
00087         (
00088             const fvPatch&,
00089             const DimensionedField<scalar, volMesh>&
00090         );
00091 
00092         //- Construct from patch, internal field and dictionary
00093         turbulentMixingLengthDissipationRateInletFvPatchScalarField
00094         (
00095             const fvPatch&,
00096             const DimensionedField<scalar, volMesh>&,
00097             const dictionary&
00098         );
00099 
00100         //- Construct by mapping given
00101         //  turbulentMixingLengthDissipationRateInletFvPatchScalarField
00102         //  onto a new patch
00103         turbulentMixingLengthDissipationRateInletFvPatchScalarField
00104         (
00105             const turbulentMixingLengthDissipationRateInletFvPatchScalarField&,
00106             const fvPatch&,
00107             const DimensionedField<scalar, volMesh>&,
00108             const fvPatchFieldMapper&
00109         );
00110 
00111         //- Construct as copy
00112         turbulentMixingLengthDissipationRateInletFvPatchScalarField
00113         (
00114             const turbulentMixingLengthDissipationRateInletFvPatchScalarField&
00115         );
00116 
00117         //- Construct and return a clone
00118         virtual tmp<fvPatchScalarField> clone() const
00119         {
00120             return tmp<fvPatchScalarField>
00121             (
00122                 new turbulentMixingLengthDissipationRateInletFvPatchScalarField
00123                 (
00124                     *this
00125                 )
00126             );
00127         }
00128 
00129         //- Construct as copy setting internal field reference
00130         turbulentMixingLengthDissipationRateInletFvPatchScalarField
00131         (
00132             const turbulentMixingLengthDissipationRateInletFvPatchScalarField&,
00133             const DimensionedField<scalar, volMesh>&
00134         );
00135 
00136         //- Construct and return a clone setting internal field reference
00137         virtual tmp<fvPatchScalarField> clone
00138         (
00139             const DimensionedField<scalar, volMesh>& iF
00140         ) const
00141         {
00142             return tmp<fvPatchScalarField>
00143             (
00144                 new turbulentMixingLengthDissipationRateInletFvPatchScalarField
00145                 (
00146                     *this,
00147                     iF
00148                 )
00149             );
00150         }
00151 
00152 
00153     // Member functions
00154 
00155         //- Update the coefficients associated with the patch field
00156         virtual void updateCoeffs();
00157 
00158         //- Write
00159         virtual void write(Ostream&) const;
00160 };
00161 
00162 
00163 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00164 
00165 } // End namespace incompressible
00166 } // End namespace Foam
00167 
00168 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00169 
00170 #endif
00171 
00172 // ************************ vim: set sw=4 sts=4 et: ************************ //
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines