<s>[INST] Prove $abc+abd+acd+bcd\le\frac{1}{27}+\frac{176abcd}{27}$ for $a+b+c+d=1$ 
Let $a,b,c$, and $d$ be four positive reals satisfying $a+b+c+d=1$. Show that
$$abc+abd+acd+bcd\le\frac{1}{27}+\frac{176abcd}{27}.$$

I tried the inequality between $27abc$ and $(a+b+c)^3$ but it didn't help me
 [/INST] Inspired by https://math.stackexchange.com/a/1748125/823641.

Define $f(a,b,c,d) = abc+abd+acd+bcd - \frac{1}{27} - \frac{176abcd}{27}$.
We have $f(1/4,1/4,1/4,1/4) = 0$.
We shall show that $f(1/4,1/4,1/4,1/4)$ is the maximum among all $a,b,c,d$ satisfying the conditions.
Suppose not, and assume that another value of $(a,b,c,d) = (x,y,z,w) \neq (1/4,1/4,1/4,1/4)$ corresponds to the maximum $f(x,y,z,w)$.
WLOG, we assume that $x \neq y$.
We have
\begin{align}
&f(\frac{x+y}{2},\frac{x+y}{2},z,w) - f(x,y,z,w) \\
=~&(x-y)^2(z+w)/4 - \frac{176zw}{27 * 4}(x-y)^2 \\
=~& \frac{(x-y)^2}{4}(z+w-\frac{176zw}{27}),
\end{align}
where
$$\frac{(x-y)^2}{4} > 0.$$
If $z+w-\frac{176zw}{27} > 0$ then we are done because in that case we have $f(\frac{x+y}{2},\frac{x+y}{2},z,w) > f(x,y,z,w)$, completing the proof by contradicting the assumption of maximality.
Now, we assume that
$z+w-\frac{176zw}{27} \leq 0$,
then we have
$$f(x,y,z,w) = xy(z+w - 176zw/27) + (x+y)zw - 1/27$$
$$\leq (x+y)zw - 1/27 \leq (1 - t)t^2/4 - 1/27,$$
where we have used the Cauchy–Schwarz inequality and $t = z+w$.
Let $g(t) = (1 - t)t^2/4 - 1/27$.
It is easy to check (by $g'(t)$) that $g(t)$ achieves its maximum at $t = 2/3$ with $g(t) = 0$.
Therefore, we have $f(x,y,z,w) \leq 0$, completing the proof.
</s>