# Simplification of expressions?

The expression below

fd < S &&  ld > e || fs > s && ld > e || fd > s && ld < e || fd < s && ld < e


Is the same as this...

fd < e && ld > s


But how can I simplify the first into the second? The first one was easily constructed by looking at a generalized version of my data. The second was a bit more tricky to figure out.

• Is that upper-case "S" in the first sub-expression the same as lower-case "s" in the other ones? And is "fd" a variable or the multiplication (AND-ing) of "f" and "d"? – Rory Daulton Dec 10 '14 at 0:38

The expressions are not equivalent. The top one is equivalent to $\mathit{fd}\ne s\land\mathit ld\ne e$.
So a counterexample would be $\mathit{fd}=1$, $e=2$, $\mathit{ld}=3$, $s=4$, which makes the upper expression true (because the first disjuct is), but the lower one false (because $\mathit{ld}>s$ fails).