22 template<
class F,
class G>
43 typedef typename F::type type;
47 typedef typename Cmplxtype<type>::type
c_type;
49 typedef typename std::conditional<std::is_same<typename Realtype<F>::type, F>::value ,
74 template<
class H,
class I>
75 void multiply(
const H&
fact,
I&
dest)
const {
111 template<
class H,
class I>
122 const F&
matrix()
const {
return *m_; }
124 virtual std::ostream&
info(std::ostream&
os)
const;
133 template<
class H,
class I>
virtual void operator()()
void addInto(Matrix< H > &dest, const I fact, const uint rowoffset=0, const uint coloffset=0) const
virtual void operator()(const Function< c_type > &fncY, Function< c_type > &fncX)
virtual type & operator()(const uint i, const uint j)
Returns and allows access to entry with indices i and j.
SubMatrixN()
Standard constructor.
virtual type operator()(const uint i, const uint j) const
Index operator.
const Set< IndexRange > indicesX_
Index sets of sub matrix.
const_iterator end() const
Constant iterator, standing behind last element.
const_iterator begin(uint r=0) const
Constant iterator over the elements, standing at position (0,0)
std::conditional< std::is_same< typenameRealtype< F >::type, F >::value, typenameRealtype< F >::type, typenameCmplxtype< F >::type >::type d_type
Data type, depending if F is real or complex.
F & matrix()
Matrix, which the sub matrix is based on.
Cmplxtype< type >::type c_type
Complex type of data type.
iterator begin(uint r=0)
Iterator over the elements, standing at position (0,0)
virtual std::ostream & info(std::ostream &os) const
Returns information in an output stream.
Realtype< type >::type r_type
Real type of data type.
SubMatrixN(F &m, const Set< IndexRange > &indicesX, const Set< IndexRange > &indicesY)
Constructor.
virtual void convertCRS(type *a, int *asub, int *xa) const
Converts sub matrix to CRS format.
virtual void convertCCS(type *a, int *asub, int *xa) const
Converts sub matrix to CCS format.
const Set< IndexRange > & indicesX() const
Returns index range for the rows.
const Set< IndexRange > & indicesY() const
Returns index range for the columns.
virtual void convertIJK(type *, int *, int *) const
Converts sub matrix to IJK format.
void matrixMultiplyRowSorting(const F &factL, const G &factR, Matrix< H > &dest)
Set< F > makeSet(uint n, const F &first,...)