ECOGEN 4.0
Evolutive, Compressible, Open, Genuine, Easy, N-phase
Loading...
Searching...
No Matches
FluxEulerKorteweg.h
Go to the documentation of this file.
1//
2// ,---. ,--, .---. ,--, ,---. .-. .-.
3// | .-' .' .') / .-. ) .' .' | .-' | \| |
4// | `-. | |(_) | | |(_) | | __ | `-. | | |
5// | .-' \ \ | | | | \ \ ( _) | .-' | |\ |
6// | `--. \ `-. \ `-' / \ `-) ) | `--. | | |)|
7// /( __.' \____\ )---' )\____/ /( __.' /( (_)
8// (__) (_) (__) (__) (__)
9// Official webSite: https://code-mphi.github.io/ECOGEN/
10//
11// This file is part of ECOGEN.
12//
13// ECOGEN is the legal property of its developers, whose names
14// are listed in the copyright file included with this source
15// distribution.
16//
17// ECOGEN is free software: you can redistribute it and/or modify
18// it under the terms of the GNU General Public License as published
19// by the Free Software Foundation, either version 3 of the License,
20// or (at your option) any later version.
21//
22// ECOGEN is distributed in the hope that it will be useful,
23// but WITHOUT ANY WARRANTY; without even the implied warranty of
24// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25// GNU General Public License for more details.
26//
27// You should have received a copy of the GNU General Public License
28// along with ECOGEN (file LICENSE).
29// If not, see <http://www.gnu.org/licenses/>.
30
31#ifndef FLUXEULERKORTEWEG_H
32#define FLUXEULERKORTEWEG_H
33
34#include "../Flux.h"
35
38class FluxEulerKorteweg : public Flux
39{
40 public:
42 virtual ~FluxEulerKorteweg();
43
44 virtual void printFlux() const;
45 virtual void addFlux(double coefA);
46 virtual void addFlux(Flux* flux);
47 virtual void subtractFlux(double coefA);
48 virtual void multiply(double scalar);
49 virtual void setBufferFlux(Cell& cell);
50 virtual void buildCons(Phase** phase, Mixture* /*mixture*/);
51 virtual void buildPrim(Phase** phase, Mixture* /*mixture*/);
52 virtual void setToZero();
53 virtual void addNonCons(double /*coefA*/, const Cell* /*cell*/, const Coord& /*normal*/, const Coord& /*tangent*/, const Coord& /*binormal*/) {};
54 virtual void subtractNonCons(double /*coefA*/, const Cell* /*cell*/, const Coord& /*normal*/, const Coord& /*tangent*/, const Coord& /*binormal*/) {};
55
56 virtual void addSymmetricTerms(Phase** /*phases*/, Mixture* /*mixture*/,const double& /*r*/, const double& /*v*/) {};
57 virtual void prepSourceTermsGravity(const Coord& /*g*/) {};
58 virtual void prepSourceTermsHeating(const double& /*q*/) {};
59 virtual void prepSourceTermsMRF(Cell* /*cell*/, const Coord& /*omega*/) {};
60
61 // Accessors
62 //----------
63 virtual const double& getMassMix() const { return m_mass; };
64 virtual const double& getEqOmega() const { return m_eqOmega; };
65 virtual const double& getEqEta() const { return m_eqEta; };
66 virtual const Coord& getMomentum() const { return m_momentum; };
67 virtual const Coord& getEqVectorP() const { return m_eqVectorP; };
68 virtual void setCons(const Flux* cons);
69
70 protected:
71 double m_mass;
72 double m_eqOmega;
73 double m_eqEta;
76
77 private:
78
79 friend class ModEulerKorteweg;
80 // To modify if needed, example: to add a class APEViscosity, add friend class APEViscosity.
81};
82
84
85#endif // FLUXEULERKORTEWEG_H
86
87
double kappaEK
Simulation variable for Euler-Korteweg (temperatureEK is a constant temperature)
Definition FluxEulerKorteweg.h:83
double alphaEK
Definition FluxEulerKorteweg.cpp:34
double betaEK
Definition FluxEulerKorteweg.h:83
double temperatureEK
Definition FluxEulerKorteweg.h:83
Base class for a mesh cell.
Definition Cell.h:59
Class for a coordinate system object such as coordinates of the vertex or a vector.
Definition Coord.h:43
Model class for Augmented Euler–Korteweg Flux (single phase)
Definition FluxEulerKorteweg.h:39
virtual void addFlux(double coefA)
Add flux to the corresponding model flux.
Definition FluxEulerKorteweg.cpp:52
virtual void prepSourceTermsHeating(const double &)
Heating source term.
Definition FluxEulerKorteweg.h:58
double m_eqEta
Eta equation.
Definition FluxEulerKorteweg.h:73
virtual void subtractFlux(double coefA)
Subtract flux to the corresponding model buffer flux.
Definition FluxEulerKorteweg.cpp:74
virtual const Coord & getEqVectorP() const
Definition FluxEulerKorteweg.h:67
double m_eqOmega
Omega equation (omega: time derivative of eta)
Definition FluxEulerKorteweg.h:72
virtual void subtractNonCons(double, const Cell *, const Coord &, const Coord &, const Coord &)
Subtract non conservative term to the flux.
Definition FluxEulerKorteweg.h:54
virtual const double & getMassMix() const
Definition FluxEulerKorteweg.h:63
virtual void multiply(double scalar)
multiply the flux of the corresponding model by a constant
Definition FluxEulerKorteweg.cpp:85
virtual void addNonCons(double, const Cell *, const Coord &, const Coord &, const Coord &)
Add non conservative term to the flux.
Definition FluxEulerKorteweg.h:53
virtual void setBufferFlux(Cell &cell)
Temporary store the conservative variables of a given cell.
Definition FluxEulerKorteweg.cpp:96
Coord m_momentum
Momentum
Definition FluxEulerKorteweg.h:74
virtual ~FluxEulerKorteweg()
Definition FluxEulerKorteweg.cpp:41
virtual void printFlux() const
Definition FluxEulerKorteweg.cpp:45
virtual void prepSourceTermsGravity(const Coord &)
Gravity source term.
Definition FluxEulerKorteweg.h:57
virtual void buildCons(Phase **phase, Mixture *)
Build the conservative variables for a given cell from primitive one.
Definition FluxEulerKorteweg.cpp:103
virtual const Coord & getMomentum() const
Definition FluxEulerKorteweg.h:66
virtual const double & getEqEta() const
Definition FluxEulerKorteweg.h:65
virtual void addSymmetricTerms(Phase **, Mixture *, const double &, const double &)
Add symetric terms.
Definition FluxEulerKorteweg.h:56
virtual void prepSourceTermsMRF(Cell *, const Coord &)
MRF source term.
Definition FluxEulerKorteweg.h:59
Coord m_eqVectorP
Equation for vector P (P: gradient of eta)
Definition FluxEulerKorteweg.h:75
virtual void buildPrim(Phase **phase, Mixture *)
Build the primitive variables for a given cell from conservative one.
Definition FluxEulerKorteweg.cpp:116
virtual void setToZero()
set each attribute of the flux to zero
Definition FluxEulerKorteweg.cpp:136
virtual const double & getEqOmega() const
Definition FluxEulerKorteweg.h:64
double m_mass
Mass
Definition FluxEulerKorteweg.h:71
virtual void setCons(const Flux *cons)
Definition FluxEulerKorteweg.cpp:147
FluxEulerKorteweg()
Definition FluxEulerKorteweg.cpp:36
Abstract class for conservative variables and fluxes.
Definition Flux.h:43
Abstract class for mixture variables.
Definition Mixture.h:43
Model class for Augmented Euler–Korteweg mathematical system of equations (single phase)
Definition ModEulerKorteweg.h:42
Abstract class for a phase.
Definition Phase.h:47