Posts

Showing posts with the label Chinese Remainder Theorem

Solve the system of linear congruences $x \equiv 2 ~(mod ~3)$ , $x \equiv 3 ~(mod ~5)$, $x \equiv 2 ~(mod ~7)$.

Example: Solve the system of linear congruences $x \equiv 2 ~(mod ~3)$, $x \equiv 3 ~(mod ~5)$, $x \equiv 2 ~(mod ~7)$. Answer:   Let $ n = 3 \cdot 5 \cdot 7 = 105, ~N_{1} = \dfrac{n}{3} = \dfrac{105}{3} = 35, ~ N_2 = \dfrac{n}{5} = \dfrac{105}{5} = 21, ~ N_3 = \dfrac{n}{7} = \dfrac{105}{7} = 15$. Now, we find solution of linear congruences $35 x_{1} \equiv 1 ~(mod ~3), ~ 2 1 x_2 \equiv 1 ~(mod ~5),  15x_3 \equiv 1 ~(mod ~7)$ We will find solution of linear congruences $35 x_{1} \equiv 1 ~(mod ~3), ~ 2 1 x_2 \equiv 1 ~(mod ~5),  15x_3 \equiv 1 ~(mod ~7)$ by trial and error method.  Firstly we find solution of linear congruence $35 x_{1} \equiv 1 ~(mod ~3)$. We will consider simple values of $x_{1}$ as $1, ~-1,~ 2,~ -2,~ \cdots $ and check which value satisfy given linear congruence $35 x_{1} \equiv 1 ~(mod ~3)$. When we take $x_{1} = 1, ~-1,~ 2,~ -2,~3, ~ -3$, we observe that $x_{1} =1, ~-1,$ are not a solution of $35 x_{1} \equiv 1 ...

State and Prove Chinese Remainder Theorem.

  Chinese Remainder Theorem . Let $n_{1},~ n_2,~ \cdots,~ n_r$ be positive integers such that $gcd(n_i, n_j) = 1$  for $i \not = j$. Then the system of linear congruences $x \equiv a_{1} ~(mod ~n_{1})$ $x \equiv a_2 ~(mod~ n_2)$ $x \equiv a_3~ (mod~ n_3)$ $\vdots$ $x \equiv a_r~ (mod ~n_r)$ has a simultaneous solution, which is unique modulo the integer  $n_{1} \cdot n_2 \cdot n_3 ~\cdots~ n_r$. P roof: Consider $n = n_{1} \cdot n_2 \cdot n_3 ~\cdots~ n_r$. Let $N_k = \dfrac{n}{n_k} = n_{1} \cdot n_2 \cdot n_3 ~\cdots~ n_{k-1} \cdot n_{k+1} ~\cdots ~n_r $ for each $k = 1, ~2, ~3,~ \cdots, ~r $ i.e. $N_k$ is the product of all the integers $n_i$; with the factor $n_k$ omitted. Since $gcd(n_i, n_j) = 1$  for $i \not = j$, we will have $gcd(N_k, n_k) = 1$. By Theorem , the  linear congruence $N_k ~x \equiv 1 ~(mod ~n_k)$, has a solution; call the unique solution $x_k$. We claim that the integer  $\bar{x} = a_{1} \cdot N_...