Function lair::matrix::circulant [−][src]
pub fn circulant<A>(a: &[A]) -> Array2<A> where
A: Copy,
Constructs a circulant matrix.
Examples
use lair::matrix::circulant; let a = vec![1., 2., 3.]; let c = circulant(&a); assert_eq!(c, ndarray::aview2(&[[1., 3., 2.], [2., 1., 3.], [3., 2., 1.]]));