sympy/sympy — pull request #2044 by jrioux (2013-04-26 13:42:28+00:00)
Title: Solve of Piecewise functions.

Don't rely on bool(Relational) in the Piecewise solver. Also, check that the solution is valid i.e. Piecewise conditions are satisfied.

Fixes issue 2961: `__nonzero__` method of Rel breaks solve of Piecewise functions
http://code.google.com/p/sympy/issues/detail?id=2961