Prove the following inequality $\sum_{i<j<k}\frac{a_ia_ja_k}{(n-2)(n-1)n}\le \bigg(\sum_{i<j}\frac{a_ia_j}{(n-1)n}\bigg)^2+\frac{1}{12}$

Let $\sum\limits_{i=1}^{n-1}a_i=(n-1)u,$ $\sum\limits_{1\leq i<j\leq n-1}a_ia_j=\frac{(n-1)(n-2)}{2}v^2$ and $\sum\limits_{1\leq i<j<k\leq n-1}a_ia_ja_k=\frac{(n-1)(n-2)(n-3)}{6}w^3.$

Thus, we need to prove that $$\frac{\frac{(n-1)(n-2)(n-3)w^3}{6}-(n-1)u\cdot\frac{(n-1)(n-2)v^2}{2}}{(n-2)(n-1)n}\leq\left(\frac{\frac{(n-1)(n-2)v^2}{2}-(n-1)^2u^2}{(n-1)n}\right)^2+\frac{1}{12}$$ or $$3(2(n-1)u^2-(n-2)v^2)^2+n^2\geq2n((n-3)w^3-3(n-1)uv^2).$$ Now, by AM-GM we obtain: $$3(2(n-1)u^2-(n-2)v^2)^2+n^2\geq4\sqrt[4]{(2(n-1)u^2-(n-2)v^2)^6n^2}.$$ and it's enough to prove that: $$2\sqrt{(2(n-1)u^2-(n-2)v^2)^3}\geq\sqrt{n}((n-3)w^3-3(n-1)uv^2).$$ Now, we know that $a_1,$ $a_2,$...$a_{n-1}$ are roots of the equation: $$\prod_{i=1}^{n-1}(x-a_i)=0$$ or $$x^{n-1}-(n-1)ux^{n-2}+\tfrac{(n-1)(n-2)v^2}{2}x^{n-3}-\tfrac{(n-1)(n-2)(n-3)w^3}{6}x^{n-4}+...=0,$$ which says that the equation $$\left(x^{n-1}-(n-1)ux^{n-2}+\tfrac{(n-1)(n-2)v^2}{2}x^{n-3}-\tfrac{(n-1)(n-2)(n-3)w^3}{6}x^{n-4}+...\right)^{(n-4)}=0$$ or $$x^3-3ux^2+3v^2x-w^3=0$$ has three real roots.

Let $p$, $q$ and $r$ are roots of the last equation.

Thus, $$p+q+r=3u,$$ $$pq+pr+qr=3v^2$$ and $$pqr=w^3.$$

Id est, it's enough to prove that: $$2\sqrt{(2(n-1)u^2-(n-2)v^2)^3}\geq\sqrt{n}((n-3)w^3-3(n-1)uv^2)$$ as an inequality of three variables $p$, $q$ and $r$, for which it's enough to prove this inequality for a maximal value of $w^3,$ which by $uvw$ it's enough to make for an equality case of two variables.

Since the last inequality is homogeneous, symmetric, with non-negative left side and for $q=r=0$ is obvious, it's enough to assume $q=r=1,$ which gives: $$2\sqrt{\left(\frac{2(n-1)(p+2)^2}{9}-\frac{(n-2)(2p+1)}{3}\right)^3}\geq\sqrt{n}\left((n-3)p-\frac{(n-1)(p+2)(2p+1)}{3}\right),$$ for which it's enough to prove that $$4\left(\frac{2(n-1)(p+2)^2}{9}-\frac{(n-2)(2p+1)}{3}\right)^3\geq n\left((n-3)p-\frac{(n-1)(p+2)(2p+1)}{3}\right)^2$$ or $$(p-1)^2((n-1)p+2n+1)^2(n(8p^2+8p+11)-8(p-1)^2)\geq0,$$ which is true because $$n(8p^2+8p+11)-8(p-1)^2\geq3(8p^2+8p+11)-8(p-1)^2=(4p+5)^2\geq0.$$

About $uvw$ see here: https://artofproblemsolving.com/community/c6h278791


With $$ u = \frac{1}{n(n-1)}\sum_{i<j} a_i a_j \, , \quad v = \frac{1}{n(n-1)(n-2)}\sum_{i<j<k} a_i a_j a_k $$ the goal to to show that $$\tag 1 v \le u^2 + \frac {1}{12} \, . $$

We can assume that $v > 0$ because otherwise the inequality holds trivially. The polynomial $$ p(x) = (x-a_1)\cdots (x-a_n) = x^n + n(n-1)u x^{n-2} - n(n-1)(n-2)v x^{n-3} + \ldots $$ has $n$ real roots. $(n-3)$-fold application of Rolle's theorem shows that the cubic polynomial $$ p^{(n-3)}(x) = n(n-1)\cdots 4 \cdot\left( x^3 + 6u x - 6v\right) $$ has three real roots. It follows that the discriminant $ \Delta = -4 \left(6u \right)^3 - 27 \left( 6v \right)^2 $ is non-negative, i.e. $$ \tag 2 v^2 \le -\frac{8}{9} u^3 \, . $$

It remains to show that $(2)$ implies the desired inequality $(1)$. We see that $u$ must be negative, so that $u = -\sqrt{t}$ for some $t > 0$. Then $(2)$ becomes $$ v \le \frac{\sqrt{8}}{3} t^{3/4} $$ and in order to get $(1)$ it suffices to show that $$ \frac{\sqrt{8}}{3} t^{3/4} \le t + \frac{1}{12} \, . $$ This is an elementary calculation: The difference $$ f(t) = \frac{\sqrt{8}}{3} t^{3/4} - t - \frac{1}{12} $$ is maximal at $t^*= 1/4$ with $f(t^*) =0$. This concludes the proof.


One can also see that equality holds exactly if $t=1/4$ and $\Delta = 0$, that is if $$ \begin{align} u &= \frac{1}{n(n-1)}\sum_{i<j} a_i a_j = -\frac 12 \, ,\\ v &= \frac{1}{n(n-1)(n-2)}\sum_{i<j<k} a_i a_j a_k = \frac 13 \, . \end{align} $$