pub struct Mat {
pub n: usize,
pub a: Vec<Fp>,
}Expand description
Dense square matrix over F_p.
Fields§
§n: usize§a: Vec<Fp>Implementations§
Source§impl Mat
impl Mat
pub fn zero(n: usize) -> Self
pub fn identity(n: usize) -> Self
pub fn get(&self, i: usize, j: usize) -> Fp
pub fn mul(&self, o: &Mat) -> Mat
pub fn add(&self, o: &Mat) -> Mat
pub fn scale(&self, s: Fp) -> Mat
pub fn kron(&self, o: &Mat) -> Mat
pub fn pow(&self, e: usize) -> Mat
Trait Implementations§
impl Eq for Mat
impl StructuralPartialEq for Mat
Auto Trait Implementations§
impl Forget for Mat
impl Freeze for Mat
impl Move for Mat
impl RefUnwindSafe for Mat
impl Send for Mat
impl Sync for Mat
impl Unpin for Mat
impl UnsafeUnpin for Mat
impl UnwindSafe for Mat
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more