25 #if defined (HAVE_CONFIG_H)
65 if (beg < 0 || end >=
length () || end < beg)
66 (*current_liboctave_error_handler) (
"range error for fill");
78 if (a.
numel () != len)
91 if (a.
numel () != len)
104 if (beg < 0 || beg + a_len >=
length ())
105 (*current_liboctave_error_handler) (
"range error for fill");
117 if (beg < 0 || beg + a_len >=
length ())
118 (*current_liboctave_error_handler) (
"range error for fill");
171 (*current_liboctave_error_handler) (
"invalid row selection");
174 if (r <= c || (r > c && i < c))
175 retval.elem (i) =
elem (i, i);
184 (*current_liboctave_error_handler) (
"invalid row selection");
187 if (c ==
'f' || c ==
'F')
188 return row (static_cast<octave_idx_type>(0));
189 else if (c ==
'l' || c ==
'L')
201 (*current_liboctave_error_handler) (
"invalid column selection");
204 if (r >= c || (r < c && i < r))
205 retval.elem (i) =
elem (i, i);
214 (*current_liboctave_error_handler) (
"invalid column selection");
217 if (c ==
'f' || c ==
'F')
218 return column (static_cast<octave_idx_type>(0));
219 else if (c ==
'l' || c ==
'L')
239 (*current_liboctave_error_handler) (
"inverse requires square matrix");
249 retval.elem (
i,
i) = 1.0 /
elem (
i,
i);
267 if (val < tol || val == 0.0
f)
268 retval.
elem (
i,
i) = 0.0f;
312 (*current_liboctave_error_handler) (
"determinant requires square matrix");
325 float amx = av.
max ();
326 float amn = av.
min ();
327 return amx == 0 ? 0.0f : amn / amx;
340 os <<
" " << a.
elem (
i,
i);
FloatDiagMatrix & fill(float val)
float elem(octave_idx_type r, octave_idx_type c) const
FloatDiagMatrix operator*(const FloatDiagMatrix &a, const FloatDiagMatrix &b)
octave_idx_type numel(void) const
Number of elements in the array.
identity matrix If supplied two scalar respectively For allows like xample val
F77_RET_T F77_REAL &F77_RET_T F77_DBLE &F77_RET_T F77_REAL &F77_RET_T F77_DBLE &F77_RET_T F77_REAL &F77_RET_T F77_DBLE &F77_RET_T const F77_REAL const F77_REAL F77_REAL &F77_RET_T const F77_DBLE const F77_DBLE F77_DBLE &F77_RET_T F77_REAL &F77_RET_T F77_DBLE &F77_RET_T F77_DBLE &F77_RET_T F77_REAL &F77_RET_T F77_REAL &F77_RET_T F77_DBLE &F77_RET_T const F77_DBLE F77_DBLE &F77_RET_T const F77_REAL F77_REAL &F77_RET_T F77_REAL F77_REAL &F77_RET_T F77_DBLE F77_DBLE &F77_RET_T const F77_DBLE const F77_DBLE * f
OCTAVE_NORETURN liboctave_error_handler current_liboctave_error_handler
FloatDiagMatrix abs(void) const
octave_idx_type rows(void) const
const float * data(void) const
FloatDET determinant(void) const
T & elem(octave_idx_type n)
calling an anonymous function involves an overhead quite comparable to the overhead of an m file function Passing a handle to a built in function is because the interpreter is not involved in the internal loop For a
T dgelem(octave_idx_type i) const
Array< U > map(F fcn) const
Apply function fcn to each element of the Array.
FloatMatrix extract(octave_idx_type r1, octave_idx_type c1, octave_idx_type r2, octave_idx_type c2) const
void err_nonconformant(const char *op, octave_idx_type op1_len, octave_idx_type op2_len)
FloatDiagMatrix real(const FloatComplexDiagMatrix &a)
T & dgxelem(octave_idx_type i)
FloatColumnVector extract_diag(octave_idx_type k=0) const
the sparsity preserving column transformation such that that defines the pivoting threshold can be given in which case it defines the c
bool operator!=(const FloatDiagMatrix &a) const
FloatComplexColumnVector extract_diag(octave_idx_type k=0) const
With real return the complex result
FloatDiagMatrix inverse(void) const
FloatDiagMatrix pseudo_inverse(float tol=0.0f) const
octave_idx_type cols(void) const
=val(i)}if ode{val(i)}occurs in table i
OCTAVE_EXPORT octave_value_list return the value of the option it must match the dimension of the state and the relative tolerance must also be a vector of the same length tem it must match the dimension of the state and the absolute tolerance must also be a vector of the same length The local error test applied at each integration step is xample roup abs(local error in x(i))<
FloatColumnVector column(octave_idx_type i) const
octave_idx_type columns(void) const
bool operator==(const FloatDiagMatrix &a) const
bool mx_inline_equal(size_t n, const T1 *x, const T2 *y)
FloatDiagMatrix imag(const FloatComplexDiagMatrix &a)
FloatRowVector row(octave_idx_type i) const
octave_idx_type length(void) const
std::ostream & operator<<(std::ostream &os, const FloatDiagMatrix &a)