26 #if !defined (octave_DiagArray2_h)
27 #define octave_DiagArray2_h 1
49 :
Array<T> (), d1 (0), d2 (0) { }
58 :
Array<T> (a.as_column ()), d1 (a.numel ()), d2 (a.numel ()) { }
63 :
Array<T> (a), d1 (a.d1), d2 (a.d2) { }
67 :
Array<T> (a.extract_diag ()), d1 (a.dim1 ()), d2 (a.dim2 ()) { }
129 return check_idx (r, c) ?
elem (r, c) : T (0);
134 #if defined (BOUNDS_CHECKING)
135 return checkelem (r, c);
144 return check_idx (r, c) ?
elem (r, c) : zero;
149 #if defined (BOUNDS_CHECKING)
150 return checkelem (r, c);
186 void print_info (std::ostream& os,
const std::string& prefix)
const