Lemma 31.18.5. Let $f : X \to S$ be a morphism of schemes. Let $D \subset X$ be a relative effective Cartier divisor on $X/S$. If $x \in D$ and $\mathcal{O}_{X, x}$ is Noetherian, then $f$ is flat at $x$.

Proof. Set $A = \mathcal{O}_{S, f(x)}$ and $B = \mathcal{O}_{X, x}$. Let $h \in B$ be an element which generates the ideal of $D$. Then $h$ is a nonzerodivisor in $B$ such that $B/hB$ is a flat local $A$-algebra. Let $I \subset A$ be a finitely generated ideal. Consider the commutative diagram

$\xymatrix{ 0 \ar[r] & B \ar[r]_ h & B \ar[r] & B/hB \ar[r] & 0 \\ 0 \ar[r] & B \otimes _ A I \ar[r]^ h \ar[u] & B \otimes _ A I \ar[r] \ar[u] & B/hB \otimes _ A I \ar[r] \ar[u] & 0 }$

The lower sequence is short exact as $B/hB$ is flat over $A$, see Algebra, Lemma 10.39.12. The right vertical arrow is injective as $B/hB$ is flat over $A$, see Algebra, Lemma 10.39.5. Hence multiplication by $h$ is surjective on the kernel $K$ of the middle vertical arrow. By Nakayama's lemma, see Algebra, Lemma 10.20.1 we conclude that $K= 0$. Hence $B$ is flat over $A$, see Algebra, Lemma 10.39.5. $\square$

In your comment you can use Markdown and LaTeX style mathematics (enclose it like $\pi$). A preview option is available if you wish to see how it works out (just click on the eye in the toolbar).