Bootstrap
  E.E.A. .com
It doesn't have to be difficult if someone just explains it right.

Calculator

For the Euclidean Algorithm, Extended Euclidean Algorithm and multiplicative inverse.

Before you use this calculator

If you're used to a different notation, the output of the calculator might confuse you at first.
Even though this is basically the same as the notation you expect. If that happens, don't panic.
Just make sure to have a look the following pages first and then it will all make sense:


Input

Algorithm

Choose which algorithm you would like to use.

Numbers

Enter the input numbers. Note that you need to enter n before b.
E.g. if you want to know the multiplicative inverse of 26 mod 11, then use n=11 and b=26.

n=
b=


Output

This is the calculation for finding the multiplicative inverse of 20567 mod 803 using the Extended Euclidean Algorithm:
nbqr t1t2t3
803205670803010
2056780325492101
803492131101-1
49231111811-12
3111811130-12-3
1811301512-35
13051228-35-13
51281235-1318
282315-1318-31
2354318-31142
5312-31142-173
3211142-173315
2120-173315-803
Answer

So t = 315. Now we still have to apply mod n to that number:
315 mod 803 ≡ 315
So the multiplicative inverse of 20567 modulo 803 is 315.

Verification

Let i be the answer we just found, so i=315. We also have b=20567 and n=803.
If our answer is correct, then i × b (mod n) ≡ 1 (mod n).
Let's see if that's indeed the case.
i × b (mod n) ≡
315 × 20567 (mod 803) ≡
6478605 (mod 803) ≡
1 (mod 803)