@eyorble's solution can already yield great results, especially when dealing with inequalities. My main idea is similar to @eyorble's, but with more generalization and simplification.
Step 0: Create a fast FindInstance
The problem with FindInstance is that it will try to find exact solutions, which significantly slow down the computation and might leave out some solutions. So here we first test the inequality by substituting variables with random numbers. In this case, because all functions are of the same order, we can simply use var = RandomReal[{0, 1}, Length@var];. But in other use cases, you might want to tune the random function for better performance.
myFindInstance[eqn_, var_, dom_] :=
Catch[Block[var,
Do[var = RandomReal[{0, 1}, Length@var];
If[eqn, Throw[1]], {10000}];];
TimeConstrained[
Throw@Length@
FindInstance[eqn && (And @@ Thread[0. < var]), var, dom,
WorkingPrecision -> 15, RandomSeeding -> Automatic]
, 2, Throw@0]
]
myFindInstance returns 0 if no instance is found, and returns 1 otherwise.
Step 1: Test inequalities and determine equations' relationship
First we shall define function edge as follows:
edge[{0, 1, 0}, i_, j_] := {Labeled[DirectedEdge[i, j], Equal],
Labeled[DirectedEdge[j, i], Equal]};
edge[{1, 0, 0}, i_, j_] := Labeled[DirectedEdge[j, i], Greater];
edge[{0, 0, 1}, i_, j_] := Labeled[DirectedEdge[i, j], Greater];
edge[{1, 1, 0}, i_, j_] := Labeled[DirectedEdge[j, i], GreaterEqual];
edge[{0, 1, 1}, i_, j_] := Labeled[DirectedEdge[i, j], GreaterEqual];
edge[___] := Nothing;
where the first parameters are the result of myFindInstance with (in)equality {eqn1<eqn2, eqn1==eqn2, eqn1>eqn2} and the second are the id of these two equations.
Then, we try to construct a relation graph between these equations:
gsss = Block[{g = Graph[Range@Length@sets, {}], symb, e},
Do[
If[Length[FindShortestPath[g, i, j]] ==
Length[FindShortestPath[g, j, i]] == 0,
e = edge[
myFindInstance[#[sets[[i]], sets[[j]]],
DeleteDuplicates@Cases[sets[[{i, j}]], _Symbol, Infinity],
Reals] & /@ {Less, Equal, Greater}, i, j];
If[e =!= Nothing, g = EdgeAdd[g, e[[1]]];
PropertyValue[{g, e[[1]]}, EdgeLabels] = e[[2]];
PropertyValue[{g, e[[1]]}, EdgeWeight] = -1]
], {i, Length[sets] - 1}, {j, i + 1, Length@sets}]; g]
Here we can reduce the computation by utilizing the fact that if a>=b and b>=c, then a>=c is automatically guaranteed (the FindShortestPath part).
Step 2: Find the longest possible chain
We can use a trick in this step: if we set EdgeWeight of each vertex to -1 then the shortest path will actually be the longest chain! so the code for finding the longest chain is simple:
FindShortestPath[gsss, ##] & @@@ With[{dm = GraphDistanceMatrix[gsss]}, Position[dm, Min@dm]]
Step 3: Visualization
No explanation.
Column[Inequality @@ (Riffle[sets[[#]],
MovingMap[
PropertyValue[{gsss, DirectedEdge[#[[1]], #[[2]]]},
EdgeLabels] &, #, 1]]) & /@ (FindShortestPath[gsss, ##] & @@@
With[{dm = GraphDistanceMatrix[gsss]}, Position[dm, Min@dm]])]
The result will be something like:
$\begin{array}{l}
a^3+b^3+c^3\geq \frac{\left(a^2+b^2+c^2\right)^2}{a+b+c}\geq \frac{1}{2} \left(a^2 b+a^3+a c^2+b^2 c+b^3+c^3\right)\geq \frac{1}{3} (a+b+c) \left(a^2+b^2+c^2\right)\geq \frac{(a b+a c+b c) \left(a^2+b^2+c^2\right)}{a+b+c}\geq \frac{1}{3} (a+b+c) (a b+a c+b c)\geq \frac{(a b+a c+b c)^2}{a+b+c} \\
a^3+b^3+c^3\geq \frac{\left(a^2+b^2+c^2\right)^2}{a+b+c}\geq \frac{1}{2} \left(a^2 b+a^3+a c^2+b^2 c+b^3+c^3\right)\geq \frac{1}{3} (a+b+c) \left(a^2+b^2+c^2\right)\geq \frac{(a b+a c+b c) \left(a^2+b^2+c^2\right)}{a+b+c}\geq \frac{1}{3} (a+b+c) (a b+a c+b c)\geq \frac{a b c (a+b+c)^2}{a b+a c+b c} \\
\end{array}$
There are two possible longest chains with a length of 7. The chains are longer than @eyorble's solution, and I am not quite sure whether they are correct, but hey, at least I'm unable to find any counter-example using Mathematica.
The complete code is as follows:
sets = {a^3 + b^3 + c^3,
a b^2 + a^2 c +
b c^2, (a^2 + b^2 + c^2)^2/(a + b + c), (a b + a c + b c)^2/(a +
b + c), (a b c (a + b + c)^2)/(a b + a c +
b c), (a^4 + b^4 + c^4)^2/(a^5 + b^5 +
c^5), (a^5 + b^5 + c^5)^2/(a^7 + b^7 + c^7),
1/3 (a + b + c) (a b + a c + b c), (3 (a b^3 + a^3 c + b c^3))/(a +
b + c), (3 (a^3 b + b^3 c + a c^3))/(a + b +
c), (3 a b c (a^2 + b^2 + c^2))/(a b + a c + b c),
1/3 (a + b + c) (a^2 + b^2 +
c^2), (3 (a^2 b^2 + a^2 c^2 + b^2 c^2))/(a + b + c),
a^2 b + a b^2 + a^2 c - 3 a b c + b^2 c + a c^2 + b c^2,
1/2 (a^2 b + 3 a b c + b^2 c + a c^2),
1/2 (a b^2 + a^2 c + 3 a b c +
b c^2), (a b c (a^2 + b^2 + c^2)^2)/(a^2 b^2 + a^2 c^2 +
b^2 c^2), 1/2 (a^3 + a^2 b + b^3 + b^2 c + a c^2 + c^3),
1/2 (a^3 + a b^2 + b^3 + a^2 c + b c^2 +
c^3), ((a b + a c + b c) (a^2 + b^2 + c^2))/(a + b + c)};
myFindInstance[eqn_, var_, dom_] :=
Catch[Block[var,
Do[var = RandomReal[{0, 1}, Length@var];
If[eqn, Throw[1]], {10000}];];
TimeConstrained[
Throw@Length@
FindInstance[eqn && (And @@ Thread[0. < var]), var, dom,
WorkingPrecision -> 15, RandomSeeding -> Automatic]
, 2, Throw@0]
]
edge[{0, 1, 0}, i_, j_] := {Labeled[DirectedEdge[i, j], Equal],
Labeled[DirectedEdge[j, i], Equal]};
edge[{1, 0, 0}, i_, j_] := Labeled[DirectedEdge[j, i], Greater];
edge[{0, 0, 1}, i_, j_] := Labeled[DirectedEdge[i, j], Greater];
edge[{1, 1, 0}, i_, j_] := Labeled[DirectedEdge[j, i], GreaterEqual];
edge[{0, 1, 1}, i_, j_] := Labeled[DirectedEdge[i, j], GreaterEqual];
edge[___] := Nothing;
gsss = Block[{g = Graph[Range@Length@sets, {}], symb, e},
Do[
If[Length[FindShortestPath[g, i, j]] ==
Length[FindShortestPath[g, j, i]] == 0,
e = edge[
myFindInstance[#[sets[[i]], sets[[j]]],
DeleteDuplicates@Cases[sets[[{i, j}]], _Symbol, Infinity],
Reals] & /@ {Less, Equal, Greater}, i, j];
If[e =!= Nothing, g = EdgeAdd[g, e[[1]]];
PropertyValue[{g, e[[1]]}, EdgeLabels] = e[[2]];
PropertyValue[{g, e[[1]]}, EdgeWeight] = -1]
], {i, Length[sets] - 1}, {j, i + 1, Length@sets}]; g]
Column[Inequality @@ (Riffle[sets[[#]],
MovingMap[
PropertyValue[{gsss, DirectedEdge[#[[1]], #[[2]]]},
EdgeLabels] &, #, 1]]) & /@ (FindShortestPath[gsss, ##] & @@@
With[{dm = GraphDistanceMatrix[gsss]}, Position[dm, Min@dm]])]
Graphmight help: The vertices are the expressions and you add a directed edge for each proven inequality. Then graph-based algorithms should be able to compute a longest chain efficiently... – Henrik Schumacher Apr 12 '20 at 11:16