2

can you explain for me the arithmetic manipulation:

Let p a prime number, so

$\frac{1}{p-1}≡\frac{1}{-1}≡-1 (\text{mod}\ p)$

$\frac{1}{p-2}≡\frac{1}{-2}≡\frac{-1}{2} (\text{mod}\ p)$

$\frac{1}{p-3}≡\frac{1}{-3}≡\frac{-1}{3} (\text{mod}\ p)$

$\vdots$

$\frac{1}{p-3}≡\frac{1}{-3}≡\frac{-1}{3} (\text{mod}\ p)$

I understand that $p-k≡-k(\text{mod}\ p)$ for any natural p, but I can't figure out how to generalize for a fraction of type $\frac{1}{p-k}≡\frac{-1}{k}(\text{mod}\ p)$. I can't understand, how can you explain it?

snowfall512
  • 2,114
  • 2
    Instead of thinking of this as division, think of it as multiplication by inverses. That is $\frac{1}{a} = 1a^{-1}$, where $aa^{-1} \equiv 1$ – SquirtleSquad Aug 04 '16 at 19:59

2 Answers2

2

The integers modulo a prime form a field, which means all non-zero elements have a multiplicative inverse. To take an example, let $p=13$. Then $\frac 1{p-3}=\frac 1{10}=\frac 1{-3}$. From the fact that $10 \cdot 4=40 \equiv 1 \pmod {13}$ we can say that $\frac 1{10}=4=\frac 1{-3} \pmod {13}$

Ross Millikan
  • 374,822
1

Mod $\,n,\,$ a fraction $\,x \equiv a/b\,$ is a root of $\,bx \equiv a.\,$ It is well defined $\iff$ a root uniquely exists $\!\iff\!$ $\gcd(b,n) = 1,\,$ in which case $\,b^{-1}$ exists by Besout, so $\ a/b = ab^{-1}.$

It is easy to see that - just like for other arithmetical congruence laws - we can replace the arguments of fractions by any congruent value.

Indeed, by said congruence laws, if $\,A\equiv a,\,B\equiv b\,$ then $\, Bx\equiv A\iff ax\equiv b,\,$ hence

$$\begin{align}{A\equiv a\\ B\equiv B}\end{align}\ \Rightarrow\, \dfrac{A}B\equiv \dfrac{a}b$$

Note that if $\,B\equiv b\,$ then $\,\gcd(B,n) = \gcd(b,n) = 1\,$ so both fractions are well-defined, i.e. their denominators are invertible.

Thus in your example, $\ {\rm mod}\ n\!:\ n\!-\!1\equiv -1\,\Rightarrow\, \dfrac{1}{n-1}\equiv \dfrac{1}{-1}\equiv -1$

Bill Dubuque
  • 272,048