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

pointLinear.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) 2011-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     pointLinear
00026 
00027 Description
00028     Face-point interpolation scheme class derived from linear and
00029     returns linear weighting factors but also applies an explicit correction.
00030 
00031     Uses volPointInterpolation to obtain the field values at the face-points.
00032 
00033 SourceFiles
00034     pointLinear.C
00035 
00036 \*---------------------------------------------------------------------------*/
00037 
00038 #ifndef pointLinear_H
00039 #define pointLinear_H
00040 
00041 #include <finiteVolume/linear.H>
00042 
00043 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00044 
00045 namespace Foam
00046 {
00047 
00048 /*---------------------------------------------------------------------------*\
00049                            Class pointLinear Declaration
00050 \*---------------------------------------------------------------------------*/
00051 
00052 template<class Type>
00053 class pointLinear
00054 :
00055     public linear<Type>
00056 {
00057     // Private Member Functions
00058 
00059         //- Disallow default bitwise copy construct
00060         pointLinear(const pointLinear&);
00061 
00062         //- Disallow default bitwise assignment
00063         void operator=(const pointLinear&);
00064 
00065 
00066 public:
00067 
00068     //- Runtime type information
00069     TypeName("pointLinear");
00070 
00071 
00072     // Constructors
00073 
00074         //- Construct from mesh
00075         pointLinear(const fvMesh& mesh)
00076         :
00077             linear<Type>(mesh)
00078         {}
00079 
00080 
00081         //- Construct from mesh and Istream
00082         pointLinear
00083         (
00084             const fvMesh& mesh,
00085             Istream&
00086         )
00087         :
00088             linear<Type>(mesh)
00089         {}
00090 
00091 
00092         //- Construct from mesh, faceFlux and Istream
00093         pointLinear
00094         (
00095             const fvMesh& mesh,
00096             const surfaceScalarField&,
00097             Istream&
00098         )
00099         :
00100             linear<Type>(mesh)
00101         {}
00102 
00103 
00104     // Member Functions
00105 
00106         //- Return true if this scheme uses an explicit correction
00107         virtual bool corrected() const
00108         {
00109             return true;
00110         }
00111 
00112         //- Return the explicit correction to the face-interpolate
00113         virtual tmp<GeometricField<Type, fvsPatchField, surfaceMesh> >
00114         correction
00115         (
00116             const GeometricField<Type, fvPatchField, volMesh>& vf
00117         ) const;
00118 };
00119 
00120 
00121 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00122 
00123 } // End namespace Foam
00124 
00125 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
00126 
00127 #endif
00128 
00129 // ************************ vim: set sw=4 sts=4 et: ************************ //
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines