annotate liboctave/array/PermMatrix.h @ 19006:2e0613dadfee draft

All calls to "find" use the same generic implementation (bug #42408, 42421) * find.cc: Rewrite. Move generic "find" logic to find.h (Ffind) : Changed calls to find_nonzero_elem_idx to find_templated Added unit test for bug #42421 * Array.cc (and .h) (Array::find): Deleted function. Replaced with find::find(Array) from find.h * Array.h: Added typedef for array_iterator (in nz-iterators.h) as Array::iter_type * DiagArray2.h: Added typedef for diag_iterator (in nz-iterators.h) as DiagArray2::iter_type * PermMatrix.h: Added typedef for perm_iterator (in nz-iterators.h) as PermMatrix::iter_type Also added typedef for bool as PermMatrix::element_type (not octave_idx_type) Added an nnz() function (which is an alias for perm_length) and a perm_elem(i) function for retrieving the ith element of the permutation * Sparse.h: Added typedef for sparse_iterator (in nz-iterators.h) as Sparse::iter_type Added a short comment documenting the the argument to the numel function * idx-vector.cc (idx_vector::idx_mask_rep::as_array): Changed Array.find to find::find(Array) (in find.h) * (new file) find.h * (new file) interp-idx.h: Simple methods for converting between interpreter index type and internal octave_idx_type/row-col pair * (new file) min-with-nnz.h: Fast methods for taking an arbitrary matrix M and an octave_idx_type n and finding min(M.nnz(), n) * (new file) nz-iterators.h: Iterators for traversing (in column-major order) the nonzero elements of any array or matrix backwards or forwards * (new file) direction.h: Generic methods for simplifying code has to deal with a "backwards or forwards" template argument * build-sparse-tests.sh: Removed 5-return-value calls to "find" in unit-tests; Admittedly this commit breaks this "feature" which was undocumented and only partially supported to begin with (ie never worked for full matrices, permutation matrices, or diagonal matrices)
author David Spies <dnspies@gmail.com>
date Tue, 17 Jun 2014 16:41:11 -0600
parents aa9ca67f09fb
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
1 /*
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
2
17744
d63878346099 maint: Update copyright notices for release.
John W. Eaton <jwe@octave.org>
parents: 15271
diff changeset
3 Copyright (C) 2008-2013 Jaroslav Hajek
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
4
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
5 This file is part of Octave.
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
6
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
7 Octave is free software; you can redistribute it and/or modify it
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
8 under the terms of the GNU General Public License as published by the
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
9 Free Software Foundation; either version 3 of the License, or (at your
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
10 option) any later version.
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
11
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
12 Octave is distributed in the hope that it will be useful, but WITHOUT
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
15 for more details.
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
16
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
17 You should have received a copy of the GNU General Public License
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
18 along with Octave; see the file COPYING. If not, see
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
19 <http://www.gnu.org/licenses/>.
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
20
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
21 */
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
22
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
23 #if !defined (octave_PermMatrix_h)
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
24 #define octave_PermMatrix_h 1
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
25
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
26 #include "Array.h"
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
27 #include "mx-defs.h"
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
28
19006
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
29 //Forward declaration for perm_iterator,
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
30 //the nonzero-iterator type for PermMatrix (in nz_iterator.h)
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
31 class perm_iterator;
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
32
8524
937921654627 clean up Array and DiagArray2
Jaroslav Hajek <highegg@gmail.com>
parents: 8375
diff changeset
33 // Array<T> is inherited privately so that some methods, like index, don't
937921654627 clean up Array and DiagArray2
Jaroslav Hajek <highegg@gmail.com>
parents: 8375
diff changeset
34 // produce unexpected results.
8375
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
35
9237
3c1762c7e787 Add missing xxx_API decoration and remove misplaced ones
Michael Goffioul <michael.goffioul@gmail.com>
parents: 8958
diff changeset
36 class OCTAVE_API PermMatrix : protected Array<octave_idx_type>
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
37 {
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
38 public:
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
39
19006
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
40 typedef bool element_type;
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
41 typedef perm_iterator iter_type;
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
42
18849
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
43 PermMatrix (void) : Array<octave_idx_type> () { }
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
44
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
45 PermMatrix (octave_idx_type n);
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
46
18849
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
47 PermMatrix (const Array<octave_idx_type>& p) GCC_ATTR_DEPRECATED;
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
48
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
49 PermMatrix (const Array<octave_idx_type>& p, bool colp, bool check = true);
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
50
18849
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
51 PermMatrix (const PermMatrix& m) : Array<octave_idx_type> (m) { }
11586
12df7854fa7c strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents: 11523
diff changeset
52
18849
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
53 PermMatrix (const idx_vector& idx) GCC_ATTR_DEPRECATED;
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
54
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
55 PermMatrix (const idx_vector& idx, bool colp, octave_idx_type n = 0);
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
56
11586
12df7854fa7c strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents: 11523
diff changeset
57 octave_idx_type dim1 (void) const
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
58 { return Array<octave_idx_type>::length (); }
11586
12df7854fa7c strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents: 11523
diff changeset
59 octave_idx_type dim2 (void) const
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
60 { return Array<octave_idx_type>::length (); }
8375
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
61
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
62 octave_idx_type rows (void) const { return dim1 (); }
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
63 octave_idx_type cols (void) const { return dim2 (); }
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
64 octave_idx_type columns (void) const { return dim2 (); }
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
65
11586
12df7854fa7c strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents: 11523
diff changeset
66 octave_idx_type perm_length (void) const
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
67 { return Array<octave_idx_type>::length (); }
9698
7c6d5d8c8d37 fix diag*diag multiplication
Jaroslav Hajek <highegg@gmail.com>
parents: 9237
diff changeset
68 // FIXME: a dangerous ambiguity?
11586
12df7854fa7c strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents: 11523
diff changeset
69 octave_idx_type length (void) const
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
70 { return perm_length (); }
8375
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
71 octave_idx_type nelem (void) const { return dim1 () * dim2 (); }
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
72 octave_idx_type numel (void) const { return nelem (); }
19006
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
73 octave_idx_type nnz (void) const { return perm_length (); }
8375
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
74
11586
12df7854fa7c strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents: 11523
diff changeset
75 size_t byte_size (void) const
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
76 { return Array<octave_idx_type>::byte_size (); }
8375
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
77
8524
937921654627 clean up Array and DiagArray2
Jaroslav Hajek <highegg@gmail.com>
parents: 8375
diff changeset
78 dim_vector dims (void) const { return dim_vector (dim1 (), dim2 ()); }
8375
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
79
18849
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
80 const Array<octave_idx_type>& col_perm_vec (void) const
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
81 { return *this; }
8375
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
82
11586
12df7854fa7c strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents: 11523
diff changeset
83 octave_idx_type
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
84 elem (octave_idx_type i, octave_idx_type j) const
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
85 {
18849
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
86 return (Array<octave_idx_type>::elem (j) == i) ? 1 : 0;
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
87 }
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
88
11586
12df7854fa7c strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents: 11523
diff changeset
89 octave_idx_type
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
90 checkelem (octave_idx_type i, octave_idx_type j) const;
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
91
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
92 octave_idx_type
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
93 operator () (octave_idx_type i, octave_idx_type j) const
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
94 {
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
95 #if defined (BOUNDS_CHECKING)
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
96 return checkelem (i, j);
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
97 #else
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
98 return elem (i, j);
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
99 #endif
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
100 }
11586
12df7854fa7c strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents: 11523
diff changeset
101
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
102 // These are, in fact, super-fast.
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
103 PermMatrix transpose (void) const;
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
104 PermMatrix inverse (void) const;
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
105
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
106 // Determinant, i.e. the sign of permutation.
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
107 octave_idx_type determinant (void) const;
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
108
8958
6ccc12cc65ef implement raising a permutation matrix to integer power
Jaroslav Hajek <highegg@gmail.com>
parents: 8920
diff changeset
109 // Efficient integer power of a permutation.
6ccc12cc65ef implement raising a permutation matrix to integer power
Jaroslav Hajek <highegg@gmail.com>
parents: 8920
diff changeset
110 PermMatrix power (octave_idx_type n) const;
6ccc12cc65ef implement raising a permutation matrix to integer power
Jaroslav Hajek <highegg@gmail.com>
parents: 8920
diff changeset
111
18849
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
112 bool is_col_perm (void) const { return true; }
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
113 bool is_row_perm (void) const { return false; }
8375
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
114
19006
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
115 octave_idx_type perm_elem(octave_idx_type i) const
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
116 { return Array<octave_idx_type>::elem (i); }
2e0613dadfee All calls to "find" use the same generic implementation (bug #42408, 42421)
David Spies <dnspies@gmail.com>
parents: 18849
diff changeset
117
8375
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
118 void print_info (std::ostream& os, const std::string& prefix) const
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
119 { Array<octave_idx_type>::print_info (os, prefix); }
8375
e3c9102431a9 fix design problems of diag & perm matrix classes
Jaroslav Hajek <highegg@gmail.com>
parents: 8367
diff changeset
120
9708
6f3ffe11d926 implement luupdate
Jaroslav Hajek <highegg@gmail.com>
parents: 9698
diff changeset
121 static PermMatrix eye (octave_idx_type n);
6f3ffe11d926 implement luupdate
Jaroslav Hajek <highegg@gmail.com>
parents: 9698
diff changeset
122
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
123 private:
18849
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
124
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
125 PermMatrix pos_power (octave_idx_type m) const;
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
126
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
127 void setup (const Array<octave_idx_type>& p, bool colp, bool check);
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
128
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
129 void setup (const idx_vector& idx, bool colp, octave_idx_type n);
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
130 };
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
131
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
132 // Multiplying permutations together.
11586
12df7854fa7c strip trailing whitespace from source files
John W. Eaton <jwe@octave.org>
parents: 11523
diff changeset
133 PermMatrix
9237
3c1762c7e787 Add missing xxx_API decoration and remove misplaced ones
Michael Goffioul <michael.goffioul@gmail.com>
parents: 8958
diff changeset
134 OCTAVE_API
18849
aa9ca67f09fb make all permutation matrices column permutations (bug #42418)
David Spies <dnspies@gmail.com>
parents: 17769
diff changeset
135 operator * (const PermMatrix& a, const PermMatrix& b);
8367
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
136
445d27d79f4e support permutation matrix objects
Jaroslav Hajek <highegg@gmail.com>
parents:
diff changeset
137 #endif