|
chombo-discharge
|
Neumann domain boundary condition for PetscHelmholtzOp. More...
#include <CD_PetscHelmholtzNeumannDomainBC.H>


Public Member Functions | |
| PetscHelmholtzNeumannDomainBC () | |
| Default constructor. Must subsequently call setDphiDn. | |
| PetscHelmholtzNeumannDomainBC (const Real a_DphiDn) | |
| Constructor with a constant normal derivative. | |
| PetscHelmholtzNeumannDomainBC (const std::function< Real(const RealVect &a_pos)> &a_DphiDn) | |
| Constructor with a spatially varying normal derivative. | |
| virtual | ~PetscHelmholtzNeumannDomainBC () |
| Destructor. | |
| void | setDphiDn (const Real a_DphiDn) |
| Set a constant normal derivative on the boundary. | |
| void | setDphiDn (const std::function< Real(const RealVect &a_pos)> &a_DphiDn) |
| Set a spatially varying normal derivative on the boundary. | |
| void | getFaceFluxStencil (Real &a_boundaryWeight, VoFStencil &a_stencilCoar, VoFStencil &a_stencil, VoFStencil &a_stencilFine, const int a_phase, const int a_level, const DataIndex &a_din, const VolIndex &a_vof, const int a_dir, const Side::LoHiSide a_side) const override |
| Get the stencil of the face flux through a domain face. The stencil is empty and w_B = -s, with s = -1 on the low side and +1 on the high side: a positive dphi/dn is a flux into the domain, as in EBHelmholtzNeumannDomainBC. | |
| Real | getBoundaryData (const int a_phase, const int a_level, const DataIndex &a_din, const VolIndex &a_vof, const int a_dir, const Side::LoHiSide a_side) const override |
| Get the boundary data, i.e. dphi/dn on the boundary. | |
| Public Member Functions inherited from PetscHelmholtzDomainBC | |
| PetscHelmholtzDomainBC () | |
| Default constructor. Must subsequently call define. | |
| virtual | ~PetscHelmholtzDomainBC () |
| Destructor. | |
| PetscHelmholtzDomainBC (const PetscHelmholtzDomainBC &a_other)=delete | |
| Disallowed copy constructor. | |
| PetscHelmholtzDomainBC (const PetscHelmholtzDomainBC &&a_other)=delete | |
| Disallowed move constructor. | |
| PetscHelmholtzDomainBC & | operator= (const PetscHelmholtzDomainBC &a_other)=delete |
| Disallowed copy assignment operator. | |
| PetscHelmholtzDomainBC & | operator= (const PetscHelmholtzDomainBC &&a_other)=delete |
| Disallowed move assignment operator. | |
| virtual void | define (const RefCountedPtr< PetscGrid > &a_petscGrid, const RealVect &a_probLo, const Vector< Real > &a_dx) |
| Define the BC over the AMR hierarchy. | |
Protected Attributes | |
| bool | m_useConstant |
| Use a constant value or not. | |
| bool | m_useFunction |
| Use a spatially varying value or not. | |
| Real | m_constantDphiDn |
| Constant dphi/dn. | |
| std::function< Real(const RealVect &a_pos)> | m_functionDphiDn |
| Spatially varying dphi/dn. | |
| Protected Attributes inherited from PetscHelmholtzDomainBC | |
| bool | m_isDefined |
| Is defined or not. | |
| RefCountedPtr< PetscGrid > | m_petscGrid |
| PETSc grid. | |
| RealVect | m_probLo |
| Lower-left corner of the computational domain. | |
| Vector< Real > | m_dx |
| Grid resolution on each level. | |
Additional Inherited Members | |
| Protected Member Functions inherited from PetscHelmholtzDomainBC | |
| RealVect | getBoundaryPosition (const int a_phase, const int a_level, const DataIndex &a_din, const VolIndex &a_vof, const int a_dir, const Side::LoHiSide a_side) const noexcept |
| Get the physical position of the centroid of a domain face. | |
Neumann domain boundary condition for PetscHelmholtzOp.
As in EBHelmholtzNeumannDomainBC, a positive dphi/dn is a flux into the domain. The flux has no phi-dependent part, so the stencil is empty.
| PetscHelmholtzNeumannDomainBC::PetscHelmholtzNeumannDomainBC | ( | const Real | a_DphiDn | ) |
Constructor with a constant normal derivative.
| [in] | a_DphiDn | Value of dphi/dn on the boundary |
| PetscHelmholtzNeumannDomainBC::PetscHelmholtzNeumannDomainBC | ( | const std::function< Real(const RealVect &a_pos)> & | a_DphiDn | ) |
Constructor with a spatially varying normal derivative.
| [in] | a_DphiDn | Value of dphi/dn on the boundary |
|
overridevirtual |
Get the boundary data, i.e. dphi/dn on the boundary.
| [in] | a_phase | Phase |
| [in] | a_level | Grid level |
| [in] | a_din | Grid index on the level |
| [in] | a_vof | Cell adjacent to the domain face |
| [in] | a_dir | Coordinate direction of the face |
| [in] | a_side | Domain side of the face |
Implements PetscHelmholtzDomainBC.
|
overridevirtual |
Get the stencil of the face flux through a domain face. The stencil is empty and w_B = -s, with s = -1 on the low side and +1 on the high side: a positive dphi/dn is a flux into the domain, as in EBHelmholtzNeumannDomainBC.
| [out] | a_boundaryWeight | Weight w_B of the boundary data in the flux, see getBoundaryData |
| [out] | a_stencilCoar | Stencil over cells on level a_level - 1 |
| [out] | a_stencil | Stencil over cells on level a_level |
| [out] | a_stencilFine | Stencil over cells on level a_level + 1 |
| [in] | a_phase | Phase |
| [in] | a_level | Grid level |
| [in] | a_din | Grid index on the level |
| [in] | a_vof | Cell adjacent to the domain face |
| [in] | a_dir | Coordinate direction of the face |
| [in] | a_side | Domain side of the face |
Implements PetscHelmholtzDomainBC.
| void PetscHelmholtzNeumannDomainBC::setDphiDn | ( | const Real | a_DphiDn | ) |
Set a constant normal derivative on the boundary.
| [in] | a_DphiDn | Value of dphi/dn on the boundary |
| void PetscHelmholtzNeumannDomainBC::setDphiDn | ( | const std::function< Real(const RealVect &a_pos)> & | a_DphiDn | ) |
Set a spatially varying normal derivative on the boundary.
| [in] | a_DphiDn | Value of dphi/dn on the boundary |