Arageli::matrix< T, REFCNT > Class Template Reference

Template class matrix. More...

#include <matrix.hpp>

List of all members.

Assignments.

void assign ()
 Creates a matrix with zero dimensions.
template<typename X>
void assign (const X &x)
 Mixed constructor: creates from a string, by a size, from another vector or matrix.
template<typename X>
void assign (size_type rowscols_a, const X &x)
 Mixed constructor: creates square matrix from a sequence or just null matrix with any dimensions.
template<typename X>
void assign (size_type rows_a, size_type cols_a, const X &x)
 Mixed constructor: creates matrix with any dimentions from a value or from a sequence.
template<typename X>
matrixoperator= (const X &x)

Public Types

Standard type definition.
typedef Mem::value_type value_type
 The item type. It is T.
typedef Mem::value_type element_type
 The item type. It is T.
typedef Mem::reference reference
 Lvalue of item type.
typedef Mem::const_reference const_reference
 Const lvalue of item type.
typedef Mem::pointer pointer
 Pointer to const item type.
typedef Mem::const_pointer const_pointer
 Pointer to item type.
typedef Mem::size_type size_type
 Unsigned integer type for size and absolute index representation.
typedef Mem::difference_type difference_type
 Signed integer type for offsets and relative index representation.
typedef Rep::Mem::iterator iterator
 Iterator type.
typedef Rep::Mem::const_iterator const_iterator
 Const iterator type.

Public Member Functions

void assign_fromsize (std::size_t size_a)
 Creates square matrix sized by size_a by size_a with values factory<T>::null().
void assign_fromstr (const char *s)
 Creates matrix from string noted by usual rules for matrices.
template<typename Vec>
void assign_fromvec (const Vec &vec)
 Creates a row-matrix copied from a vector-like structure.
template<typename Mat>
void assign_frommat (const Mat &mat)
 Creates a matrix as a copy of another matrix-like structure.
template<typename Val>
void assign_fromval (size_type rowscols_a, const Val &val)
 Creates square matrix with val as each element.
template<typename Seq>
void assign_fromseq (size_type rowscols_a, const Seq &seq)
 Creates square matrix from a sequence.
void assign_fromsize (size_type rows_a, size_type cols_a)
 Creates matrix with any dimensions, each item is equal to factory<T>::null().
template<typename Vec>
void assign_fromvec (size_type rows_a, const Vec &vec)
 Creates matrix with each row copied from some vector.
template<typename Vec>
void assign_colwise (const Vec &vec)
 Creates a column-matrix copied from a vector-like structure.
template<typename Vec>
void assign_colwise_fromvec (size_type cols_a, const Vec &vec)
 Creates a matrix each column copied from a vector.
template<typename Seq>
void assign_colwise_fromseq (size_type rowcols_a, const Seq &seq)
 Creates a square matrix from a sequence with column-wise filling.
template<typename X>
void assign_colwise (size_type rowcols_a, const X &x)
template<typename Seq>
void assign_colwise (size_type rows_a, size_type cols_a, const Seq &seq)
 Creates a matrix from a sequence with column-wise filling.
template<typename Val>
void assign_fromval (size_type rows_a, size_type cols_a, const Val &val)
 Creates matrix with any dimentions and with val as each element.
template<typename Seq>
void assign_fromseq (size_type rows_a, size_type cols_a, Seq seq)
 Creates matrix with any dimentions from sequence.
template<typename Vec>
void assign_diag (const Vec &vec)
 Creates a square diagonal matrix from a vector.
template<typename Val>
void assign_diag_fromval (size_type rowscols_a, const Val &val)
 Creates a square diagonal matrix with a particular value on the diagonal.
template<typename Seq>
void assign_diag_fromseq (size_type rowscols_a, const Seq &seq)
 Creates a square diagonal matrix from a sequence.
template<typename Vec>
void assign_diag_fromvec (size_type rowscols_a, const Vec &vec)
 Creates a square diagonal matrix from a vector.
template<typename X>
void assign_diag (size_type rowscols_a, const X &x)
 Mixed constructor: creates a square diagonal matrix from a value, from a sequence or from a vector.
template<typename Val>
void assign_diag_fromval (size_type rows_a, size_type cols_a, const Val &val)
 Creates a diagonal matrix with any dimensions with a particular value on the diagonal.
template<typename Seq>
void assign_diag_fromseq (size_type rows_a, size_type cols_a, Seq seq)
 Creates a diagonal with any dimensions matrix from a sequence.
template<typename Vec>
void assign_diag_fromvec (size_type rows_a, size_type cols_a, const Vec &vec)
 Creates a diagonal with any dimensions matrix from a sequence.
template<typename X>
void assign_diag (size_type rows_a, size_type cols_a, const X &x)
 Mixed constructor: creates a diagonal matrix with any dimentions from a value or from a sequence.
void assign_eye (size_type rowscols_a)
 Creates a square identity matrix.
void assign_eye (size_type rows_a, size_type cols_a)
 Creates an identity matrix with any dimensions.
void resize (size_type rows_a, size_type cols_a)
bool pack ()
size_type nrows () const
 Number of rows in the matrix.
size_type ncols () const
 Number of rows in the matrix.
size_type size () const
 Number of items in the matrix.
size_type length () const
 The maximum from nrows() and ncols().
size_type capacity () const
bool is_empty () const
 Returns true if the matrix is empty.
bool is_null () const
 Returns true if the matrix is null-matrix.
bool is_unit () const
 Returns true if the matrix is unit-matrix.
bool is_opposite_unit () const
 Returns true if the matrix is opposite unit-matrix.
bool is_square () const
 Returns true if the matrix is square matrix.
matrixopposite ()
 Makes opposite matrix.
matrixinverse ()
 Makes inversed matrix.
matrixeach_inverse ()
 Makes matrix with inversed elements.
template<typename T1>
matrixadd_scalar (const T1 &x)
template<typename T1>
matrixsub_scalar (const T1 &x)
template<typename T1>
matrixmul_scalar (const T1 &x)
template<typename T1>
matrixdiv_scalar (const T1 &x)
template<typename T1>
matrixmod_scalar (const T1 &x)
template<typename T1>
matrixbitand_scalar (const T1 &x)
template<typename T1>
matrixbitor_scalar (const T1 &x)
template<typename T1>
matrixbitxor_scalar (const T1 &x)
template<typename T1>
matrixshl_scalar (const T1 &x)
template<typename T1>
matrixshr_scalar (const T1 &x)
template<typename T1>
matrixadd_matrix (const T1 &x)
template<typename T1>
matrixsub_matrix (const T1 &x)
template<typename T1>
matrixmul_matrix (const T1 &x)
template<typename T1>
matrixdiv_matrix (const T1 &x)
template<typename T1>
matrixmod_matrix (const T1 &x)
template<typename T1>
matrixbitand_matrix (const T1 &x)
template<typename T1>
matrixbitor_matrix (const T1 &x)
template<typename T1>
matrixbitxor_matrix (const T1 &x)
template<typename T1>
matrixshl_matrix (const T1 &x)
template<typename T1>
matrixshr_matrix (const T1 &x)
template<typename T1>
matrixeach_add_matrix (const T1 &x)
template<typename T1>
matrixeach_sub_matrix (const T1 &x)
template<typename T1>
matrixeach_mul_matrix (const T1 &x)
template<typename T1>
matrixeach_div_matrix (const T1 &x)
template<typename T1>
matrixeach_mod_matrix (const T1 &x)
template<typename T1>
matrixeach_bitand_matrix (const T1 &x)
template<typename T1>
matrixeach_bitor_matrix (const T1 &x)
template<typename T1>
matrixeach_bitxor_matrix (const T1 &x)
template<typename T1>
matrixeach_shl_matrix (const T1 &x)
template<typename T1>
matrixeach_shr_matrix (const T1 &x)
template<typename T1, bool REFCNT1>
matrixoperator *= (const matrix< T1, REFCNT1 > &x)
 Matrix multiplication.
template<typename T1, bool REFCNT1>
matrixoperator/= (const matrix< T1, REFCNT1 > &x)
 Divides one square matrix by another square matrix.
matrix operator- () const
 Returns matrix with opposite values of items of this matrix.
const matrixoperator+ () const
 Returns reference to this matrix. For sameness only.
matrixoperator++ ()
matrix operator++ (int)
matrixoperator-- ()
matrix operator-- (int)
void transpose ()
 Transposes the matrix.
template<typename T1, bool REFCNT1>
void swap (matrix< T1, REFCNT1 > &x)
 Swaps this matrix with x without actually coping (if possible).
template<typename M>
void insert_matrix_bottom (const M &m)
template<typename RS, typename CS>
matrix< T, true > copy_submatrix (const RS &rs, const CS &cs) const
template<typename RS, typename CS, typename M>
M & copy_submatrix (const RS &rs, const CS &cs, M &res) const
template<typename RS, typename CS>
void erase_submatrix (const RS &rs, const CS &cs)
template<typename RS, typename CS, typename M>
M & take_submatrix (const RS &rs, const CS &cs, M &res)
template<typename RS, typename CS>
matrix< T, true > take_submatrix (const RS &rs, const CS &cs)
bool unique ()
 Makes an individual representation for this object.
bool unique_clear ()
 Makes an individual or a clean individual representation for this object.
Constructors.
 matrix ()
 Creates a matrix with zero dimensions.
 matrix (std::size_t size_a, const fromsize_t &select)
 Creates square matrix sized by size_a by size_a with values factory<T>::null().
 matrix (const char *s, const fromstr_t &select)
 Creates matrix from string noted by usual rules for matrices.
template<typename Vec>
 matrix (const Vec &vec, const fromvec_t &select)
 Creates a row-matrix copied from a vector-like structure.
template<typename Mat>
 matrix (const Mat &mat, const frommat_t &select)
 Creates a matrix as a copy of another matrix-like structure.
template<typename X>
 matrix (const X &x)
 Mixed constructor: creates from a string, by a size, from another vector or matrix.
template<typename Val>
 matrix (size_type rowscols_a, const Val &val, const fromval_t &select)
 Creates square matrix with val as each element.
template<typename Seq>
 matrix (size_type rowscols_a, const Seq &seq, const fromseq_t &select)
 Creates square matrix from a sequence.
 matrix (size_type rows_a, size_type cols_a, const fromsize_t &select)
 Creates matrix with any dimensions, each item is equal to factory<T>::null().
template<typename Vec>
 matrix (size_type rows_a, const Vec &vec, const fromvec_t &select)
 Creates matrix with each row copied from some vector.
template<typename X>
 matrix (size_type rowscols_a, const X &x)
 Mixed constructor: creates square matrix from a sequence or just null matrix with any dimensions.
template<typename Vec>
 matrix (const Vec &vec, const colwise_t &select)
 Creates a column-matrix copied from a vector-like structure.
template<typename Vec>
 matrix (size_type cols_a, const Vec &vec, const colwise_t &select_1, const fromvec_t &select_2)
 Creates a matrix each column copied from a vector.
template<typename Seq>
 matrix (size_type rowcols_a, const Seq &seq, const colwise_t &select_1, const fromseq_t &select_2)
 Creates a square matrix from a sequence with column-wise filling.
template<typename X>
 matrix (size_type rowcols_a, const X &x, const colwise_t &select)
template<typename Seq>
 matrix (size_type rows_a, size_type cols_a, const Seq &seq, const colwise_t &select)
 Creates a matrix from a sequence with column-wise filling.
template<typename Val>
 matrix (size_type rows_a, size_type cols_a, const Val &val, const fromval_t &select)
 Creates matrix with any dimentions and with val as each element.
template<typename Seq>
 matrix (size_type rows_a, size_type cols_a, const Seq &seq, const fromseq_t &select)
 Creates matrix with any dimentions from sequence.
template<typename X>
 matrix (size_type rows_a, size_type cols_a, const X &x)
 Mixed constructor: creates matrix with any dimentions from a value or from a sequence.
template<typename Vec>
 matrix (const Vec &vec, const diag_t &select)
 Creates a square diagonal matrix from a vector.
template<typename Val>
 matrix (size_type rowscols_a, const Val &val, const diag_t &select_1, const fromval_t &select_2)
 Creates a square diagonal matrix with a particular value on the diagonal.
template<typename Seq>
 matrix (size_type rowscols_a, const Seq &seq, const diag_t &select_1, const fromseq_t &select_2)
 Creates a square diagonal matrix from a sequence.
template<typename Vec>
 matrix (size_type rowscols_a, const Vec &vec, const diag_t &select_1, const fromvec_t &select_2)
 Creates a square diagonal matrix from a vector.
template<typename X>
 matrix (size_type rowscols_a, const X &x, const diag_t &select)
 Mixed constructor: creates a square diagonal matrix from a value, from a sequence or from a vector.
template<typename Val>
 matrix (size_type rows_a, size_type cols_a, const Val &val, const diag_t &select_1, const fromval_t &select_2)
 Creates a diagonal matrix with any dimensions with a particular value on the diagonal.
template<typename Seq>
 matrix (size_type rows_a, size_type cols_a, const Seq &seq, const diag_t &select_1, const fromseq_t &select_2)
 Creates a diagonal with any dimensions matrix from a sequence.
template<typename Vec>
 matrix (size_type rows_a, size_type cols_a, const Vec &vec, const diag_t &select_1, const fromvec_t &select_2)
 Creates a diagonal with any dimensions matrix from a sequence.
template<typename X>
 matrix (size_type rows_a, size_type cols_a, const X &x, const diag_t &select)
 Mixed constructor: creates a diagonal matrix with any dimentions from a value or from a sequence.
 matrix (size_type rowscols_a, const eye_t &select)
 Creates a square identity matrix.
 matrix (size_type rows_a, size_type cols_a, const eye_t &select)
 Creates an identity matrix with any dimensions.
Element accessing.
const_reference el (size_type i, size_type j) const
 Accesses to matrix item by index (i, j). Constant form.
reference el (size_type i, size_type j)
 Accesses to matrix item by index (i, j). Non-constant form.
const_reference operator() (size_type i, size_type j) const
 Accesses to matrix item by index (i, j). Constant form.
reference operator() (size_type i, size_type j)
 Accesses to matrix item by index (i, j). Non-constant form.
const_reference at (size_type i, size_type j) const
 Accesses to matrix item by index (i, j). Constant form.
reference at (size_type i, size_type j)
 Accesses to matrix item by index (i, j). Non-constant form.
Matrix with scalar assignment operators.
This group of operators applied the specified operation for each item of the matrix with scalar-value 'x'. Returns reference to the matrix.

template<typename T1>
matrixoperator+= (const T1 &x)
template<typename T1>
matrixoperator-= (const T1 &x)
template<typename T1>
matrixoperator *= (const T1 &x)
template<typename T1>
matrixoperator/= (const T1 &x)
template<typename T1>
matrixoperator%= (const T1 &x)
template<typename T1>
matrixoperator &= (const T1 &x)
template<typename T1>
matrixoperator|= (const T1 &x)
template<typename T1>
matrixoperator^= (const T1 &x)
template<typename T1>
matrixoperator<<= (const T1 &x)
template<typename T1>
matrixoperator>>= (const T1 &x)
matrixoperator+= (const T &x)
matrixoperator-= (const T &x)
matrixoperator *= (const T &x)
matrixoperator/= (const T &x)
matrixoperator%= (const T &x)
matrixoperator &= (const T &x)
matrixoperator|= (const T &x)
matrixoperator^= (const T &x)
matrixoperator<<= (const T &x)
matrixoperator>>= (const T &x)
Matrix with matrix assignment operators.
This group of operators applied the specified operation for each pair of the corresponding items of two matrices. Returns reference to the first matrix.

template<typename T1, bool REFCNT1>
matrixoperator+= (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixoperator-= (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixeach_add (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixeach_sub (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixeach_mul (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixeach_div (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixeach_mod (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixeach_bitand (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixeach_bitor (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixeach_bitxor (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixeach_shl (const matrix< T1, REFCNT1 > &x)
template<typename T1, bool REFCNT1>
matrixeach_shr (const matrix< T1, REFCNT1 > &x)
Access via iterators.
iterator begin ()
 Returns iterator on begin of items sequence. Non-constant form.
iterator end ()
 Returns iterator on end of items sequence. Non-constant form.
const_iterator begin () const
 Returns iterator on begin of items sequence. Constant form.
const_iterator end () const
 Returns iterator on end of items sequence. Constant form.
Working with rows.
void insert_row (size_type pos, const T &val)
 Inserts new row filled by val at postition pos.
template<typename T1, bool REFCNT1>
void insert_row (size_type pos, const vector< T1, REFCNT1 > &vals)
 Inserts new row filled by values from vals at positition pos.
template<typename In>
void insert_row (size_type pos, In first)
 Inserts new row filled by values from range [first, first + ncols()) at posititon pos.
void insert_rows (size_type pos, size_type n, const T &val)
 Inserts n new rows filled by val at position pos.
template<typename T1, bool REFCNT1>
void insert_rows (size_type pos, size_type n, const vector< T1, REFCNT1 > &vals)
 Inserts n new rows that each row is filled by values from vals at positition pos.
template<typename In>
void insert_rows (size_type pos, size_type n, In first)
 Inserts n new rows that each row is filled by values from range [first, first + ncols()) at posititon pos.
void erase_row (size_type pos)
 Erases pos-th row.
void erase_rows (size_type pos, size_type n)
 Erases n rows from range [pos, pos + n).
void swap_rows (size_type xpos, size_type ypos)
 Swaps two rows at xpos and ypos.
template<typename T1>
void mult_row (size_type i, const T1 &x)
 Multiplies row i by value x.
template<typename T1>
void div_row (size_type i, const T1 &x)
 Divides row i by value x.
template<typename T1>
void mod_row (size_type i, const T1 &x)
 Gives row i by modulo x.
void add_rows (size_type dstpos, size_type srcpos)
 Performs row[dstpos] += row[srcpos].
void sub_rows (size_type dstpos, size_type srcpos)
 Performs row[dstpos] -= row[srcpos].
template<typename T2>
void addmult_rows (size_type dstpos, size_type srcpos, const T2 &y)
 Performs row[dstpos] += y*row[srcpos].
template<typename T1, typename T2>
void addmult_rows (size_type dstpos, const T1 &x, size_type srcpos, const T2 &y)
 Performs row[dstpos] = x*row[dstpos] + y*row[srcpos].
template<typename T1, typename T2>
void addmult_rows (size_type dstpos, const T1 &x, int srcpos, const T2 &y)
 Performs row[dstpos] = x*row[dstpos] + y*row[srcpos].
template<typename T1, typename V, typename T2>
void addmult_rows (size_type dstpos, const T1 &x, const V &srcvec, const T2 &y)
 Performs row[dstpos] = x*row[dstpos] + y*srcvec.
vector< T, true > copy_row (size_type i) const
 Returns a copy of the specified row of the matrix.
template<typename V>
V & copy_row (size_type i, V &res) const
 Fills the argument of a copy of the specified row of the matrix.
template<typename SV>
matrix< T, true > copy_rows (const SV &sv) const
template<typename SV, typename M>
M & copy_rows (const SV &sv, M &res) const
template<typename SV>
void erase_rows (const SV &sv)
template<typename SV, typename M>
M & take_rows (const SV &sv, M &res)
template<typename SV>
matrix< T, true > take_rows (const SV &sv)
template<typename V>
V & take_row (size_type i, V &res)
vector< T, true > take_row (size_type i)
template<typename V>
void assign_row (size_type i, const V &v)
Working with columns.
void insert_col (size_type pos, const T &val)
 Inserts new col filled by val at postition pos.
template<typename T1, bool REFCNT1>
void insert_col (size_type pos, const vector< T1, REFCNT1 > &vals)
 Inserts new col filled by values from vals at positition pos.
template<typename In>
void insert_col (size_type pos, In first)
 Inserts new col filled by values from range [first, first + ncols()) at posititon pos.
void insert_cols (size_type pos, size_type n, const T &val)
 Inserts n new cols filled by val at position pos.
template<typename T1, bool REFCNT1>
void insert_cols (size_type pos, size_type n, const vector< T1, REFCNT1 > &vals)
 Inserts n new cols that each col is filled by values from vals at positition pos.
template<typename In>
void insert_cols (size_type pos, size_type n, In first)
 Inserts n new cols that each col is filled by values from range [first, first + ncols()) at posititon pos.
void erase_col (size_type pos)
 Erases pos-th col.
void erase_cols (size_type pos, size_type n)
 Erases n cols from range [pos, pos + n).
void swap_cols (size_type xpos, size_type ypos)
 Swaps two cols at xpos and ypos.
template<typename T1>
void mult_col (size_type i, const T1 &x)
 Multiplies col i by value x.
template<typename T1>
void div_col (size_type i, const T1 &x)
 Divides col i by value x.
template<typename T1>
void mod_col (size_type i, const T1 &x)
 Gives col i by modulo x.
void add_cols (size_type dstpos, size_type srcpos)
 Performs col[dstpos] += col[srcpos].
void sub_cols (size_type dstpos, size_type srcpos)
 Performs col[dstpos] -= col[srcpos].
template<typename T2>
void addmult_cols (size_type dstpos, size_type srcpos, const T2 &y)
 Performs col[dstpos] += y*col[srcpos].
template<typename T1, typename T2>
void addmult_cols (size_type dstpos, const T1 &x, size_type srcpos, const T2 &y)
 Performs col[dstpos] = x*col[dstpos] + y*col[srcpos].
template<typename T1, typename T2>
void addmult_cols (size_type dstpos, const T1 &x, int srcpos, const T2 &y)
 Performs col[dstpos] = x*col[dstpos] + y*col[srcpos].
template<typename T1, typename V, typename T2>
void addmult_cols (size_type dstpos, const T1 &x, const V &srcvec, const T2 &y)
 Performs col[dstpos] = x*col[dstpos] + y*srcvec.
vector< T, true > copy_col (size_type i) const
 Returns a copy of the specified col of the matrix.
template<typename V>
V & copy_col (size_type i, V &res) const
 Fills the argument of a copy of the specified col of the matrix.
template<typename SV>
matrix< T, true > copy_cols (const SV &sv) const
template<typename SV, typename M>
M & copy_cols (const SV &sv, M &res) const
template<typename SV>
void erase_cols (const SV &sv)
template<typename SV, typename M>
M & take_cols (const SV &sv, M &res)
template<typename SV>
matrix< T, true > take_cols (const SV &sv)
template<typename V>
V & take_col (size_type i, V &res)
vector< T, true > take_col (size_type i)
template<typename V>
void assign_col (size_type j, const V &v)

Static Public Attributes

static const bool refcounting = REFCNT
 Reference counting property.

Classes

struct  other_element_type
 Defines vector type with other element type and the same reference counter. More...
struct  other_element_type_refcnt
 Defines vector type with other element type ane reference counter. More...


Detailed Description

template<typename T, bool REFCNT>
class Arageli::matrix< T, REFCNT >

Template class matrix.

Definition of "dense" matrix data structure. All indexes are started from zero.

Parameters:
T type of matrix's items
REFCNT reference counter switch

Definition at line 156 of file matrix.hpp.


Member Typedef Documentation

template<typename T, bool REFCNT>
typedef Rep::Mem::const_iterator Arageli::matrix< T, REFCNT >::const_iterator

Const iterator type.

Definition at line 223 of file matrix.hpp.

template<typename T, bool REFCNT>
typedef Mem::const_pointer Arageli::matrix< T, REFCNT >::const_pointer

Pointer to item type.

Definition at line 210 of file matrix.hpp.

template<typename T, bool REFCNT>
typedef Mem::const_reference Arageli::matrix< T, REFCNT >::const_reference

Const lvalue of item type.

Definition at line 204 of file matrix.hpp.

template<typename T, bool REFCNT>
typedef Mem::difference_type Arageli::matrix< T, REFCNT >::difference_type

Signed integer type for offsets and relative index representation.

Definition at line 217 of file matrix.hpp.

template<typename T, bool REFCNT>
typedef Mem::value_type Arageli::matrix< T, REFCNT >::element_type

The item type. It is T.

Definition at line 198 of file matrix.hpp.

template<typename T, bool REFCNT>
typedef Rep::Mem::iterator Arageli::matrix< T, REFCNT >::iterator

Iterator type.

Definition at line 220 of file matrix.hpp.

template<typename T, bool REFCNT>
typedef Mem::pointer Arageli::matrix< T, REFCNT >::pointer

Pointer to const item type.

Definition at line 207 of file matrix.hpp.

template<typename T, bool REFCNT>
typedef Mem::reference Arageli::matrix< T, REFCNT >::reference

Lvalue of item type.

Definition at line 201 of file matrix.hpp.

template<typename T, bool REFCNT>
typedef Mem::size_type Arageli::matrix< T, REFCNT >::size_type

Unsigned integer type for size and absolute index representation.

Can represent each non-negative value of difference_type.

Definition at line 214 of file matrix.hpp.

template<typename T, bool REFCNT>
typedef Mem::value_type Arageli::matrix< T, REFCNT >::value_type

The item type. It is T.

Definition at line 195 of file matrix.hpp.


Constructor & Destructor Documentation

template<typename T, bool REFCNT>
Arageli::matrix< T, REFCNT >::matrix (  )  [inline]

Creates a matrix with zero dimensions.

Definition at line 249 of file matrix.hpp.

template<typename T, bool REFCNT>
Arageli::matrix< T, REFCNT >::matrix ( std::size_t  size_a,
const fromsize_t select 
) [inline]

Creates square matrix sized by size_a by size_a with values factory<T>::null().

Definition at line 260 of file matrix.hpp.

template<typename T, bool REFCNT>
Arageli::matrix< T, REFCNT >::matrix ( const char *  s,
const fromstr_t select 
) [inline]

Creates matrix from string noted by usual rules for matrices.

Definition at line 265 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
Arageli::matrix< T, REFCNT >::matrix ( const Vec &  vec,
const fromvec_t select 
) [inline]

Creates a row-matrix copied from a vector-like structure.

Definition at line 271 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Mat>
Arageli::matrix< T, REFCNT >::matrix ( const Mat &  mat,
const frommat_t select 
) [inline]

Creates a matrix as a copy of another matrix-like structure.

Definition at line 277 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename X>
Arageli::matrix< T, REFCNT >::matrix ( const X &  x  )  [inline]

Mixed constructor: creates from a string, by a size, from another vector or matrix.

Definition at line 283 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Val>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rowscols_a,
const Val &  val,
const fromval_t select 
) [inline]

Creates square matrix with val as each element.

Parameters:
rowscols_a size of a matrix, it is number of rows and number of columns
val an initial value for each element

Definition at line 295 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Seq>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rowscols_a,
const Seq &  seq,
const fromseq_t select 
) [inline]

Creates square matrix from a sequence.

Parameters:
rowscols_a size of a matrix, it is number of rows and number of columns
seq an iterator to begin of the sequence, and elements of matrix will be rowwise constructed from this sequence.

Definition at line 305 of file matrix.hpp.

template<typename T, bool REFCNT>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
size_type  cols_a,
const fromsize_t select 
) [inline]

Creates matrix with any dimensions, each item is equal to factory<T>::null().

Parameters:
rows_a number of rows
cols_a number of columns

Definition at line 312 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
const Vec &  vec,
const fromvec_t select 
) [inline]

Creates matrix with each row copied from some vector.

Definition at line 318 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename X>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rowscols_a,
const X &  x 
) [inline]

Mixed constructor: creates square matrix from a sequence or just null matrix with any dimensions.

Definition at line 324 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
Arageli::matrix< T, REFCNT >::matrix ( const Vec &  vec,
const colwise_t select 
) [inline]

Creates a column-matrix copied from a vector-like structure.

Definition at line 333 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
Arageli::matrix< T, REFCNT >::matrix ( size_type  cols_a,
const Vec &  vec,
const colwise_t select_1,
const fromvec_t select_2 
) [inline]

Creates a matrix each column copied from a vector.

Definition at line 340 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Seq>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rowcols_a,
const Seq &  seq,
const colwise_t select_1,
const fromseq_t select_2 
) [inline]

Creates a square matrix from a sequence with column-wise filling.

Definition at line 350 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename X>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rowcols_a,
const X &  x,
const colwise_t select 
) [inline]

Definition at line 358 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Seq>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
size_type  cols_a,
const Seq &  seq,
const colwise_t select 
) [inline]

Creates a matrix from a sequence with column-wise filling.

Definition at line 365 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Val>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
size_type  cols_a,
const Val &  val,
const fromval_t select 
) [inline]

Creates matrix with any dimentions and with val as each element.

Parameters:
rows_a number of rows
cols_a number of columns
val an initial value for each element

Definition at line 381 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Seq>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
size_type  cols_a,
const Seq &  seq,
const fromseq_t select 
) [inline]

Creates matrix with any dimentions from sequence.

Parameters:
rows_a number of rows
cols_a number of columns
in an iterator to begin of the sequence, and elements of matrix will be rowwise constructed from this sequence

Definition at line 396 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename X>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
size_type  cols_a,
const X &  x 
) [inline]

Mixed constructor: creates matrix with any dimentions from a value or from a sequence.

Chooses between matrix(rows_a, cols_a, x, const fromval_t& select) and matrix(rows_a, cols_a, x, const fromseq_t& select).

Parameters:
rows_a number of rows
cols_a number of columns
x Meaning of this parameter depends on a structure of In_or_T1. If X is conversible to T then x is an initial value for each element of the matrix; otherwise x is an iterator to begin of the sequence, and elements of matrix will be rowwise constructed from this sequence.

Definition at line 417 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
Arageli::matrix< T, REFCNT >::matrix ( const Vec &  vec,
const diag_t select 
) [inline]

Creates a square diagonal matrix from a vector.

Parameters:
rowscols_a size of a matrix
seq sequence of init values

Definition at line 428 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Val>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rowscols_a,
const Val &  val,
const diag_t select_1,
const fromval_t select_2 
) [inline]

Creates a square diagonal matrix with a particular value on the diagonal.

Parameters:
rowscols_a size of a matrix
val value on the diagonal

Definition at line 437 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Seq>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rowscols_a,
const Seq &  seq,
const diag_t select_1,
const fromseq_t select_2 
) [inline]

Creates a square diagonal matrix from a sequence.

Parameters:
rowscols_a size of a matrix
seq sequence of init values

Definition at line 450 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rowscols_a,
const Vec &  vec,
const diag_t select_1,
const fromvec_t select_2 
) [inline]

Creates a square diagonal matrix from a vector.

Parameters:
rowscols_a size of a matrix
seq sequence of init values

Definition at line 463 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename X>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rowscols_a,
const X &  x,
const diag_t select 
) [inline]

Mixed constructor: creates a square diagonal matrix from a value, from a sequence or from a vector.

Definition at line 474 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Val>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
size_type  cols_a,
const Val &  val,
const diag_t select_1,
const fromval_t select_2 
) [inline]

Creates a diagonal matrix with any dimensions with a particular value on the diagonal.

Parameters:
rows_a number of rows
cols_a number of columns
val value on the diagonal

Definition at line 487 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Seq>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
size_type  cols_a,
const Seq &  seq,
const diag_t select_1,
const fromseq_t select_2 
) [inline]

Creates a diagonal with any dimensions matrix from a sequence.

Parameters:
rows_a number of rows
cols_a number of columns
seq sequence of init values

Definition at line 502 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
size_type  cols_a,
const Vec &  vec,
const diag_t select_1,
const fromvec_t select_2 
) [inline]

Creates a diagonal with any dimensions matrix from a sequence.

Parameters:
rows_a number of rows
cols_a number of columns
vec sequence of init values

Definition at line 516 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename X>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
size_type  cols_a,
const X &  x,
const diag_t select 
) [inline]

Mixed constructor: creates a diagonal matrix with any dimentions from a value or from a sequence.

Parameters:
rows_a number of rows
cols_a number of columns
x Meaning of this parameter depends on a structure of X.

Definition at line 530 of file matrix.hpp.

template<typename T, bool REFCNT>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rowscols_a,
const eye_t select 
) [inline]

Creates a square identity matrix.

Parameters:
rowscols_a size of a matrix
select helper argument for choosing this constructor, use eye

Definition at line 545 of file matrix.hpp.

template<typename T, bool REFCNT>
Arageli::matrix< T, REFCNT >::matrix ( size_type  rows_a,
size_type  cols_a,
const eye_t select 
) [inline]

Creates an identity matrix with any dimensions.

Parameters:
rowscols_a size of a matrix
select helper argument for choosing this constructor, use eye

Definition at line 554 of file matrix.hpp.


Member Function Documentation

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::add_cols ( size_type  dstpos,
size_type  srcpos 
)

Performs col[dstpos] += col[srcpos].

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::add_matrix ( const T1 &  x  )  [inline]

Definition at line 2109 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::add_rows ( size_type  dstpos,
size_type  srcpos 
)

Performs row[dstpos] += row[srcpos].

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::add_scalar ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, typename V, typename T2>
void Arageli::matrix< T, REFCNT >::addmult_cols ( size_type  dstpos,
const T1 &  x,
const V &  srcvec,
const T2 &  y 
)

Performs col[dstpos] = x*col[dstpos] + y*srcvec.

template<typename T, bool REFCNT>
template<typename T1, typename T2>
void Arageli::matrix< T, REFCNT >::addmult_cols ( size_type  dstpos,
const T1 &  x,
int  srcpos,
const T2 &  y 
) [inline]

Performs col[dstpos] = x*col[dstpos] + y*col[srcpos].

Definition at line 2537 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1, typename T2>
void Arageli::matrix< T, REFCNT >::addmult_cols ( size_type  dstpos,
const T1 &  x,
size_type  srcpos,
const T2 &  y 
)

Performs col[dstpos] = x*col[dstpos] + y*col[srcpos].

template<typename T, bool REFCNT>
template<typename T2>
void Arageli::matrix< T, REFCNT >::addmult_cols ( size_type  dstpos,
size_type  srcpos,
const T2 &  y 
)

Performs col[dstpos] += y*col[srcpos].

template<typename T, bool REFCNT>
template<typename T1, typename V, typename T2>
void Arageli::matrix< T, REFCNT >::addmult_rows ( size_type  dstpos,
const T1 &  x,
const V &  srcvec,
const T2 &  y 
)

Performs row[dstpos] = x*row[dstpos] + y*srcvec.

template<typename T, bool REFCNT>
template<typename T1, typename T2>
void Arageli::matrix< T, REFCNT >::addmult_rows ( size_type  dstpos,
const T1 &  x,
int  srcpos,
const T2 &  y 
) [inline]

Performs row[dstpos] = x*row[dstpos] + y*row[srcpos].

Definition at line 2373 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1, typename T2>
void Arageli::matrix< T, REFCNT >::addmult_rows ( size_type  dstpos,
const T1 &  x,
size_type  srcpos,
const T2 &  y 
)

Performs row[dstpos] = x*row[dstpos] + y*row[srcpos].

template<typename T, bool REFCNT>
template<typename T2>
void Arageli::matrix< T, REFCNT >::addmult_rows ( size_type  dstpos,
size_type  srcpos,
const T2 &  y 
)

Performs row[dstpos] += y*row[srcpos].

template<typename T, bool REFCNT>
template<typename X>
void Arageli::matrix< T, REFCNT >::assign ( size_type  rows_a,
size_type  cols_a,
const X &  x 
) [inline]

Mixed constructor: creates matrix with any dimentions from a value or from a sequence.

Parameters:
rows_a number of rows
cols_a number of columns
x Meaning of this parameter depends on a structure of In_or_T1. If X is conversible to T then x is an initial value for each element of the matrix; otherwise x is an iterator to begin of the sequence, and elements of matrix will be rowwise constructed from this sequence.

Definition at line 1145 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename X>
void Arageli::matrix< T, REFCNT >::assign ( size_type  rowscols_a,
const X &  x 
) [inline]

Mixed constructor: creates square matrix from a sequence or just null matrix with any dimensions.

Creates matrix with any dimensions, each item is equal to factory<T>::null().

Parameters:
rows_a number of rows

Definition at line 1011 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename X>
void Arageli::matrix< T, REFCNT >::assign ( const X &  x  )  [inline]

Mixed constructor: creates from a string, by a size, from another vector or matrix.

Definition at line 947 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::assign (  )  [inline]

Creates a matrix with zero dimensions.

Definition at line 916 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename V>
void Arageli::matrix< T, REFCNT >::assign_col ( size_type  j,
const V &  v 
) [inline]

Definition at line 2606 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Seq>
void Arageli::matrix< T, REFCNT >::assign_colwise ( size_type  rows_a,
size_type  cols_a,
const Seq &  seq 
)

Creates a matrix from a sequence with column-wise filling.

template<typename T, bool REFCNT>
template<typename X>
void Arageli::matrix< T, REFCNT >::assign_colwise ( size_type  rowcols_a,
const X &  x 
)

template<typename T, bool REFCNT>
template<typename Vec>
void Arageli::matrix< T, REFCNT >::assign_colwise ( const Vec &  vec  ) 

Creates a column-matrix copied from a vector-like structure.

template<typename T, bool REFCNT>
template<typename Seq>
void Arageli::matrix< T, REFCNT >::assign_colwise_fromseq ( size_type  rowcols_a,
const Seq &  seq 
)

Creates a square matrix from a sequence with column-wise filling.

template<typename T, bool REFCNT>
template<typename Vec>
void Arageli::matrix< T, REFCNT >::assign_colwise_fromvec ( size_type  cols_a,
const Vec &  vec 
)

Creates a matrix each column copied from a vector.

template<typename T, bool REFCNT>
template<typename X>
void Arageli::matrix< T, REFCNT >::assign_diag ( size_type  rows_a,
size_type  cols_a,
const X &  x 
) [inline]

Mixed constructor: creates a diagonal matrix with any dimentions from a value or from a sequence.

Parameters:
rows_a number of rows
cols_a number of columns
x Meaning of this parameter depends on a structure of X.

Definition at line 864 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename X>
void Arageli::matrix< T, REFCNT >::assign_diag ( size_type  rowscols_a,
const X &  x 
) [inline]

Mixed constructor: creates a square diagonal matrix from a value, from a sequence or from a vector.

Definition at line 826 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
void Arageli::matrix< T, REFCNT >::assign_diag ( const Vec &  vec  )  [inline]

Creates a square diagonal matrix from a vector.

Parameters:
rowscols_a size of a matrix
seq sequence of init values

Definition at line 796 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Seq>
void Arageli::matrix< T, REFCNT >::assign_diag_fromseq ( size_type  rows_a,
size_type  cols_a,
Seq  seq 
)

Creates a diagonal with any dimensions matrix from a sequence.

Parameters:
rows_a number of rows
cols_a number of columns
seq sequence of init values

template<typename T, bool REFCNT>
template<typename Seq>
void Arageli::matrix< T, REFCNT >::assign_diag_fromseq ( size_type  rowscols_a,
const Seq &  seq 
) [inline]

Creates a square diagonal matrix from a sequence.

Parameters:
rowscols_a size of a matrix
seq sequence of init values

Definition at line 812 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Val>
void Arageli::matrix< T, REFCNT >::assign_diag_fromval ( size_type  rows_a,
size_type  cols_a,
const Val &  val 
)

Creates a diagonal matrix with any dimensions with a particular value on the diagonal.

Parameters:
rows_a number of rows
cols_a number of columns
val value on the diagonal

template<typename T, bool REFCNT>
template<typename Val>
void Arageli::matrix< T, REFCNT >::assign_diag_fromval ( size_type  rowscols_a,
const Val &  val 
) [inline]

Creates a square diagonal matrix with a particular value on the diagonal.

Parameters:
rowscols_a size of a matrix
val value on the diagonal

Definition at line 804 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
void Arageli::matrix< T, REFCNT >::assign_diag_fromvec ( size_type  rows_a,
size_type  cols_a,
const Vec &  vec 
) [inline]

Creates a diagonal with any dimensions matrix from a sequence.

Parameters:
rows_a number of rows
cols_a number of columns
vec sequence of init values

Definition at line 854 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
void Arageli::matrix< T, REFCNT >::assign_diag_fromvec ( size_type  rowscols_a,
const Vec &  vec 
) [inline]

Creates a square diagonal matrix from a vector.

Parameters:
rowscols_a size of a matrix
seq sequence of init values

Definition at line 820 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::assign_eye ( size_type  rows_a,
size_type  cols_a 
) [inline]

Creates an identity matrix with any dimensions.

Parameters:
rowscols_a size of a matrix
select helper argument for choosing this constructor, use eye

Definition at line 901 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::assign_eye ( size_type  rowscols_a  )  [inline]

Creates a square identity matrix.

Parameters:
rowscols_a size of a matrix
select helper argument for choosing this constructor, use eye

Definition at line 893 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Mat>
void Arageli::matrix< T, REFCNT >::assign_frommat ( const Mat &  mat  )  [inline]

Creates a matrix as a copy of another matrix-like structure.

Definition at line 701 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Seq>
void Arageli::matrix< T, REFCNT >::assign_fromseq ( size_type  rows_a,
size_type  cols_a,
Seq  seq 
)

Creates matrix with any dimentions from sequence.

Parameters:
rows_a number of rows
cols_a number of columns
in an iterator to begin of the sequence, and elements of matrix will be rowwise constructed from this sequence

template<typename T, bool REFCNT>
template<typename Seq>
void Arageli::matrix< T, REFCNT >::assign_fromseq ( size_type  rowscols_a,
const Seq &  seq 
) [inline]

Creates square matrix from a sequence.

Parameters:
rowscols_a size of a matrix, it is number of rows and number of columns
seq an iterator to begin of the sequence, and elements of matrix will be rowwise constructed from this sequence.

Definition at line 723 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::assign_fromsize ( size_type  rows_a,
size_type  cols_a 
) [inline]

Creates matrix with any dimensions, each item is equal to factory<T>::null().

Parameters:
rows_a number of rows
cols_a number of columns

Definition at line 730 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::assign_fromsize ( std::size_t  size_a  )  [inline]

Creates square matrix sized by size_a by size_a with values factory<T>::null().

Parameters:
rowscols_a size of a matrix, it is number of rows and number of columns

Definition at line 685 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::assign_fromstr ( const char *  s  ) 

Creates matrix from string noted by usual rules for matrices.

template<typename T, bool REFCNT>
template<typename Val>
void Arageli::matrix< T, REFCNT >::assign_fromval ( size_type  rows_a,
size_type  cols_a,
const Val &  val 
)

Creates matrix with any dimentions and with val as each element.

Parameters:
rows_a number of rows
cols_a number of columns
val an initial value for each element

template<typename T, bool REFCNT>
template<typename Val>
void Arageli::matrix< T, REFCNT >::assign_fromval ( size_type  rowscols_a,
const Val &  val 
) [inline]

Creates square matrix with val as each element.

Parameters:
rowscols_a size of a matrix, it is number of rows and number of columns
val an initial value for each element

Definition at line 713 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename Vec>
void Arageli::matrix< T, REFCNT >::assign_fromvec ( size_type  rows_a,
const Vec &  vec 
)

Creates matrix with each row copied from some vector.

template<typename T, bool REFCNT>
template<typename Vec>
void Arageli::matrix< T, REFCNT >::assign_fromvec ( const Vec &  vec  )  [inline]

Creates a row-matrix copied from a vector-like structure.

Definition at line 695 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename V>
void Arageli::matrix< T, REFCNT >::assign_row ( size_type  i,
const V &  v 
) [inline]

Definition at line 2448 of file matrix.hpp.

template<typename T, bool REFCNT>
reference Arageli::matrix< T, REFCNT >::at ( size_type  i,
size_type  j 
) [inline]

Accesses to matrix item by index (i, j). Non-constant form.

Accesses with validation of index (i, j). If index is invalid function throws 'out_of_range' exception.

Definition at line 1993 of file matrix.hpp.

template<typename T, bool REFCNT>
const_reference Arageli::matrix< T, REFCNT >::at ( size_type  i,
size_type  j 
) const [inline]

Accesses to matrix item by index (i, j). Constant form.

Accesses with validation of index (i, j). If index is invalid function throws 'out_of_range' exception.

Definition at line 1984 of file matrix.hpp.

template<typename T, bool REFCNT>
const_iterator Arageli::matrix< T, REFCNT >::begin (  )  const [inline]

Returns iterator on begin of items sequence. Constant form.

Definition at line 2286 of file matrix.hpp.

template<typename T, bool REFCNT>
iterator Arageli::matrix< T, REFCNT >::begin (  )  [inline]

Returns iterator on begin of items sequence. Non-constant form.

Calls unique().

Definition at line 2279 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::bitand_matrix ( const T1 &  x  )  [inline]

Definition at line 2114 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::bitand_scalar ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::bitor_matrix ( const T1 &  x  )  [inline]

Definition at line 2115 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::bitor_scalar ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::bitxor_matrix ( const T1 &  x  )  [inline]

Definition at line 2116 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::bitxor_scalar ( const T1 &  x  ) 

template<typename T, bool REFCNT>
size_type Arageli::matrix< T, REFCNT >::capacity (  )  const [inline]

Definition at line 2041 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename V>
V& Arageli::matrix< T, REFCNT >::copy_col ( size_type  i,
V &  res 
) const

Fills the argument of a copy of the specified col of the matrix.

Returns a reference to the second argument (the resulting vector).

template<typename T, bool REFCNT>
vector<T, true> Arageli::matrix< T, REFCNT >::copy_col ( size_type  i  )  const [inline]

Returns a copy of the specified col of the matrix.

Definition at line 2552 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename SV, typename M>
M& Arageli::matrix< T, REFCNT >::copy_cols ( const SV &  sv,
M &  res 
) const

template<typename T, bool REFCNT>
template<typename SV>
matrix<T, true> Arageli::matrix< T, REFCNT >::copy_cols ( const SV &  sv  )  const [inline]

Definition at line 2564 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename V>
V& Arageli::matrix< T, REFCNT >::copy_row ( size_type  i,
V &  res 
) const [inline]

Fills the argument of a copy of the specified row of the matrix.

Returns a reference to the second argument (the resulting vector).

Definition at line 2396 of file matrix.hpp.

template<typename T, bool REFCNT>
vector<T, true> Arageli::matrix< T, REFCNT >::copy_row ( size_type  i  )  const [inline]

Returns a copy of the specified row of the matrix.

Definition at line 2389 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename SV, typename M>
M& Arageli::matrix< T, REFCNT >::copy_rows ( const SV &  sv,
M &  res 
) const

template<typename T, bool REFCNT>
template<typename SV>
matrix<T, true> Arageli::matrix< T, REFCNT >::copy_rows ( const SV &  sv  )  const [inline]

Definition at line 2404 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename RS, typename CS, typename M>
M& Arageli::matrix< T, REFCNT >::copy_submatrix ( const RS &  rs,
const CS &  cs,
M &  res 
) const

template<typename T, bool REFCNT>
template<typename RS, typename CS>
matrix<T, true> Arageli::matrix< T, REFCNT >::copy_submatrix ( const RS &  rs,
const CS &  cs 
) const [inline]

Definition at line 2630 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
void Arageli::matrix< T, REFCNT >::div_col ( size_type  i,
const T1 &  x 
)

Divides col i by value x.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::div_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1>
void Arageli::matrix< T, REFCNT >::div_row ( size_type  i,
const T1 &  x 
)

Divides row i by value x.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::div_scalar ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::each_add ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2183 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::each_add_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::each_bitand ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2198 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::each_bitand_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::each_bitor ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2201 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::each_bitor_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::each_bitxor ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2204 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::each_bitxor_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::each_div ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2192 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::each_div_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::each_inverse (  ) 

Makes matrix with inversed elements.

Calls 'value_traitsinverse' for each item of the matrix. Returns reference to the matrix.

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::each_mod ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2195 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::each_mod_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::each_mul ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2189 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::each_mul_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::each_shl ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2207 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::each_shl_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::each_shr ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2210 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::each_shr_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::each_sub ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2186 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::each_sub_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
reference Arageli::matrix< T, REFCNT >::el ( size_type  i,
size_type  j 
) [inline]

Accesses to matrix item by index (i, j). Non-constant form.

Accesses without validation of index (i, j).

Definition at line 1964 of file matrix.hpp.

template<typename T, bool REFCNT>
const_reference Arageli::matrix< T, REFCNT >::el ( size_type  i,
size_type  j 
) const [inline]

Accesses to matrix item by index (i, j). Constant form.

Accesses without validation of index (i, j).

Definition at line 1956 of file matrix.hpp.

template<typename T, bool REFCNT>
const_iterator Arageli::matrix< T, REFCNT >::end (  )  const [inline]

Returns iterator on end of items sequence. Constant form.

Definition at line 2289 of file matrix.hpp.

template<typename T, bool REFCNT>
iterator Arageli::matrix< T, REFCNT >::end (  )  [inline]

Returns iterator on end of items sequence. Non-constant form.

Calls unique().

Definition at line 2283 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::erase_col ( size_type  pos  ) 

Erases pos-th col.

template<typename T, bool REFCNT>
template<typename SV>
void Arageli::matrix< T, REFCNT >::erase_cols ( const SV &  sv  ) 

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::erase_cols ( size_type  pos,
size_type  n 
)

Erases n cols from range [pos, pos + n).

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::erase_row ( size_type  pos  ) 

Erases pos-th row.

template<typename T, bool REFCNT>
template<typename SV>
void Arageli::matrix< T, REFCNT >::erase_rows ( const SV &  sv  ) 

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::erase_rows ( size_type  pos,
size_type  n 
)

Erases n rows from range [pos, pos + n).

template<typename T, bool REFCNT>
template<typename RS, typename CS>
void Arageli::matrix< T, REFCNT >::erase_submatrix ( const RS &  rs,
const CS &  cs 
)

template<typename T, bool REFCNT>
template<typename In>
void Arageli::matrix< T, REFCNT >::insert_col ( size_type  pos,
In  first 
)

Inserts new col filled by values from range [first, first + ncols()) at posititon pos.

All lower cols will shift down.

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
void Arageli::matrix< T, REFCNT >::insert_col ( size_type  pos,
const vector< T1, REFCNT1 > &  vals 
)

Inserts new col filled by values from vals at positition pos.

All lower cols will shift down. Size of vals must be not less then ncols() value.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::insert_col ( size_type  pos,
const T &  val 
)

Inserts new col filled by val at postition pos.

All lower cols will shift down.

template<typename T, bool REFCNT>
template<typename In>
void Arageli::matrix< T, REFCNT >::insert_cols ( size_type  pos,
size_type  n,
In  first 
)

Inserts n new cols that each col is filled by values from range [first, first + ncols()) at posititon pos.

All lower cols will shift down.

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
void Arageli::matrix< T, REFCNT >::insert_cols ( size_type  pos,
size_type  n,
const vector< T1, REFCNT1 > &  vals 
)

Inserts n new cols that each col is filled by values from vals at positition pos.

All lower cols will shift down. Size of vals must be not less then ncols() value.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::insert_cols ( size_type  pos,
size_type  n,
const T &  val 
)

Inserts n new cols filled by val at position pos.

All lower cols will shift down.

template<typename T, bool REFCNT>
template<typename M>
void Arageli::matrix< T, REFCNT >::insert_matrix_bottom ( const M &  m  )  [inline]

Definition at line 2619 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename In>
void Arageli::matrix< T, REFCNT >::insert_row ( size_type  pos,
In  first 
)

Inserts new row filled by values from range [first, first + ncols()) at posititon pos.

All lower rows will shift down.

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
void Arageli::matrix< T, REFCNT >::insert_row ( size_type  pos,
const vector< T1, REFCNT1 > &  vals 
)

Inserts new row filled by values from vals at positition pos.

All lower rows will shift down. Size of vals must be not less then ncols() value.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::insert_row ( size_type  pos,
const T &  val 
)

Inserts new row filled by val at postition pos.

All lower rows will shift down.

template<typename T, bool REFCNT>
template<typename In>
void Arageli::matrix< T, REFCNT >::insert_rows ( size_type  pos,
size_type  n,
In  first 
)

Inserts n new rows that each row is filled by values from range [first, first + ncols()) at posititon pos.

All lower rows will shift down.

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
void Arageli::matrix< T, REFCNT >::insert_rows ( size_type  pos,
size_type  n,
const vector< T1, REFCNT1 > &  vals 
)

Inserts n new rows that each row is filled by values from vals at positition pos.

All lower rows will shift down. Size of vals must be not less then ncols() value.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::insert_rows ( size_type  pos,
size_type  n,
const T &  val 
)

Inserts n new rows filled by val at position pos.

All lower rows will shift down.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::inverse (  ) 

Makes inversed matrix.

Inverses this matrix. Requirement: the matrix is not singular, otherwise will be throwed matrix_is_singular exception. Returns reference to the matrix.

template<typename T, bool REFCNT>
bool Arageli::matrix< T, REFCNT >::is_empty (  )  const [inline]

Returns true if the matrix is empty.

Returns true if and only if matrix is not contained any items (i.e. if size() == 0). Note that nrows() or ncols() maybe returns nonzero value if is_empty() == true.

Definition at line 2047 of file matrix.hpp.

template<typename T, bool REFCNT>
bool Arageli::matrix< T, REFCNT >::is_null (  )  const

Returns true if the matrix is null-matrix.

Returns true if and only if for each item 'x' of the matrix expression value_traits::is_null(x) is true. If the matrix is empty then this function returns true.

template<typename T, bool REFCNT>
bool Arageli::matrix< T, REFCNT >::is_opposite_unit (  )  const

Returns true if the matrix is opposite unit-matrix.

Returns true if and only if for each item 'x' of the matrix expression value_traits::is_opposite_unit(x) is true. If the matrix is empty then this function returns true.

template<typename T, bool REFCNT>
bool Arageli::matrix< T, REFCNT >::is_square (  )  const [inline]

Returns true if the matrix is square matrix.

Returns true if nrows() == ncols(). Those dimentions maybe are zero.

Definition at line 2073 of file matrix.hpp.

template<typename T, bool REFCNT>
bool Arageli::matrix< T, REFCNT >::is_unit (  )  const

Returns true if the matrix is unit-matrix.

Returns true if and only if for each item 'x' of the matrix expression value_traits::is_unit(x) is true. If the matrix is empty then this function returns true.

template<typename T, bool REFCNT>
size_type Arageli::matrix< T, REFCNT >::length (  )  const [inline]

The maximum from nrows() and ncols().

Note, if we have a vector-like matrix (matrix-row or matrix-col), the returned value is the same as size() returns. Compare with vector::length().

Definition at line 2039 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
void Arageli::matrix< T, REFCNT >::mod_col ( size_type  i,
const T1 &  x 
)

Gives col i by modulo x.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::mod_matrix ( const T1 &  x  )  [inline]

Definition at line 2113 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
void Arageli::matrix< T, REFCNT >::mod_row ( size_type  i,
const T1 &  x 
)

Gives row i by modulo x.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::mod_scalar ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::mul_matrix ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::mul_scalar ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1>
void Arageli::matrix< T, REFCNT >::mult_col ( size_type  i,
const T1 &  x 
)

Multiplies col i by value x.

template<typename T, bool REFCNT>
template<typename T1>
void Arageli::matrix< T, REFCNT >::mult_row ( size_type  i,
const T1 &  x 
)

Multiplies row i by value x.

template<typename T, bool REFCNT>
size_type Arageli::matrix< T, REFCNT >::ncols (  )  const [inline]

Number of rows in the matrix.

Definition at line 2030 of file matrix.hpp.

template<typename T, bool REFCNT>
size_type Arageli::matrix< T, REFCNT >::nrows (  )  const [inline]

Number of rows in the matrix.

Definition at line 2027 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator &= ( const T &  x  )  [inline]

Definition at line 2157 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::operator &= ( const T1 &  x  )  [inline]

Definition at line 2144 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::operator *= ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Matrix multiplication.

Definition at line 2217 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator *= ( const T &  x  )  [inline]

Definition at line 2154 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::operator *= ( const T1 &  x  )  [inline]

Definition at line 2141 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator%= ( const T &  x  )  [inline]

Definition at line 2156 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::operator%= ( const T1 &  x  )  [inline]

Definition at line 2143 of file matrix.hpp.

template<typename T, bool REFCNT>
reference Arageli::matrix< T, REFCNT >::operator() ( size_type  i,
size_type  j 
) [inline]

Accesses to matrix item by index (i, j). Non-constant form.

The same as el method (non-const).

Definition at line 1978 of file matrix.hpp.

template<typename T, bool REFCNT>
const_reference Arageli::matrix< T, REFCNT >::operator() ( size_type  i,
size_type  j 
) const [inline]

Accesses to matrix item by index (i, j). Constant form.

The same as el method (const).

Definition at line 1973 of file matrix.hpp.

template<typename T, bool REFCNT>
const matrix& Arageli::matrix< T, REFCNT >::operator+ (  )  const [inline]

Returns reference to this matrix. For sameness only.

Definition at line 2237 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix Arageli::matrix< T, REFCNT >::operator++ ( int   )  [inline]

Definition at line 2245 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator++ (  )  [inline]

Definition at line 2239 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::operator+= ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2177 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator+= ( const T &  x  )  [inline]

Definition at line 2152 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::operator+= ( const T1 &  x  )  [inline]

Definition at line 2139 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix Arageli::matrix< T, REFCNT >::operator- (  )  const [inline]

Returns matrix with opposite values of items of this matrix.

The original matrix stills the same.

Definition at line 2230 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix Arageli::matrix< T, REFCNT >::operator-- ( int   )  [inline]

Definition at line 2253 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator-- (  )  [inline]

Definition at line 2247 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::operator-= ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Definition at line 2180 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator-= ( const T &  x  )  [inline]

Definition at line 2153 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::operator-= ( const T1 &  x  )  [inline]

Definition at line 2140 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
matrix& Arageli::matrix< T, REFCNT >::operator/= ( const matrix< T1, REFCNT1 > &  x  )  [inline]

Divides one square matrix by another square matrix.

This performs via inversing of the second matrix and multiplication. Requirement:

Definition at line 2226 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator/= ( const T &  x  )  [inline]

Definition at line 2155 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::operator/= ( const T1 &  x  )  [inline]

Definition at line 2142 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator<<= ( const T &  x  )  [inline]

Definition at line 2160 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::operator<<= ( const T1 &  x  )  [inline]

Definition at line 2147 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename X>
matrix& Arageli::matrix< T, REFCNT >::operator= ( const X &  x  )  [inline]

Creates an identity matrix with any dimensions.

Parameters:
rowscols_a size of a matrix

Definition at line 1318 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator>>= ( const T &  x  )  [inline]

Definition at line 2161 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::operator>>= ( const T1 &  x  )  [inline]

Definition at line 2148 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator^= ( const T &  x  )  [inline]

Definition at line 2159 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::operator^= ( const T1 &  x  )  [inline]

Definition at line 2146 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::operator|= ( const T &  x  )  [inline]

Definition at line 2158 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::operator|= ( const T1 &  x  )  [inline]

Definition at line 2145 of file matrix.hpp.

template<typename T, bool REFCNT>
matrix& Arageli::matrix< T, REFCNT >::opposite (  ) 

Makes opposite matrix.

Calls 'value_traitsopposite' for each item of the matrix. Returns reference to the matrix.

template<typename T, bool REFCNT>
bool Arageli::matrix< T, REFCNT >::pack (  )  [inline]

Definition at line 2011 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::resize ( size_type  rows_a,
size_type  cols_a 
) [inline]

Definition at line 2002 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::shl_matrix ( const T1 &  x  )  [inline]

Definition at line 2117 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::shl_scalar ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::shr_matrix ( const T1 &  x  )  [inline]

Definition at line 2118 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::shr_scalar ( const T1 &  x  ) 

template<typename T, bool REFCNT>
size_type Arageli::matrix< T, REFCNT >::size (  )  const [inline]

Number of items in the matrix.

Definition at line 2033 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::sub_cols ( size_type  dstpos,
size_type  srcpos 
)

Performs col[dstpos] -= col[srcpos].

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::sub_matrix ( const T1 &  x  )  [inline]

Definition at line 2110 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::sub_rows ( size_type  dstpos,
size_type  srcpos 
)

Performs row[dstpos] -= row[srcpos].

template<typename T, bool REFCNT>
template<typename T1>
matrix& Arageli::matrix< T, REFCNT >::sub_scalar ( const T1 &  x  ) 

template<typename T, bool REFCNT>
template<typename T1, bool REFCNT1>
void Arageli::matrix< T, REFCNT >::swap ( matrix< T1, REFCNT1 > &  x  )  [inline]

Swaps this matrix with x without actually coping (if possible).

Definition at line 2264 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::swap_cols ( size_type  xpos,
size_type  ypos 
)

Swaps two cols at xpos and ypos.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::swap_rows ( size_type  xpos,
size_type  ypos 
)

Swaps two rows at xpos and ypos.

template<typename T, bool REFCNT>
vector<T, true> Arageli::matrix< T, REFCNT >::take_col ( size_type  i  )  [inline]

Definition at line 2599 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename V>
V& Arageli::matrix< T, REFCNT >::take_col ( size_type  i,
V &  res 
) [inline]

Definition at line 2592 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename SV>
matrix<T, true> Arageli::matrix< T, REFCNT >::take_cols ( const SV &  sv  )  [inline]

Definition at line 2585 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename SV, typename M>
M& Arageli::matrix< T, REFCNT >::take_cols ( const SV &  sv,
M &  res 
) [inline]

Definition at line 2577 of file matrix.hpp.

template<typename T, bool REFCNT>
vector<T, true> Arageli::matrix< T, REFCNT >::take_row ( size_type  i  )  [inline]

Definition at line 2440 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename V>
V& Arageli::matrix< T, REFCNT >::take_row ( size_type  i,
V &  res 
) [inline]

Definition at line 2433 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename SV>
matrix<T, true> Arageli::matrix< T, REFCNT >::take_rows ( const SV &  sv  )  [inline]

Definition at line 2425 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename SV, typename M>
M& Arageli::matrix< T, REFCNT >::take_rows ( const SV &  sv,
M &  res 
) [inline]

Definition at line 2417 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename RS, typename CS>
matrix<T, true> Arageli::matrix< T, REFCNT >::take_submatrix ( const RS &  rs,
const CS &  cs 
) [inline]

Definition at line 2651 of file matrix.hpp.

template<typename T, bool REFCNT>
template<typename RS, typename CS, typename M>
M& Arageli::matrix< T, REFCNT >::take_submatrix ( const RS &  rs,
const CS &  cs,
M &  res 
) [inline]

Definition at line 2643 of file matrix.hpp.

template<typename T, bool REFCNT>
void Arageli::matrix< T, REFCNT >::transpose (  ) 

Transposes the matrix.

template<typename T, bool REFCNT>
bool Arageli::matrix< T, REFCNT >::unique (  )  [inline]

Makes an individual representation for this object.

If ‘refcounting’ is false then this is empty operation. Otherwise it makes so that this matrix descriptor gets individual copy of internal representation. Thus after this operation reference counter value is equal to one exactly. Returns true if the internal representation object is still the same and false if new copy has been made.

Definition at line 2666 of file matrix.hpp.

template<typename T, bool REFCNT>
bool Arageli::matrix< T, REFCNT >::unique_clear (  )  [inline]

Makes an individual or a clean individual representation for this object.

If ‘refcounting’ is false this is empty operation. Otherwise if reference counter value is one (only this descriptor refers to) then immediate returns true. Else create for this descriptor new clean internal representation object (empty matrix) and return false.

Definition at line 2674 of file matrix.hpp.


Member Data Documentation

template<typename T, bool REFCNT>
const bool Arageli::matrix< T, REFCNT >::refcounting = REFCNT [static]

Reference counting property.

If it is true then counting is enabled else it is disabled.

Definition at line 238 of file matrix.hpp.


The documentation for this class was generated from the following file:
Generated on Thu Aug 31 17:38:25 2006 for Arageli by  doxygen 1.4.7