Is $n^{n-1}+(-1)^{n+1}(n-1)^{n-1}$ a squarefree number?

I am trying to prove that $f(x)=x^n+nx+n$ has Galois group $S_n$ over the rationals. The discriminant of this polynomial is $\Delta= (-1)^{n(n-1)/2}n^n(-(n-1)^{n-1}+(-1)^n n^{n-1})$. The Newton polygon of this polynomial to a prime $p|n$ is given by a line with slope $-v_p(n)/n$, hence this polynomial is irreducible. It seems that the factor $d=n^{n-1}+(-1)^{n+1}(n-1)^{n-1}$ of the discriminant is always a squarefree number, hence the question. I have read in Serre's Topics in Galois Theory the following argument, but I am not so confident to interpret if it means, that $d$ is always a squarefree number: Let $p$ be a prime $p|\Delta$, $p$ does not divide $n$, hence $p|d$. This will happen if $f(x)$ and $f'(x)$ have a common root mod $p$. We have $f'(x) = nx^{n-1}+n = 0 \text{ mod } p$, hence since $p$ does not divide $n$, we have $x^{n-1} = -1 \text{ mod } p$. Now we plug in $x^{n-1} = -1 \text{ mod } p$ in $f(x) = 0 \text{ mod } p$ and get $x = \frac{n}{1-n} \text{ mod } p$. Now the agument of Serre goes like this: "Hence there can be at most one double root $\text{mod} p$ for each ramified prime $p$ which does not divide $n$. This shows that the inertia subgroup at $p$ is either trivial, or is of order two, generated by transpositions. But $G=Gal(f)$ is generated by its inertia subgroups, because $\mathbb{Q}$ has no nontrivial unramified extension. But $G$ is transitive, since $f(x)$ is irreducible."

Does this argument prove, that $d$ is a squarefree number? I am not so confident with inertia subgroups and ramified primes.

Edit:

As it turns out when asking questions, I found a counterexample for $n=29$ and $n=47$. In this cases $d$ is nearly a squarefree number, meaning that there is a prime $q$ with $v_q(d) = 2$. Hence my modified questions are:

1) Does the argument of Serre imply that $v_q(d) \le 2$ for each prime $q$ dividing $d$?

2) How does one prove, that the $Gal(f) = S_n$ over the rationals?

• No, the argument in Serre does not prove that the factor $d$ is square-free, it proves that the polynomial has Galois group $S_n$ (since, as you note, it is irreducible). Contrary to what a quick numerical test may falsely suggest, It is not true that $d$ is always a square-free number, although the first counterexample is surprisingly large as I recall. There is a definite conjecture for the (positive) density of the values $n$ having $d$ non-square-free. I can't recall at the moment the paper that gave (and justified) this conjecture though; you could try searching it by keywords. – Vesselin Dimitrov Feb 6 '17 at 9:19
• OK, I did this myself: Squarefree values of trinomial discriminants, by David Boyd, Greg Martin and Mark Thom. See here: arxiv.org/pdf/1402.5148.pdf . The conjectured density of the values $n$ having $d$ square-free is about $0.9934466\ldots$ - so the vast majority. But even proving infinitely many square-free values appears beyond reach of current methods. – Vesselin Dimitrov Feb 6 '17 at 9:24
• But I think your main question was, why doesn't the order of $p$ dividing the discriminant of $f$ simply related to the multiplicities of the multiple roots of $f \mod{p}$? It is because the number field generated by a root $\alpha$ of the polynomial need not be monogenic: its integer ring may be larger than $\mathbb{Z}[\alpha]$. What you do know, instead, is that the discriminant of the number field $\mathbb{Q}(\alpha)$ equals $\pm n^n \cdot \mathrm{rad}(d)$ (square-free away from $n$). But the discriminant of the polynomial itself is in general a proper multiple of the discrimiant of the NF. – Vesselin Dimitrov Feb 6 '17 at 9:50
• As a specific example, when $n=279$, $d$ is divisible by $5^3$. It would be very surprising if some simple nontrivial formula produced only integers with bounded powers of each prime. – Richard Stanley Feb 6 '17 at 20:13
• As far as I know, your best reference for this might be a recent paper of Boyd, Martin and Thom, available at math.ubc.ca/~gerg/papers/downloads/SVTD.pdf – Mike Bennett Feb 7 '17 at 6:14