1
$\begingroup$

I am attempting to solve this question by "playing around" with the numbers so I get $46x\equiv 208\pmod {202}$ then divided by 2 since gcd = 2 to get $23x\equiv 104\pmod {202}$. I don't know how to go further from this. Have I done something wrong?

  • 4
    You need to divide the modulus out by $2$ as well.2017-01-16
  • 0
    Dividing normally by 2 is illegal; you should have 23x==104 mod 101 or 23x==3 mod 101.2017-01-16
  • 1
    As people are saying, you should divide 2 from the modulus as well. Other than that, the next step would be to find the inverse of 23 (mod 101). You may want to look up the extended Euclidean algorithm.2017-01-16
  • 0
    Thanks guys for your input, so I have now that 1=22x23 - 5x101. So 22 is the inverse of 23, do I simply now just times 22 by 3 to get 66 which is 1 solution?2017-01-16
  • 0
    @pie314271: But $104\equiv 3\pmod{101}$, so that's the same equation.2017-01-16
  • 0
    @HenningMakholm: But that's exactly what you end up getting from the equation above unfortunately. You do have a point though.2017-01-16
  • 0
    @pie314271: I don't see anything unfortunate here.2017-01-16
  • 0
    @HenningMakholm: In other words, this part is mostly useless (though it does simplify the work).2017-01-16

3 Answers 3

1

As already noticed, $$46x\equiv6\mod 2002\iff 23x\equiv 3\mod 101.$$ There remains to find the inverse of $23$ modulo $101$. This is obtained with the Extended Euclidean algorithm: \begin{array}{rrrl} \hline r_i&u_i&v_i&q_i\\\hline101&0&1\\23&1&0&4\\\hline 9&-4&1&2\\5&9&-2&1\\4&-13&3&1\\1&22&-5\\\hline \end{array} The last row yields the coefficients of a Bézout's relation between $13$ and $101$: $$22\times 23-5\times101=1,$$ whence the inverse of $23$ mod $101$: $22$, and the solution of the congruence: $$x\equiv 22\times3=66\mod 101.$$

1

You must cancel $\,2\,$ from the modulus too, as is clear by converting to equation form, i.e.

$\ 46x\equiv 6\pmod{\!202}\!\iff\! 46x\!-\!202y=6\!\!\!\overset{\,\large \div\, 2}\iff\! 23x\!-\!101y=3\!\iff\! \color{#c00}{23x\equiv 3}\pmod{\!101}$

Finally below we give a couple convenient ways to compute the fraction $\, \color{#c00}{x\equiv 3/23}\pmod{101}$

${\rm mod}\,\ 101\!:\ \ \color{#c00}{\dfrac{3}{23}}\!\!\!\overset{\ \ \ \times 4_{\phantom{._{._.}}}}\equiv\!\!\dfrac{12}{92}\equiv\,\dfrac{12}{-9}\,\equiv\, \dfrac{4}{-3}\equiv\dfrac{105}{-3}\equiv\color{#0a0}{-35}\ $ by Gauss's algorithm. $ $ Alternatively

${\rm mod}\,\ 101\!: \ \dfrac{0}{101} \overset{\large\frown}\equiv \underbrace{\color{#c00}{\dfrac{3}{23}}\overset{\large\frown}\equiv \dfrac{-12}9\equiv \color{#90f}{\dfrac{-4}3}\overset{\large\frown}\equiv \color{#0a0}{\dfrac{35}{-1}}} _{\Large \begin{align}\color{#c00}3\ \ \ \ \ -\ \ \ \ \ &8(\color{#90f}{-4})\ \ \ \ =\ \ \ \, \color{#0a0}{35}\\ \color{#c00}{23}\ \ \ \ -\ \ \ \ \ &8\ (\ \color{#90f}3\ )\ \ \ \ =\ \ \, \color{#0a0}{-1}\end{align}}\ $ by the fractional extended Euclidean algorithm

where the underbace shows the basic reduction step, i.e. perform Euclid's algorithm to reduce the denominator sequence, doing the same in parallel to the numerators (explained in the prior link). Above we also used an intermediate step (cancelling $\,3\,$ from $-12/9\,$ to get $\color{#90f}{-4/3})\,$ before applying the underlined Euclidean reduction step (cancelling $\,3\,$ is valid because $3$ is coprime to $101).$

Beware $\ $ Modular fraction arithmetic is well-defined only for fractions with denominator coprime to the modulus. See here for further discussion.

0

The congruence $46x\equiv 6\bmod{202}$ is equivalent to $$ 46x=202y+6 $$ for some integer $y$, which in turn is equivalent to $$ 23x=101y+3 $$ that is $23x \equiv 3\bmod{101}$.