-1
$\begingroup$

I hope someone can explain me how to solve modulo -equations ,e.g.

$5^{123} \mod 2$

It was a little bit overwhelming for me to get a feeling for solving such equations.I don't how and when i have to use one of these great theorems like, Fermat's little ,Euler totient function,Chinese remainder theorem a.s.o.So I decide to ask you guys for helping me with my stacks.

$\endgroup$
13
  • 5
    $\begingroup$ In this case , the result is obvious : $0$ $\endgroup$ – Peter Sep 21 '19 at 19:54
  • $\begingroup$ Tip for the general case : Use the chinese remainder theorem and the Euler theorem (sometimes Fermat's little theorem is already sufficient) $\endgroup$ – Peter Sep 21 '19 at 19:56
  • 1
    $\begingroup$ Ok,you are right.It is a bit trivial example. $\endgroup$ – Gui Sep 21 '19 at 19:58
  • $\begingroup$ Maybe 5^123 mod 2 should be better. $\endgroup$ – Gui Sep 21 '19 at 19:59
  • 1
    $\begingroup$ @Gui Since this one is closed, I posted in another similar one, vote if you like math.stackexchange.com/a/3364841/399263 $\endgroup$ – zwim Sep 21 '19 at 20:40
2
$\begingroup$

The answer is pretty obvious: it is $0$ ($3^n$ where $n$ is a positive integer obviously divides $3$ and thus has a remainder of $0$). If you were asking for$\pmod{10}$, then we would apply Euler's Totient's Function, $\phi(n)$ and then simplify from there. For your next question, since $5\equiv 1\pmod 2$, we have that $$5^{123}\equiv 1^{123}\equiv 1\pmod{2}.$$

$\endgroup$
2
  • $\begingroup$ I will try it for $5^{123}$ mod 10: $\endgroup$ – Gui Sep 21 '19 at 20:16
  • $\begingroup$ 5 is the answer then. As any odd multiple of 5 ends in a 5 in base 10. $\endgroup$ – user645636 Sep 22 '19 at 15:07

Not the answer you're looking for? Browse other questions tagged or ask your own question.