chombo-discharge
Loading...
Searching...
No Matches
CD_MFHelmholtzDirichletEBBC.H
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2021-2026 SINTEF Energy Research
3 *
4 * SPDX-License-Identifier: GPL-3.0-or-later
5 */
6
13#ifndef CD_MFHELMHOLTZDIRICHLETEBBC_H
14#define CD_MFHELMHOLTZDIRICHLETEBBC_H
15
16// Our includes
17#include <CD_MFHelmholtzEBBC.H>
18#include <CD_NamespaceHeader.H>
19
24{
25public:
31 MFHelmholtzDirichletEBBC(const int a_phase, const RefCountedPtr<MFHelmholtzJumpBC>& a_jumpBC);
32
37
42 virtual void
43 setValue(const Real a_value);
44
49 virtual void
50 setValue(const std::function<Real(const RealVect& a_pos)>& a_value);
51
56 void
57 setOrder(const int a_order);
58
63 void
64 setWeight(const int a_weight);
65
70 virtual void
71 setDomainDropOrder(const int a_domainSize);
72
77 virtual void
78 setCoarseGridDropOrder(const bool a_dropOrder);
79
80protected:
85
90
95
100
105
110
115
119 std::function<Real(const RealVect& a_pos)> m_functionValue;
120
124 virtual void
125 defineSinglePhase() override;
126
137 virtual void
138 applyEBFluxSinglePhase(VoFIterator& a_singlePhaseVofs,
139 EBCellFAB& a_Lphi,
140 const EBCellFAB& a_phi,
141 const BaseIVFAB<Real>& a_Bcoef,
142 const DataIndex& a_dit,
143 const Real& a_beta,
144 const bool& a_homogeneousPhysBC) const override;
145};
146
147#include <CD_NamespaceFooter.H>
148
149#endif
Declaration of an EB boundary condition class for MFHelmholtzOp.
Class for making Dirichlet boundary conditions on the EB in a multifluid context.
Definition CD_MFHelmholtzDirichletEBBC.H:24
virtual void setDomainDropOrder(const int a_domainSize)
Drop BC order if domain size is equal or below this.
Definition CD_MFHelmholtzDirichletEBBC.cpp:83
int m_order
Stencil order.
Definition CD_MFHelmholtzDirichletEBBC.H:99
virtual void setValue(const Real a_value)
Set the value on the EB.
Definition CD_MFHelmholtzDirichletEBBC.cpp:41
virtual void setCoarseGridDropOrder(const bool a_dropOrder)
Signal that it should drop the stencil order if the cell is a coarsened cell.
Definition CD_MFHelmholtzDirichletEBBC.cpp:91
virtual void applyEBFluxSinglePhase(VoFIterator &a_singlePhaseVofs, EBCellFAB &a_Lphi, const EBCellFAB &a_phi, const BaseIVFAB< Real > &a_Bcoef, const DataIndex &a_dit, const Real &a_beta, const bool &a_homogeneousPhysBC) const override
Apply flux single phase.
Definition CD_MFHelmholtzDirichletEBBC.cpp:245
int m_weight
Stencil weight.
Definition CD_MFHelmholtzDirichletEBBC.H:104
virtual ~MFHelmholtzDirichletEBBC()
Default constructor.
Definition CD_MFHelmholtzDirichletEBBC.cpp:35
virtual void defineSinglePhase() override
User define function.
Definition CD_MFHelmholtzDirichletEBBC.cpp:97
void setOrder(const int a_order)
Set stencil order.
Definition CD_MFHelmholtzDirichletEBBC.cpp:63
void setWeight(const int a_weight)
Set stencil weight.
Definition CD_MFHelmholtzDirichletEBBC.cpp:73
Real m_constantValue
Value on EB.
Definition CD_MFHelmholtzDirichletEBBC.H:94
std::function< Real(const RealVect &a_pos)> m_functionValue
Value on the EB. Does not apply to matching cells.
Definition CD_MFHelmholtzDirichletEBBC.H:119
bool m_useConstant
Use constant for BC.
Definition CD_MFHelmholtzDirichletEBBC.H:84
int m_domainDropOrder
Special flag for dropping stencil order when domains become coarser than this.
Definition CD_MFHelmholtzDirichletEBBC.H:109
bool m_useFunction
Use function for BC value.
Definition CD_MFHelmholtzDirichletEBBC.H:89
bool m_dropOrder
Special flag for dropping stencil order if the cell is a coarsened cell.
Definition CD_MFHelmholtzDirichletEBBC.H:114
Class for making boundary conditions on the EB in a multifluid context.
Definition CD_MFHelmholtzEBBC.H:28