Let $P = Y^2 + X^2 (X - 1)^2 \in \mathbb{R}[X,Y]$.
I want to prove that $I(P)$, the ideal generated by $P$, is prime. The teacher gave us the hint "show irreducibility as a polynomial in $Y$ ".
Does this mean that if it's irreducible in both $X$ and $Y$ it is irreducible in $\mathbb{R}[X,Y]$ ? And then if the polynomial is irreducible it means the ideal is prime ?
It's for a course on Algebraic Geometry, but we always worked with $\mathbb{C}$ so the reals field is giving us a hard time.
If $P$ would be reducible, you could write it as $P=F\cdot G$ where $F$ and $G$ are polynomials of degree $1$. Note that in this case, the polynomial would stay reducible even when you insert any real number to $X$. For example, if you insert $X=2$, then you get $P(2,Y)=F(2,Y)\cdot G(2,Y)$ but $P(2,Y)=Y^2+4$ is irreducible over $\mathbb{R}$.
Edit : Note that this argument works because $F$ and $G$ are linear. In general, it is possible that when you insert a value to $P$, one of the factors disappear or it becomes a constant.