Let $\mathcal{I}$ be the vanishing ideal. I understand that $\mathcal{I}(A\cup B)=\mathcal{I}(A)\cap\mathcal{I}(B)$ where $A,B\subset \mathbb{A}^n$. For any collection of subsets $X_i$ of $\mathbb{A}^n$, I find it hard to show that $\mathcal{I}(\bigcup_iX_i)=\bigcap_i\mathcal{I}(X_i)$.
Since $X_i\subset\bigcup_iX_i$, it is easy to check that $\mathcal{I}(\bigcup_iX_i)\subset\mathcal{I}(X_i)$. Then $\mathcal{I}(\bigcup_iX_i)\subset\bigcap_i\mathcal{I}(X_i)$.
How about reverse inclusion? Can I solve this question by induction? I can easily extend this conclusion to any finite cases by induction, which means it is easy to check that $$\mathcal{I}(\bigcup_{i=1}^n X_i)=\bigcap_{i=1}^n\mathcal{I}(X_i).$$ But for infinite cases, I’ve tried it hard but failed. I’m learning commutative algebra at the beginning so this question may be simple but still unskillful. I’d be grateful if you could help me out!
I don't see what is the problem.
Assume that $f \in \cap_i \mathcal{I}(X_i)$. Then, $f$ vanishes at all points of every $X_i$. Hence, $f$ vanishes at every point of $\cup_i X_i$.