0

So I'm trying to find a solution for the equation $$(65!)^2\equiv x\:(\text{mod}\: 131)$$ I'm given the hint to use Wilson's Theorem which states, that for a prime $p$ we have $(p-1)!\equiv -1\:(\text{mod}\:p)$.

The only thing I've managed to so far is insert my number in Wilson's Theorem: So I get $(130!)\equiv -1\:(\text{mod}\: 131)$. From here on I have no idea what to do.

Any help would be appreciated. Apologies for any english errors.

Bill Dubuque
  • 272,048
SirCircle
  • 129

1 Answers1

7

$$\begin{align} 130! &\equiv130\cdot129\cdots66\cdot65\cdots2\cdot1\mod{131}\\ &\equiv(-1)\cdot(-2)\cdots(-65)\cdot65\cdots2\cdot1\mod{131}\\ &\equiv(-1)^{65}(65!)^2\mod{131}\\ &\equiv-(65!)^2\mod{131}\\ &\equiv-1\mod{131}\\ \end{align}$$ $$\therefore(65!)^2\equiv1\mod{131}$$

Peter Foreman
  • 19,947
  • This answer is written "out of order", isn't it? You start with $130!$ and show that it's congruent to $-(65!)^2$, and then you invoke the fact that $130! \cong -1$, and finally you conclude that $-(65!)^2 \cong -1$ and therefore $(65!)^2 \cong 1$. Wouldn't it be easier to follow if you started with $-(65!)^2$, manipulated that into $130!$, and then rewrote that to $-1$? – Tanner Swett Jul 18 '19 at 21:48