10 template<
typename time>
17 template<
typename time>
26 template<
typename time>
35 template<
typename time>
44 template<
typename time>
59 template<
typename time>
65 size_t ndst = dst.size();
66 size_t nsrc = src.size();
69 for (
auto elem : dst) { elem->zero(); }
72 for (
size_t n = 0; n < ndst; n++) {
73 for (
size_t m = 0; m < nsrc; m++) {
76 dst[n]->saxpy(a*s, src[m]);
82 template<
typename time>
91 template<
typename time>
101 template<
typename time>
111 template<
typename time>
static void zero(vector< precision > &data)
virtual void broadcast(ICommunicator *comm)
Broadcasting this data structure to all processes in comm.
virtual void saxpy(time a, shared_ptr< const Encapsulation< time >> x)
Provides basic mathematical operation \( y+=ax \).
Not implemented yet exception.
virtual void zero()
Zeroes out all values of this data structure.
virtual void copy(shared_ptr< const Encapsulation< time >> other)
Copies values from other into this data structure.
virtual void mat_apply(vector< shared_ptr< Encapsulation< time >>> dst, time a, Matrix< time > mat, vector< shared_ptr< Encapsulation< time >>> src, bool zero=true)
Defines matrix-vector multiplication for this data type.
virtual void recv(ICommunicator *comm, int tag, bool blocking)
Receive values to store in this data structure.
virtual void send(ICommunicator *comm, int tag, bool blocking)
Send values stored in this data structure.
Data/solution encapsulation.
#define UNUSED(expr)
Denoting unused function parameters for omitting compiler warnings.
Abstract interface for communicators.
Eigen::Matrix< scalar, Eigen::Dynamic, Eigen::Dynamic, Eigen::RowMajor > Matrix
virtual void post(ICommunicator *comm, int tag)
virtual time norm0() const
Computes the \( 0 \)-norm of the data structure's values.