The divisor of a local equation of a hypersurface is the hypersurface in certain open subset

118 Views Asked by At

Let $X$ be an integral and normal scheme and $D=[Y]$ an irreducible Weil divisor of $X$. Suppose that $x\in X$ is such that $x\in Y$ and the prime ideal $\mathfrak{p}\in \mathrm{Spec}(\mathcal{O}_{X,x})$ corresponding to $Y$ is principal, generated by $f\in \mathcal{O}_{X,x}$. Let $U$ be an open neighborhood of $x$ such that we may understand $f\in\Gamma(U,\mathcal{O}_{X})$. I want to prove that $$ D|_{U}=\mathrm{div}|_{U}(f). $$ It is clear that $D|_{U}=[Y\cap U]$ and that $\mathrm{div}|_U(f)\geq 0$. How do we know that $\mathrm{div}|_{U}(f)$ is precisely $[Y\cap U]$?