26#if ! defined (octave_DiagArray2_h)
27#define octave_DiagArray2_h 1
29#include "octave-config.h"
49 :
Array<T> (), m_d1 (0), m_d2 (0) { }
63 :
Array<T> (a), m_d1 (a.m_d1), m_d2 (a.m_d2) { }
67 :
Array<T> (a.extract_diag ()), m_d1 (a.dim1 ()), m_d2 (a.dim2 ()) { }
128 {
return check_idx (r, c) ? elem (r, c) : T (0); }
171 void print_info (std::ostream& os,
const std::string& prefix)
const
charNDArray min(char d, const charNDArray &m)
N Dimensional Array with copy-on-write semantics.
T & xelem(octave_idx_type n)
Size of the specified dimension.
std::size_t byte_size() const
Size of the specified dimension.
Array< T, Alloc > transpose() const
Size of the specified dimension.
Array< T, Alloc > & operator=(const Array< T, Alloc > &a)
Array< T, Alloc > hermitian(T(*fcn)(const T &)=nullptr) const
Size of the specified dimension.
T & elem(octave_idx_type n)
Size of the specified dimension.
void resize(const dim_vector &dv, const T &rfv)
Size of the specified dimension.
octave_idx_type dim2() const
octave_idx_type dim1() const
const T * data() const
Size of the specified dimension.
void print_info(std::ostream &os, const std::string &prefix) const
Size of the specified dimension.
T * rwdata()
Size of the specified dimension.
T & checkelem(octave_idx_type n)
Size of the specified dimension.
T & operator()(octave_idx_type n)
Size of the specified dimension.
octave_idx_type numel() const
Number of elements in the array.
void print_info(std::ostream &os, const std::string &prefix) const
octave_idx_type nelem() const
octave_idx_type rows() const
T dgelem(octave_idx_type i) const
DiagArray2(octave_idx_type r, octave_idx_type c, const T &val)
void resize(octave_idx_type n, octave_idx_type m)
octave_idx_type length() const
T elem(octave_idx_type r, octave_idx_type c) const
T checkelem(octave_idx_type r, octave_idx_type c) const
octave_idx_type dim2() const
T xelem(octave_idx_type r, octave_idx_type c) const
DiagArray2(const DiagArray2< T > &a)
octave_idx_type columns() const
DiagArray2(const Array< T > &a)
octave_idx_type cols() const
octave_idx_type dim1() const
T & dgxelem(octave_idx_type i)
DiagArray2(octave_idx_type r, octave_idx_type c)
DiagArray2< T > build_diag_matrix() const
octave_idx_type diag_length() const
std::size_t byte_size() const
T & dgelem(octave_idx_type i)
DiagArray2(const DiagArray2< U > &a)
octave_idx_type numel() const
T dgxelem(octave_idx_type i) const
Vector representing the dimensions (size) of an Array.
T::size_type numel(const T &str)