OpenFOAM logo
The Open Source CFD Toolbox
  Programmer’s C++ Doxygen OpenCFD Solutions Contact OpenFOAM

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-2007 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 the
00013     Free Software Foundation; either version 2 of the License, or (at your
00014     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, write to the Free Software Foundation,
00023     Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
00024 
00025 Class
00026     turbulentMixingLengthDissipationRateInletFvPatchScalarField
00027 
00028 Description
00029     Calculate epsilon via the mixing length [m]
00030 
00031     Example of the BC specification:
00032 
00033         inlet
00034         {
00035             type            turbulentMixingLengthDissipationRateInlet;
00036             mixingLength    0.005;    // 5 mm
00037         }
00038 
00039 SourceFiles
00040     turbulentMixingLengthDissipationRateInletFvPatchScalarField.C
00041 
00042 \*---------------------------------------------------------------------------*/
00043 
00044 #ifndef turbulentMixingLengthDissipationRateInletFvPatchScalarField_H
00045 #define turbulentMixingLengthDissipationRateInletFvPatchScalarField_H
00046 
00047 #include "fixedValueFvPatchFields.H"
00048 
00049 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00050 
00051 namespace Foam
00052 {
00053 
00054 /*---------------------------------------------------------------------------*\
00055        Class turbulentMixingLengthDissipationRateInletFvPatch Declaration
00056 \*---------------------------------------------------------------------------*/
00057 
00058 class turbulentMixingLengthDissipationRateInletFvPatchScalarField
00059 :
00060     public fixedValueFvPatchScalarField
00061 {
00062     // Private data
00063 
00064         //- turbulent length scale
00065         scalar mixingLength_;
00066 
00067 public:
00068 
00069     //- Runtime type information
00070     TypeName("turbulentMixingLengthDissipationRateInlet");
00071 
00072 
00073     // Constructors
00074 
00075         //- Construct from patch and internal field
00076         turbulentMixingLengthDissipationRateInletFvPatchScalarField
00077         (
00078             const fvPatch&,
00079             const DimensionedField<scalar, volMesh>&
00080         );
00081 
00082         //- Construct from patch, internal field and dictionary
00083         turbulentMixingLengthDissipationRateInletFvPatchScalarField
00084         (
00085             const fvPatch&,
00086             const DimensionedField<scalar, volMesh>&,
00087             const dictionary&
00088         );
00089 
00090         //- Construct by mapping given
00091         //  turbulentMixingLengthDissipationRateInletFvPatchScalarField
00092         //  onto a new patch
00093         turbulentMixingLengthDissipationRateInletFvPatchScalarField
00094         (
00095             const turbulentMixingLengthDissipationRateInletFvPatchScalarField&,
00096             const fvPatch&,
00097             const DimensionedField<scalar, volMesh>&,
00098             const fvPatchFieldMapper&
00099         );
00100 
00101         //- Construct as copy
00102         turbulentMixingLengthDissipationRateInletFvPatchScalarField
00103         (
00104             const turbulentMixingLengthDissipationRateInletFvPatchScalarField&
00105         );
00106 
00107         //- Construct and return a clone
00108         virtual tmp<fvPatchScalarField> clone() const
00109         {
00110             return tmp<fvPatchScalarField>
00111             (
00112                 new turbulentMixingLengthDissipationRateInletFvPatchScalarField
00113                 (
00114                     *this
00115                 )
00116             );
00117         }
00118 
00119         //- Construct as copy setting internal field reference
00120         turbulentMixingLengthDissipationRateInletFvPatchScalarField
00121         (
00122             const turbulentMixingLengthDissipationRateInletFvPatchScalarField&,
00123             const DimensionedField<scalar, volMesh>&
00124         );
00125 
00126         //- Construct and return a clone setting internal field reference
00127         virtual tmp<fvPatchScalarField> clone
00128         (
00129             const DimensionedField<scalar, volMesh>& iF
00130         ) const
00131         {
00132             return tmp<fvPatchScalarField>
00133             (
00134                 new turbulentMixingLengthDissipationRateInletFvPatchScalarField
00135                 (
00136                     *this,
00137                     iF
00138                 )
00139             );
00140         }
00141 
00142 
00143     // Member functions
00144 
00145         //- Update the coefficients associated with the patch field
00146         virtual void updateCoeffs();
00147 
00148         //- Write
00149         virtual void write(Ostream&) const;
00150 };
00151 
00152 
00153 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00154 
00155 } // End namespace Foam
00156 
00157 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00158 
00159 #endif
00160 
00161 // ************************************************************************* //
Copyright © 2000-2007 OpenCFD Ltd