Modular inversion

Use the extended Euclidean algorithm to compute a modular multiplicative inverse


Computes m for n-1 = m (mod p), where n and p are coprime.

Displays the steps of the extended Euclidean algorithm.

Set n =
Set p =

step quotient t1 t2 t3 u1 u2 u3 v1 v2 v3
0    1025018
131-310181-31
28-82501-31-8250

The modular inverse is:

22


Darren Sri-Jayantha