Mercurial > hg > octave-lyh
comparison liboctave/CmplxQR.h @ 7553:56be6f31dd4e
implementation of QR factorization updating
author | Jaroslav Hajek <highegg@gmail.com> |
---|---|
date | Tue, 04 Mar 2008 21:47:11 -0500 |
parents | a1dbe9d80eee |
children | 40574114c514 |
comparison
equal
deleted
inserted
replaced
7552:6070c3bd69c4 | 7553:56be6f31dd4e |
---|---|
25 #define octave_ComplexQR_h 1 | 25 #define octave_ComplexQR_h 1 |
26 | 26 |
27 #include <iostream> | 27 #include <iostream> |
28 | 28 |
29 #include "CMatrix.h" | 29 #include "CMatrix.h" |
30 #include "CColVector.h" | |
31 #include "CRowVector.h" | |
30 #include "dbleQR.h" | 32 #include "dbleQR.h" |
33 | |
31 | 34 |
32 class | 35 class |
33 OCTAVE_API | 36 OCTAVE_API |
34 ComplexQR | 37 ComplexQR |
35 { | 38 { |
36 public: | 39 public: |
37 | 40 |
38 ComplexQR (void) : q (), r () { } | 41 ComplexQR (void) : q (), r () { } |
39 | 42 |
40 ComplexQR (const ComplexMatrix&, QR::type = QR::std); | 43 ComplexQR (const ComplexMatrix&, QR::type = QR::std); |
44 | |
45 ComplexQR (const ComplexMatrix& q, const ComplexMatrix& r); | |
41 | 46 |
42 ComplexQR (const ComplexQR& a) : q (a.q), r (a.r) { } | 47 ComplexQR (const ComplexQR& a) : q (a.q), r (a.r) { } |
43 | 48 |
44 ComplexQR& operator = (const ComplexQR& a) | 49 ComplexQR& operator = (const ComplexQR& a) |
45 { | 50 { |
57 | 62 |
58 ComplexMatrix Q (void) const { return q; } | 63 ComplexMatrix Q (void) const { return q; } |
59 | 64 |
60 ComplexMatrix R (void) const { return r; } | 65 ComplexMatrix R (void) const { return r; } |
61 | 66 |
67 void update (const ComplexMatrix& u, const ComplexMatrix& v); | |
68 | |
69 void insert_col (const ComplexMatrix& u, octave_idx_type j); | |
70 | |
71 void delete_col (octave_idx_type j); | |
72 | |
73 void insert_row (const ComplexMatrix& u, octave_idx_type j); | |
74 | |
75 void delete_row (octave_idx_type j); | |
76 | |
77 void economize(); | |
78 | |
62 friend std::ostream& operator << (std::ostream&, const ComplexQR&); | 79 friend std::ostream& operator << (std::ostream&, const ComplexQR&); |
63 | 80 |
64 protected: | 81 protected: |
65 | 82 |
66 ComplexMatrix q; | 83 ComplexMatrix q; |