-1

I've been stuck on this question for quite a bit of time. I have tried using euclids algorithm, solving for x, just about everything. Hints appreciated.

$$19x\equiv 341\;(\text{mod}\;401)$$

I have used Euclid's Algorithm using gcd(19,401) and then applying the extended algorithm to find 19m and 401k but it does not give me the correct solution set according to my answer book

2 Answers2

1

Well, the extended Euclidean algorithm gives $$190\cdot 19 + (-9)\cdot 401 = 1.$$ Now you see that $$190\equiv 19^{-1}\mod 401$$ and so $$x \equiv 19^{-1}\cdot 341\mod 401,$$ i.e., $$x\equiv 190\cdot 341\mod 401.$$ Thus $$x\equiv 229\mod 401.$$

Wuestenfux
  • 20,964
1

$\!\bmod 401\!:\,\ x\equiv \dfrac{341}{19}\equiv \dfrac{-60}{19}\equiv \dfrac{-60\cdot 21}{\ \ \ \underbrace{19\cdot 21}_{\large -2\ \ \ \ }}\equiv 30\cdot 21\equiv 229\ $ by Gauss's algorithm

Remark $\,\bmod a^2\!+\!1\!:\,\ \dfrac{1}{a-1}\equiv \dfrac{a+1}{-2}\ $ by $\,(a\!-\!1)(a\!+\!1)\equiv -2\,$ as above (where $\, n = 20).$

This is a prototypical "easy inverse" where Gauss's or Euclid's algorithm takes only $1$ or $2$ steps because we are inverting a factor of modulus$\pm k\,$ for very small $k$.

Bill Dubuque
  • 272,048