Struct ark_test_curves::short_weierstrass::Projective
source · pub struct Projective<P>where
P: SWCurveConfig,{
pub x: <P as CurveConfig>::BaseField,
pub y: <P as CurveConfig>::BaseField,
pub z: <P as CurveConfig>::BaseField,
}
Expand description
Jacobian coordinates for a point on an elliptic curve in short Weierstrass
form, over the base field P::BaseField
. This struct implements arithmetic
via the Jacobian formulae
Fields§
§x: <P as CurveConfig>::BaseField
X / Z
projection of the affine X
y: <P as CurveConfig>::BaseField
Y / Z
projection of the affine Y
z: <P as CurveConfig>::BaseField
Projective multiplicative inverse. Will be 0
only at infinity.
Implementations§
source§impl<P> Projective<P>where
P: SWCurveConfig,
impl<P> Projective<P>where P: SWCurveConfig,
sourcepub const fn new_unchecked(
x: <P as CurveConfig>::BaseField,
y: <P as CurveConfig>::BaseField,
z: <P as CurveConfig>::BaseField
) -> Projective<P>
pub const fn new_unchecked( x: <P as CurveConfig>::BaseField, y: <P as CurveConfig>::BaseField, z: <P as CurveConfig>::BaseField ) -> Projective<P>
Constructs a new group element without checking whether the coordinates specify a point in the subgroup.
sourcepub fn new(
x: <P as CurveConfig>::BaseField,
y: <P as CurveConfig>::BaseField,
z: <P as CurveConfig>::BaseField
) -> Projective<P>
pub fn new( x: <P as CurveConfig>::BaseField, y: <P as CurveConfig>::BaseField, z: <P as CurveConfig>::BaseField ) -> Projective<P>
Constructs a new group element in a way while enforcing that points are in the prime-order subgroup.
Trait Implementations§
source§impl<'a, 'b, P> Add<&'a Projective<P>> for &'b Projective<P>where
P: SWCurveConfig,
impl<'a, 'b, P> Add<&'a Projective<P>> for &'b Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
+
operator.source§fn add(self, other: &'a Projective<P>) -> Projective<P>
fn add(self, other: &'a Projective<P>) -> Projective<P>
+
operation. Read moresource§impl<'a, P> Add<&'a Projective<P>> for Affine<P>where
P: SWCurveConfig,
impl<'a, P> Add<&'a Projective<P>> for Affine<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
+
operator.source§fn add(self, other: &'a Projective<P>) -> Projective<P>
fn add(self, other: &'a Projective<P>) -> Projective<P>
+
operation. Read moresource§impl<'a, P> Add<&'a Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<'a, P> Add<&'a Projective<P>> for Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
+
operator.source§fn add(self, other: &'a Projective<P>) -> Projective<P>
fn add(self, other: &'a Projective<P>) -> Projective<P>
+
operation. Read moresource§impl<'a, 'b, P> Add<&'a mut Projective<P>> for &'b Projective<P>where
P: SWCurveConfig,
impl<'a, 'b, P> Add<&'a mut Projective<P>> for &'b Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
+
operator.source§fn add(self, other: &'a mut Projective<P>) -> Projective<P>
fn add(self, other: &'a mut Projective<P>) -> Projective<P>
+
operation. Read moresource§impl<'a, P> Add<&'a mut Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<'a, P> Add<&'a mut Projective<P>> for Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
+
operator.source§fn add(self, other: &'a mut Projective<P>) -> Projective<P>
fn add(self, other: &'a mut Projective<P>) -> Projective<P>
+
operation. Read moresource§impl<'b, P> Add<Projective<P>> for &'b Projective<P>where
P: SWCurveConfig,
impl<'b, P> Add<Projective<P>> for &'b Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
+
operator.source§fn add(self, other: Projective<P>) -> Projective<P>
fn add(self, other: Projective<P>) -> Projective<P>
+
operation. Read moresource§impl<P> Add<Projective<P>> for Affine<P>where
P: SWCurveConfig,
impl<P> Add<Projective<P>> for Affine<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
+
operator.source§fn add(self, other: Projective<P>) -> Projective<P>
fn add(self, other: Projective<P>) -> Projective<P>
+
operation. Read moresource§impl<P> Add<Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<P> Add<Projective<P>> for Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
+
operator.source§fn add(self, other: Projective<P>) -> Projective<P>
fn add(self, other: Projective<P>) -> Projective<P>
+
operation. Read moresource§impl<P, T> Add<T> for Projective<P>where
P: SWCurveConfig,
T: Borrow<Affine<P>>,
impl<P, T> Add<T> for Projective<P>where P: SWCurveConfig, T: Borrow<Affine<P>>,
§type Output = Projective<P>
type Output = Projective<P>
+
operator.source§fn add(self, other: T) -> Projective<P>
fn add(self, other: T) -> Projective<P>
+
operation. Read moresource§impl<'a, P> AddAssign<&'a Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<'a, P> AddAssign<&'a Projective<P>> for Projective<P>where P: SWCurveConfig,
source§fn add_assign(&mut self, other: &'a Projective<P>)
fn add_assign(&mut self, other: &'a Projective<P>)
+=
operation. Read moresource§impl<'a, P> AddAssign<&'a mut Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<'a, P> AddAssign<&'a mut Projective<P>> for Projective<P>where P: SWCurveConfig,
source§fn add_assign(&mut self, other: &'a mut Projective<P>)
fn add_assign(&mut self, other: &'a mut Projective<P>)
+=
operation. Read moresource§impl<P> AddAssign<Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<P> AddAssign<Projective<P>> for Projective<P>where P: SWCurveConfig,
source§fn add_assign(&mut self, other: Projective<P>)
fn add_assign(&mut self, other: Projective<P>)
+=
operation. Read moresource§impl<P, T> AddAssign<T> for Projective<P>where
P: SWCurveConfig,
T: Borrow<Affine<P>>,
impl<P, T> AddAssign<T> for Projective<P>where P: SWCurveConfig, T: Borrow<Affine<P>>,
source§fn add_assign(&mut self, other: T)
fn add_assign(&mut self, other: T)
Using http://www.hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html#addition-madd-2007-bl
source§impl<P> CanonicalDeserialize for Projective<P>where
P: SWCurveConfig,
impl<P> CanonicalDeserialize for Projective<P>where P: SWCurveConfig,
source§fn deserialize_with_mode<R>(
reader: R,
compress: Compress,
validate: Validate
) -> Result<Projective<P>, SerializationError>where
R: Read,
fn deserialize_with_mode<R>( reader: R, compress: Compress, validate: Validate ) -> Result<Projective<P>, SerializationError>where R: Read,
fn deserialize_compressed<R>(reader: R) -> Result<Self, SerializationError>where R: Read,
fn deserialize_compressed_unchecked<R>( reader: R ) -> Result<Self, SerializationError>where R: Read,
fn deserialize_uncompressed<R>(reader: R) -> Result<Self, SerializationError>where R: Read,
fn deserialize_uncompressed_unchecked<R>( reader: R ) -> Result<Self, SerializationError>where R: Read,
source§impl<P> CanonicalSerialize for Projective<P>where
P: SWCurveConfig,
impl<P> CanonicalSerialize for Projective<P>where P: SWCurveConfig,
source§fn serialize_with_mode<W>(
&self,
writer: W,
compress: Compress
) -> Result<(), SerializationError>where
W: Write,
fn serialize_with_mode<W>( &self, writer: W, compress: Compress ) -> Result<(), SerializationError>where W: Write,
fn serialized_size(&self, compress: Compress) -> usize
fn serialize_compressed<W>(&self, writer: W) -> Result<(), SerializationError>where W: Write,
fn compressed_size(&self) -> usize
fn serialize_uncompressed<W>(&self, writer: W) -> Result<(), SerializationError>where W: Write,
fn uncompressed_size(&self) -> usize
source§impl<P> Clone for Projective<P>where
P: SWCurveConfig,
impl<P> Clone for Projective<P>where P: SWCurveConfig,
source§fn clone(&self) -> Projective<P>
fn clone(&self) -> Projective<P>
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl<P> CurveGroup for Projective<P>where
P: SWCurveConfig,
impl<P> CurveGroup for Projective<P>where P: SWCurveConfig,
source§fn normalize_batch(
v: &[Projective<P>]
) -> Vec<<Projective<P> as CurveGroup>::Affine, Global> ⓘ
fn normalize_batch( v: &[Projective<P>] ) -> Vec<<Projective<P> as CurveGroup>::Affine, Global> ⓘ
Normalizes a slice of projective elements so that conversion to affine is cheap.
In more detail, this method converts a curve point in Jacobian coordinates (x, y, z) into an equivalent representation (x/z^2, y/z^3, 1).
For N = v.len()
, this costs 1 inversion + 6N field multiplications + N
field squarings.
(Where batch inversion comprises 3N field multiplications + 1 inversion of these operations)
type Config = P
§type BaseField = <P as CurveConfig>::BaseField
type BaseField = <P as CurveConfig>::BaseField
§type FullGroup = Affine<P>
type FullGroup = Affine<P>
source§fn into_affine(self) -> Self::Affine
fn into_affine(self) -> Self::Affine
self
into the affine representation.source§impl<P> Debug for Projective<P>where
P: SWCurveConfig,
impl<P> Debug for Projective<P>where P: SWCurveConfig,
source§impl<P> Default for Projective<P>where
P: SWCurveConfig,
impl<P> Default for Projective<P>where P: SWCurveConfig,
source§fn default() -> Projective<P>
fn default() -> Projective<P>
source§impl<P> Display for Projective<P>where
P: SWCurveConfig,
impl<P> Display for Projective<P>where P: SWCurveConfig,
source§impl<'a, P> From<&'a Projective<<P as BW6Config>::G1Config>> for G1Prepared<P>where
P: BW6Config,
impl<'a, P> From<&'a Projective<<P as BW6Config>::G1Config>> for G1Prepared<P>where P: BW6Config,
source§fn from(q: &'a Projective<<P as BW6Config>::G1Config>) -> G1Prepared<P>
fn from(q: &'a Projective<<P as BW6Config>::G1Config>) -> G1Prepared<P>
source§impl<'a, P> From<&'a Projective<<P as BW6Config>::G2Config>> for G2Prepared<P>where
P: BW6Config,
impl<'a, P> From<&'a Projective<<P as BW6Config>::G2Config>> for G2Prepared<P>where P: BW6Config,
source§fn from(q: &'a Projective<<P as BW6Config>::G2Config>) -> G2Prepared<P>
fn from(q: &'a Projective<<P as BW6Config>::G2Config>) -> G2Prepared<P>
source§impl<'a, P> From<&'a Projective<<P as Bls12Config>::G1Config>> for G1Prepared<P>where
P: Bls12Config,
impl<'a, P> From<&'a Projective<<P as Bls12Config>::G1Config>> for G1Prepared<P>where P: Bls12Config,
source§fn from(q: &'a Projective<<P as Bls12Config>::G1Config>) -> G1Prepared<P>
fn from(q: &'a Projective<<P as Bls12Config>::G1Config>) -> G1Prepared<P>
source§impl<'a, P> From<&'a Projective<<P as Bls12Config>::G2Config>> for G2Prepared<P>where
P: Bls12Config,
impl<'a, P> From<&'a Projective<<P as Bls12Config>::G2Config>> for G2Prepared<P>where P: Bls12Config,
source§fn from(q: &'a Projective<<P as Bls12Config>::G2Config>) -> G2Prepared<P>
fn from(q: &'a Projective<<P as Bls12Config>::G2Config>) -> G2Prepared<P>
source§impl<'a, P> From<&'a Projective<<P as BnConfig>::G1Config>> for G1Prepared<P>where
P: BnConfig,
impl<'a, P> From<&'a Projective<<P as BnConfig>::G1Config>> for G1Prepared<P>where P: BnConfig,
source§fn from(q: &'a Projective<<P as BnConfig>::G1Config>) -> G1Prepared<P>
fn from(q: &'a Projective<<P as BnConfig>::G1Config>) -> G1Prepared<P>
source§impl<'a, P> From<&'a Projective<<P as BnConfig>::G2Config>> for G2Prepared<P>where
P: BnConfig,
impl<'a, P> From<&'a Projective<<P as BnConfig>::G2Config>> for G2Prepared<P>where P: BnConfig,
source§fn from(q: &'a Projective<<P as BnConfig>::G2Config>) -> G2Prepared<P>
fn from(q: &'a Projective<<P as BnConfig>::G2Config>) -> G2Prepared<P>
source§impl<'a, P> From<&'a Projective<<P as MNT4Config>::G1Config>> for G1Prepared<P>where
P: MNT4Config,
impl<'a, P> From<&'a Projective<<P as MNT4Config>::G1Config>> for G1Prepared<P>where P: MNT4Config,
source§fn from(g1: &'a Projective<<P as MNT4Config>::G1Config>) -> G1Prepared<P>
fn from(g1: &'a Projective<<P as MNT4Config>::G1Config>) -> G1Prepared<P>
source§impl<'a, P> From<&'a Projective<<P as MNT4Config>::G2Config>> for G2Prepared<P>where
P: MNT4Config,
impl<'a, P> From<&'a Projective<<P as MNT4Config>::G2Config>> for G2Prepared<P>where P: MNT4Config,
source§fn from(g2: &'a Projective<<P as MNT4Config>::G2Config>) -> G2Prepared<P>
fn from(g2: &'a Projective<<P as MNT4Config>::G2Config>) -> G2Prepared<P>
source§impl<'a, P> From<&'a Projective<<P as MNT6Config>::G1Config>> for G1Prepared<P>where
P: MNT6Config,
impl<'a, P> From<&'a Projective<<P as MNT6Config>::G1Config>> for G1Prepared<P>where P: MNT6Config,
source§fn from(g1: &'a Projective<<P as MNT6Config>::G1Config>) -> G1Prepared<P>
fn from(g1: &'a Projective<<P as MNT6Config>::G1Config>) -> G1Prepared<P>
source§impl<'a, P> From<&'a Projective<<P as MNT6Config>::G2Config>> for G2Prepared<P>where
P: MNT6Config,
impl<'a, P> From<&'a Projective<<P as MNT6Config>::G2Config>> for G2Prepared<P>where P: MNT6Config,
source§fn from(g2: &'a Projective<<P as MNT6Config>::G2Config>) -> G2Prepared<P>
fn from(g2: &'a Projective<<P as MNT6Config>::G2Config>) -> G2Prepared<P>
source§impl<P> From<Affine<P>> for Projective<P>where
P: SWCurveConfig,
impl<P> From<Affine<P>> for Projective<P>where P: SWCurveConfig,
source§fn from(p: Affine<P>) -> Projective<P>
fn from(p: Affine<P>) -> Projective<P>
source§impl<P> From<Projective<<P as BW6Config>::G1Config>> for G1Prepared<P>where
P: BW6Config,
impl<P> From<Projective<<P as BW6Config>::G1Config>> for G1Prepared<P>where P: BW6Config,
source§fn from(q: Projective<<P as BW6Config>::G1Config>) -> G1Prepared<P>
fn from(q: Projective<<P as BW6Config>::G1Config>) -> G1Prepared<P>
source§impl<P> From<Projective<<P as BW6Config>::G2Config>> for G2Prepared<P>where
P: BW6Config,
impl<P> From<Projective<<P as BW6Config>::G2Config>> for G2Prepared<P>where P: BW6Config,
source§fn from(q: Projective<<P as BW6Config>::G2Config>) -> G2Prepared<P>
fn from(q: Projective<<P as BW6Config>::G2Config>) -> G2Prepared<P>
source§impl<P> From<Projective<<P as Bls12Config>::G1Config>> for G1Prepared<P>where
P: Bls12Config,
impl<P> From<Projective<<P as Bls12Config>::G1Config>> for G1Prepared<P>where P: Bls12Config,
source§fn from(q: Projective<<P as Bls12Config>::G1Config>) -> G1Prepared<P>
fn from(q: Projective<<P as Bls12Config>::G1Config>) -> G1Prepared<P>
source§impl<P> From<Projective<<P as Bls12Config>::G2Config>> for G2Prepared<P>where
P: Bls12Config,
impl<P> From<Projective<<P as Bls12Config>::G2Config>> for G2Prepared<P>where P: Bls12Config,
source§fn from(q: Projective<<P as Bls12Config>::G2Config>) -> G2Prepared<P>
fn from(q: Projective<<P as Bls12Config>::G2Config>) -> G2Prepared<P>
source§impl<P> From<Projective<<P as BnConfig>::G1Config>> for G1Prepared<P>where
P: BnConfig,
impl<P> From<Projective<<P as BnConfig>::G1Config>> for G1Prepared<P>where P: BnConfig,
source§fn from(q: Projective<<P as BnConfig>::G1Config>) -> G1Prepared<P>
fn from(q: Projective<<P as BnConfig>::G1Config>) -> G1Prepared<P>
source§impl<P> From<Projective<<P as BnConfig>::G2Config>> for G2Prepared<P>where
P: BnConfig,
impl<P> From<Projective<<P as BnConfig>::G2Config>> for G2Prepared<P>where P: BnConfig,
source§fn from(q: Projective<<P as BnConfig>::G2Config>) -> G2Prepared<P>
fn from(q: Projective<<P as BnConfig>::G2Config>) -> G2Prepared<P>
source§impl<P> From<Projective<<P as MNT4Config>::G1Config>> for G1Prepared<P>where
P: MNT4Config,
impl<P> From<Projective<<P as MNT4Config>::G1Config>> for G1Prepared<P>where P: MNT4Config,
source§fn from(g1: Projective<<P as MNT4Config>::G1Config>) -> G1Prepared<P>
fn from(g1: Projective<<P as MNT4Config>::G1Config>) -> G1Prepared<P>
source§impl<P> From<Projective<<P as MNT4Config>::G2Config>> for G2Prepared<P>where
P: MNT4Config,
impl<P> From<Projective<<P as MNT4Config>::G2Config>> for G2Prepared<P>where P: MNT4Config,
source§fn from(g2: Projective<<P as MNT4Config>::G2Config>) -> G2Prepared<P>
fn from(g2: Projective<<P as MNT4Config>::G2Config>) -> G2Prepared<P>
source§impl<P> From<Projective<<P as MNT6Config>::G1Config>> for G1Prepared<P>where
P: MNT6Config,
impl<P> From<Projective<<P as MNT6Config>::G1Config>> for G1Prepared<P>where P: MNT6Config,
source§fn from(g1: Projective<<P as MNT6Config>::G1Config>) -> G1Prepared<P>
fn from(g1: Projective<<P as MNT6Config>::G1Config>) -> G1Prepared<P>
source§impl<P> From<Projective<<P as MNT6Config>::G2Config>> for G2Prepared<P>where
P: MNT6Config,
impl<P> From<Projective<<P as MNT6Config>::G2Config>> for G2Prepared<P>where P: MNT6Config,
source§fn from(g2: Projective<<P as MNT6Config>::G2Config>) -> G2Prepared<P>
fn from(g2: Projective<<P as MNT6Config>::G2Config>) -> G2Prepared<P>
source§impl<P> From<Projective<P>> for Affine<P>where
P: SWCurveConfig,
impl<P> From<Projective<P>> for Affine<P>where P: SWCurveConfig,
source§fn from(p: Projective<P>) -> Affine<P>
fn from(p: Projective<P>) -> Affine<P>
source§impl<P> Group for Projective<P>where
P: SWCurveConfig,
impl<P> Group for Projective<P>where P: SWCurveConfig,
source§fn double_in_place(&mut self) -> &mut Projective<P>
fn double_in_place(&mut self) -> &mut Projective<P>
Sets self = 2 * self
. Note that Jacobian formulae are incomplete, and
so doubling cannot be computed as self + self
. Instead, this
implementation uses the following specialized doubling formulae:
§type ScalarField = <P as CurveConfig>::ScalarField
type ScalarField = <P as CurveConfig>::ScalarField
F_r
, where r
is the order of this group.source§fn generator() -> Projective<P>
fn generator() -> Projective<P>
source§fn mul_bigint(&self, other: impl AsRef<[u64]>) -> Projective<P>
fn mul_bigint(&self, other: impl AsRef<[u64]>) -> Projective<P>
source§fn mul_bits_be(&self, other: impl Iterator<Item = bool>) -> Self
fn mul_bits_be(&self, other: impl Iterator<Item = bool>) -> Self
other * self
, where other
is a big-endian
bit representation of some integer.source§impl<P> Hash for Projective<P>where
P: SWCurveConfig,
impl<P> Hash for Projective<P>where P: SWCurveConfig,
source§impl<P> MapToCurve<Projective<P>> for SWUMap<P>where
P: SWUConfig,
impl<P> MapToCurve<Projective<P>> for SWUMap<P>where P: SWUConfig,
source§fn new() -> Result<SWUMap<P>, HashToCurveError>
fn new() -> Result<SWUMap<P>, HashToCurveError>
Constructs a new map if P
represents a valid map.
source§fn map_to_curve(
&self,
point: <P as CurveConfig>::BaseField
) -> Result<Affine<P>, HashToCurveError>
fn map_to_curve( &self, point: <P as CurveConfig>::BaseField ) -> Result<Affine<P>, HashToCurveError>
Map an arbitrary base field element to a curve point. Based on https://github.com/zcash/pasta_curves/blob/main/src/hashtocurve.rs.
source§impl<P> MapToCurve<Projective<P>> for WBMap<P>where
P: WBConfig,
impl<P> MapToCurve<Projective<P>> for WBMap<P>where P: WBConfig,
source§fn new() -> Result<WBMap<P>, HashToCurveError>
fn new() -> Result<WBMap<P>, HashToCurveError>
Constructs a new map if P
represents a valid map.
source§fn map_to_curve(
&self,
element: <Affine<P> as AffineRepr>::BaseField
) -> Result<Affine<P>, HashToCurveError>
fn map_to_curve( &self, element: <Affine<P> as AffineRepr>::BaseField ) -> Result<Affine<P>, HashToCurveError>
Map random field point to a random curve point inspired from https://github.com/zcash/pasta_curves/blob/main/src/hashtocurve.rs
source§impl<P, T> Mul<T> for Projective<P>where
P: SWCurveConfig,
T: Borrow<<P as CurveConfig>::ScalarField>,
impl<P, T> Mul<T> for Projective<P>where P: SWCurveConfig, T: Borrow<<P as CurveConfig>::ScalarField>,
§type Output = Projective<P>
type Output = Projective<P>
*
operator.source§fn mul(self, other: T) -> Projective<P>
fn mul(self, other: T) -> Projective<P>
*
operation. Read moresource§impl<P, T> MulAssign<T> for Projective<P>where
P: SWCurveConfig,
T: Borrow<<P as CurveConfig>::ScalarField>,
impl<P, T> MulAssign<T> for Projective<P>where P: SWCurveConfig, T: Borrow<<P as CurveConfig>::ScalarField>,
source§fn mul_assign(&mut self, other: T)
fn mul_assign(&mut self, other: T)
*=
operation. Read moresource§impl<P> Neg for Projective<P>where
P: SWCurveConfig,
impl<P> Neg for Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
-
operator.source§fn neg(self) -> Projective<P>
fn neg(self) -> Projective<P>
-
operation. Read moresource§impl<P> PartialEq<Affine<P>> for Projective<P>where
P: SWCurveConfig,
impl<P> PartialEq<Affine<P>> for Projective<P>where P: SWCurveConfig,
source§impl<P> PartialEq<Projective<P>> for Affine<P>where
P: SWCurveConfig,
impl<P> PartialEq<Projective<P>> for Affine<P>where P: SWCurveConfig,
source§fn eq(&self, other: &Projective<P>) -> bool
fn eq(&self, other: &Projective<P>) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl<P> PartialEq<Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<P> PartialEq<Projective<P>> for Projective<P>where P: SWCurveConfig,
source§fn eq(&self, other: &Projective<P>) -> bool
fn eq(&self, other: &Projective<P>) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl<P> ScalarMul for Projective<P>where
P: SWCurveConfig,
impl<P> ScalarMul for Projective<P>where P: SWCurveConfig,
type MulBase = Affine<P>
const NEGATION_IS_CHEAP: bool = true
fn batch_convert_to_mul_base( bases: &[Projective<P>] ) -> Vec<<Projective<P> as ScalarMul>::MulBase, Global> ⓘ
source§impl<'a, 'b, P> Sub<&'a Projective<P>> for &'b Projective<P>where
P: SWCurveConfig,
impl<'a, 'b, P> Sub<&'a Projective<P>> for &'b Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
-
operator.source§fn sub(self, other: &'a Projective<P>) -> Projective<P>
fn sub(self, other: &'a Projective<P>) -> Projective<P>
-
operation. Read moresource§impl<'a, P> Sub<&'a Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<'a, P> Sub<&'a Projective<P>> for Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
-
operator.source§fn sub(self, other: &'a Projective<P>) -> Projective<P>
fn sub(self, other: &'a Projective<P>) -> Projective<P>
-
operation. Read moresource§impl<'a, 'b, P> Sub<&'a mut Projective<P>> for &'b Projective<P>where
P: SWCurveConfig,
impl<'a, 'b, P> Sub<&'a mut Projective<P>> for &'b Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
-
operator.source§fn sub(self, other: &'a mut Projective<P>) -> Projective<P>
fn sub(self, other: &'a mut Projective<P>) -> Projective<P>
-
operation. Read moresource§impl<'a, P> Sub<&'a mut Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<'a, P> Sub<&'a mut Projective<P>> for Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
-
operator.source§fn sub(self, other: &'a mut Projective<P>) -> Projective<P>
fn sub(self, other: &'a mut Projective<P>) -> Projective<P>
-
operation. Read moresource§impl<'b, P> Sub<Projective<P>> for &'b Projective<P>where
P: SWCurveConfig,
impl<'b, P> Sub<Projective<P>> for &'b Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
-
operator.source§fn sub(self, other: Projective<P>) -> Projective<P>
fn sub(self, other: Projective<P>) -> Projective<P>
-
operation. Read moresource§impl<P> Sub<Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<P> Sub<Projective<P>> for Projective<P>where P: SWCurveConfig,
§type Output = Projective<P>
type Output = Projective<P>
-
operator.source§fn sub(self, other: Projective<P>) -> Projective<P>
fn sub(self, other: Projective<P>) -> Projective<P>
-
operation. Read moresource§impl<P, T> Sub<T> for Projective<P>where
P: SWCurveConfig,
T: Borrow<Affine<P>>,
impl<P, T> Sub<T> for Projective<P>where P: SWCurveConfig, T: Borrow<Affine<P>>,
§type Output = Projective<P>
type Output = Projective<P>
-
operator.source§fn sub(self, other: T) -> Projective<P>
fn sub(self, other: T) -> Projective<P>
-
operation. Read moresource§impl<'a, P> SubAssign<&'a Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<'a, P> SubAssign<&'a Projective<P>> for Projective<P>where P: SWCurveConfig,
source§fn sub_assign(&mut self, other: &'a Projective<P>)
fn sub_assign(&mut self, other: &'a Projective<P>)
-=
operation. Read moresource§impl<'a, P> SubAssign<&'a mut Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<'a, P> SubAssign<&'a mut Projective<P>> for Projective<P>where P: SWCurveConfig,
source§fn sub_assign(&mut self, other: &'a mut Projective<P>)
fn sub_assign(&mut self, other: &'a mut Projective<P>)
-=
operation. Read moresource§impl<P> SubAssign<Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<P> SubAssign<Projective<P>> for Projective<P>where P: SWCurveConfig,
source§fn sub_assign(&mut self, other: Projective<P>)
fn sub_assign(&mut self, other: Projective<P>)
-=
operation. Read moresource§impl<P, T> SubAssign<T> for Projective<P>where
P: SWCurveConfig,
T: Borrow<Affine<P>>,
impl<P, T> SubAssign<T> for Projective<P>where P: SWCurveConfig, T: Borrow<Affine<P>>,
source§fn sub_assign(&mut self, other: T)
fn sub_assign(&mut self, other: T)
-=
operation. Read moresource§impl<'a, P> Sum<&'a Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<'a, P> Sum<&'a Projective<P>> for Projective<P>where P: SWCurveConfig,
source§fn sum<I>(iter: I) -> Projective<P>where
I: Iterator<Item = &'a Projective<P>>,
fn sum<I>(iter: I) -> Projective<P>where I: Iterator<Item = &'a Projective<P>>,
Self
from the elements by
“summing up” the items.source§impl<P> Sum<Projective<P>> for Projective<P>where
P: SWCurveConfig,
impl<P> Sum<Projective<P>> for Projective<P>where P: SWCurveConfig,
source§fn sum<I>(iter: I) -> Projective<P>where
I: Iterator<Item = Projective<P>>,
fn sum<I>(iter: I) -> Projective<P>where I: Iterator<Item = Projective<P>>,
Self
from the elements by
“summing up” the items.source§impl<P, T> Sum<T> for Projective<P>where
P: SWCurveConfig,
T: Borrow<Affine<P>>,
impl<P, T> Sum<T> for Projective<P>where P: SWCurveConfig, T: Borrow<Affine<P>>,
source§fn sum<I>(iter: I) -> Projective<P>where
I: Iterator<Item = T>,
fn sum<I>(iter: I) -> Projective<P>where I: Iterator<Item = T>,
Self
from the elements by
“summing up” the items.source§impl<M, ConstraintF> ToConstraintField<ConstraintF> for Projective<M>where
M: SWCurveConfig,
ConstraintF: Field,
<M as CurveConfig>::BaseField: ToConstraintField<ConstraintF>,
impl<M, ConstraintF> ToConstraintField<ConstraintF> for Projective<M>where M: SWCurveConfig, ConstraintF: Field, <M as CurveConfig>::BaseField: ToConstraintField<ConstraintF>,
source§impl<P> Valid for Projective<P>where
P: SWCurveConfig,
impl<P> Valid for Projective<P>where P: SWCurveConfig,
fn check(&self) -> Result<(), SerializationError>
fn batch_check<'a>( batch: impl Iterator<Item = &'a Projective<P>> + Send ) -> Result<(), SerializationError>where Projective<P>: 'a,
source§impl<P> VariableBaseMSM for Projective<P>where
P: SWCurveConfig,
impl<P> VariableBaseMSM for Projective<P>where P: SWCurveConfig,
source§fn msm(
bases: &[<Projective<P> as ScalarMul>::MulBase],
bigints: &[<Projective<P> as Group>::ScalarField]
) -> Result<Projective<P>, usize>
fn msm( bases: &[<Projective<P> as ScalarMul>::MulBase], bigints: &[<Projective<P> as Group>::ScalarField] ) -> Result<Projective<P>, usize>
bases.len() == scalars.len()
. Read moresource§fn msm_unchecked(bases: &[Self::MulBase], scalars: &[Self::ScalarField]) -> Self
fn msm_unchecked(bases: &[Self::MulBase], scalars: &[Self::ScalarField]) -> Self
PrimeField
elements in scalars
and the corresponding group elements in bases
. Read more