GNU Octave 11.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
 
Loading...
Searching...
No Matches
dSparse.h
Go to the documentation of this file.
1////////////////////////////////////////////////////////////////////////
2//
3// Copyright (C) 1998-2026 The Octave Project Developers
4//
5// See the file COPYRIGHT.md in the top-level directory of this
6// distribution or <https://octave.org/copyright/>.
7//
8// This file is part of Octave.
9//
10// Octave is free software: you can redistribute it and/or modify it
11// under the terms of the GNU General Public License as published by
12// the Free Software Foundation, either version 3 of the License, or
13// (at your option) any later version.
14//
15// Octave is distributed in the hope that it will be useful, but
16// WITHOUT ANY WARRANTY; without even the implied warranty of
17// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18// GNU General Public License for more details.
19//
20// You should have received a copy of the GNU General Public License
21// along with Octave; see the file COPYING. If not, see
22// <https://www.gnu.org/licenses/>.
23//
24////////////////////////////////////////////////////////////////////////
25
26#if ! defined (octave_dSparse_h)
27#define octave_dSparse_h 1
28
29#include "octave-config.h"
30
31#include "mx-fwd.h"
32
33#include "CColVector.h"
34#include "CMatrix.h"
35#include "DET.h"
36#include "MSparse.h"
37#include "MatrixType.h"
38#include "Sparse-op-decls.h"
39#include "dColVector.h"
40#include "dMatrix.h"
41#include "dNDArray.h"
42
43class SparseMatrix : public MSparse<double>
44{
45public:
46
47 // Corresponding dense matrix type for this sparse matrix type.
49
50 typedef void (*solve_singularity_handler) (double rcond);
51
53
56
58 MSparse<double> (dv, nz) { }
59
60 explicit SparseMatrix (octave_idx_type r, octave_idx_type c, double val)
61 : MSparse<double> (r, c, val) { }
62
64
65 SparseMatrix (const SparseMatrix& a, const dim_vector& dv)
66 : MSparse<double> (a, dv) { }
67
69
71
72 explicit OCTAVE_API SparseMatrix (const SparseBoolMatrix& a);
73
74 explicit SparseMatrix (const Matrix& a) : MSparse<double> (a) { }
75
76 explicit SparseMatrix (const NDArray& a) : MSparse<double> (a) { }
77
78 SparseMatrix (const Array<double>& a, const octave::idx_vector& r,
79 const octave::idx_vector& c, octave_idx_type nr = -1,
80 octave_idx_type nc = -1, bool sum_terms = true,
81 octave_idx_type nzm = -1)
82 : MSparse<double> (a, r, c, nr, nc, sum_terms, nzm) { }
83
84 explicit OCTAVE_API SparseMatrix (const DiagMatrix& a);
85
86 explicit SparseMatrix (const PermMatrix& a) : MSparse<double> (a) { }
87
90
92 {
94 return *this;
95 }
96
97 ~SparseMatrix () = default;
98
99 OCTAVE_API bool operator == (const SparseMatrix& a) const;
100 OCTAVE_API bool operator != (const SparseMatrix& a) const;
101
102 OCTAVE_API bool issymmetric () const;
103
105 max (int dim = -1, bool nanflag = true, bool realabs = true) const;
107 max (Array<octave_idx_type>& index, int dim = -1,
108 bool nanflag = true, bool realabs = true) const;
110 min (int dim = -1, bool nanflag = true, bool realabs = true) const;
112 min (Array<octave_idx_type>& index, int dim = -1,
113 bool nanflag = true, bool realabs = true) const;
114
115 // destructive insert/delete/reorder operations
116
119
121 insert (const SparseMatrix& a, const Array<octave_idx_type>& indx);
122
127
130
132 {
134 }
135 SparseMatrix hermitian () const { return transpose (); }
136
137 // extract row or column i.
138
140
142
143private:
145 dinverse (MatrixType& mattype, octave_idx_type& info, double& rcond,
146 const bool force = false, const bool calccond = true) const;
147
149 tinverse (MatrixType& mattype, octave_idx_type& info, double& rcond,
150 const bool force = false, const bool calccond = true) const;
151
152public:
154 OCTAVE_API SparseMatrix inverse (MatrixType& mattype) const;
156 inverse (MatrixType& mattype, octave_idx_type& info) const;
158 inverse (MatrixType& mattype, octave_idx_type& info, double& rcond,
159 bool force = false, bool calc_cond = true) const;
160
161 OCTAVE_API DET determinant () const;
163 OCTAVE_API DET determinant (octave_idx_type& info, double& rcond,
164 bool calc_cond = true) const;
165
166private:
167 // Diagonal matrix solvers
169 dsolve (MatrixType& typ, const Matrix& b, octave_idx_type& info,
170 double& rcond, solve_singularity_handler sing_handler,
171 bool calc_cond = false) const;
172
174 dsolve (MatrixType& typ, const ComplexMatrix& b, octave_idx_type& info,
175 double& rcond, solve_singularity_handler sing_handler,
176 bool calc_cond = false) const;
177
179 dsolve (MatrixType& typ, const SparseMatrix& b, octave_idx_type& info,
180 double& rcond, solve_singularity_handler sing_handler,
181 bool calc_cond = false) const;
182
184 dsolve (MatrixType& typ, const SparseComplexMatrix& b, octave_idx_type& info,
185 double& rcond, solve_singularity_handler sing_handler,
186 bool calc_cond = false) const;
187
188 // Upper triangular matrix solvers
190 utsolve (MatrixType& typ, const Matrix& b, octave_idx_type& info,
191 double& rcond, solve_singularity_handler sing_handler,
192 bool calc_cond = false) const;
193
195 utsolve (MatrixType& typ, const ComplexMatrix& b, octave_idx_type& info,
196 double& rcond, solve_singularity_handler sing_handler,
197 bool calc_cond = false) const;
198
200 utsolve (MatrixType& typ, const SparseMatrix& b, octave_idx_type& info,
201 double& rcond, solve_singularity_handler sing_handler,
202 bool calc_cond = false) const;
203
205 utsolve (MatrixType& typ, const SparseComplexMatrix& b, octave_idx_type& info,
206 double& rcond, solve_singularity_handler sing_handler,
207 bool calc_cond = false) const;
208
209 // Lower triangular matrix solvers
211 ltsolve (MatrixType& typ, const Matrix& b, octave_idx_type& info,
212 double& rcond, solve_singularity_handler sing_handler,
213 bool calc_cond = false) const;
214
216 ltsolve (MatrixType& typ, const ComplexMatrix& b, octave_idx_type& info,
217 double& rcond, solve_singularity_handler sing_handler,
218 bool calc_cond = false) const;
219
221 ltsolve (MatrixType& typ, const SparseMatrix& b, octave_idx_type& info,
222 double& rcond, solve_singularity_handler sing_handler,
223 bool calc_cond = false) const;
224
226 ltsolve (MatrixType& typ, const SparseComplexMatrix& b, octave_idx_type& info,
227 double& rcond, solve_singularity_handler sing_handler,
228 bool calc_cond = false) const;
229
230 // Tridiagonal matrix solvers
232 trisolve (MatrixType& typ, const Matrix& b, octave_idx_type& info,
233 double& rcond, solve_singularity_handler sing_handler,
234 bool calc_cond = false) const;
235
237 trisolve (MatrixType& typ, const ComplexMatrix& b, octave_idx_type& info,
238 double& rcond, solve_singularity_handler sing_handler,
239 bool calc_cond = false) const;
240
242 trisolve (MatrixType& typ, const SparseMatrix& b, octave_idx_type& info,
243 double& rcond, solve_singularity_handler sing_handler,
244 bool calc_cond = false) const;
245
247 trisolve (MatrixType& typ, const SparseComplexMatrix& b, octave_idx_type& info,
248 double& rcond, solve_singularity_handler sing_handler,
249 bool calc_cond = false) const;
250
251 // Banded matrix solvers (umfpack/cholesky)
253 bsolve (MatrixType& typ, const Matrix& b, octave_idx_type& info,
254 double& rcond, solve_singularity_handler sing_handler,
255 bool calc_cond = false) const;
256
258 bsolve (MatrixType& typ, const ComplexMatrix& b, octave_idx_type& info,
259 double& rcond, solve_singularity_handler sing_handler,
260 bool calc_cond = false) const;
261
263 bsolve (MatrixType& typ, const SparseMatrix& b, octave_idx_type& info,
264 double& rcond, solve_singularity_handler sing_handler,
265 bool calc_cond = false) const;
266
268 bsolve (MatrixType& typ, const SparseComplexMatrix& b, octave_idx_type& info,
269 double& rcond, solve_singularity_handler sing_handler,
270 bool calc_cond = false) const;
271
272 // Full matrix solvers (umfpack/cholesky)
273 OCTAVE_API void *
274 factorize (octave_idx_type& err, double& rcond, Matrix& Control,
275 Matrix& Info, solve_singularity_handler sing_handler,
276 bool calc_cond = false) const;
277
279 fsolve (MatrixType& typ, const Matrix& b, octave_idx_type& info,
280 double& rcond, solve_singularity_handler sing_handler,
281 bool calc_cond = false) const;
282
284 fsolve (MatrixType& typ, const ComplexMatrix& b, octave_idx_type& info,
285 double& rcond, solve_singularity_handler sing_handler,
286 bool calc_cond = false) const;
287
289 fsolve (MatrixType& typ, const SparseMatrix& b, octave_idx_type& info,
290 double& rcond, solve_singularity_handler sing_handler,
291 bool calc_cond = false) const;
292
294 fsolve (MatrixType& typ, const SparseComplexMatrix& b, octave_idx_type& info,
295 double& rcond, solve_singularity_handler sing_handler,
296 bool calc_cond = false) const;
297
298public:
299 // Generic interface to solver with no probing of type
300 OCTAVE_API Matrix solve (MatrixType& typ, const Matrix& b) const;
302 solve (MatrixType& typ, const Matrix& b, octave_idx_type& info) const;
304 solve (MatrixType& typ, const Matrix& b, octave_idx_type& info,
305 double& rcond) const;
307 solve (MatrixType& typ, const Matrix& b, octave_idx_type& info,
308 double& rcond, solve_singularity_handler sing_handler,
309 bool singular_fallback = true) const;
310
312 solve (MatrixType& typ, const ComplexMatrix& b) const;
314 solve (MatrixType& typ, const ComplexMatrix& b, octave_idx_type& info) const;
316 solve (MatrixType& typ, const ComplexMatrix& b, octave_idx_type& info,
317 double& rcond) const;
319 solve (MatrixType& typ, const ComplexMatrix& b, octave_idx_type& info,
320 double& rcond, solve_singularity_handler sing_handler,
321 bool singular_fallback = true) const;
322
323 OCTAVE_API SparseMatrix solve (MatrixType& typ, const SparseMatrix& b) const;
325 solve (MatrixType& typ, const SparseMatrix& b, octave_idx_type& info) const;
327 solve (MatrixType& typ, const SparseMatrix& b, octave_idx_type& info,
328 double& rcond) const;
330 solve (MatrixType& typ, const SparseMatrix& b, octave_idx_type& info,
331 double& rcond, solve_singularity_handler sing_handler,
332 bool singular_fallback = true) const;
333
335 solve (MatrixType& typ, const SparseComplexMatrix& b) const;
337 solve (MatrixType& typ, const SparseComplexMatrix& b,
338 octave_idx_type& info) const;
340 solve (MatrixType& typ, const SparseComplexMatrix& b,
341 octave_idx_type& info, double& rcond) const;
343 solve (MatrixType& typ, const SparseComplexMatrix& b,
344 octave_idx_type& info, double& rcond,
345 solve_singularity_handler sing_handler,
346 bool singular_fallabck = true) const;
347
348 OCTAVE_API ColumnVector solve (MatrixType& typ, const ColumnVector& b) const;
350 solve (MatrixType& typ, const ColumnVector& b, octave_idx_type& info) const;
352 solve (MatrixType& typ, const ColumnVector& b, octave_idx_type& info,
353 double& rcond) const;
355 solve (MatrixType& typ, const ColumnVector& b, octave_idx_type& info,
356 double& rcond, solve_singularity_handler sing_handler) const;
357
359 solve (MatrixType& typ, const ComplexColumnVector& b) const;
361 solve (MatrixType& typ, const ComplexColumnVector& b,
362 octave_idx_type& info) const;
364 solve (MatrixType& typ, const ComplexColumnVector& b,
365 octave_idx_type& info, double& rcond) const;
367 solve (MatrixType& typ, const ComplexColumnVector& b,
368 octave_idx_type& info, double& rcond,
369 solve_singularity_handler sing_handler) const;
370
371 // Generic interface to solver with probing of type
372 OCTAVE_API Matrix solve (const Matrix& b) const;
373 OCTAVE_API Matrix solve (const Matrix& b, octave_idx_type& info) const;
375 solve (const Matrix& b, octave_idx_type& info, double& rcond) const;
377 solve (const Matrix& b, octave_idx_type& info, double& rcond,
378 solve_singularity_handler sing_handler) const;
379
382 solve (const ComplexMatrix& b, octave_idx_type& info) const;
384 solve (const ComplexMatrix& b, octave_idx_type& info, double& rcond) const;
386 solve (const ComplexMatrix& b, octave_idx_type& info, double& rcond,
387 solve_singularity_handler sing_handler) const;
388
389 OCTAVE_API SparseMatrix solve (const SparseMatrix& b) const;
391 solve (const SparseMatrix& b, octave_idx_type& info) const;
393 solve (const SparseMatrix& b, octave_idx_type& info, double& rcond) const;
395 solve (const SparseMatrix& b, octave_idx_type& info, double& rcond,
396 solve_singularity_handler sing_handler) const;
397
400 solve (const SparseComplexMatrix& b, octave_idx_type& info) const;
403 double& rcond) const;
406 double& rcond, solve_singularity_handler sing_handler) const;
407
408 OCTAVE_API ColumnVector solve (const ColumnVector& b) const;
410 solve (const ColumnVector& b, octave_idx_type& info) const;
412 solve (const ColumnVector& b, octave_idx_type& info, double& rcond) const;
414 solve (const ColumnVector& b, octave_idx_type& info, double& rcond,
415 solve_singularity_handler sing_handler) const;
416
419 solve (const ComplexColumnVector& b, octave_idx_type& info) const;
422 double& rcond) const;
425 double& rcond, solve_singularity_handler sing_handler) const;
426
427 // other operations
428
429 OCTAVE_API bool any_element_is_negative (bool = false) const;
430 OCTAVE_API bool any_element_is_nan () const;
433 OCTAVE_API bool all_elements_are_zero () const;
435 OCTAVE_API bool all_integers (double& max_val, double& min_val) const;
436 OCTAVE_API bool too_large_for_float () const;
437
439
440 OCTAVE_API SparseBoolMatrix all (int dim = -1) const;
441 OCTAVE_API SparseBoolMatrix any (int dim = -1) const;
442
443 OCTAVE_API SparseMatrix cumprod (int dim = -1, bool nanflag = false) const;
444 OCTAVE_API SparseMatrix cumsum (int dim = -1, bool nanflag = false) const;
445 OCTAVE_API SparseMatrix prod (int dim = -1, bool nanflag = false) const;
446 OCTAVE_API SparseMatrix sum (int dim = -1, bool nanflag = false) const;
447 OCTAVE_API SparseMatrix xsum (int dim = -1, bool nanflag = false) const;
448 OCTAVE_API SparseMatrix sumsq (int dim = -1, bool nanflag = false) const;
449 OCTAVE_API SparseMatrix abs () const;
450
452
454
456
457 OCTAVE_API SparseMatrix reshape (const dim_vector& new_dims) const;
458
460 permute (const Array<octave_idx_type>& vec, bool inv = false) const;
461
463
464 // i/o
465
466 friend OCTAVE_API std::ostream& operator << (std::ostream& os,
467 const SparseMatrix& a);
468 friend OCTAVE_API std::istream& operator >> (std::istream& is,
469 SparseMatrix& a);
470
471};
472
473// Publish externally used friend functions.
474
477
478// Other operators.
479
481 const SparseMatrix& b);
482extern OCTAVE_API Matrix operator * (const Matrix& a,
483 const SparseMatrix& b);
484extern OCTAVE_API Matrix mul_trans (const Matrix& a,
485 const SparseMatrix& b);
487 const Matrix& b);
488extern OCTAVE_API Matrix trans_mul (const SparseMatrix& a,
489 const Matrix& b);
490
492 const SparseMatrix&);
494 const DiagMatrix&);
495
497 const SparseMatrix&);
499 const DiagMatrix&);
501 const SparseMatrix&);
503 const DiagMatrix&);
504
506 const SparseMatrix&);
508 const PermMatrix&);
509
510extern OCTAVE_API SparseMatrix min (double d, const SparseMatrix& m);
511extern OCTAVE_API SparseMatrix min (double d, const SparseMatrix& m,
512 const bool nanflag);
513extern OCTAVE_API SparseMatrix min (double d, const SparseMatrix& m,
514 const bool nanflag, const bool realabs);
515extern OCTAVE_API SparseMatrix min (const SparseMatrix& m, double d);
516extern OCTAVE_API SparseMatrix min (const SparseMatrix& m, double d,
517 const bool nanflag);
518extern OCTAVE_API SparseMatrix min (const SparseMatrix& m, double d,
519 const bool nanflag, const bool realabs);
520extern OCTAVE_API SparseMatrix min (const SparseMatrix& a,
521 const SparseMatrix& b);
522extern OCTAVE_API SparseMatrix min (const SparseMatrix& a,
523 const SparseMatrix& b, const bool nanflag);
524extern OCTAVE_API SparseMatrix min (const SparseMatrix& a,
525 const SparseMatrix& b,
526 const bool nanflag, const bool realabs);
527
528extern OCTAVE_API SparseMatrix max (double d, const SparseMatrix& m);
529extern OCTAVE_API SparseMatrix max (double d, const SparseMatrix& m,
530 const bool nanflag);
531extern OCTAVE_API SparseMatrix max (double d, const SparseMatrix& m,
532 const bool nanflag, const bool realabs);
533extern OCTAVE_API SparseMatrix max (const SparseMatrix& m, double d);
534extern OCTAVE_API SparseMatrix max (const SparseMatrix& m, double d,
535 const bool nanflag);
536extern OCTAVE_API SparseMatrix max (const SparseMatrix& m, double d,
537 const bool nanflag, const bool realabs);
538extern OCTAVE_API SparseMatrix max (const SparseMatrix& a,
539 const SparseMatrix& b);
540extern OCTAVE_API SparseMatrix max (const SparseMatrix& a,
541 const SparseMatrix& b, const bool nanflag);
542extern OCTAVE_API SparseMatrix max (const SparseMatrix& a,
543 const SparseMatrix& b,
544 const bool nanflag, const bool realabs);
545
548
551
554
556
557#endif
#define SPARSE_FORWARD_DEFS(B, R, F, T)
Definition MSparse.h:192
#define SPARSE_SMSM_CMP_OP_DECLS(M1, M2, API)
#define SPARSE_SMSM_BOOL_OP_DECLS(M1, M2, API)
#define SPARSE_SSM_CMP_OP_DECLS(S, M, API)
#define SPARSE_SMS_BOOL_OP_DECLS(M, S, API)
#define SPARSE_SSM_BOOL_OP_DECLS(S, M, API)
#define SPARSE_SMS_CMP_OP_DECLS(M, S, API)
N Dimensional Array with copy-on-write semantics.
Definition Array-base.h:130
MSparse< T > transpose() const
Definition MSparse.h:96
MSparse< T > & operator=(const MSparse< T > &a)
Definition MSparse.h:78
SparseMatrix & insert(const SparseMatrix &a, octave_idx_type r, octave_idx_type c)
Definition dSparse.cc:168
SparseMatrix squeeze() const
Definition dSparse.cc:7735
SparseMatrix min(int dim=-1, bool nanflag=true, bool realabs=true) const
Definition dSparse.cc:439
bool issymmetric() const
Definition dSparse.cc:128
bool any_element_not_one_or_zero() const
Definition dSparse.cc:7429
SparseMatrix reshape(const dim_vector &new_dims) const
Definition dSparse.cc:7741
SparseBoolMatrix any(int dim=-1) const
Definition dSparse.cc:7553
bool any_element_is_inf_or_nan() const
Definition dSparse.cc:7414
SparseMatrix cumprod(int dim=-1, bool nanflag=false) const
Definition dSparse.cc:7560
bool all_integers(double &max_val, double &min_val) const
Definition dSparse.cc:7476
bool any_element_is_nan() const
Definition dSparse.cc:7399
bool too_large_for_float() const
Definition dSparse.cc:7504
bool operator==(const SparseMatrix &a) const
Definition dSparse.cc:98
SparseMatrix max(int dim=-1, bool nanflag=true, bool realabs=true) const
Definition dSparse.cc:183
SparseMatrix transpose() const
Definition dSparse.h:131
SparseMatrix(const Sparse< double > &a)
Definition dSparse.h:70
DET determinant() const
Definition dSparse.cc:1227
SparseMatrix abs() const
Definition dSparse.cc:7681
SparseMatrix prod(int dim=-1, bool nanflag=false) const
Definition dSparse.cc:7588
SparseMatrix inverse() const
Definition dSparse.cc:818
bool operator!=(const SparseMatrix &a) const
Definition dSparse.cc:122
RowVector row(octave_idx_type i) const
Definition dSparse.cc:710
SparseMatrix sum(int dim=-1, bool nanflag=false) const
Definition dSparse.cc:7619
ComplexMatrix solve(const ComplexMatrix &b) const
friend SparseMatrix real(const SparseComplexMatrix &a)
Definition dSparse.cc:761
SparseMatrix diag(octave_idx_type k=0) const
Definition dSparse.cc:7694
SparseMatrix(const SparseMatrix &a, const dim_vector &dv)
Definition dSparse.h:65
bool all_elements_are_zero() const
Definition dSparse.cc:7444
~SparseMatrix()=default
SparseBoolMatrix all(int dim=-1) const
Definition dSparse.cc:7546
SparseMatrix xsum(int dim=-1, bool nanflag=false) const
Definition dSparse.cc:7645
SparseMatrix(const SparseMatrix &a)
Definition dSparse.h:63
SparseMatrix sumsq(int dim=-1, bool nanflag=false) const
Definition dSparse.cc:7653
SparseMatrix permute(const Array< octave_idx_type > &vec, bool inv=false) const
Definition dSparse.cc:7747
SparseMatrix(octave_idx_type r, octave_idx_type c)
Definition dSparse.h:54
ColumnVector column(octave_idx_type i) const
Definition dSparse.cc:729
SparseMatrix concat(const SparseMatrix &rb, const Array< octave_idx_type > &ra_idx)
Definition dSparse.cc:741
SparseMatrix(const MSparse< double > &a)
Definition dSparse.h:68
SparseMatrix cumsum(int dim=-1, bool nanflag=false) const
Definition dSparse.cc:7568
void(* solve_singularity_handler)(double rcond)
Definition dSparse.h:50
SparseMatrix ipermute(const Array< octave_idx_type > &vec) const
Definition dSparse.cc:7753
Matrix dense_matrix_type
Definition dSparse.h:48
SparseBoolMatrix operator!() const
Definition dSparse.cc:7510
SparseMatrix(const Array< double > &a, const octave::idx_vector &r, const octave::idx_vector &c, octave_idx_type nr=-1, octave_idx_type nc=-1, bool sum_terms=true, octave_idx_type nzm=-1)
Definition dSparse.h:78
SparseMatrix hermitian() const
Definition dSparse.h:135
SparseMatrix(octave_idx_type r, octave_idx_type c, octave_idx_type num_nz)
Definition dSparse.h:88
SparseMatrix(const NDArray &a)
Definition dSparse.h:76
bool all_elements_are_int_or_inf_or_nan() const
Definition dSparse.cc:7456
Matrix solve(MatrixType &typ, const Matrix &b) const
Definition dSparse.cc:6888
SparseMatrix(const PermMatrix &a)
Definition dSparse.h:86
SparseMatrix(const Matrix &a)
Definition dSparse.h:74
friend SparseMatrix imag(const SparseComplexMatrix &a)
Definition dSparse.cc:782
friend std::ostream & operator<<(std::ostream &os, const SparseMatrix &a)
Definition dSparse.cc:7706
SparseMatrix(const dim_vector &dv, octave_idx_type nz=0)
Definition dSparse.h:57
SparseMatrix & operator=(const SparseMatrix &a)
Definition dSparse.h:91
bool any_element_is_negative(bool=false) const
Definition dSparse.cc:7378
Matrix matrix_value() const
Definition dSparse.cc:7700
friend std::istream & operator>>(std::istream &is, SparseMatrix &a)
Definition dSparse.cc:7727
SparseMatrix(octave_idx_type r, octave_idx_type c, double val)
Definition dSparse.h:60
Sparse< T, Alloc > index(const octave::idx_vector &i, bool resize_ok=false) const
Definition Sparse.cc:1447
Definition DET.h:38
Vector representing the dimensions (size) of an Array.
Definition dim-vector.h:92
SparseMatrix operator+(const DiagMatrix &, const SparseMatrix &)
Definition dSparse.cc:7805
Matrix trans_mul(const SparseMatrix &a, const Matrix &b)
Definition dSparse.cc:7785
SparseMatrix operator*(const SparseMatrix &a, const SparseMatrix &b)
Definition dSparse.cc:7761
SparseMatrix real(const SparseComplexMatrix &a)
Definition dSparse.cc:761
SparseMatrix min(double d, const SparseMatrix &m)
Definition dSparse.cc:7849
SparseMatrix operator-(const DiagMatrix &, const SparseMatrix &)
Definition dSparse.cc:7811
SparseMatrix max(double d, const SparseMatrix &m)
Definition dSparse.cc:8072
Matrix mul_trans(const Matrix &a, const SparseMatrix &b)
Definition dSparse.cc:7773
SparseMatrix imag(const SparseComplexMatrix &a)
Definition dSparse.cc:782
#define OCTAVE_API
Definition main.in.cc:55
const octave_base_value const Array< octave_idx_type > & ra_idx
F77_RET_T const F77_DBLE const F77_DBLE F77_DBLE * d