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
26 Foam::transformFvPatchField
29 Foam::transformFvPatchField
32 transformFvPatchField.C
34 \*---------------------------------------------------------------------------*/
36 #ifndef transformFvPatchField_H
37 #define transformFvPatchField_H
39 #include "fvPatchField.H"
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46 /*---------------------------------------------------------------------------*\
47 Class transformFvPatch Declaration
48 \*---------------------------------------------------------------------------*/
51 class transformFvPatchField
53 public fvPatchField<Type>
58 //- Runtime type information
59 TypeName("transform");
64 //- Construct from patch and internal field
68 const DimensionedField<Type, volMesh>&
71 //- Construct from patch, internal field and dictionary
75 const DimensionedField<Type, volMesh>&,
79 //- Construct by mapping the given transformFvPatchField<Type>
83 const transformFvPatchField<Type>&,
85 const DimensionedField<Type, volMesh>&,
86 const fvPatchFieldMapper&
92 const transformFvPatchField<Type>&
95 //- Construct and return a clone
96 virtual tmp<fvPatchField<Type> > clone() const = 0;
98 //- Construct as copy setting internal field reference
101 const transformFvPatchField<Type>&,
102 const DimensionedField<Type, volMesh>&
105 //- Construct and return a clone setting internal field reference
106 virtual tmp<fvPatchField<Type> > clone
108 const DimensionedField<Type, volMesh>&
114 // Evaluation functions
116 //- Return gradient at boundary
117 virtual tmp<Field<Type> > snGrad() const = 0;
119 //- Return face-gradient transform diagonal
120 virtual tmp<Field<Type> > snGradTransformDiag() const = 0;
122 //- Return the matrix diagonal coefficients corresponding to the
123 // evaluation of the value of this patchField with given weights
124 virtual tmp<Field<Type> > valueInternalCoeffs
126 const tmp<scalarField>&
129 //- Return the matrix source coefficients corresponding to the
130 // evaluation of the value of this patchField with given weights
131 virtual tmp<Field<Type> > valueBoundaryCoeffs
133 const tmp<scalarField>&
136 //- Return the matrix diagonal coefficients corresponding to the
137 // evaluation of the gradient of this patchField
138 virtual tmp<Field<Type> > gradientInternalCoeffs() const;
140 //- Return the matrix source coefficients corresponding to the
141 // evaluation of the gradient of this patchField
142 virtual tmp<Field<Type> > gradientBoundaryCoeffs() const;
147 virtual void operator=(const fvPatchField<Type>&);
151 // * * * * * * * * * * * Template Specialisations * * * * * * * * * * * * * //
155 transformFvPatchField<scalar>::gradientInternalCoeffs() const;
158 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
160 } // End namespace Foam
162 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
165 # include "transformFvPatchField.C"
168 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
172 // ************************************************************************* //