1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
//! This library provides routines to compute low-rank approximations of matrices.
//!
//! - [Overview](#overview)
//! - [Random sampling of operators](random_sampling)
//! - [Examples](examples)
//! # Overview
//! Let $A\in\mathbb{C}^{m\times n}$ be a given matrix. A low-rank approximation is
//! a representation of the form
//! $$
//! A\approx UV^H
//! $$
//! with $U\in\mathbb{C}^{m\times k}$ and $V\in\mathbb{C}^{n\times k}$, where $k$ is
//! sufficiently small for the required application. A frequently used
//! representation is also
//! $$
//! A\approx \tilde{U}X\tilde{V}^H
//! $$
//! with a $k\times k$ matrix $X$.
//!
//! The basis of the library is a pivoted QR decomposition of $A$ of the form
//! $$
//! AP = QR
//! $$
//! with $P$ a permutation matrix, $Q\in\mathbb{C}^{m\times \ell}$ a matrix
//! with orthogonal columns of unit norm, $R\in\mathbb{C}^{\ell\times n}$
//! upper triangular, and $\ell=\min\\{m, n\\}$.
//!
//! In a pivoted QR decomposition the diagonal elements of $R$
//! are sorted in non-increasing order, that is $|r_{11}|\geq |r_{22}|\geq \dots$.
//! We can therefore compress $A$ by choosing an index $k$ and only keeping the first
//! $k$ columns of $Q$ and the first $k$ rows of $R$. The library allows to choose the
//! parameter $k$ directly or by a given tolerance $\tau$ such that
//! $\langle|\frac{r_{kk}}{r_{11}}\rangle|< \tau$.
//!
//! Alternatively, one can also low-rank compress by first computing the Singular Value
//! Decomposition. This is more accurate but also more costly.
//!
//! From the compressed QR decomposition we can compute a column pivoted interpolative
//! decomposition of the form
//! $$
//! A \approx CZ
//! $$
//! The matrix $C$ is defined as
//! $$
//! C = A[:, [i_1, i_2, \dots]],
//! $$
//! that is a selection of columns of $A$ with
//! indices $i_1, i_2, \dots$.
//!
//! The column pivoted interpolative decomposition has
//! the advantage that we are using columns of $A$ as low-rank basis, which in
//! applications often have physical meaning as opposed to the columns of $Q$.
//!
//! From the column pivoted interpolative decomposition we can also compute a two-sided
//! decomposition of the form
//! $$
//! A\approx C X R
//! $$
//! Here, $X$ is a $k\times k$ matrix, which is the submatrix of $A$ formed of the column indices
//! $i_1, i_2, \dots$ and row indices $j_1, j_2, \dots$.
//!
//! Similarly to a column interpolative decomposition, a corresponding row interpolative decomposition
//! is available that selects rows of $A$ for the low rank approximation.
//!
pub
pub use ;
pub use ;
pub use ;
pub use ;
pub use ;
pub use RandomMatrix;
pub use *;
pub use RelDiff;
pub use *;
pub use ;
pub use Result;