Let $G\subset S_n$ be a permutation group, and let it act on $R = \mathbb{Z}[x_1,\dots,x_n]$ by permuting the variables, as usual. $G$ acts on $R\otimes_\mathbb{Z} S$ for any unital ring $S$ via its action on $R$.
Does $R^G\otimes S = (R\otimes S)^G$ always?
In general, taking invariants doesn't commute with base change, but in the present case, it seems to me it should: after all, the action of $G$ has "nothing to do" with the choice of coefficient ring, i.e. "works the same" regardless of the coefficients. But this is very fuzzy logic so I want to know if I'm missing something.
I would appreciate a proof, reference, or counterexample.
Let $B$ be the set of monomials in $x_1,\ldots,x_n$. $R$ is merely a free $\Bbb Z$-module with basis $B$.
The action of $G$ corresponds to permutations on $B$, let $B/G$ be the set of orbits of $B$ under $G$. There is an obvious map $B/G \to R$ (obtained by summing the monomials of the orbits together).
If you remove from $B$ one representant of each orbit to get a set $B'$, then $R$ is the free $\Bbb Z$-module generated by $(B/G \cup B')$, and $R^G$ is its free submodule generated by $B/G$
Then $R \otimes S$ is the free $S$-module generated by $(B/G \cup B')$ and $(R \otimes S)^G$ and $R^G \otimes S$ both are its free submodule generated by $B/G$.