<s>[INST] Prove that $\frac{x^2}{x^2 + y^2}$ is irreducible in $\Bbb{Q}[x,y,\frac{1}{x^2+y^2}]_0$ I was doing Vakil's FOAG, in exercise 5.4 N needs to investigate an important example that $\Bbb{Q}[x,y,\frac{1}{x^2+y^2}]_0$ is not UFD (where we take localization of $\Bbb{Q}[x,y]$ at $x^2+y^2$ and take the degree zero part of it).
Ravi gives an example :
$$(\frac{x^2}{x^2+y^2})(\frac{y^2}{x^2+y^2}) = (\frac{xy}{x^2+y^2})^2$$
However I have some difficulty in showing $\frac{x^2}{x^2+y^2}$ is irreducible, notice that is not irreducible in $\Bbb{Q}[x,y,\frac{1}{x^2+y^2}]$ but the example indicate that it is irreducible in the degree zero part of $\Bbb{Q}[x,y,\frac{1}{x^2+y^2}]$. in this case we may have to prove it by definition?
 [/INST] We have $p / (x^2 + y^2)^m * q / (x^2 + y^2)^n = x^2 / (x^2 + y^2)$. Rearranging, we get $pq = x^2 (x^2 + y^2)^{m+n-1}$. Assume that neither $p$ nor $q$ are divisible by $x^2+y^2$. Note that as $p / (x^2 + y^2)^m $ has degree 0 and $deg(p) \geq 0$, $m$ cannot be negative, and similarly for $n$.
Now, $\mathbb{Q}[x,y]$ is a UFD and $x^2 + y^2$ is irreducible in it. Since $x^2 + y^2$ does not divide $pq$, it cannot divide the right side either, so $m+n-1 = 0$. WLOG let $m = 1, n = 0$, so $p$ has degree 2 and $q$ has degree 0.
This implies $q$ is invertible.
</s>