Struct snarkvm_fields::fp6_3over2::Fp6 [−][src]
pub struct Fp6<P: Fp6Parameters> { pub c0: Fp2<P::Fp2Params>, pub c1: Fp2<P::Fp2Params>, pub c2: Fp2<P::Fp2Params>, // some fields omitted }
Expand description
An element of Fp6, represented by c0 + c1 * v + c2 * v^(2).
Fields
c0: Fp2<P::Fp2Params>
c1: Fp2<P::Fp2Params>
c2: Fp2<P::Fp2Params>
Implementations
impl<P: Fp6Parameters> Fp6<P>
[src]
impl<P: Fp6Parameters> Fp6<P>
[src]pub fn new(
c0: Fp2<P::Fp2Params>,
c1: Fp2<P::Fp2Params>,
c2: Fp2<P::Fp2Params>
) -> Self
[src]
c0: Fp2<P::Fp2Params>,
c1: Fp2<P::Fp2Params>,
c2: Fp2<P::Fp2Params>
) -> Self
pub fn mul_by_fp(&mut self, element: &<P::Fp2Params as Fp2Parameters>::Fp)
[src]
pub fn mul_by_fp2(&mut self, element: &Fp2<P::Fp2Params>)
[src]
pub fn mul_by_1(&mut self, c1: &Fp2<P::Fp2Params>)
[src]
pub fn mul_by_01(&mut self, c0: &Fp2<P::Fp2Params>, c1: &Fp2<P::Fp2Params>)
[src]
Trait Implementations
impl<'a, P: Fp6Parameters> Add<&'a Fp6<P>> for Fp6<P>
[src]
impl<'a, P: Fp6Parameters> Add<&'a Fp6<P>> for Fp6<P>
[src]impl<'a, P: Fp6Parameters> AddAssign<&'a Fp6<P>> for Fp6<P>
[src]
impl<'a, P: Fp6Parameters> AddAssign<&'a Fp6<P>> for Fp6<P>
[src]fn add_assign(&mut self, other: &Self)
[src]
fn add_assign(&mut self, other: &Self)
[src]Performs the +=
operation. Read more
impl<P: Fp6Parameters> CanonicalDeserialize for Fp6<P>
[src]
impl<P: Fp6Parameters> CanonicalDeserialize for Fp6<P>
[src]fn deserialize<R: Read>(reader: &mut R) -> Result<Self, SerializationError>
[src]
fn deserialize<R: Read>(reader: &mut R) -> Result<Self, SerializationError>
[src]Reads Self
from reader
.
fn deserialize_uncompressed<R>(
reader: &mut R
) -> Result<Self, SerializationError> where
R: Read,
[src]
fn deserialize_uncompressed<R>(
reader: &mut R
) -> Result<Self, SerializationError> where
R: Read,
[src]Reads Self
from reader
without compression.
impl<P: Fp6Parameters> CanonicalDeserializeWithFlags for Fp6<P>
[src]
impl<P: Fp6Parameters> CanonicalDeserializeWithFlags for Fp6<P>
[src]fn deserialize_with_flags<R: Read, F: Flags>(
reader: &mut R
) -> Result<(Self, F), SerializationError>
[src]
fn deserialize_with_flags<R: Read, F: Flags>(
reader: &mut R
) -> Result<(Self, F), SerializationError>
[src]Reads Self
and Flags
from reader
.
Returns empty flags by default. Read more
impl<P: Fp6Parameters> CanonicalSerialize for Fp6<P>
[src]
impl<P: Fp6Parameters> CanonicalSerialize for Fp6<P>
[src]fn serialize<W: Write>(&self, writer: &mut W) -> Result<(), SerializationError>
[src]
fn serialize<W: Write>(&self, writer: &mut W) -> Result<(), SerializationError>
[src]Serializes self
into writer
.
fn serialized_size(&self) -> usize
[src]
fn serialize_uncompressed<W>(
&self,
writer: &mut W
) -> Result<(), SerializationError> where
W: Write,
[src]
fn serialize_uncompressed<W>(
&self,
writer: &mut W
) -> Result<(), SerializationError> where
W: Write,
[src]Serializes self
into writer
without compression.
fn uncompressed_size(&self) -> usize
[src]
impl<P: Fp6Parameters> CanonicalSerializeWithFlags for Fp6<P>
[src]
impl<P: Fp6Parameters> CanonicalSerializeWithFlags for Fp6<P>
[src]fn serialize_with_flags<W: Write, F: Flags>(
&self,
writer: &mut W,
flags: F
) -> Result<(), SerializationError>
[src]
fn serialize_with_flags<W: Write, F: Flags>(
&self,
writer: &mut W,
flags: F
) -> Result<(), SerializationError>
[src]Serializes self
and flags
into writer
.
impl<P: Fp6Parameters> Clone for Fp6<P> where
P: Fp6Parameters,
[src]
impl<P: Fp6Parameters> Clone for Fp6<P> where
P: Fp6Parameters,
[src]impl<P: Fp6Parameters> ConstantSerializedSize for Fp6<P>
[src]
impl<P: Fp6Parameters> ConstantSerializedSize for Fp6<P>
[src]impl<P: Fp6Parameters> Debug for Fp6<P> where
P: Fp6Parameters,
[src]
impl<P: Fp6Parameters> Debug for Fp6<P> where
P: Fp6Parameters,
[src]impl<P: Fp6Parameters> Default for Fp6<P> where
P: Fp6Parameters,
[src]
impl<P: Fp6Parameters> Default for Fp6<P> where
P: Fp6Parameters,
[src]impl<'de, P: Fp6Parameters> Deserialize<'de> for Fp6<P>
[src]
impl<'de, P: Fp6Parameters> Deserialize<'de> for Fp6<P>
[src]fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]Deserialize this value from the given Serde deserializer. Read more
impl<P: Fp6Parameters> Display for Fp6<P>
[src]
impl<P: Fp6Parameters> Display for Fp6<P>
[src]impl<'a, P: Fp6Parameters> Div<&'a Fp6<P>> for Fp6<P>
[src]
impl<'a, P: Fp6Parameters> Div<&'a Fp6<P>> for Fp6<P>
[src]impl<'a, P: Fp6Parameters> DivAssign<&'a Fp6<P>> for Fp6<P>
[src]
impl<'a, P: Fp6Parameters> DivAssign<&'a Fp6<P>> for Fp6<P>
[src]fn div_assign(&mut self, other: &Self)
[src]
fn div_assign(&mut self, other: &Self)
[src]Performs the /=
operation. Read more
impl<P: Fp6Parameters> Field for Fp6<P>
[src]
impl<P: Fp6Parameters> Field for Fp6<P>
[src]fn characteristic<'a>() -> &'a [u64]
[src]
fn characteristic<'a>() -> &'a [u64]
[src]Returns the characteristic of the field.
fn double_in_place(&mut self) -> &mut Self
[src]
fn double_in_place(&mut self) -> &mut Self
[src]Doubles self
in place.
fn from_random_bytes_with_flags(bytes: &[u8]) -> Option<(Self, u8)>
[src]
fn from_random_bytes_with_flags(bytes: &[u8]) -> Option<(Self, u8)>
[src]Returns a field element with an extra sign bit used for group parsing if the set of bytes forms a valid field element, otherwise returns None. This function is primarily intended for sampling random field elements from a hash-function or RNG output. Read more
fn from_random_bytes(bytes: &[u8]) -> Option<Self>
[src]
fn from_random_bytes(bytes: &[u8]) -> Option<Self>
[src]Returns a field element if the set of bytes forms a valid field element, otherwise returns None. This function is primarily intended for sampling random field elements from a hash-function or RNG output. Read more
fn square_in_place(&mut self) -> &mut Self
[src]
fn square_in_place(&mut self) -> &mut Self
[src]Squares self
in place.
fn inverse(&self) -> Option<Self>
[src]
fn inverse(&self) -> Option<Self>
[src]Computes the multiplicative inverse of self
if self
is nonzero.
fn inverse_in_place(&mut self) -> Option<&mut Self>
[src]
fn frobenius_map(&mut self, power: usize)
[src]
fn frobenius_map(&mut self, power: usize)
[src]Exponentiates this element by a power of the base prime modulus via the Frobenius automorphism. Read more
impl<P: Fp6Parameters> From<u128> for Fp6<P>
[src]
impl<P: Fp6Parameters> From<u128> for Fp6<P>
[src]impl<P: Fp6Parameters> From<u16> for Fp6<P>
[src]
impl<P: Fp6Parameters> From<u16> for Fp6<P>
[src]impl<P: Fp6Parameters> From<u32> for Fp6<P>
[src]
impl<P: Fp6Parameters> From<u32> for Fp6<P>
[src]impl<P: Fp6Parameters> From<u64> for Fp6<P>
[src]
impl<P: Fp6Parameters> From<u64> for Fp6<P>
[src]impl<P: Fp6Parameters> From<u8> for Fp6<P>
[src]
impl<P: Fp6Parameters> From<u8> for Fp6<P>
[src]impl<P: Fp6Parameters> FromBytes for Fp6<P>
[src]
impl<P: Fp6Parameters> FromBytes for Fp6<P>
[src]impl<P: Fp6Parameters> Hash for Fp6<P> where
P: Fp6Parameters,
[src]
impl<P: Fp6Parameters> Hash for Fp6<P> where
P: Fp6Parameters,
[src]impl<'a, P: Fp6Parameters> Mul<&'a Fp6<P>> for Fp6<P>
[src]
impl<'a, P: Fp6Parameters> Mul<&'a Fp6<P>> for Fp6<P>
[src]impl<'a, P: Fp6Parameters> MulAssign<&'a Fp6<P>> for Fp6<P>
[src]
impl<'a, P: Fp6Parameters> MulAssign<&'a Fp6<P>> for Fp6<P>
[src]fn mul_assign(&mut self, other: &Self)
[src]
fn mul_assign(&mut self, other: &Self)
[src]Performs the *=
operation. Read more
impl<P: Fp6Parameters> Neg for Fp6<P>
[src]
impl<P: Fp6Parameters> Neg for Fp6<P>
[src]impl<P: Fp6Parameters> Ord for Fp6<P>
[src]
impl<P: Fp6Parameters> Ord for Fp6<P>
[src]Fp3
elements are ordered lexicographically.
impl<P: Fp6Parameters> PartialEq<Fp6<P>> for Fp6<P> where
P: Fp6Parameters,
[src]
impl<P: Fp6Parameters> PartialEq<Fp6<P>> for Fp6<P> where
P: Fp6Parameters,
[src]impl<P: Fp6Parameters> PartialOrd<Fp6<P>> for Fp6<P>
[src]
impl<P: Fp6Parameters> PartialOrd<Fp6<P>> for Fp6<P>
[src]fn partial_cmp(&self, other: &Self) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Self) -> Option<Ordering>
[src]This method returns an ordering between self
and other
values if one exists. Read more
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn lt(&self, other: &Rhs) -> bool
1.0.0[src]This method tests less than (for self
and other
) and is used by the <
operator. Read more
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]fn le(&self, other: &Rhs) -> bool
1.0.0[src]This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl<P: Fp6Parameters> Serialize for Fp6<P>
[src]
impl<P: Fp6Parameters> Serialize for Fp6<P>
[src]impl<'a, P: Fp6Parameters> Sub<&'a Fp6<P>> for Fp6<P>
[src]
impl<'a, P: Fp6Parameters> Sub<&'a Fp6<P>> for Fp6<P>
[src]impl<'a, P: Fp6Parameters> SubAssign<&'a Fp6<P>> for Fp6<P>
[src]
impl<'a, P: Fp6Parameters> SubAssign<&'a Fp6<P>> for Fp6<P>
[src]fn sub_assign(&mut self, other: &Self)
[src]
fn sub_assign(&mut self, other: &Self)
[src]Performs the -=
operation. Read more
impl<P: Fp6Parameters> ToBytes for Fp6<P>
[src]
impl<P: Fp6Parameters> ToBytes for Fp6<P>
[src]impl<P: Fp6Parameters> Copy for Fp6<P> where
P: Fp6Parameters,
[src]
P: Fp6Parameters,
impl<P: Fp6Parameters> Eq for Fp6<P> where
P: Fp6Parameters,
[src]
P: Fp6Parameters,
Auto Trait Implementations
impl<P> RefUnwindSafe for Fp6<P> where
P: RefUnwindSafe,
<<P as Fp6Parameters>::Fp2Params as Fp2Parameters>::Fp: RefUnwindSafe,
<P as Fp6Parameters>::Fp2Params: RefUnwindSafe,
P: RefUnwindSafe,
<<P as Fp6Parameters>::Fp2Params as Fp2Parameters>::Fp: RefUnwindSafe,
<P as Fp6Parameters>::Fp2Params: RefUnwindSafe,
impl<P> Send for Fp6<P>
impl<P> Sync for Fp6<P>
impl<P> Unpin for Fp6<P> where
P: Unpin,
<<P as Fp6Parameters>::Fp2Params as Fp2Parameters>::Fp: Unpin,
<P as Fp6Parameters>::Fp2Params: Unpin,
P: Unpin,
<<P as Fp6Parameters>::Fp2Params as Fp2Parameters>::Fp: Unpin,
<P as Fp6Parameters>::Fp2Params: Unpin,
impl<P> UnwindSafe for Fp6<P> where
P: UnwindSafe,
<<P as Fp6Parameters>::Fp2Params as Fp2Parameters>::Fp: UnwindSafe,
<P as Fp6Parameters>::Fp2Params: UnwindSafe,
P: UnwindSafe,
<<P as Fp6Parameters>::Fp2Params as Fp2Parameters>::Fp: UnwindSafe,
<P as Fp6Parameters>::Fp2Params: UnwindSafe,
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
impl<T> UniformRand for T where
Standard: Distribution<T>,
[src]
impl<T> UniformRand for T where
Standard: Distribution<T>,
[src]impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
pub fn vzip(self) -> V
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,