# Define a relation and find its equivalence classes.

Define a relation $\sim$ on $\Bbb{N}$ as follows. For any $a,b∈\Bbb N$, $a\sim b$ if and only if $ab$ is a perfect square. Show that $\sim$ is an equivalence relation. What are the equivalence classes?

So far I have $a\sim a$ so $\sim$ is reflexive, $ab\sim ba$ $\sim$ is symmetric, $ab=x^2$ and $bc=y^2$ prove $ac$ is a perfect square so $$ac =\frac{ab\cdot bc}{b\cdot b} = \frac{x^2\cdot y^2}{b^2} = \left(\frac{xy}{b}\right)^2$$ Therefore ac is square, ~ is transitive and an equivalence relation. I think you use the equation $a=b^2a'$ to find the equivalence classes but I don't know how.

• You might want to elaborate slightly on why/how $b|xy$. – The Chaz 2.0 Nov 3 '15 at 19:23
• Since ab=$x^2$ and bc=$y^2$, b is a common multiple so b|xy – Inverbe Nov 3 '15 at 19:29
• In order to find the equivalence class of a number, maybe you could try to use its prime factorization? – GBQT Nov 3 '15 at 22:39
• Wouldn't the prime factorizations go on forever? Any number to the power of 2? Or would that mean they are all the same equivalence class? – Inverbe Nov 4 '15 at 1:21

This may not be exactly what you are looking for but I think it is a good example that you could apply to your problem:

Let $x\sim y$ means $xy > 0$. Prove this is an equivalence relation. Find the subset of $\mathbb{R} \times \mathbb{R}$ which defines the relation. Find the equivalence classes.

proof: $x\sim y \Leftrightarrow xy > 0$ is an equivalence relation since it is:

1) Reflexive: $x\sim x$ since $x\times x > 0$, that is $x^{2} > 0$, which is trivially true. Although, if we have the case where $x = 0$ then $0\sim 0$ is false since $0\times 0 \ngtr 0$

2) Symmetric: If $x\sim y$ such that $xy > 0$ and $yx > 0$, we know that $xy > 0$ will be positive so either $x > 0$ and $y > 0$ or $x < 0$ and $y < 0$ since $xy > 0$ will be positive so will $yx > 0$.

3) Transitive: $x\sim y$ and $y\sim z$ implies $x\sim z$: $xy > 0$ and $yz > 0$ where $z$ is an integer. Since, $(xy)(yz) > 0$ then $xy^{2}z > 0$ since $y^{2}$ is strictly positive for any $y$, $xz > 0$.

Thus the subset that defines the relation is $\mathbb{R} \setminus \lbrace 0 \rbrace$. The equivalence classes of $x\in \mathbb{R} \setminus \lbrace 0 \rbrace$ are: $$[x] := \lbrace y\in \mathbb{R} \setminus \lbrace 0 \rbrace:xy > 0 \rbrace$$

• So my equivalence class would be [m]:={n∈ℕ:xy is a perfect square} – Inverbe Nov 4 '15 at 4:30
• That seems correct to me – Wolfy Nov 4 '15 at 13:56
• Awesome thanks! – Inverbe Nov 4 '15 at 16:34