simplify boolean expressions