fix float vs rational comparisons