Fixes issue8666 solvers
both lhs and rhs should be checked in solve
Merge pull request #8684 from aktech/issue8666

Solve returns correct solution for Equations where denominator becomes 0 (fixes #8666)