|
ERF
Energy Research and Forecasting: An Atmospheric Modeling Code
|
Owns and exposes cell-centered and face-centered EB factories. More...
#include <ERF_EB.H>

Public Member Functions | |
| ~eb_ () | |
| Destroy the EB factory manager. More... | |
| eb_ (amrex::Geometry const &a_geom, amrex::FArrayBox const &terrain_fab, amrex::Gpu::DeviceVector< amrex::Real > &a_dz_stretched, bool is_anelastic) | |
| Construct an EB description from terrain data. More... | |
| eb_ () | |
| Construct an empty EB factory manager. More... | |
| void | define (int level, amrex::Geometry const &a_geom, amrex::EB2::Level const *a_eb_level, bool is_anelastic) |
| Define the EB level metadata used by this factory manager. More... | |
| void | make_all_factories (int level, amrex::Geometry const &a_geom, amrex::BoxArray const &ba, amrex::DistributionMapping const &dm, amrex::EB2::Level const &a_eb_level) |
| Build cell-centered and staggered EB factories for the level. More... | |
| void | make_cc_factory (int level, amrex::Geometry const &a_geom, amrex::BoxArray const &ba, amrex::DistributionMapping const &dm, amrex::EB2::Level const &a_eb_level) |
| Build only the cell-centered EB factory for the level. More... | |
| int | nghost_basic () const |
| Number of ghost cells needed for basic EB flags. More... | |
| int | nghost_volume () const |
| Number of ghost cells needed for EB volume data. More... | |
| int | nghost_full () const |
| Number of ghost cells needed for full EB geometric data. More... | |
| const std::unique_ptr< amrex::EBFArrayBoxFactory > & | get_const_factory () const noexcept |
| Return the cell-centered EB factory. More... | |
| void | set_connection_flags (amrex::EBFArrayBoxFactory *factory) |
| Disconnect covered neighbors in an EB factory's cell flags. More... | |
| eb_aux_ const * | get_u_const_factory () const noexcept |
| Return the ERF auxiliary x-face EB factory. More... | |
| eb_aux_ const * | get_v_const_factory () const noexcept |
| Return the ERF auxiliary y-face EB factory. More... | |
| eb_aux_ const * | get_w_const_factory () const noexcept |
| Return the ERF auxiliary z-face EB factory. More... | |
Private Member Functions | |
| void | make_terrain (amrex::Geometry const &a_geom) |
| Build terrain EB geometry for the supplied Geometry. More... | |
| template<class F > | |
| void | build_level (amrex::Geometry const &a_geom, amrex::EB2::GeometryShop< F > a_gshop) |
| Construct EB levels from an AMReX GeometryShop. More... | |
| amrex::FabArray< amrex::EBCellFlagFab > & | getNonConstEBCellFlags (const amrex::EBFArrayBoxFactory &ebfact) |
| Return mutable EB cell flags from an AMReX factory. More... | |
| amrex::MultiFab & | getNonConstVolFrac (const amrex::EBFArrayBoxFactory &ebfact) |
| Return mutable volume fractions from an AMReX factory. More... | |
| amrex::MultiCutFab & | getNonConstCentroid (const amrex::EBFArrayBoxFactory &ebfact) |
| Return mutable cell centroids from an AMReX factory. More... | |
| amrex::Array< amrex::MultiCutFab *, AMREX_SPACEDIM > | getNonConstAreaFrac (const amrex::EBFArrayBoxFactory &ebfact) |
| Return mutable area-fraction arrays from an AMReX factory. More... | |
| amrex::Array< amrex::MultiCutFab *, AMREX_SPACEDIM > | getNonConstFaceCent (const amrex::EBFArrayBoxFactory &ebfact) |
| Return mutable face-centroid arrays from an AMReX factory. More... | |
Private Attributes | |
| int | m_has_eb |
| std::string | m_type |
| amrex::EBSupport | m_support_level |
| int | m_write_eb_surface |
| amrex::FabArray< amrex::EBCellFlagFab > * | m_cellflags = nullptr |
| amrex::EB2::Level const * | m_eb_level |
| EB level constructed from building GeometryShop. More... | |
| std::unique_ptr< amrex::EBFArrayBoxFactory > | m_factory = nullptr |
| eb_aux_ | m_u_factory |
| eb_aux_ | m_v_factory |
| eb_aux_ | m_w_factory |
| std::unique_ptr< amrex::EBFArrayBoxFactory > | m_u_factory_fc = nullptr |
| std::unique_ptr< amrex::EBFArrayBoxFactory > | m_v_factory_fc = nullptr |
| std::unique_ptr< amrex::EBFArrayBoxFactory > | m_w_factory_fc = nullptr |
Owns and exposes cell-centered and face-centered EB factories.
The class builds AMReX EB factories for cell-centered state data and, depending on USE_FC_FACTORY, either native AMReX or ERF auxiliary factories for staggered velocity components.
| eb_::~eb_ | ( | ) |
| eb_::eb_ | ( | amrex::Geometry const & | a_geom, |
| amrex::FArrayBox const & | terrain_fab, | ||
| amrex::Gpu::DeviceVector< amrex::Real > & | a_dz_stretched, | ||
| bool | is_anelastic | ||
| ) |
Construct an EB description from terrain data.
| a_geom | Geometry used to place the terrain EB. |
| terrain_fab | Terrain height data. |
| a_dz_stretched | Device vector containing stretched vertical spacing. |
| is_anelastic | Whether the owning level is using anelastic dynamics. |
| eb_::eb_ | ( | ) |
Construct an empty EB factory manager.
|
inlineprivate |
Construct EB levels from an AMReX GeometryShop.
| F | Implicit-function type stored by the GeometryShop. |
| a_geom | Geometry used to build the EB index space. |
| a_gshop | GeometryShop describing the implicit EB. |
| void eb_::define | ( | int | level, |
| amrex::Geometry const & | a_geom, | ||
| amrex::EB2::Level const * | a_eb_level, | ||
| bool | is_anelastic | ||
| ) |
Define the EB level metadata used by this factory manager.
| level | AMR level index. |
| a_geom | Geometry for the level. |
| a_eb_level | AMReX EB level owned by the global EB index space. |
| is_anelastic | Whether the owning level is using anelastic dynamics. |
|
inlinenoexcept |
Return the cell-centered EB factory.
Referenced by compute_gradp_xy(), compute_gradp_z(), ComputeTurbulentViscosityLES_EB(), erf_make_tau_terms(), erf_slow_rhs_pre(), ERF::estTimeStep(), and make_buoyancy().

|
inlinenoexcept |
Return the ERF auxiliary x-face EB factory.
Referenced by AdvectionSrcForMom_EB(), compute_gradp_xy(), ComputeStrain_EB(), ComputeTurbulentViscosityLES_EB(), DiffusionSrcForMom_EB(), and make_mom_sources().

|
inlinenoexcept |
Return the ERF auxiliary y-face EB factory.
Referenced by AdvectionSrcForMom_EB(), compute_gradp_xy(), ComputeStrain_EB(), ComputeTurbulentViscosityLES_EB(), DiffusionSrcForMom_EB(), and make_mom_sources().

|
inlinenoexcept |
Return the ERF auxiliary z-face EB factory.
Referenced by AdvectionSrcForMom_EB(), compute_gradp_z(), ComputeStrain_EB(), ComputeTurbulentViscosityLES_EB(), DiffusionSrcForMom_EB(), and make_mom_sources().

|
inlineprivate |
Return mutable area-fraction arrays from an AMReX factory.
|
inlineprivate |
|
inlineprivate |
Return mutable EB cell flags from an AMReX factory.
Referenced by set_connection_flags().

|
inlineprivate |
Return mutable face-centroid arrays from an AMReX factory.
|
inlineprivate |
| void eb_::make_all_factories | ( | int | level, |
| amrex::Geometry const & | a_geom, | ||
| amrex::BoxArray const & | ba, | ||
| amrex::DistributionMapping const & | dm, | ||
| amrex::EB2::Level const & | a_eb_level | ||
| ) |
Build cell-centered and staggered EB factories for the level.
| level | AMR level index. |
| a_geom | Geometry for the level. |
| ba | BoxArray over which factories are defined. |
| dm | DistributionMapping for the BoxArray. |
| a_eb_level | AMReX EB level used to populate factory data. |

| void eb_::make_cc_factory | ( | int | level, |
| amrex::Geometry const & | a_geom, | ||
| amrex::BoxArray const & | ba, | ||
| amrex::DistributionMapping const & | dm, | ||
| amrex::EB2::Level const & | a_eb_level | ||
| ) |
Build only the cell-centered EB factory for the level.
| level | AMR level index. |
| a_geom | Geometry for the level. |
| ba | BoxArray over which the factory is defined. |
| dm | DistributionMapping for the BoxArray. |
| a_eb_level | AMReX EB level used to populate factory data. |

|
private |
Build terrain EB geometry for the supplied Geometry.
| a_geom | Geometry used to define the EB index space. |
|
inline |
Number of ghost cells needed for basic EB flags.
Referenced by make_all_factories(), and make_cc_factory().

|
inline |
Number of ghost cells needed for full EB geometric data.
Referenced by make_all_factories(), and make_cc_factory().

|
inline |
Number of ghost cells needed for EB volume data.
Referenced by make_all_factories(), and make_cc_factory().

| void eb_::set_connection_flags | ( | amrex::EBFArrayBoxFactory * | factory | ) |
Disconnect covered neighbors in an EB factory's cell flags.
Reset cell flags to disconnect cells with zero volume fraction.
| factory | Factory whose non-const flag data are updated. |
The factory EBCellFlagFab data are updated through a non-const reference.
Referenced by make_all_factories().


|
private |
|
private |
EB level constructed from building GeometryShop.
Referenced by build_level().
|
private |
Referenced by get_const_factory(), make_all_factories(), and make_cc_factory().
|
private |
|
private |
Referenced by make_all_factories(), and make_cc_factory().
|
private |
|
private |
Referenced by get_u_const_factory(), and make_all_factories().
|
private |
Referenced by make_all_factories().
|
private |
Referenced by get_v_const_factory(), and make_all_factories().
|
private |
Referenced by make_all_factories().
|
private |
Referenced by get_w_const_factory(), and make_all_factories().
|
private |
Referenced by make_all_factories().
|
private |