reciprocal_2_mg10

Function reciprocal_2_mg10 

pub unsafe fn reciprocal_2_mg10(d: u128) -> u64
Expand description

⚠️ Computes $\floor{\frac{2^{192} - 1}{\mathsf{d}}} - 2^{64}$.

⚠️ This function is not part of the stable API.
Requires $\mathsf{d} ∈ [2^{127}, 2^{128})$, i.e. the most significant bit of $\mathsf{d}$ must be set.

Implements MG10 algorithm 6.

§Safety

  • The input d must be at least 2^127, i.e., its highest bit must be set.