1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | foam-extend: Open Source CFD
4 \\ / O peration | Version: 3.2
5 \\ / A nd | Web: http://www.foam-extend.org
6 \\/ M anipulation | For copyright notice see file Copyright
7 -------------------------------------------------------------------------------
9 This file is part of foam-extend.
11 foam-extend 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 3 of the License, or (at your
14 option) any later version.
16 foam-extend is distributed in the hope that it will be useful, but
17 WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with foam-extend. If not, see <http://www.gnu.org/licenses/>.
25 Foam::fixedFluxPressureFvPatchScalarField
28 Foam::fixedFluxPressureFvPatchScalarField
31 fixedFluxPressureFvPatchScalarField.C
33 \*---------------------------------------------------------------------------*/
35 #ifndef fixedFluxPressureFvPatchScalarFields_H
36 #define fixedFluxPressureFvPatchScalarFields_H
38 #include "fvPatchFields.H"
39 #include "fixedGradientFvPatchFields.H"
42 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
47 /*---------------------------------------------------------------------------*\
48 Class fixedFluxPressureFvPatch Declaration
49 \*---------------------------------------------------------------------------*/
51 class fixedFluxPressureFvPatchScalarField
53 public fixedGradientFvPatchScalarField
57 //- Name of the velocity field
60 //- Name of the flux transporting the field
63 //- Name of the density field used to normalise the mass flux
67 //- Name of the pressure diffusivity factor
70 //- Is the pressure adjoint, i.e. has the opposite sign
76 //- Runtime type information
77 TypeName("fixedFluxPressure");
82 //- Construct from patch and internal field
83 fixedFluxPressureFvPatchScalarField
86 const DimensionedField<scalar, volMesh>&
89 //- Construct from patch, internal field and dictionary
90 fixedFluxPressureFvPatchScalarField
93 const DimensionedField<scalar, volMesh>&,
97 //- Construct by mapping given fixedFluxPressureFvPatchScalarField onto
99 fixedFluxPressureFvPatchScalarField
101 const fixedFluxPressureFvPatchScalarField&,
103 const DimensionedField<scalar, volMesh>&,
104 const fvPatchFieldMapper&
107 //- Construct as copy
108 fixedFluxPressureFvPatchScalarField
110 const fixedFluxPressureFvPatchScalarField&
113 //- Construct and return a clone
114 virtual tmp<fvPatchScalarField> clone() const
116 return tmp<fvPatchScalarField>
118 new fixedFluxPressureFvPatchScalarField(*this)
122 //- Construct as copy setting internal field reference
123 fixedFluxPressureFvPatchScalarField
125 const fixedFluxPressureFvPatchScalarField&,
126 const DimensionedField<scalar, volMesh>&
129 //- Construct and return a clone setting internal field reference
130 virtual tmp<fvPatchScalarField> clone
132 const DimensionedField<scalar, volMesh>& iF
135 return tmp<fvPatchScalarField>
137 new fixedFluxPressureFvPatchScalarField(*this, iF)
144 //- Update the coefficients associated with the patch field
145 virtual void updateCoeffs();
148 virtual void write(Ostream&) const;
152 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
154 } // End namespace Foam
156 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
160 // ************************************************************************* //