3 #include <AMReX_Config.H>
10 #include "_hypre_utilities.h"
41 int max_iter,
const BndryData& bndry,
int max_bndry_order) = 0;
43 static HYPRE_Int
ispow2 (HYPRE_Int i)
45 return (i == 1) ? 1 : (((i <= 0) || (i & 1)) ? 0 :
ispow2(i / 2));
49 const auto& v =
b.loVect();
51 static_cast<HYPRE_Int
>(v[1]),
52 static_cast<HYPRE_Int
>(v[2]))};
56 const auto& v =
b.hiVect();
58 static_cast<HYPRE_Int
>(v[1]),
59 static_cast<HYPRE_Int
>(v[2]))};
101 [[nodiscard]] std::unique_ptr<Hypre>
102 makeHypre (
const BoxArray& grids,
const DistributionMapping& dmap,
104 const iMultiFab* overset_mask =
nullptr);
#define AMREX_D_TERM(a, b, c)
Definition: AMReX_SPACE.H:129
#define AMREX_D_DECL(a, b, c)
Definition: AMReX_SPACE.H:104
#define BL_SPACEDIM
Definition: AMReX_SPACE.H:15
int MPI_Comm
Definition: AMReX_ccse-mpi.H:47
static constexpr int MPI_COMM_NULL
Definition: AMReX_ccse-mpi.H:55
A BndryData stores and manipulates boundary data information on each side of each box in a BoxArray.
Definition: AMReX_BndryData.H:41
A collection of Boxes stored in an Array.
Definition: AMReX_BoxArray.H:549
Calculates the distribution of FABs to MPI processes.
Definition: AMReX_DistributionMapping.H:41
Rectangular problem domain geometry.
Definition: AMReX_Geometry.H:73
Definition: AMReX_Hypre.H:18
Array< MultiFab, AMREX_SPACEDIM > bcoefs
Definition: AMReX_Hypre.H:89
bool is_matrix_singular
Definition: AMReX_Hypre.H:98
void setHypreOldDefault(bool l) noexcept
Definition: AMReX_Hypre.H:65
void setVerbose(int _verbose)
Definition: AMReX_Hypre.cpp:89
MultiFab acoefs
Definition: AMReX_Hypre.H:88
int verbose
Definition: AMReX_Hypre.H:79
void setHypreStrongThreshold(Real t) noexcept
Definition: AMReX_Hypre.H:69
Hypre(Hypre &&) noexcept=default
void setHypreRelaxType(int n) noexcept
Definition: AMReX_Hypre.H:66
static HYPRE_Int ispow2(HYPRE_Int i)
Definition: AMReX_Hypre.H:43
static constexpr HYPRE_Int eb_stencil_size
Definition: AMReX_Hypre.H:72
MPI_Comm comm
Definition: AMReX_Hypre.H:76
Real scalar_a
Definition: AMReX_Hypre.H:90
BndryData const * m_bndry
Definition: AMReX_Hypre.H:95
void setHypreOptionsNamespace(const std::string &ns) noexcept
Definition: AMReX_Hypre.H:63
MultiFab diaginv
Definition: AMReX_Hypre.H:92
int m_maxorder
Definition: AMReX_Hypre.H:96
FabFactory< FArrayBox > const * m_factory
Definition: AMReX_Hypre.H:94
Real scalar_b
Definition: AMReX_Hypre.H:90
Geometry geom
Definition: AMReX_Hypre.H:77
void setBCoeffs(const Array< const MultiFab *, BL_SPACEDIM > &beta)
Definition: AMReX_Hypre.cpp:80
std::string options_namespace
Definition: AMReX_Hypre.H:86
void setHypreNumSweeps(int n) noexcept
Definition: AMReX_Hypre.H:68
int relax_order
Definition: AMReX_Hypre.H:82
int relax_type
Definition: AMReX_Hypre.H:81
static Array< HYPRE_Int, AMREX_SPACEDIM > hiV(const Box &b)
Definition: AMReX_Hypre.H:55
int num_sweeps
Definition: AMReX_Hypre.H:83
static constexpr HYPRE_Int regular_stencil_size
Definition: AMReX_Hypre.H:71
void setScalars(Real sa, Real sb)
Definition: AMReX_Hypre.cpp:67
Real strong_threshold
Definition: AMReX_Hypre.H:84
virtual void solve(MultiFab &soln, const MultiFab &rhs, Real rel_tol, Real abs_tol, int max_iter, const BndryData &bndry, int max_bndry_order)=0
void setIsMatrixSingular(bool flag)
Definition: AMReX_Hypre.H:39
static Array< HYPRE_Int, AMREX_SPACEDIM > loV(const Box &b)
Definition: AMReX_Hypre.H:48
void setACoeffs(const MultiFab &alpha)
Definition: AMReX_Hypre.cpp:74
void setHypreRelaxOrder(int n) noexcept
Definition: AMReX_Hypre.H:67
Interface
Definition: AMReX_Hypre.H:21
bool old_default
Definition: AMReX_Hypre.H:80
Hypre(const BoxArray &grids, const DistributionMapping &dmap, const Geometry &geom, MPI_Comm comm_)
Definition: AMReX_Hypre.cpp:27
A collection (stored as an array) of FArrayBox objects.
Definition: AMReX_MultiFab.H:38
Definition: AMReX_Amr.cpp:49
const int[]
Definition: AMReX_BLProfiler.cpp:1664
std::unique_ptr< Hypre > makeHypre(const BoxArray &grids, const DistributionMapping &dmap, const Geometry &geom, MPI_Comm comm_, Hypre::Interface interface, const iMultiFab *overset_mask)
Definition: AMReX_Hypre.cpp:12
std::array< T, N > Array
Definition: AMReX_Array.H:24