26 typedef typename T1::elem_type eT;
36 const eT* A_mem = A.
memptr();
43 for(
uword i=0; i<N; ++i)
45 out.
at(i,i) = A_mem[i];
54 const eT* tmp_mem = tmp.
memptr();
58 for(
uword i=0; i<N; ++i)
60 out.
at(i,i) = tmp_mem[i];
78 for(
uword i=0; i<N; ++i)
80 out.
at(i,i) = A.
at(i,i);
87 for(
uword i=0; i<N; ++i)
89 eT* colptr = out.
colptr(i);
arma_inline arma_warn_unused bool is_vec() const
returns true if the object can be interpreted as a column or row vector
arma_inline arma_warn_unused eT * memptr()
returns a pointer to array of eTs used by the matrix
A lightweight array for POD types. If the amount of memory requested is small, the stack is used...
const uword n_elem
number of elements in the matrix (read-only)
const uword n_rows
number of rows in the matrix (read-only)
arma_aligned const T1 & m
storage of reference to the operand (eg. a matrix)
arma_inline arma_warn_unused eT * colptr(const uword in_col)
returns a pointer to array of eTs for a specified column; no bounds check
static arma_hot void inplace_set(eT *dest, const eT val, const uword n_elem)
arma_inline arma_warn_unused eT & at(const uword i)
linear element accessor (treats the matrix as a vector); no bounds check.
arma_inline arma_warn_unused bool is_square() const
returns true if the object has the same number of non-zero rows and columnns
#define arma_extra_debug_sigprint
static void apply(Mat< typename T1::elem_type > &out, const Op< T1, op_diagmat > &X)
arma_inline eT * memptr()