prove $x = (b-a) \mod m$

43 Views Asked by At

If $(ai+x)\mod m = b $ then how can we prove that $x = (b-a)\mod m$?

If it is not correct then what is correct value for $x$?

1

There are 1 best solutions below

0
On

Just use Definitions.

$A\equiv B\pmod m$ means $m|A-B$ means there exists an integer $k$ so that $mk = A- B$ means there exists an integer so that $A = B + mk$.

So if $ai+x \equiv b \pmod m$ then there exists a $k$ so that $ai+x = b + mk$, but then there exists an integer $k$ so that $x=b - ai + mk$. So $x\equiv b-ai\pmod m$.