35 #ifndef restricted_schwarz_hpp 36 #define restricted_schwarz_hpp 42 #include <schwarz/config.hpp> 44 #include <schwarz_base.hpp> 61 template <
typename ValueType = gko::default_precision,
62 typename IndexType = gko::int32,
63 typename MixedValueType = gko::default_precision>
79 std::shared_ptr<gko::matrix::Csr<ValueType, IndexType>> &
global_matrix,
80 std::shared_ptr<gko::matrix::Csr<ValueType, IndexType>> &
local_matrix,
81 std::shared_ptr<gko::matrix::Csr<ValueType, IndexType>>
89 std::shared_ptr<gko::matrix::Dense<ValueType>> &main_buffer)
override;
93 std::shared_ptr<gko::matrix::Dense<ValueType>>
100 const std::shared_ptr<gko::matrix::Dense<ValueType>> &
local_rhs,
102 const std::shared_ptr<gko::matrix::Csr<ValueType, IndexType>>
110 #endif // restricted_schwarz.hpp void setup_windows(const Settings &settings, const Metadata< ValueType, IndexType > &metadata, std::shared_ptr< gko::matrix::Dense< ValueType >> &main_buffer) override
Sets up the windows needed for the asynchronous communication.
Definition: restricted_schwarz.cpp:608
std::shared_ptr< gko::matrix::Csr< ValueType, IndexType > > interface_matrix
The local interface matrix.
Definition: schwarz_base.hpp:162
std::shared_ptr< gko::matrix::Dense< ValueType > > local_solution
The local solution vector.
Definition: schwarz_base.hpp:182
std::shared_ptr< gko::matrix::Csr< ValueType, IndexType > > local_matrix
The local subdomain matrix.
Definition: schwarz_base.hpp:137
std::shared_ptr< gko::matrix::Dense< ValueType > > global_solution
The global solution vector.
Definition: schwarz_base.hpp:187
void setup_comm_buffers() override
Sets up the communication buffers needed for the boundary exchange.
Definition: restricted_schwarz.cpp:308
void exchange_boundary(const Settings &settings, const Metadata< ValueType, IndexType > &metadata, std::shared_ptr< gko::matrix::Dense< ValueType >> &global_solution) override
Exchanges the elements of the solution vector.
Definition: restricted_schwarz.cpp:977
std::shared_ptr< gko::matrix::Dense< ValueType > > local_rhs
The local right hand side.
Definition: schwarz_base.hpp:172
The struct that contains the solver settings and the parameters to be set by the user.
Definition: settings.hpp:77
std::shared_ptr< gko::matrix::Csr< ValueType, IndexType > > global_matrix
The global matrix.
Definition: schwarz_base.hpp:167
void setup_local_matrices(Settings &settings, Metadata< ValueType, IndexType > &metadata, std::vector< unsigned int > &partition_indices, std::shared_ptr< gko::matrix::Csr< ValueType, IndexType >> &global_matrix, std::shared_ptr< gko::matrix::Csr< ValueType, IndexType >> &local_matrix, std::shared_ptr< gko::matrix::Csr< ValueType, IndexType >> &interface_matrix) override
Sets up the local and the interface matrices from the global matrix and the partition indices...
Definition: restricted_schwarz.cpp:56
The Schwarz wrappers namespace.
Definition: comm_helpers.hpp:49
An implementation of the solver interface using the RAS solver.
Definition: restricted_schwarz.hpp:64
The Base solver class is meant to be the class implementing the common implementations for all the sc...
Definition: schwarz_base.hpp:76
std::vector< unsigned int > partition_indices
The partition indices containing the subdomains to which each row(vertex) of the matrix(graph) belong...
Definition: initialization.hpp:80
SolverRAS(Settings &settings, Metadata< ValueType, IndexType > &metadata)
The constructor that takes in the user settings and a metadata struct containing the solver metadata...
Definition: restricted_schwarz.cpp:49
void update_boundary(const Settings &settings, const Metadata< ValueType, IndexType > &metadata, std::shared_ptr< gko::matrix::Dense< ValueType >> &local_solution, const std::shared_ptr< gko::matrix::Dense< ValueType >> &local_rhs, const std::shared_ptr< gko::matrix::Dense< ValueType >> &global_solution, const std::shared_ptr< gko::matrix::Csr< ValueType, IndexType >> &interface_matrix) override
Update the values into local vector from obtained from the neighboring sub-domains using the interfac...
Definition: restricted_schwarz.cpp:992