3 #include <AMReX_Config.H>
12 #include <petscsystypes.h>
39 int max_iter, const
BndryData& bndry,
int max_bndry_order);
66 std::unique_ptr<amrex_Mat>
A;
67 std::unique_ptr<amrex_Vec>
b;
68 std::unique_ptr<amrex_Vec>
x;
82 [[nodiscard]] std::unique_ptr<PETScABecLap>
#define AMREX_D_TERM(a, b, c)
Definition: AMReX_SPACE.H:129
#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
An Array of FortranArrayBox(FAB)-like Objects.
Definition: AMReX_FabArray.H:344
Rectangular problem domain geometry.
Definition: AMReX_Geometry.H:73
A collection (stored as an array) of FArrayBox objects.
Definition: AMReX_MultiFab.H:38
Definition: AMReX_PETSc.H:21
int verbose
Definition: AMReX_PETSc.H:53
MultiFab acoefs
Definition: AMReX_PETSc.H:55
FabArray< BaseFab< PetscInt > > cell_id
Definition: AMReX_PETSc.H:71
MPI_Comm comm
Definition: AMReX_PETSc.H:50
void loadVectors(MultiFab &soln, const MultiFab &rhs)
Definition: AMReX_PETSc.cpp:608
void getSolution(MultiFab &soln)
Definition: AMReX_PETSc.cpp:723
MultiFab diaginv
Definition: AMReX_PETSc.H:59
void solve(MultiFab &soln, const MultiFab &rhs, Real rel_tol, Real abs_tol, int max_iter, const BndryData &bndry, int max_bndry_order)
Definition: AMReX_PETSc.cpp:139
FabFactory< FArrayBox > const * m_factory
Definition: AMReX_PETSc.H:61
static constexpr PetscInt eb_stencil_size
Definition: AMReX_PETSc.H:48
std::unique_ptr< amrex_Mat > A
Definition: AMReX_PETSc.H:66
void setVerbose(int _verbose)
Definition: AMReX_PETSc.cpp:133
BndryData const * m_bndry
Definition: AMReX_PETSc.H:62
PETScABecLap(PETScABecLap &&) noexcept=delete
LayoutData< PetscInt > ncells_grid
Definition: AMReX_PETSc.H:70
std::unique_ptr< amrex_Vec > x
Definition: AMReX_PETSc.H:68
Real scalar_a
Definition: AMReX_PETSc.H:57
~PETScABecLap()
Definition: AMReX_PETSc.cpp:96
std::unique_ptr< amrex_KSP > solver
Definition: AMReX_PETSc.H:65
PETScABecLap(const BoxArray &grids, const DistributionMapping &dmap, const Geometry &geom_, MPI_Comm comm_)
Definition: AMReX_PETSc.cpp:61
void setBCoeffs(const Array< const MultiFab *, BL_SPACEDIM > &beta)
Definition: AMReX_PETSc.cpp:124
std::unique_ptr< amrex_Vec > b
Definition: AMReX_PETSc.H:67
Real scalar_b
Definition: AMReX_PETSc.H:57
int m_maxorder
Definition: AMReX_PETSc.H:63
MultiFab const * m_eb_b_coeffs
Definition: AMReX_PETSc.H:74
Array< MultiFab, AMREX_SPACEDIM > bcoefs
Definition: AMReX_PETSc.H:56
void prepareSolver()
Definition: AMReX_PETSc.cpp:178
FabArray< BaseFab< PetscInt > > cell_id_vec
Definition: AMReX_PETSc.H:72
PETScABecLap(PETScABecLap const &)=delete
void setScalars(Real sa, Real sb)
Definition: AMReX_PETSc.cpp:111
void setACoeffs(const MultiFab &alpha)
Definition: AMReX_PETSc.cpp:118
static constexpr PetscInt regular_stencil_size
Definition: AMReX_PETSc.H:47
Geometry geom
Definition: AMReX_PETSc.H:51
Definition: AMReX_Amr.cpp:49
std::unique_ptr< PETScABecLap > makePetsc(const BoxArray &grids, const DistributionMapping &dmap, const Geometry &geom, MPI_Comm comm_)
Definition: AMReX_PETSc.cpp:54
std::array< T, N > Array
Definition: AMReX_Array.H:24