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
//! # mathru
//!
//! A crate that provides  mathematics functions implemented entirely in Rust.
//!
//!
//! ## Usage
//!
//! The library usage is described well in the API documentation - including example code.
//!
//!
//! Add this to your `Cargo.toml`:
//!
//! ```toml
//! [dependencies]
//! mathru = "0.1.4"
//! ```
//!
//! And then import the library using:
//! ```rust
//! extern crate mathru;
//! ```
//!
//! Then import the modules and it is ready to be used:
//!
//!``` rust
//! extern crate mathru;
//! use mathru::algebra::linear::{Matrix};
//! // Compute the LU decomposition of a 2x2 matrix
//! let a: Matrix<f64> = Matrix::new(2, 2, vec![1.0, -2.0, 3.0, -7.0]);
//! let l_ref: Matrix<f64> = Matrix::new(2, 2, vec![1.0, 0.0, 1.0 / 3.0, 1.0]);
//!
//! let (l, u, p): (Matrix<f64>, Matrix<f64>, Matrix<f64>) = a.dec_lu();
//!
//! assert_eq!(l_ref, l);
//!```

#[cfg(feature = "blaslapack")]
extern crate blas;
#[cfg(feature = "blaslapack")]
extern crate blas_src;
#[cfg(feature = "blaslapack")]
extern crate lapack;

//extern crate serde;

pub mod algebra;
pub mod elementary;
pub mod num;
pub mod special;
pub mod stats;
pub mod analysis;
//pub mod optim;