$\DeclareMathOperator\GL{GL}$Let $K$ be a number field and $R$ its ring of integers. Let $G$ be a connected reductive closed subgroup of $\GL\_{n,K}$. On p55 of Brian Conrad's notes [Reductive group schemes](http://math.stanford.edu/%7Econrad/papers/luminysga3.pdf), he claims that the schematic closure $\overline{G}$ of $G$ inside $\GL\_{n,R}$ is a flat closed $R$-subgroup of $\GL\_{n,R}$.


First, I assume by schematic closure, he means the reduced induced structure on the topological closure. I can see that this closure $\overline{G}$ is an $R$-subgroup of $\GL\_{n,R}$, and that it satisfies $\overline{G}(R) = \{g\in \GL\_n(R) : g\cap \GL\_{n,K}\in G\}$, where in the brackets we view $g$ as a closed subscheme of $\GL\_{n,R}$.


Why is $\overline{G}$ necessarily flat? (Is this obvious?) Is this also true if $R$ is an arbitrary domain?



Flatness of the closure of a closed subgroup of the generic fiber of an algebraic group inside an integral model of the ambient group
$\DeclareMathOperator\GL{GL}$A colleague asked me this question some time ago and here is the answer I sent him.


Let $R$ be a domain with fraction field $K$. Let $A$ be the $R$-algebra underlying the group scheme $\GL\_{n,R}$ over $R$.


Suppose given a closed subgroup scheme $H$ of $\GL\_{n,K}$. Let $B$ be the underlying $K$-algebra of $H$.
We are then given by assumption a surjection $\phi:A\_K\to B$ and an injection $\lambda:A\to A\_K$ (given by $a \mapsto a\otimes\_K 1$). Let $\mu = \phi\circ\lambda$ and consider the $R$-module $\mu(A)$,
which is a sub-$R$-module of $B$. The following fact can be checked from the definitions: $\mu(A)$ has a natural $R$-algebra structure, compatible with the $R$-algebra structure of B via $\lambda$.
In fact the R-algebra $\mu(A)$ is (by definition) the underlying $R$-algebra of the scheme-theoretic image of $H$ in $\GL\_{n,R}$. Furthermore, we have $\mu(A)\_K\simeq B$ and
$\mu(A)$ is (clearly) torsion free.
Now consider the Hopf algebra structure of B, which is given by a morphism of $K$-modules $c:B\to B\otimes\_K B$. It is easy to see (diagram chasing) that
if $x\in \mu(A)\subseteq B$, then $c(x)$ lies in the image of the natural map $\mu(A)\otimes\_R\mu(A)\to B\otimes\_K B$. So if the natural
map $\mu(A)\otimes\_R\mu(A)\to B\otimes\_K B$ is an injection, we obtain a natural map $\mu(A)\to \mu(A)\otimes\_R\mu(A)$ and this then
(checking this is elementary) defines a Hopf algebra structure on $\mu(A)$. In particular, if the natural
map $\mu(A)\otimes\_R\mu(A)\to B\otimes\_K B$ is an injection, then the scheme-theoretic closure of $H$ in $\GL\_{n,R}$ is indeed a subgroup scheme, which is reduced if $H$ is reduced
(which is what would happen if $K$ is of characteristic 0).


So the basic condition, which must be satisfied, is that the natural map $\mu(A)\otimes\_R\mu(A)\to B\otimes\_K B$ is injective. This will be true iff
$\mu(A)\otimes\_R\mu(A)$ is torsion free. For example, if $\mu(A)$ happens to be flat over $R$ then $\mu(A)\otimes\_R\mu(A)$ will also be flat and thus torsion free.
This is what will happen if $R$ is a Dedekind domain (where torsion free is equivalent to flat) or if $R$ is a valuation ring (where again torsion free is equivalent to flat).
So if we work over either of these two rings, then the scheme-theoretic closure of $H$ in $\GL\_{n,R}$ is indeed a subgroup scheme and it is even flat over $R$.


