Binary Fraction Converter
Convert numbers with fractions between decimal and binary representations with step-by-step math and customizable bit precision.
What Is a Binary Fraction?
A binary fraction represents the fractional or non-integer portion of a number in base-2 (binary) positional notation. While standard decimal fractions express values using negative powers of 10 ($10^{-1} = 0.1$, $10^{-2} = 0.01$, $10^{-3} = 0.001$), binary fractions express fractional magnitudes as sums of negative powers of 2:
$$2^{-1} = \frac{1}{2} = 0.5, \quad 2^{-2} = \frac{1}{4} = 0.25, \quad 2^{-3} = \frac{1}{8} = 0.125, \quad 2^{-4} = \frac{1}{16} = 0.0625$$
For instance, the binary fractional number $(0.1101)_2$ represents:
$$(0.1101)_2 = (1 \times 2^{-1}) + (1 \times 2^{-2}) + (0 \times 2^{-3}) + (1 \times 2^{-4}) = 0.5 + 0.25 + 0 + 0.0625 = 0.8125_{10}$$
How to Convert Decimal Fractions to Binary
Converting a decimal fraction to binary follows the repeated multiplication-by-2 method:
- Take the fractional part of your decimal number.
- Multiply the fractional part by 2.
- The integer portion of the product (either 0 or 1) becomes the next binary fractional bit.
- Subtract the integer part to keep only the new fractional remainder.
- Repeat the multiplication until the remainder reaches 0 or until you reach the desired precision in bits.
Let us convert $0.625_{10}$ into binary:
- $0.625 \times 2 = 1.25$ → Record bit 1, remainder is $0.25$
- $0.25 \times 2 = 0.50$ → Record bit 0, remainder is $0.50$
- $0.50 \times 2 = 1.00$ → Record bit 1, remainder is $0.00$ (Terminated)
Combining the recorded bits gives $(0.101)_2$.
Finite vs Repeating Binary Fractions
In base 10, a fraction has a terminating decimal expansion only if its simplified denominator has prime factors of 2 and 5. In base 2, a fractional number terminates if and only if its denominator is a pure power of 2 ($2^k$).
Fractions like $\frac{1}{10} = 0.1_{10}$ or $\frac{1}{3} \approx 0.3333$ become infinite repeating binary fractions ($0.1_{10} = 0.0001100110011..._2$). This is the mathematical reason behind floating-point precision rounding in computers.
Related Binary Tools
Explore other helpful digital logic and base conversion calculators:
- Binary Calculator: Perform addition, subtraction, multiplication, and division on binary numbers.
- Decimal Binary Converter: Convert integer decimal values to base-2 binary format.
- Bitwise Calculator: Compute AND, OR, XOR, NOT, and bit shifts.
Frequently Asked Questions
Can every decimal fraction be represented exactly in binary?
No. Only decimal fractions whose simplified denominator is a power of 2 (such as 1/2, 1/4, 3/8, 13/16) have terminating, exact representations in binary. Other decimal fractions (like 0.1 or 0.2) result in infinitely repeating binary fractions.
How is the binary point different from a decimal point?
The binary point serves the identical positional function as the decimal radix point, but positions to its right represent decreasing powers of two (2^-1 = 0.5, 2^-2 = 0.25, 2^-3 = 0.125) rather than tenths, hundredths, and thousandths.
What is 0.5 in binary fraction?
The decimal number 0.5 equals exactly 0.1 in binary because 1 * 2^-1 = 0.5.
How do floating-point numbers store binary fractions?
Standard IEEE 754 floating-point numbers represent values in scientific notation with a sign bit, an exponent (power of 2), and a mantissa (fractional binary significand with an implicit leading 1).