hipparchus_seq/lib.rs
1//! ## Create Sequence
2//!
3//! Here's an example to create the arithmetic sequence via ``hipparchus``:
4//!
5//! ```rust
6//!
7//! use hipparchus_seq::Sequence;
8//!
9//! let v = Sequence::Arithmetic { init: 1, difference: 1 }.vec(5);
10//!
11//! ```
12//!
13//! Below is a full list of all sequences ``hipperchus`` has supported:
14//!
15//! | Sequence | Syntax | Feature |
16//! | :-- | :-- | :-- |
17//! | Arithmetic | { init:T, difference:T } | arithmetic sequence with init value and difference |
18//! | Geometric | { init:T, ratio:T } | geometric sequence with init value and ratio |
19//! | Natural | (bool) | natural sequence starting with 0/1 |
20//! | Odd | - | odd sequence starting with 1 |
21//! | Even | (bool) | even sequence starting with 0/1 |
22//! | Power | (T) | power sequence starting with 1 with radix |
23//! | Triangular | - | triangular sequence starting with 1 |
24//! | Square | - | square sequence starting with 1 |
25//! | Cubic | - | cubic sequence starting with 1 |
26//! | Harmonic | { init:T, difference:T } | harmonic sequence with init value and difference |
27//! | Fibonacci | - | fibonacci sequence starting with 0, 1 |
28//! | Lucas | - | lucas sequence starting with 2, 1 |
29//! | Padova | - | padova sequence |
30//! | Catalan | - | catalan sequence |
31//! | LookAndSay | (usize) | look and say sequence starting with a usize value |
32//!
33//! And hipparchus-mean support recursive, map and fold OPs to generate complicated or derived sequences.
34//! Please refer to codes written in unit tests of sequence module.
35//!
36
37// re-exports
38pub use self::sequence::*;
39
40// modules
41pub mod sequence;