# How to solve a modulo congruence?

Looking for the correct method to solve a modulo congruence of the form,

$ax\equiv b(mod\ m)$

I know that the congruence is solvable if $(a,m)\ \vert \ b$. I'm just unsure of how to solve the congruence once I find that it IS solvable.

My working problem is,

$11x\equiv 21(mod\ 105)$

Thank you for the help! I'm so grateful for everyone's expertise.

Neurax

-

We want $11x = 105m+21 = 21(5m+1)$. This gives us $21 \mid x$. Hence, we have $x = 21k$. Hence, we want $11k = 5m+1$. $m=2$ and $k=1$ is a solution. Hence, $x=21$ is the smallest positive solution.
Hint $\rm\ x\,\equiv\, \dfrac{21}{11\,}\,\ (mod\,\ 5\cdot 21)\ \Rightarrow\:$ $\begin{eqnarray}\rm x&\equiv&\rm 21\,\ (mod\ 5)\ \, \\ \rm x&\equiv&\rm 21\,\ (mod\ 21)\end{eqnarray}$ $\rm\: \Rightarrow\ x\equiv 21\,\ (mod\ 5\cdot 21)$