1
$\begingroup$

Alright, I can go through and solve equations that do not have the "$+ c$" involved, i.e.: $ax \equiv b \mod{n}$. However, I do not know what to do when a "$+ c$" is incorporated. How does that $c$ affect the final answer / the process?

My best guess would be when pulling back to integers, without "$+ c$" you would get: $ax + ny = b$.

So do I simply need to subtract the c and move it to the right hand side? $ax + ny = b - c$.

Thanks in advance!

Sean

2 Answers 2

4

Just subtract it to begin with: $ax\equiv d\pmod n$ where $d=b-c$, reducing it to a problem already solved.

2

Yes, just as for integer equations, one may subtract an integer from both sides of a congruence, i.e.

$\begin{array}{rrl} &\rm a+b &\equiv&\rm c\qquad\quad\ \rm(mod\ n) \\ \qquad\qquad\qquad\iff &\rm\ \ a+b &=&\rm c\quad\ \ \ +\ \ \ \quad k\ n &\rm for\quad k\in\mathbb Z \\ \iff &\rm\ \ a &=&\rm c\!-\!b\ \ \ +\ \ \ k\ n &\rm for\quad k\in\mathbb Z \\ \iff &\rm\ \ a &\equiv&\rm c\!-\!b\:\ \ \ \rm (mod\ n) \end{array}$