Identify an inverse of 7 modulo 26.

discrete mathematics

I was tasked to identify an inverse for 7 modulo 26

Here is what I have done:

26 = 7(3) + 5

7 = 5 (1) + 2

5 = 2 (2) + 1

2 = 1 (2) + 0

Working backward:

1 = 5 – 2 (2)

1 = 5 – 2 (7 – 1(5))

1 = 3(5) – 2(7)

1 = 3( 26 – 3(7) ) – 2(7)

1 = 3(26) – 11(7)

So the inverse is -11

However, I know this is wrong as my professor marked it wrong

The professor's feedback was -11 + 26 = 15 therefore the inverse is 15.

When I sent a message asking why we added 26 he did not respond, so here I am asking why the addition of 26? I missed this part in my readings.

Thanks

Best Answer

Why add $26$? Because Professor Pusillanimous liked it better.

Both $-11$ and $15$ are correct answers because they represent the same residue $\bmod 26$, and this residue is indeed the multiplicative inverse of the residue $7$. Presumably, the professor wanted the smallest nonnegative number with the correct residue.