Skip to main content

NegativeDiscriminant

Trait NegativeDiscriminant 

Source
pub trait NegativeDiscriminant: Discriminant {
    // Required method
    fn absolute_value(&self) -> impl AsRef<[u8]>;

    // Provided method
    fn upper_bound_on_order(&self) -> u32 { ... }
}
Expand description

A negative discriminant of a class group.

Required Methods§

Source

fn absolute_value(&self) -> impl AsRef<[u8]>

The absolute value of this discriminant.

This is returned as its little-endian encoding.

Provided Methods§

Source

fn upper_bound_on_order(&self) -> u32

An upper bound on the order of the class group with this discriminant.

This returns k such that $2^k$ is greater than or equal to the order (class number) of this group. The returned k is not required to be minimal or calculated by any specific formula, so long as $2^k$ is greater than or equal to a proven bound on the order of this group.

The provided implementation runs in variable time. The provided implementation MAY panic if this discriminant is ill-defined or absurdly large.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<Up, Udk: Encoding> NegativeDiscriminant for Cl15k<Up, Udk>

Source§

impl<Up: BitOps, Up2, Udk: Encoding, Udp: Encoding> NegativeDiscriminant for Cl15p<Up, Up2, Udk, Udp>