if the Hilbert polynomial of coherent sheaf is constant number,then locally free? I'm reading "The Geometry of Moduli Spaces of Sheaves" (Huybrechts Lehn).
I want to prove [$\operatorname{Quot}_{X/S}(H,l)=\operatorname{Grass}_S(H,l)$]where $X=S$ and $l$ is a number.
Let $T$ be an $S$-scheme and $[\rho:H_T \rightarrow F]\in Q(T)$ where $F$ is flat over $T$ with Hilbert polynomial $P=l$,
then $F$ is locally free with rank $l$?
 A: In fact any flat coherent sheaf is locally free; see Tag 00NX implication $(1) \Rightarrow (6)$ for the corresponding algebra statement.
Thus, if $\mathscr F$ is flat over $T$, then $\mathscr F$ is locally free over $T$. But because $X_T \to T$ is an isomorphism, we conclude that $\mathscr F$ is locally free on $X_T$ (rather than on $T$). This is the step for which we crucially need that $X = S$.
By assumption, the Hilbert polynomial of each fibre $\mathscr F|_{X_t} = \mathscr F \otimes_{\mathcal O_T} \kappa(t)$ is $\ell$ . Hence, $\mathscr F \otimes_{\mathcal O_T} \kappa(t)$ is an $\ell$-dimensional vector space over $\kappa(t)$. It is then easy to see that the rank of $\mathscr F$ at $t$ is $\ell$.
(Note that the fibres of $X_T \stackrel \sim\to T$ are just points, so for any coherent sheaf $\mathscr F$ on $T$, the Hilbert polynomial of the fibre $\mathscr F|_{X_t} = \mathscr F \otimes_{\mathcal O_T} \kappa(t)$ has degree $\leq 0$, i.e. is constant. This corresponds to the fact that coherent sheaves on the spectrum of a field are just finite-dimensional vector spaces, so the only numerical invariant is their dimension.)
(Note that the rank is a priori only locally constant. But you assume that the Hilbert polynomial is constant, which forces the rank to be constant.)

Remark. Of course the situation is different once we start considering Quot schemes $\mathfrak Quot_{X/S}$ where $X$ is no longer equal to $S$: then $\mathscr F$ is a sheaf on $X_T$ which is only flat over $T$, so the above method does not give us much.
