Conditions for a decimal to be convertible to binary

261 Views Asked by At

All natural numbers (Base 10) can be converted to binary. No problem. But what about fractional numbers? All cannot be converted (finite expansion).

Example: $0.625$ can be converted but $0.11231$ cannot.

If I were to make a set of all those numbers which can be converted into binary, what condition should I impose on the set of all real numbers? This condition should be able to give an exhaustive list of all such numbers.

Would saying that a number reduced to it's $p/q$ form ($p$ and $q$ being coprime) should contains only powers of $2$ in the denominator be sufficient?

1

There are 1 best solutions below

0
On BEST ANSWER

You are correct. The form $p/q$ that you're talking about is called a binary fraction, which is any fraction of the form $p/2^k$ where $p$ and $k$ are both integers.