change fixednum to math_view::fixed and clean up code