OpenFOAM logo
Open Source CFD Toolkit

fvSchemes.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) 1991-2005 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     fvSchemes
00027 
00028 Description
00029     Selector class for finite volume differencing schemes.
00030     fvMesh is derived from fvShemes so that all fields have access to the
00031     fvSchemes from the mesh reference they hold.
00032 
00033 SourceFiles
00034     fvSchemes.C
00035 
00036 \*---------------------------------------------------------------------------*/
00037 
00038 #ifndef fvSchemes_H
00039 #define fvSchemes_H
00040 
00041 #include "IOdictionary.H"
00042 
00043 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00044 
00045 namespace Foam
00046 {
00047 
00048 /*---------------------------------------------------------------------------*\
00049                            Class fvSchemes Declaration
00050 \*---------------------------------------------------------------------------*/
00051 
00052 class fvSchemes
00053 :
00054     public IOdictionary
00055 {
00056     // Private data
00057 
00058         dictionary ddtSchemes_;
00059         ITstream defaultDdtScheme_;
00060 
00061         dictionary d2dt2Schemes_;
00062         ITstream defaultD2dt2Scheme_;
00063 
00064         dictionary interpolationSchemes_;
00065         ITstream defaultInterpolationScheme_;
00066 
00067         dictionary divSchemes_;
00068         ITstream defaultDivScheme_;
00069 
00070         dictionary gradSchemes_;
00071         ITstream defaultGradScheme_;
00072 
00073         dictionary snGradSchemes_;
00074         ITstream defaultSnGradScheme_;
00075 
00076         dictionary laplacianSchemes_;
00077         ITstream defaultLaplacianScheme_;
00078 
00079         dictionary fluxRequired_;
00080         bool defaultFluxRequired_;
00081 
00082 
00083     // Private Member Functions
00084 
00085         //- Disallow default bitwise copy construct and assignment
00086         fvSchemes(const fvSchemes&);
00087         void operator=(const fvSchemes&);
00088 
00089 
00090 public:
00091 
00092     //- Debug switch
00093     static int debug;
00094 
00095 
00096     // Constructors
00097 
00098         //- Construct for objectRegistry
00099         fvSchemes(const objectRegistry& obr);
00100 
00101 
00102     // Member Functions
00103 
00104         // Access
00105 
00106             const dictionary& schemesDict() const;
00107 
00108             ITstream& ddtScheme(const word& name) const;
00109 
00110             ITstream& d2dt2Scheme(const word& name) const;
00111 
00112             ITstream& interpolationScheme(const word& name) const;
00113 
00114             ITstream& divScheme(const word& name) const;
00115 
00116             ITstream& gradScheme(const word& name) const;
00117 
00118             ITstream& snGradScheme(const word& name) const;
00119 
00120             ITstream& laplacianScheme(const word& name) const;
00121 
00122             bool fluxRequired(const word& name) const;
00123 
00124 
00125         // Read
00126 
00127             //- Read the fvSchemes
00128             bool read();
00129 };
00130 
00131 
00132 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00133 
00134 } // End namespace Foam
00135 
00136 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00137 
00138 #endif
00139 
00140 // ************************************************************************* //
For further information go to www.openfoam.org