Improve 'simplify' function
Merge pull request #22 from magistere/simplify

Improve 'simplify' function