Wrong wolframalpha result, calculating Carmichael number?

103 Views Asked by At

I put to wolframalpha $3^{560}\pmod{561}$ and result should be $1$ ($561$ is Carmichael number), but result is $375.$ https://www.wolframalpha.com/input/?i=3%5E560mod561

Why this happens? I found some online calculators which produce same mistake.

1

There are 1 best solutions below

4
On

For a carmichael number $n$, the relation $b^{n-1}\equiv 1 \mod n$ holds for any numbers $b$ relatively prime with $n$.

For any number $b$, a carmichael number $n$ verifies $$ b^n\equiv b \mod n$$

Which you can verify with WolframAlpha