Crates.io | gramschmidt |
lib.rs | gramschmidt |
version | 0.6.0 |
source | src |
created_at | 2018-01-22 23:50:31.080695 |
updated_at | 2019-08-12 12:05:54.060712 |
description | Classical, Modified, Reorthogonalized Gram Schmidt Orthogonalization and QR decompostion |
homepage | |
repository | https://github.com/SuperFluffy/gramschmidt-rs |
max_upload_size | |
id | 47866 |
size | 45,046 |
Orthogonalization and QR decomposition of matrices in the Rust programming language and rust-ndarray
.
This crate provides the following methods:
cgs
,mgs
,cgs2
.// Import openblas_src or another blas source to have the linker find all symbols.
extern crate openblas_src;
use gramschmidt::{
GramSchmidt,
Reorthogonalized,
Result,
};
use ndarray::arr2;
fn main() -> Result<()> {
let small_matrix = arr2(
&[[2.0, 0.5, 0.0, 0.0],
[0.0, 0.3, 0.0, 0.0],
[0.0, 1.0, 0.7, 0.0],
[0.0, 0.0, 0.0, 3.0]]
);
let mut cgs2 = Reorthogonalized::from_matrix(&small_matrix)?;
cgs2.compute(&small_matrix)?;
assert!(small_matrix.all_close(&cgs2.q().dot(cgs2.r()), 1e-14));
Ok(())
}
0.6.0
: Fixed the dimensions of the triangular matrix R
:
0.5.0
: Refactored the library and updated for edition 2018
GramSchmidt
trait;cgs
, cgs2
, and mgs
.0.4.1
: Fixed doc tests and expanded + simplified tests.0.4.0
: Major rework of the library structure:
ClassicalGramSchmidt
, ModifiedGramSchmidt
, and
ReorthogonalizedGramSchmidt
(known as cgs
, mgs
, and cgs2
in the
literature, respectively);cgs
and cgs2
are implemented using blas
routines (major speedup!);0.3.1
: Update to blas 0.16
and do not specify a default backend (so that the user can set it).0.3.0
: Update to ndarray 0.10
, ndarray-parallel 0.5
0.2.1
: Added a parallelized algorithm using rayon
0.2.0
: Update to ndarray 0.9