canonicalize the rational number to avoid crash
bugfix on `lt` `gt` `eq`, added `number?`