0

One way to manipulate a congruence relation is to replace an exponent with another to which the first is congruent to; for example $9^{506} \pmod{100}$ is congruent to $9^6 \pmod{100}$ because

$506 ≡ 6 \pmod{100}$

so it is possible to write (I don't understand the reason):

$9^{506} = 9^6 \pmod{100}$

For which properties and theorems does the last identity hold?

Bill Dubuque
  • 272,048

2 Answers2

3

$100$ is quite a special case.

You have a well-known Euler theorem that $a^{\varphi(n)}\equiv 1\pmod n$ if $a$ is coprime with $n$ and $\varphi$ is Euler's totient function. (See: Wikipedia.)

In fact, this can be strengthened a bit for some $n$: let $\lambda(n)$ be the smallest exponent for which $a^{\lambda(n)}\equiv 1\pmod n$ for all $a$ coprime with $n$. $\lambda$ is called Carmichael function. (See Wikipedia.)

In the case $n=100$, $\varphi(n)=40$ but $\lambda(n)=20$ and so $a^{20}\equiv 1\pmod{100}$ and consequently $a^{20q+r}\equiv a^r\pmod {100}$ for $a$ (such as $a=9$) coprime with $100$. That is why the statement from your question is true.

In general, if $a$ is coprime with $n$, you would say that $a^u\equiv a^v\pmod n$ if $u\equiv v\pmod{\varphi(n)}$, or, if this is not enough to reach a desired conclusion, $u\equiv v\pmod{\lambda(n)}$. However, in general, you can not replace the modulus in the last two formulas with $n$.


Note: It is known that $\lambda(uv)=\text{LCM}(\lambda(u),\lambda(v))$ for $u,v$ coprime, and $\lambda(n)\mid\varphi(n)$. Thus, knowing how to calculate Euler's totient function you can easily calculate the upper bound for the Carmichael function. In the case $n=100=4\cdot 25$, you have $\lambda(4)\mid\varphi(4)=2$, $\lambda(25)\mid\varphi(25)=20$ so $\lambda(100)\mid\text{LCM}(2,20)=20$. This does not exactly show that $\lambda(100)=20$, but is still good to conclude that $9^{20}\equiv 1\pmod{100}$

0

Invoking the simple generalization of the Fermat & Euler Theorems given below yields

$$100\mid a^{\large 2+e}(a^{\large 20f}-1)\ \ \ {\rm so}\ \ \ \bbox[5px,border:2px solid #c00]{a^{\large 2+e+20f}\equiv a^{\large 2+e}\!\!\pmod{\!100}}\ \ \ \ {\rm [OP\,\ is}\ \,a,e,f = 9,4,25]\qquad$$

Theorem $\ $ Suppose that $\ m\in \mathbb N\ $ has the prime factorization $\:m = p_1^{e_{1}}\cdots\:p_k^{e_k}\ $ and suppose that for all $\,i,\,$ $\ \color{#0a0}{e_i\le e}\ $ and $\ \phi(p_i^{e_{i}})\mid f.\ $ Then $\ m\mid \color{#0a0}{a^e}(a^f-1)\ $ for all $\: a\in \mathbb Z.$

Proof $\ $ Notice that if $\ p_i\mid a\ $ then $\:p_i^{e_{i}}\mid \color{#0a0}{a^e}\ $ by $\ \color{#0a0}{e_i \le e}.\: $ Else $\:a\:$ is coprime to $\: p_i\:$ so by Euler's phi theorem, $\!\bmod q = p_i^{e_{i}}:\, \ a^{\phi(q)}\equiv 1 \Rightarrow\ a^f\equiv 1\, $ by $\: \phi(q)\mid f\, $ and modular order reduction. Therefore, since all of the prime powers $\ p_i^{e_{i}}\ |\ a^e (a^f - 1)\ $ so too does their lcm = product = $m$.

Examples $\ $ You can find many illuminating examples in prior questions, e.g. below

$\qquad\qquad\quad$ $24\mid a^3(a^2-1)$

$\qquad\qquad\quad$ $40\mid a^3(a^4-1)$

$\qquad\qquad\quad$ $88\mid a^5(a^{20}\!-1)$

$\qquad\qquad\quad$ $6p\mid a\,b^p - b\,a^p$

Bill Dubuque
  • 272,048