<s>[INST] Multiplication and division by an integer in systems of linear congruences I have the following system of linear congruences:
\begin{align}
x&\equiv -2 \pmod {6}\\
x&\equiv 2 \pmod {10}\\
x&\equiv 7 \pmod {15}
\end{align}
From the first equation we have: $ x= 6 k-2, k\in \mathbb{Z}$. Then we insert it into 2nd equation:
$  6 k -2 \equiv 2 (\mod 10) $   i.e.  $  6 k  \equiv  4 (\mod 10) $
from which we obtain
$ 3 k  \equiv 2 (\mod 5) $
Now at this point, is it allowed to multiply  the last congruence by 2 to get:
$ k \equiv -1  (\mod 5)   $
and conclude  $k = 5 l -1, l\in \mathbb{Z}$   and $ x = 30 n -8 , n\in \mathbb{Z}$ ?
I wonder if this is correct, is the obtained congruence equivalent to the first one? Thanks in advance.
 [/INST] Another approach:
$\begin{cases} x\equiv -2 \bmod 6\\x=2 \bmod 10\end{cases}$
$\rightarrow  6t_1-2=10t_2 +2\rightarrow 6t_1-10t_2=4 \rightarrow t_1=-10 s-1, t_2=6s -1$
Which gives:
$t_1=-10 s-1\rightarrow x=6(-10s-1)-2=-60 s -8$
$t_2=6s-1 \rightarrow x=10(6s-1)+2=60s -8$
$\begin{cases} x\equiv 7 \bmod 15\\x=2 \bmod 10\end{cases}$
$10t_3+2=15t_4+7$
which gives:
$t_3=15s_1-1\rightarrow x=10(15 s_1-1)+2=150 s_1-8$
$t_4=-10 s_1-1\rightarrow x=15(-10s_1-1)+7=-150 s_1-8$
$ lcm(6, 10, 15)=30|60, 150$, therefore:
$$x\equiv -8 \bmod 30\rightarrow x=30n -8$$
</s>