[prev] 60 [next]

Fractions in different Bases (cont)

If we want to convert 0.75 in decimal to binary, it may be easy to look and and realise we need 0.5 + 0.25 which gives us 0b0.11. Sometimes it is not that easy and we need a systematic approach.

The algorithm to convert a decimal fraction to another base is:

  • take the fractional component and multiply by the base
  • the whole number becomes the next digit to the right of the radix point in our fraction.
  • We now disregard the whole number part of the previous result and repeat this process until the fractional part becomes exhausted or we have sufficient digits (this process is not guaranteed to terminate).