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., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
26 threePhaseInterfaceProperties
29 Properties to aid interFoam :
30 1. Correct the alpha boundary condition for dynamic contact angle.
31 2. Calculate interface curvature.
34 threePhaseInterfaceProperties.C
36 \*---------------------------------------------------------------------------*/
38 #ifndef threePhaseInterfaceProperties_H
39 #define threePhaseInterfaceProperties_H
41 #include "threePhaseMixture.H"
42 #include "surfaceFields.H"
44 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
49 /*---------------------------------------------------------------------------*\
50 Class threePhaseInterfaceProperties Declaration
51 \*---------------------------------------------------------------------------*/
53 class threePhaseInterfaceProperties
57 const threePhaseMixture& mixture_;
59 //- Compression coefficient
62 //- Surface tension 1-2
63 dimensionedScalar sigma12_;
65 //- Surface tension 1-3
66 dimensionedScalar sigma13_;
68 //- Stabilisation for normalisation of the interface normal
69 const dimensionedScalar deltaN_;
71 surfaceScalarField nHatf_;
75 // Private Member Functions
77 //- Disallow default bitwise copy construct and assignment
78 threePhaseInterfaceProperties(const threePhaseInterfaceProperties&);
79 void operator=(const threePhaseInterfaceProperties&);
81 //- Correction for the boundary condition on the unit normal nHat on
82 // walls to produce the correct contact dynamic angle
83 // calculated from the component of U parallel to the wall
84 void correctContactAngle
86 surfaceVectorField::GeometricBoundaryField& nHat
89 //- Re-calculate the interface curvature
95 //- Conversion factor for degrees into radians
96 static const scalar convertToRad;
101 //- Construct from volume fraction field alpha and IOdictionary
102 threePhaseInterfaceProperties(const threePhaseMixture& mixture);
107 scalar cAlpha() const
112 const dimensionedScalar& deltaN() const
117 const surfaceScalarField& nHatf() const
122 const volScalarField& K() const
127 tmp<volScalarField> sigma() const
129 volScalarField limitedAlpha2 = max(mixture_.alpha2(), scalar(0));
130 volScalarField limitedAlpha3 = max(mixture_.alpha3(), scalar(0));
133 (limitedAlpha2*sigma12_ + limitedAlpha3*sigma13_)
134 /(limitedAlpha2 + limitedAlpha3 + SMALL);
137 tmp<volScalarField> sigmaK() const
149 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
151 } // End namespace Foam
153 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
157 // ************************************************************************* //