Lemma 31.22.3. Let $f : X \to S$ be a morphism of schemes. Let $Z \to X$ be a relative quasi-regular immersion. If $x \in Z$ and $\mathcal{O}_{X, x}$ is Noetherian, then $f$ is flat at $x$.

Proof. Let $f_1, \ldots , f_ r \in \mathcal{O}_{X, x}$ be a quasi-regular sequence cutting out the ideal of $Z$ at $x$. By Algebra, Lemma 10.69.6 we know that $f_1, \ldots , f_ r$ is a regular sequence. Hence $f_ r$ is a nonzerodivisor on $\mathcal{O}_{X, x}/(f_1, \ldots , f_{r - 1})$ such that the quotient is a flat $\mathcal{O}_{S, f(x)}$-module. By Lemma 31.18.5 we conclude that $\mathcal{O}_{X, x}/(f_1, \ldots , f_{r - 1})$ is a flat $\mathcal{O}_{S, f(x)}$-module. Continuing by induction we find that $\mathcal{O}_{X, x}$ is a flat $\mathcal{O}_{S, s}$-module. $\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).