pub struct ModpEquation {
pub coeffs: Vec<(usize, u64)>,
pub rhs: u64,
}Expand description
A congruence Σ (a·x) ≡ rhs (mod p). Coefficients and rhs are reduced mod p. p must be prime
(so every nonzero element is invertible, via Fermat).
Fields§
§coeffs: Vec<(usize, u64)>§rhs: u64Implementations§
Trait Implementations§
Source§impl Clone for ModpEquation
impl Clone for ModpEquation
Source§fn clone(&self) -> ModpEquation
fn clone(&self) -> ModpEquation
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ModpEquation
impl Debug for ModpEquation
Source§impl PartialEq for ModpEquation
impl PartialEq for ModpEquation
Source§fn eq(&self, other: &ModpEquation) -> bool
fn eq(&self, other: &ModpEquation) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for ModpEquation
impl StructuralPartialEq for ModpEquation
Auto Trait Implementations§
impl Freeze for ModpEquation
impl RefUnwindSafe for ModpEquation
impl Send for ModpEquation
impl Sync for ModpEquation
impl Unpin for ModpEquation
impl UnsafeUnpin for ModpEquation
impl UnwindSafe for ModpEquation
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