chombo-discharge
CD_MFHelmholtzElectrostaticEBBC.H
Go to the documentation of this file.
1 /* chombo-discharge
2  * Copyright © 2021 SINTEF Energy Research.
3  * Please refer to Copyright.txt and LICENSE in the chombo-discharge root directory.
4  */
5 
12 #ifndef CD_MFHelmholtzElectrostaticEBBC_H
13 #define CD_MFHelmholtzElectrostaticEBBC_H
14 
15 // Our includes
16 #include <CD_MFHelmholtzEBBC.H>
17 #include <CD_ElectrostaticEbBc.H>
18 #include <CD_NamespaceHeader.H>
19 
26 {
27 public:
34  MFHelmholtzElectrostaticEBBC(const int a_phase,
35  const ElectrostaticEbBc& a_electrostaticBCs,
36  const RefCountedPtr<MFHelmholtzJumpBC>& a_jumpBC);
37 
42 
48 
54 
59 
65  operator=(const MFHelmholtzElectrostaticEBBC& a_other) = delete;
66 
72  operator=(const MFHelmholtzElectrostaticEBBC&& a_other) = delete;
73 
81  void
82  setOrder(const int a_order);
83 
89  void
90  setWeight(const int a_weight);
91 
95  void
96  setDomainDropOrder(const int a_domainSize);
97 
98 protected:
102  int m_order;
103 
107  int m_weight;
108 
113 
118 
122  virtual void
123  defineSinglePhase() override;
124 
136  virtual void
137  applyEBFluxSinglePhase(VoFIterator& a_singlePhaseVofs,
138  EBCellFAB& a_Lphi,
139  const EBCellFAB& a_phi,
140  const BaseIVFAB<Real>& a_Bcoef,
141  const DataIndex& a_dit,
142  const Real& a_beta,
143  const bool& a_homogeneousPhysBC) const override;
144 
149  inline Real
150  getElectrodePotential(const RealVect& a_pos) const;
151 };
152 
153 #include <CD_NamespaceFooter.H>
154 
156 
157 #endif
Data holder for holding the voltage at electrodes.
Declaration of an EB boundary condition class for MFHelmholtzOp.
Implementation of CD_MFHelmholtzElectrostaticEBBC.H.
Class which maps boundary condition types to a side and direction.
Definition: CD_ElectrostaticEbBc.H:33
Class for making boundary conditions on the EB in a multifluid context.
Definition: CD_MFHelmholtzEBBC.H:27
Class for making Electrostatic boundary conditions on the EB in a multifluid context.
Definition: CD_MFHelmholtzElectrostaticEBBC.H:26
virtual ~MFHelmholtzElectrostaticEBBC()
Default constructor (does nothing).
Definition: CD_MFHelmholtzElectrostaticEBBC.cpp:33
void setOrder(const int a_order)
Set stencil order.
Definition: CD_MFHelmholtzElectrostaticEBBC.cpp:39
void setWeight(const int a_weight)
Set stencil weight.
Definition: CD_MFHelmholtzElectrostaticEBBC.cpp:49
MFHelmholtzElectrostaticEBBC & operator=(const MFHelmholtzElectrostaticEBBC &&a_other)=delete
No move assignment.
int m_order
Stencil order.
Definition: CD_MFHelmholtzElectrostaticEBBC.H:102
virtual void defineSinglePhase() override
User define function.
Definition: CD_MFHelmholtzElectrostaticEBBC.cpp:67
MFHelmholtzElectrostaticEBBC & operator=(const MFHelmholtzElectrostaticEBBC &a_other)=delete
No copy assignment.
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_MFHelmholtzElectrostaticEBBC.cpp:184
int m_weight
Stencil weight.
Definition: CD_MFHelmholtzElectrostaticEBBC.H:107
Real getElectrodePotential(const RealVect &a_pos) const
Get electrode potential.
Definition: CD_MFHelmholtzElectrostaticEBBCImplem.H:23
int m_domainDropOrder
Special flag for dropping stencil order when domains become coarser than this.
Definition: CD_MFHelmholtzElectrostaticEBBC.H:112
MFHelmholtzElectrostaticEBBC()=delete
No weak construction.
void setDomainDropOrder(const int a_domainSize)
Drop BC order if domain size is equal or below this.
Definition: CD_MFHelmholtzElectrostaticEBBC.cpp:59
MFHelmholtzElectrostaticEBBC(const MFHelmholtzElectrostaticEBBC &&a_other)=delete
No move construction.
MFHelmholtzElectrostaticEBBC(const MFHelmholtzElectrostaticEBBC &a_other)=delete
No copy construction.
ElectrostaticEbBc m_electrostaticBCs
Electrostatic boundary conditions.
Definition: CD_MFHelmholtzElectrostaticEBBC.H:117