For the benefit of myself and other novices in the area, I wanted to add some details to Wilberd's excellent answer, citing Donkin's *Invariants of several matrices* and Jantzen's book *Representations of Algebraic Groups* as appropriate.

We work over a base ring $R$.

First, one checks that Donkin's definition of a "good filtration" on a $G$-module $V$ coincides with Jantzens (defined in II, 4.16). The latter uses the isomorphism $H^i(M) := R^i\text{Ind}^G_B(V)\cong H^i(G/B,\mathcal{L}(M))$ (Jantzen I, 5.12), where $B\subset G$ is a Borel, $M$ a $B$-module, and $\mathcal{L}(M)$ denotes the quasi-coherent sheaf on $G/B$ associated to $M$ (I, 5.8). If $M = R$ with trivial $G$-action, then $\mathcal{L}(R)$ is the structure sheaf $\mathcal{O}_{G/B}$.

Next, we check that the $G = \text{GL}_{n,\mathbb{Z}}$-module $M = \mathbb{Z}[n]$ has a good filtration. We use the following Lemma

**Lemma** (Appendix B.9 of Jantzen) Suppose that $R$ is a principal ideal domain. Let $M$ be a $G$-module which is free of finite rank over $R$. As explained in B.4, let $V(\lambda) := H^0(-w_0\lambda)^*)$, where $w_0$ is the longest element of the Weyl group (II, 1.5). The following are equivalent:

(i) $M$ has a good filtration.

(ii) $Ext^i_G(V(\lambda),M) = 0$ for all $\lambda\in X(T)_+$ and all $i > 0$

(iii) $Ext^1_G(V(\lambda),M) = 0$ for all $\lambda\in X(T)_+$.

(iv) For each maximal ideal $\mathfrak{m}$ in $k$, the $G_{R/\mathfrak{m}}$-module $M\otimes R/\mathfrak{m}$ has a good filtration.

We write $M[n] = \bigoplus_{d\ge 0}M[n]_d$, where $M[n]_d$ consists of the polynomials of total degree $d$. One easily checks that each $M[n]_d$ is a $\text{GL}_{n,\mathbb{Z}}$-module. We apply the lemma with $R = \mathbb{Z}$ to the $R$-finite submodules $M[n]_{\le D} := \bigoplus_{0\le d\le D} M[n]_d$ for increasing $D$. Then by (iv), it suffices to check that the $G_{\mathbb{F}_p}$-modules $\mathbb{F}_p[n]_{\le D}$ all have good filtrations. Using flat base change for $G$-module cohomology (see Jantzen I, 4.13), (ii) (or (iii)) implies that it suffices to check the existence of good filtrations over algebraically closed fields $k$. By a result of Donkin (Donkin *The normality of closures of conjugacy classes of matrices* Proposition 1.2a (i) and (ii)), good filtrations behave well with respect to direct summands, so it suffices to check that $\mathbb{Z}[n]\otimes k$ has a good filtration for any algebraically closed field $k$. This is done in $\S3$ of Donkin's *Invariants of several matrices*. Thus we conclude that $M = \mathbb{Z}[n]$ has a good filtration.

Now we work over $R = \mathbb{Z}$. Let $\lambda = 0\in X(T)$, then we have $V(0) = H^0(G/B,\mathcal{L}(0)) = H^0(G/B,\mathcal{O}_{G/B})$. Since $G/B$ is smooth proper over $\mathbb{Z}$ (use Jantzen I, 5.6(9) and I,5.7 to reduce to the classical case over algebraically closed fields), Stein factorization implies that $V(0) = \mathbb{Z}$ (with trivial $G$-action), so in particular $\lambda$ is dominant (this is II, 2.6 when $R$ is a field). By (ii) or (iii), we conclude that $Ext^1_G(\mathbb{Z},M) = H^1(G,M) = 0$. By a "universal coefficient theorem" (see Jantzen I, 4.18), vanishing of $H^1(G,M)$ implies that for any ring $R$, $\mathbb{Z}[n]^{GL_{2,\mathbb{Z}}}\otimes R = R[n]^{GL_{2,R}}$, as desired.