I'm currently studying the RSA algorithm and while I understand why if $b$ is the inverse of $a$ in $\Bbb Z_n $ then $ab \equiv 1\pmod{n}$. I don't quite understand why $x^{ab} \equiv x \pmod{n}$. Can I just replace $ab$ with $1$? A proof showing why this holds would be really helpful.
Asked
Active
Viewed 68 times
0
-
When $a\in\mathbb Z_n$, the expression $x^a\pmod n$ is not well-defined... – Kenta S Apr 07 '21 at 19:01
-
You misread, it should say $,ab\equiv 1\pmod{\color{#c00}{\phi(n)}},$ and proofs are in the linked dupe. Post further question in comments here or there if anything remains unclear. – Bill Dubuque Apr 07 '21 at 19:05
-
@BillDubuque I didn't misread, they mistyped. My comment is legitimate as a response to the question they asked. – Kenta S Apr 07 '21 at 19:28
-
@KentaS Now you have misread. My prior comment is to the OP, not you (if it was addressed to you it would begin like this comment at-you) – Bill Dubuque Apr 07 '21 at 19:30
-
@BillDubuque Sorry; my bad. I guess I misread your message. – Kenta S Apr 07 '21 at 21:28
-
@BillDubuque Yes,I did actually misread the proof...It's clear now,thanks a lot! – sliiime Apr 08 '21 at 00:31
1 Answers
2
Rather, we have $$ x^{ab}\equiv x\pmod n$$ if $$ ab\equiv 1\pmod{\phi(n)}\quad\text{and}\quad \gcd(x,n)=1.$$

Hagen von Eitzen
- 374,180
-
-
1
-
another connection for $a,b$ is when written in bsse $\phi(n)+1$ they have a product of digital roots that is congruent to $1\bmod\phi(n)$ – Roddy MacPhee Apr 07 '21 at 23:26
-
Thanks a lot for the comment.This,and the post that was linked as the original question made things clear.I had actually misread the proof..This was bothering my mind for 2 days in a row.I need to be more focused. – sliiime Apr 08 '21 at 00:30