[][src]Trait mathru::algebra::linear::matrix::Transpose

pub trait Transpose {
    type Output;
    fn transpose(self) -> Self::Output;
}

Associated Types

type Output

Loading content...

Required methods

fn transpose(self) -> Self::Output

Loading content...

Implementors

impl<T> Transpose for Matrix<T> where
    T: Field + Scalar
[src]

type Output = Matrix<T>

fn transpose(self) -> Matrix<T>[src]

Function to transpose a matrix without allocating memory for the transposed matrix

catanzaro.name/papers/PPoPP-2014.pdf TODO

Example

use mathru::algebra::linear::Matrix;
use mathru::algebra::linear::matrix::Transpose;

let mut uut: Matrix<f64> = Matrix::new(4, 2, vec![1.0, 0.0, 3.0, 0.0, 1.0, -7.0, 0.5, 0.25]);
uut = uut.transpose();

let refer: Matrix<f64> = Matrix::new(2, 4, vec![1.0, 1.0, 0.0, -7.0, 3.0, 0.5, 0.0, 0.25]);
assert_eq!(refer, uut);
Loading content...