displacedPhaseInterface.H
Go to the documentation of this file.
1 /*---------------------------------------------------------------------------*\
2  ========= |
3  \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4  \\ / O peration | Website: https://openfoam.org
5  \\ / A nd | Copyright (C) 2021-2025 OpenFOAM Foundation
6  \\/ M anipulation |
7 -------------------------------------------------------------------------------
8 License
9  This file is part of OpenFOAM.
10 
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
13  the Free Software Foundation, either version 3 of the License, or
14  (at your option) any later version.
15 
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
19  for more details.
20 
21  You should have received a copy of the GNU General Public License
22  along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23 
24 Class
25  Foam::displacedPhaseInterface
26 
27 Description
28  Class to represent an interface between phases which has been displaced to
29  some extent by a third phase.
30 
31 SourceFiles
32  displacedPhaseInterface.C
33 
34 \*---------------------------------------------------------------------------*/
35 
36 #ifndef displacedPhaseInterface_H
37 #define displacedPhaseInterface_H
38 
39 #include "phaseInterface.H"
40 
41 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
42 
43 namespace Foam
44 {
45 
46 /*---------------------------------------------------------------------------*\
47  Class displacedPhaseInterface Declaration
48 \*---------------------------------------------------------------------------*/
49 
51 :
52  virtual public phaseInterface
53 {
54 private:
55 
56  // Private Data
57 
58  //- Displacing phase
59  const phaseModel& displacing_;
60 
61 
62 protected:
63 
64  // Protected Member Functions
65 
66  //- Return true if the phase interfaces are the same
67  virtual bool same(const phaseInterface& interface, bool strict) const;
68 
69 
70 public:
71 
72  //- Runtime type information
73  TypeName("displacedPhaseInterface");
74 
75 
76  // Constructors
77 
78  //- Construct from phases
80  (
81  const phaseModel& phase1,
82  const phaseModel& phase2,
83  const phaseModel& displacing
84  );
85 
86  //- Construct from fluid and name
88  (
89  const phaseSystem& fluid,
90  const word& name
91  );
92 
93 
94  //- Destructor
95  virtual ~displacedPhaseInterface();
96 
97 
98  // Static Member Functions
99 
100  //- Return the separator that delimits this interface's name
101  static word separator()
102  {
103  return "displacedBy";
104  }
105 
106 
107  // Member Functions
108 
109  //- Name
110  virtual word name() const;
111 
112 
113  // Access
114 
115  //- Displacing phase
116  const phaseModel& displacing() const;
117 };
118 
119 
120 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
121 
122 } // End namespace Foam
123 
124 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
125 
126 #endif
127 
128 // ************************************************************************* //
Class to represent an interface between phases which has been displaced to some extent by a third pha...
displacedPhaseInterface(const phaseModel &phase1, const phaseModel &phase2, const phaseModel &displacing)
Construct from phases.
virtual ~displacedPhaseInterface()
Destructor.
static word separator()
Return the separator that delimits this interface's name.
virtual bool same(const phaseInterface &interface, bool strict) const
Return true if the phase interfaces are the same.
const phaseModel & displacing() const
Displacing phase.
TypeName("displacedPhaseInterface")
Runtime type information.
Class to represent an interface between phases. Derivations can further specify the configuration of ...
const phaseSystem & fluid() const
Return the phase system.
const phaseModel & phase1() const
Return phase 1.
const phaseModel & phase2() const
Return phase 2.
Class to represent a system of phases.
Definition: phaseSystem.H:74
A class for handling words, derived from string.
Definition: word.H:62
Namespace for OpenFOAM.