Fix for #224: Fractional radical simplification

Fix for issue #224.
I noticed you had to put this code here twice. What is the reason for it and perhaps there is a way to refactor it, so that you do this only once?