How to compute the modular multiplicative inverse on WolframAlpha?

2.9k Views Asked by At

$e = 17$

$\varphi(3233) = (61 - 1)(53 - 1) = 3120$

Compute d, the modular multiplicative inverse of e (mod φ(n)) yielding d = 2753.

http://en.wikipedia.org/wiki/RSA_%28algorithm%29#A_working_example

I tried this: "modular inverse of (17 (mod φ(3233)))"

http://www.wolframalpha.com/input/?i=modular+inverse+of++%2817+%28mod+%CF%86%283233%29%29%29

It resulted into 1/17 and not 2753. Where's the mistake?

1

There are 1 best solutions below

2
On

Wolfram Alpha can use Mathematica commands, so when in doubt look into the Mathematica documentation. In this case, you can use

PowerMod[17,-1,EulerPhi[3233]]

to get the correct result.