Originally Posted by

**rpatel** how did you calculate the equivalence classes because i know that some being mod 7 means it divisble by some multiple of 7 and remainder is written in the front of the mod7. hence 34=6mod7 since 34-(7x4)=6.

but i don't understand how you've done it in terms of x and y. and also could you please explain the sqaure bracket notation for the equivalence classes. I have seen this notation before but i don't understand what the number inside the brackets and the lower case power to it means.

thanks for your help

Sure thing. You may wish to memorize this extremely useful theorem:

For any two integers $\displaystyle a,b$, an integer $\displaystyle n$ divides $\displaystyle a-b$ if and only if $\displaystyle a\equiv b\mod n$.

So, if $\displaystyle 7$ divides $\displaystyle x-y$, then $\displaystyle x\equiv y\mod 7$. Similarly, if $\displaystyle 7$ divides $\displaystyle x+y$, then $\displaystyle x\equiv -y\mod 7$. And so if $\displaystyle 7$ divides *either* $\displaystyle x-y$ or $\displaystyle x+y$, then $\displaystyle x\equiv \pm y\mod 7$.

As for the notation issue, for some integers $\displaystyle k\in\mathbb{Z}^+$ and $\displaystyle n\in[0,k)$, we have the equivalence class $\displaystyle [n]_k=\{m:m\in\mathbb{Z},m\equiv n\mod k\}$ (the set of integers which, when divided by $\displaystyle k$, have a remainder of $\displaystyle n$).