Denominator with only 2s
- Input
- 3/8
- Expected output
- 0,375
8 = 2³: ends after 3 places.
fraction to decimal repeating or terminating
Use the Fraction to decimal mode: type 1/7, 5/12 or a mixed number and see the decimal with its repeating block in parentheses, the period length and the long division until a remainder repeats. This page explains the test that predicts the result without dividing.
8 = 2³: ends after 3 places.
Remainder 1 returns at once.
6 = 2 × 3.
12 = 2² × 3.
6 is the maximum for denominator 7.
The leading zero belongs to the block.
22/7 = 3 + 1/7.
Count the decimal places, write the digits without the point as the numerator and use 1 followed by that many zeros as the denominator. Then reduce by the gcd. Example: 0.375 has 3 places, becomes 375/1000 and, dividing by 125, 3/8. With an integer part, 2.5 = 25/10 = 5/2 = 2 1/2.
Factor the denominator: 12 = 2² × 3. The factor 3 appears, so it repeats. Two places before the block (exponent 2 of the factor 2) and a one-digit block (because of the 3): 5/12 = 0.41(6).
No, it is at most the denominator minus 1 and is often much shorter. 1/9 and 1/3 have period 1, 1/11 has 2. The maximum only happens for some primes, such as 7, 17, 19 and 97.
It computes the period length from the order of 10 modulo the denominator and shows up to 1000 digits, warning when it cuts. For giant denominators where that passes a computation limit, the length is reported as very long.
Both describe the same number. Textbooks use either the block in parentheses or a bar over the digit; the ellipsis shows only the first digits. In the notation options you choose which one appears.
| Decimal | Fraction |
|---|---|
| 0,25 | 1/4 |
| 0,(3) | 1/3 |
| 1,2(5) | 113/90 |
| -0,8 | -4/5 |
All the math happens in your browser. No number is sent to any server.