Struct curve25519_dalek::montgomery::ProjectivePoint [−][src]
struct ProjectivePoint {
pub U: FieldElement51,
pub W: FieldElement51,
}
Expand description
A ProjectivePoint
holds a point on the projective line
\( \mathbb P(\mathbb F_p) \), which we identify with the Kummer
line of the Montgomery curve.
Fields
U: FieldElement51
W: FieldElement51
Implementations
Dehomogenize this point to affine coordinates.
Return
- \( u = U / W \) if \( W \neq 0 \);
- \( 0 \) if \( W \eq 0 \);
Trait Implementations
fn conditional_select(
a: &ProjectivePoint,
b: &ProjectivePoint,
choice: Choice
) -> ProjectivePoint
fn conditional_select(
a: &ProjectivePoint,
b: &ProjectivePoint,
choice: Choice
) -> ProjectivePoint
Select a
or b
according to choice
. Read more
Conditionally assign other
to self
, according to choice
. Read more
Returns the “default value” for a type. Read more
Returns the identity element of the curve. Can be used as a constructor. Read more
Auto Trait Implementations
impl RefUnwindSafe for ProjectivePoint
impl Send for ProjectivePoint
impl Sync for ProjectivePoint
impl Unpin for ProjectivePoint
impl UnwindSafe for ProjectivePoint
Blanket Implementations
Mutably borrows from an owned value. Read more
pub fn cast(self) -> U
pub fn cast(self) -> U
Numeric cast from self
to T
.
pub fn from_bits(t: T) -> T
pub fn from_bits(t: T) -> T
Safe lossless bitwise transmute from T
to Self
.
pub fn from_cast(t: T) -> T
pub fn from_cast(t: T) -> T
Numeric cast from T
to Self
.
pub fn into_bits(self) -> U
pub fn into_bits(self) -> U
Safe lossless bitwise transmute from self
to T
.