rusty_compression/
examples.rs

1//! # Library examples
2//! 
3//! We provide some examples in the `examples` subdirectory. To run them
4//! use `cargo run --example <example_filename>`.
5//! 
6//! ### Computing a rank k interpolative decomposition of an $m\times n$ matrix.
7//!
8//! This example computes the rank $k$ two-sided interpolative decomposition of a 
9//! given matrix and prints the relative distance between the compressed
10//! interpolative decmposition and the original matrix. 
11//! The corresponding code is in the file `interpolative_decomposition.rs`.
12//! 
13//! ### Adaptive range sampling of a matrix.
14//! 
15//! This code adaptively samples the range of a matrix up to a given error tolerance
16//! and uses the range estimate to compute an approximate interpolative decomposition.
17//! It generates a residual curve comparing the probabilistic erro bound from the adaptive
18//! sampling and the exact relative error. The convergence curve is saved in the file
19//! `residuals.png`.