How To Get A Fraction To A Decimal
Fractions and Decimals
This page is about converting a fraction (i.e. a ratio of two numbers, also called a rational number) into a decimal fraction and the patterns that occur in such a decimal fraction. It is interactive and you can use the calculators on this page to investigate fractions for yourself to many decimal places. No special knowledge beyond decimals and division is required.The calculators on this page require JavaScript but you appear to have switched JavaScript off (it is disabled). Please go to the Preferences for this browser and enable it if you want to use the calculators, then Reload this page.
Contents of this page
The icon means there is a Things to do section of questions to start your own investigations. The calculator icon indicates that there is a live interactive calculator in that section.
Changing a Fraction into a Decimal number
Converting a fraction to a decimal is just a division operation. So the fraction 1/2 means 1÷2.When we do the long division (or use a calculator!) we find 1÷2=0·5. This fraction was easy - just one digit and we are done.
Some examples and patterns
People have always been fascinated by the patterns in decimal fractions, trying to find the order in the seeming chaos and intrigued by the sequences. When we make a table of the first few reciprocals of the numbers 2,3,..., that is when we turn the whole numbers upside down: from 2=2/1, 3=3/1, 4=4/1,... to 1/2, 1/3, 1/4, ... we get the following:
|
|
Three types of decimal fractions
- In the table we can see that some decimal fractions stop after a few decimal places - those in the left-hand columns - such as 1/2, 1/4, 1/5, 1/8.
These are called terminating decimals. - But others become an endlessly repeating cycle of the same digits - those in the right-hand columns - such as 1/3, 1/6, 1/7.
These are called recurring (or repeating) decimal fractions. These recurring fractions are of two kinds:- Some decimal fractions are solely a collection of digits that repeat from the beginning, such as 0.3 which is just 3 repeating for ever and 1/7 which is 142857 endlessly repeated.
These are called purely repeating decimal fractions - Others start off with a fixed set of digits before they too eventually settle down to an endless repetition of the same digits, such as
- 1/6 = 0.1666666...
- which begins 0.1 and then cycles 6 indefinitely
- 1/12 = 0.0833333...
- which starts 0.08 before it too starts to repeat 3 for ever.
- Some decimal fractions are solely a collection of digits that repeat from the beginning, such as 0.3 which is just 3 repeating for ever and 1/7 which is 142857 endlessly repeated.
At first it is surprising that every fraction fits into one of these two categories:
The decimal fraction of every proper fraction is either terminating or else it becomes recurring.
We could simplify this even further by saying that all terminating decimals end with the infinite cycle of 000000... so that every proper fraction is a recurring decimal !
Patterns in recurring decimals
If we take all the fractions with the same denominator, that is, the lower number in a fraction, we can find some amazing patterns too. The first and simplest are the sevenths, the ninths and the elevenths: 1/7 = 0.142857 142857 142857 ... 2/7 = 0.285714 285714 285714 ... 3/7 = 0.428571 428571 428571 ... 4/7 = 0.571428 571428 571428 ... 5/7 = 0.714285 714285 714285 ... 6/7 = 0.857142 857142 857142 ... | 1/9 = 0.1111111... 2/9 = 0.2222222... 3/9 = 0.3333333... 4/9 = 0.4444444... 5/9 = 0.5555555... 6/9 = 0.6666666... 7/9 = 0.7777777... 8/9 = 0.8888888... | 1/11 = 0.0909090909... 2/11 = 0.1818181818... 3/11 = 0.2727272727... 4/11 = 0.3636363636... 5/11 = 0.4545454545... 6/11 = 0.5454545454... 7/11 = 0.6363636363... 8/11 = 0.7272727272... 9/11 = 0.8181818181... 10/11= 0.9090909090... |
Notation for the recurring part of a decimal fraction
Mathematicians use one of two common notations to indicate which of the digits in a decimal fraction are in the repeating part: the period or cycle.- a dot is put over the first and last digits in the recurring sequence
This notation goes back at least to Robertson (1768). - a line is drawn over the repeating part
- enclose the recurring part inside [ and ] brackets
For example:
Things to do
Alternative forms for some recurring fractions
We have just seen that there is no unique way for writing a recurring fraction since 0.[123] = 0.1[231] = 0.12[312] = ...We could choose one of two conventions: use the longest fixed part or use the shortest fixed part.
For our number example here, it makes sense to write it as 0.[123] but in other cases where the period begins with 0 we have other choices.
For instance, 1/11 = 0.0909090909... .
- With the shortest fixed part (this is the usual form), we have: 1/11 = 0.[09] which makes it a purely recurring decimal fraction.
- Others (such as used in the Mathematica as results from the RealDigits function) prefer to use the longest fixed part and to start a recurring part with a non-zero digit:
1/11 = 0.0[90], making this a mixed recurring decimal fraction.
On this page, we use the shortest fixed part for all recurring decimals.
People have suggested that all fractions are recurring ones because they all end with 000000... or they can end with 99999999... . And anyway, is 0.499999... the same as 0.5 = 0.5000000... or not?
The answer is "Yes, they are the same!" but here is a longer explanation if you need more convincing...
Things to do
Use the interactive calculator following these questions to help you answer them:
[This calculator can give as many decimal places as you like, unlike an ordinary hand-held calculator which often only gives you 8 or perhaps 12 decimal places.]
- Convert the following fractions to decimals: 1/7, 2/7, 3/7, 4/7, 5/7, 6/7.
What do all the 6-digit cycles of these 7th fractions have in common ?They all have the same six digits in their repeating part, starting at different points in the cycle:
1/7 = 0.[142857]
2/7 = 0.[285714]
3/7 = 0.[428157]
4/7 = 0.[571428]
5/7 = 0.[714285]
6/7 = 0.[857142] - Is this true of the eigths? Try all the fractions from 1/8 to 7/8. No!
- Find another number, N, all of whose decimal fractions 1/N, 2/N, 2/N, ... are made from the same cycle of digits as we found for 1/7.
Hint: there are two more with N < 20n/17 has a period of 16 digits all of which are in the same cycle as
1/17 = 0.[0588235294117647]
Similarly n/19 with the cycle being
1/19 = 0.[052631578947368421]
Fraction to Decimal Calculator
C A L C U L A T O R
| in base | |
Show periods as 123 : or [123]: |
R E S U L T S
Converting a decimal fraction into a proper fraction
Converting a terminating decimal to a fraction
First let's look at a method of converting a decimal fraction to a proper fraction by hand. This illustrates the maths behind the process. Then we can explore with an online calculator to do it for us!For example, 0.25:
The process is to write the fraction as a whole number divided by 10the number of decimal places and then simplify this fraction until it is in its lowest form.
Converting a periodic fraction to a fraction
If the decimal fraction is periodic then it never ends and we need a different approach.A purely periodic decimal fraction
First, let's take a purely periodic fraction such as 0.[037] = 0. 037 037 037 .... Let's call our decimal fraction d.First we multiply d by 10the length of the PERIOD to make the fractional part of the decimal (to the right of the decimal point) the same as the original number. For this example, we would use 103 since the period is of length 3:
103 d = 37.037 037 037 ...
Now, if we subtract the original number form this the part to the right of the decimal point will disappear:103 d | = | 37 | .037 037 037 ... | – |
d | = | 0 | .037 037 037 ... | |
103d – d | = | 37 | .000 000 000 ... | |
(103 – 1) d | = | 37 | ||
d | = | 37/999 | ||
d | = | 1/27 |
A mixed periodic decimal fraction
If the decimal fraction is mixed, we use a combination of the terminating and purely periodic methods.For example, 0.12[037] = 0.12 037 037 037 037.... Let's call this m.
First, multiply m by 10length of the FIXED part to get a purely periodic fraction. The power to use here is 2:
100 m = 12.037 037 037 ... and so:
100 m = 12 + 0.[037]
100 m = 12 + 1/27
Now find a proper fraction that is the value of m: 100 m = 12 + 1/27
100 m = (12×27 + 1)/27
100 m = (324 + 1)/27
100 m = 325/27
m = 325/2700
m = 13/108
Decimal to Fraction Calculator
You can input a decimal fraction and the calculator will convert it to a proper fraction. Give the fixed part (if it has one) followed by the recurring part (if your decimal fraction is not a terminating one).- If your decimal fraction is a terminating fraction such as 0·12, type the digits 12 into the FIXED part, leaving the RECURRING part empty.
- If your decimal fraction is purely recurring as in 0·037 037 037.., type the digits that repeat (in this example it is just 037) into the RECURRING part leaving the FIXED part empty. Don't forget to type in all initial and trailing zeroes.
- If your decimal fraction starts with a fixed part and is followed by a recurring part, as in 0·12[037] = 0·12 037 037 ... then put 12 into the fixed part and type 037 into the box for the recurring part.
Things to do
- Can you find a fraction which is all 1's: 0.[1]=0.111111...?
- Can you find a fraction which is all 2's: 0.[2]=0.222222...?
Looking at the result from the Calculator, how could you have got this without using the Calculator> - Without using the calculator, what fraction is 0.[3]=0.3333...?
- ... and what is 0.[4]=0.44444...?
- Can you find a fraction which is all 2's: 0.[2]=0.222222...?
- Can you find a fraction which repeats your age (e.g. 0.[14]=0.14 14 14 14 14... )?
- What fraction will it be on your next birthday?
- Can you find a fraction which is your birthday? e.g. for 5 January 1985 you might try 0.05 01 1985 or 01 05 1985 if you prefer the American system of writing dates
- Can you... find a fraction which is 0.123456789?
- By stopping any long fraction after a few decimal places, we can find a fraction that approximates the original one.
For instance π is 3.1415926535....- What is 3.1 as a fraction?
- What is 3.14 as a fraction?
- What about 3.141 and 3.142 if we round to 3 dps?
For a much better way see my page on Continued Fractions
Which decimal fractions terminate and which recur?
How to tell if a fraction is terminating as a decimal fraction
Some experimentation will help answer this question but we will also justify our answers mathematically.Use the Fraction to Decimal calculator above to find all the fractions which have a denominator less than 50 and whose decimal fractions terminate.
Your list should begin with 2, 4, 5, 8, 10, 16, 20 because:1/2 = 0·5, 1/4 = 0·25, 1/5 = 0·2, 1/8 = 0·125, 1/10 = 0·1, 1/16 = 0·0625, 1/20 = 0·05
All these fractions stop after a limited number of digits: they terminate.
Can you... spot the pattern that is common to the numbers 2, 4, 5, 8, 10, 16, 20, ...?
Try looking at their prime factors.
All the numbers have 2 or 5 or both as their prime factors and no other prime factors.
They are the numbers 2a×5b for whole numbers a, b ≥ 0.
See if you can find some more numbers, N, whose unit fractions, 1/N terminate and then check your list with A003592.
How to find the length of a terminating decimal fraction
If the proper fraction n/d is in its lowest terms then it terminates if and only if d is divisible by 2 or by 5 or by both and is not divisible by any other prime number.This is because in the process of dividing d into n by long division, some power of 10 will then be an exact multiple of the denominator and so will leave no remainder and our process of long-division will stop.
We can write this as d = 2α × 5β where α and β are whole numbers but may be 0.
The decimal fraction for n/d has LCM(α, β) decimal places where the LCM(α, β) function means the lowest common multiple of both α and β; the smallest number that is a multiple of both α and β.
The list of denominators with terminating decimals begins:
2, 4, 5, 8, 10, 16, 20, 25, 32, 40, 50, ... A003592
How to tell if a fraction is purely recurring as a decimal fraction
The rule for a fraction which is purely recurring, that is, its period starts immediately after the decimal point, is just the opposite of the rule for detecting a terminating fraction above:The fraction n/d , in its lowest terms, is purely recurring if and only if neither 2 nor 5 are factors of d
n | 1/n | Period length | n is Prime? |
---|---|---|---|
3 | 0.3 | 1 | Prime |
7 | 0.142857 | 6 | Prime |
9 | 0.1 | 1 | not Prime |
11 | 0.09 | 2 | Prime |
13 | 0.076923 | 6 | Prime |
17 | 0.0588235294117647 | 16 | Prime |
19 | 0.052631578947368421 | 18 | Prime |
21 | 0.047619 | 6 | not Prime |
23 | 0.0434782608695652173913 | 22 | Prime |
27 | 0.037 | 3 | not Prime |
29 | 0.0344827586206896551724137931 | 28 | Prime |
- the numbers coprime to 10
- the numbers with no prime factor in common with 10
- the numbers n for which GCD(10,n) = 1
- the numbers which are not divisible by either 2 or by 5
Did you notice that all the primes numbers are in this list, except of course 2 and 5?
Also, the length of the period of 1/n when n is such a prime is sometimes n–1 and sometimes not! Can you spot any patterns in the period length for a prime n?
The length of the period of a purely periodic decimal fraction
When we divide n into 1 and we eventually reach a remainder of 1 again, then the decimal fraction will repeat. At this point, for example, we have the following if we are using long division to find the decimal fraction for 1/21:. 0 4 7 6 1 9 21 ) 1 . 0 0 0 0 0 0
8 41 6 0
1 4 71 3 0
1 2 64 0
2 11 9 0
1 8 91
106 = 47619 × 21 + 1 or:
106 - 1 is divisible by 21
The length of the recurring part of a purely periodic decimal fraction
is the smallest power of 10 that leaves a remainder of 1 when divided by the denominator.
The decimal form of a fraction is purely recurring if and only if the denominator does not have either 2 or 5 as a factor.
Modular arithmetic has many important applications in modern Number Theory. The great mathematician Carl Friedrich Gauss (1777 - 1855) was the first to fully develop this topic and show its power in his book Disquisitiones Arithmeticae written in Latin. See the References at the foot of this page for the English translation in paperback.
Here we have found that
106 mod 21 = 1
and that 6 is the smallest power of 10 that leaves a remainder of 1 when divided by 21. The same is true for all fractions 1/n which have purely periodic decimal fractions.
Often in textbooks you will see the Greek letter λ (lambda) used for this length:
If λ is the smallest power of 10 that leaves a remainder of 1 when divided by n, then there are λ digits in the period of 1/n:
λ is the smallest number for which 10λ mod n = 1
3, 7, 9, 11, 13, 17, 19, 21, 23, 27, 29, 31, ... A045572
Mixed Recurring Fractions
All fractions as a decimal will either terminate or recurr. Some recurr from the first decimal place and are the purely recurring decimal fractions of the previous section. Others have a few decimal digits at the start and then they recurr. These are the mixed recurring decimal fractions that we look at in this section.For the fraction n/d, in its lowest terms, to terminate have seen that the prime factors of d must also be prime factors of 10, namely 2 or 5 or both.
Examples are: 2, 8 = 2×2×2, 40 = 2×2×2×5, 100 = 2×2×5×5
For it to be purely recurring, none of the prime factors of d must be a prime factor of 10.
Examples are: 3, 7, 9 = 3×3, 11 and all the other prime numbers bigger than 5.
So that leaves the mixed recurring decimal fractions which have at least one prime factor in common with those of 10 and at least one not in common with those of 10
Examples are 6 = 2×3, 15 = 5×3, 30 = 2×5×3
These denominators are of the form
d = 2α1 5α2 p1 β1 p2 β2 ...
where the pi are prime numbers other than 2 and 5 and α1 or α2 can be 0 (which effectively excludes that prime as a factor).How long are the fixed and recurring parts of a mixed recurring fraction?
Using the above description of the denominator d, we separate its factorization into two parts, so that d = D × E
where D includes only the prime factors 2 and/or 5
or else is 1 and
E is the rest of the factorization for the other prime factors
or else is 1.
The size of the fixed and recurring parts are determined solely by D. 1/D will be therefore be a terminating decimal fraction and the number of decimal places it has is the size of the initial fixed part of reduced fractions with d as the denominator.
The size of the recurring part is determined by the rest of the factorization of the denominator, E.
1/E will be purely recurring and the length of its period is the same as the length of the recurring part of 1/d.
Let's look at some examples:
- 1/12
12 = 22 × 3 so D = 22, E = 3
The fixed part is determined by D = 22 = 4 and 1/4 = 0.25 has 2 decimal digits.
The recurring part is determined by E=12/4=3 and 1/3 = 0.[3] has a recurring period of length 1. We see that 1/12 = 0.08[3] and does indeed have a fixed part of 2 digits and a recurring part of 1 digit. - 1/38
38 = 2 × 19 so D = 2, E = 19
The fixed part is the same length as 1/D = 1/2 = 0.5, 1 digit.
The recurring part is the same length as 1/E = 1/19 = 0.[052631578947368421], 18 digits.
Check: 1/38 = 0.0[263157894736842105] does have a fixed part of 1 digit and a recurring part of 18 digits. - 1/19250
19250 = 2 × 53 × 7 × 11 so D = 2 × 53, E = 7 × 11
The fixed part is given by D = 2 × 53 = 250 and 1/250 = 0.004 has 3 decimal digits.
The recurring part is determined by the rest of the factorisation: E = 7 × 11 = 77 and 1/77 = 0.[012987] has a recurring period of length 6.
We find that 1/19250 = 0.000[051948] and does indeed have a fixed part of 3 digits and a recurring part of 6 digits.
The denominators of fractions with purely recurring decimals are:
3, 7, 9, 11, 13, 17, 19, 21, 23, 27, 29, 31 ... A045572
The denominators that have decimals that eventually recur, either as purely recurring decimals or else as mixed recurring decimals are those which do not have a terminating decimal expansion:3, 6, 7, 9, 11, 12, 13, 14, 15, 17, 18, 19, 21, 22, 23, 24, 26, 27,... A085837
Fractions with the same denominator
We have mainly looked at 1/n up to now and how many decimal places it has and if it is periodic or not. What can we say about k/n ?Some examples are:
|
|
|
|
The character of the decimal fraction - whether it terminates or not and the lengths of the fixed and recurring parts - is solely determined by the denominator provided the fraction is in its lowest terms.
The rules for decimal (base 10) fraction for 1/d in its lowest form
The decimal fraction terminates if and only if
the only prime factors of d are 2 or 5 or both.
The decimal fraction is purely periodic (its period begins immediately after the decimal point) if and only if
neither 2 nor 5 are factors of d.
The decimal fraction has an initial number of non-repeating decimal places and then is periodic if and only if
d has both a prime factor which is a prime factor of 10 and a prime factor which is not a prime factor of 10
Here are the mathematical details (optional) to show why the numerator does not matter:
For example:13/108 has an initial fixed part of 2 decimal places and a periodic repeating part of 3 dps and so will all decimal fractions for n/108 provided that n has no factor in common with 108 :
|
|
|
Same denominator Decimal Fraction Calculator
This calculator finds all those fractions with the same denominator and counts them, displays all the numerators or shows the all the decimal places or the period. The denominator can be a number up to 16 digits long and the Count is displayed but you will need to confirm you want to see all the numerators or decimals if there are more than 50 numerators.The number of fractions with the same denominator and Euler's Totient function φ(n)
The Calculator above computes the number of fractions with the same denominator by using a relatively simple formula which is why it is so fast. The number of fractions with the same denominator d is an important function in mathematics and in Number Theory in particular. Euler used it in his research and called it φ(d), the (Euler) Totient function. It has nothing to do with the golden mean number φ as that is a completely different use for the Greek letter phi! Euler's phi function φ(d) is
the number of fractions 0 < n/d < 1 which in their lowest form have d as their denominator.
d | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
φ(d) | 1 | 2 | 2 | 4 | 2 | 6 | 4 | 6 | 4 | 10 | 4 | 12 | 6 | 8 | 8 | 16 | 6 | 18 | 8 |
This is the series A000010, the totient numbers and it plays an important part in many results in Number Theory.
Nontotient Numbers
All values of φ(n) are even for n>2. But not all even numbers are the result of φ(n) for some n.In other words when we list the counts of proper fractions with a given denominator, there are some counts that never appear in the list and these are the nontotient numbers. For instance,
we can find n for φ(n) = 12, since φ(13) = 12 and there are 12 proper fractions less than 1 with a denominator of 13.
Similarly, φ(n) = 16 since φ(17) = 16 and there are 16 proper fractions less than 1 with a denominator of 17.
But there is no solution to φ(n) = 14: there is no denominator that has exactly 14 reduced fractions!
14 is the smallest nontotient number.
The list begins:
14, 26, 34, 38, 50, 62, 68, 74, 76, 86, 90, 94, 98, ... A005277.
Fractions with the same lengths of period, fixed part or terminating part
We have seen how to compute the length of the terminating part of of the fixed and periodic parts of a given fraction. Now let's ask the question in reverse:Given the length of terminating part or the lengths of fixed and periodic parts, how do we find such fractions?
Terminating Decimals of a given length
A terminating decimal fraction n/d must have d = 2α × 5β ( α and β may be 0) and the length of its (terminating) decimal is LCM(α, β) which we saw above.So, given a length t of a terminating decimal fraction we need to find α and β with LCM(α, β) = t. This means that both α and β are among the factors of t or else one of them is 0 and the other is t.
For example, if t = 2, we have
α | 2α | β | 5β | d = 2α×5β | 1/d | φ(d) |
---|---|---|---|---|---|---|
0 | 1 | 2 | 25 | 25 | 0.04 | 20 |
1 | 2 | 2 | 25 | 50 | 0.02 | 20 |
2 | 4 | 0 | 1 | 4 | 0.25 | 2 |
2 | 4 | 1 | 5 | 20 | 0.05 | 8 |
2 | 4 | 2 | 25 | 100 | 0.01 | 40 |
Total φ= | 90 |
We must exclude those 2-digit numbers that end in 0, leaving just 90 terminating fractions of 2 digits (decimal places).
Purely periodic decimals of a given length
A common notation used for the length of the period of the decimal for 1/d is the Greek lowercase letter for ℓ for length, which is lambda λ.λ will be the smallest power of 10 that has a remainder of 1 when divided by d. If we are given a value for λ we want to find the d for which 10λ = 1 (mod d) which means that d will be a factor of 10λ - 1.
Here are the factors of 10λ - 1 for various values of λ = length of period:
λ | 10λ–1 | prime factorisation | factors>1 found ealier | new factors>1 |
---|---|---|---|---|
1 | 9 | 32 | 3, 9 | |
2 | 99 | 32×11 | 3, 9 | 11, 33, 99 |
3 | 999 | 33×37 | 3, 9 | 27, 37, 111, 333, 999 |
4 | 9999 | 32×11×101 | 3, 9, 11, 33, 99 | 101, 303, 909, 1111, 3333, 9999 |
5 | 99999 | 32×41×27 | 3, 9 | 41, 123, 271, 369, 813, 2439, 11111, 33333, 99999 |
6 | 999999 | 33×7×11×13×37 | 3, 9, 11, 27, 33, 37, 99, 111, 333, 999 | 7, 13, 21, 39, 63, 77, 91, 117, 143, 189, 231, 259, 273, 297, 351, 407, 429, 481, 693, 777, 819, 1001, 1221, 11287, 1443, 2079, 10101, 10989, 12987, 15873, 25641, 27027, 30303, 37037, 47619, 76923, 90909, 111111, 142857, 333333, 999999 |
7 | 9999999 | 32×239×4649 | 3, 9 | 239, 717, 2151, 4649, 13947, 41841, 1111111, 3333333, 9999999 |
- If we find one of the factors d in row λ but not in any earlier row, then 1/d is purely periodic with a period of length λ.
- Any other fraction n/d with GCD(n,d)=1 will also have a period of the same length.
- The number of divisors of 10n–1 varies considerably (A070528 and this table includes the factor 1):
n 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 #divisors 3 6 8 12 12 64 12 48 20 48 12 256 24 48 128 192 12 640 6 384 - For instance,
1023–1 has only 6 factors but
1024–1 has 2048
1030–1 has 16384
Here are three consecutive values of the power with wildly differing numbers of factors:
1059–1 has 12 factors but
1060–1 has 2097152 and
1061–1 has 384. - This is because if m is a factor of n then 10m–1 is a factor of 10n–1.
So numbers n that have many factors will give rise to many factors for 10n–1 - All numbers 10n–1 for n>1 have at least these 6 factors: 1, 3, 9, (10n–1)/9 = 11..11, (10n–1)/3 = 33..33, (10n–1)/9 = 999...999
- These 6 factors are the only divisors for 102–1, 1019–1 and 1023–1.
- So, for n = 2, 19 and 23 the larger 3 factors will be their only denominators for purely recurring fractions with those period lengths.
Decimals of given fixed part length and period length
Let's call the fixed part length t and the period length ℓ and either may be 0.Combining the results of the above two sections, we find all numbers T with terminating decimal of length t and all numbers R which are purely recurring with a period of length λ, as described above.
The mixed fraction denominators which have both fixed part length t and a period of length λ are those numbers made from a product of one of the T with one of the R.
From the sections above we see that
- the denominators of fractions whose decimal is only a fixed-part of F decimals are factors of 10F
- the denominators of fractions whose decimal is only a period of P decimals are factors of 10P−1
- the denominators of fractions whose decimal has both a fixed part and periodic part are a product of the denominators with just the fixed part and just the periodic part
Similar sized Decimals Calculator
The fixed length and period length cannot be larger than 15 with this calculator. Leave the 'up to' value empty to include all valid integers with up to 16 digits.This Calculator finds the number of distinct denominators that can occur for decimal numbers with a given number of fixed-part decimal places and a given number of periodic-part decimal places.
For example, there are 9 distinct decimals of the form 0.d with 1 fixed decimal digit d>0 and no periodic decimals as follows:
0.1 = 1/10, 0.2 = 1/5, 0.3 = 3/10, 0.4 = 2/5, 0.5 = 1/2, 0.6 = 3/5, 0.7 = 7/10, 0.8 = 4/5, 0.9 = 9/10
but there are only 3 possible denominators for these fractions: 2, 5 and 10.Plots of Period lengths
Here are plots of the lengths of the periods of the purely periodic fractions 1/N for different ranges of N:
Decimal fractions that look like special sequences
Now we look at some special kinds of decimal fractions, ones that contain a whole special series in their decimals! It is amazing to find that some fractions have a decimal expansion with a special pattern such as the powers of 2 as in0.01 02 04 08 16 32 ....
which is the first few decimal places of 1/98! Can you guess which simple fraction begins with the powers of 3: 0.01 03 09 27 ... ?How about 0.001 002 004 008 016 032 ...?
However after a few more decimal places the series often get "muddled" and the pattern seems to disappear.
Why? Are all series of numbers codeable as a fraction in this way? How can we find a fraction for a series?
This section unravels some of the simple maths behind this mystery.Powers of a number
If we look more closely at some simple fractions near 1/100 we see their decimal fractions are special:1/99 | = 0. 01 01 01 01 01 01 01 01 01 1 ... |
1/98 | = 0. 01 02 04 08 16 32 65 30 61 2 ... |
1/97 | = 0. 01 03 09 27 83 50 51 54 63 9 ... |
and 1/97 looks like 01 03 09 27 8(1)... the powers of three and 97 = 100 - 3.
In fact, even 1/99 fits this pattern because 99 = 100 - 1 and it would then be the powers of 1, that is 01 01 01 01 01 ... which it is!
But soon the pattern of powers disappears. Why?
Because it is really there, just masked as the powers get larger.....
Shift-and-add applied to the a series makes the fraction!
We take the powers of 2 but moving each power exactly 2 places to the right each time and then we add them:0. | 0 | 1 | + | |||||||||||||||||||||
0 | 2 | + | ||||||||||||||||||||||
0 | 4 | + | ||||||||||||||||||||||
0 | 8 | + | ||||||||||||||||||||||
1 | 6 | + | ||||||||||||||||||||||
3 | 2 | + | ||||||||||||||||||||||
6 | 4 | + | ||||||||||||||||||||||
1 | 2 | 8 | + | |||||||||||||||||||||
2 | 5 | 6 | + | |||||||||||||||||||||
5 | 1 | 2 | + | |||||||||||||||||||||
1 | 0 | 2 | 4 | + | ||||||||||||||||||||
. | . | . | ||||||||||||||||||||||
0. | 0 | 1 | 0 | 2 | 0 | 4 | 0 | 8 | 1 | 6 | 3 | 2 | 6 | 5 | 3 | 0 | 6 | 1 | . | . | . | . | . | . |
Did you notice that
- the powers of 2 taken two digits at a time are in the fraction 1/(102 - 2) = 1/98
- the powers of 3 taken two digits at a time are in the fraction 1/(102 - 3) = 1/97
Things to do
- Check this out with 1/97 = 1/(100 - 3) and the powers of 3.
Make a table, moving the unit digit two places to the right each time and adding. Check you have enough powers to verify the first 20 decimal places as we did for the powers of two above.30= 0. 0 1 + 31= 0 3 + 32= 0 9 + 33= 2 7 + 34= 8 1 + 35= 2 4 3 + 36= 7 2 9 + 37= 2 1 8 7 + 3... ... ... ... ... TOTAL: - To about 20 or 30 decimal places, what are 1/9980 and 1/9970?
So we observe (or guess!) that
the powers of p taken d digits at a time appear in the decimal fraction for 1/(10d–p)
The powers backwards!
At the top of this page, you might not have noticed among the examples of fractions converted into decimals this particular one:1/19 = 0 . [052631578947368421]
It does not seem interesting except when you look at it backwards: ..., (1)6, 8, 4, 2, 1. Surely these cannot be the powers of 2 in reverse order and added, can they?1 | |||||||||||||||
2 | |||||||||||||||
4 | |||||||||||||||
8 | |||||||||||||||
1 | 6 | ||||||||||||||
3 | 2 | ||||||||||||||
6 | 4 | ||||||||||||||
1 | 2 | 8 | |||||||||||||
2 | 5 | 6 | |||||||||||||
5 | 1 | 2 | |||||||||||||
1 | 0 | 2 | 4 | ||||||||||||
. | . | . | . | ||||||||||||
. | . | . | . | 7 | 8 | 9 | 4 | 7 | 3 | 6 | 8 | 4 | 2 | 1 |
Here is another, this time the powers-of-2 ..., 32, 64, 32, 16, 8, 4, 2, 1 have first 2 and then 3 digits each:
1/199 = 0.[00502512562814070351...14572864321608040201] with a period of 99 digits,
1/1999 = 0.[00050025012506253126...64032016008004002001] with a period of 999 digits, ...
What about powers of 3 backwards? ..., 81, 27, 9, 3, 1
1/29 = 0.[0344827586206896551724137931] with a period length of 28,
1/299 = 0.[00334448160535117056...48829431438127090301] with a period length of 66,
1/2999 = 0.[00033344448149383127...29243081027009003001] with a period of 1499 digits,
1/39 = 0.[025641] with period length of 6
1/399 = 0.[002506265664160401] with a period length of 18
1/3999 = 0.[00025006251562890722...97024256064016004001] with a period length of 105
An interesting thing happens with the Triangular Numbers
1, 3, 6, 10, 15, 21, 28, ...
which we will meet later on this page. Here they are in a fraction with 2 digits per triangular number:100/970299 = 0.[000103061015212836...5545362821151006030100], period length is 19602
The series appears both forwards from the left and backwards from the right!The Fibonacci numbers backwards appear as the periods of:
10/109 = 0.[0917431192660550458...064220183486238532110] (108 digits)
100/10099 = 0.[00990197049212793345...34211308050302010100] (3366 digits)
1000/1000999 = 0.[0009990019970049920...008005003002001001000] (500499 digits)
Why? I will expand this section soon to include some of the theory so that we can directly find a fraction for a given series....watch this space!
See if you can spot some more rules for other series in this Calculator:
Series to Decimal Fraction Calculator
If numbers become too large to decide if the fraction terminates or recurs or to compute the size of fixed and periodic parts, an error message is shown but you can still use the Show button to display any number of decimal places, even thousands of decimal places if you want!C A L C U L A T O R
Series to Decimal Fraction | ||||||||
| ||||||||
| ||||||||
k for k from 0 to with each power shifted digits | and multiply by |
R E S U L T S
Summing powers in a decimal
Things to do
-
- What series do you notice in the decimal expansion of 1/9801?
- What fraction would give the same series but starting at 1 instead of 0? 100/9801
- Can you guess a fraction that has three places for each member of this series? 1/998001
- ... and what about a fraction with four places for each number? 1/99980001
-
- Look at your answer to the previous question and take a guess as to what 2/9801 would look like.
Check your answer with the calculator above. 0, 2, 4, 6, 8, ... the evens, two digits at a time - What series appears in the decimal for 3/9801? 0, 3, 6, 9, 12, ... the triples two digits at a time
- Look at your answer to the previous question and take a guess as to what 2/9801 would look like.
Why do the powers patterns ultimately disappear?
We said earlier that all fractions when put into decimal form either terminate or recurr. This is true for our fractions whose decimal fractions correspond to a particular number series. They cannot go on for ever in the decimal digits! The reason lies in the fact that the numbers (the powers of 2, say) appear with two digits each. When we get to a power greater than 100, there will be an "overflow" into the 2-digit power before it. In fact what happens is that we do include every number from 0 upwards but the overflows eventually cause the decimal to get into a recurring sequence.Number of Divisors
The fractions 1/10k – 1 have a fascinating application.They are all periodic as none of their denominators has a factor of 2 or 5:
k | 1/10k-1 | decimal | |
---|---|---|---|
1 | 1/9 | 0.[1] | 0.111111111... |
2 | 1/99 | 0.[01] | 0.010101010... |
3 | 1/999 | 0.[001] | 0.001001001... |
4 | 1/9999 | 0.[00001] | 0.000100010... |
5 | 1/99999 | 0.[000001] | 0.000010000... |
6 | 0.000001000... | ||
7 | 0.000000100... | ||
8 | 0.000000010... | ||
9 | 0.000000001... | ||
... | |||
Sum | 0.122324243... |
- the first row has a 1 in every position
- the second row has a 1 in every other position - the even positions
- the third row has a 1 in every third position, where the column number is a multiple of 3
- ...
The sum of the rows is therefore the series of the number of divisors of C but as a decimal!
C | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | ... |
---|---|---|---|---|---|---|---|---|---|---|
Divisors | 1 | 1,2 | 1,3 | 1,2,4 | 1,5 | 1,2,3,6 | 1,7 | 1,2,4,8 | 1,3,9 | ... |
#Divisors | 1 | 2 | 2 | 3 | 2 | 4 | 2 | 4 | 3 | ... |
0.1223242434262445262644283446282644492448282664
and then we find the number of divisors of 48 is 10 and its tens digit overflows into the 47th decimal place sadly!We can increase the accuracy of the decimal by taking 2 digits per value, so we have the following as the first 100 dps:
0.0102020302040204030402060204040502060206040402080304040602080206040404090204040802080206060402100306...
We can see the last three values are now 10, 3 and 6 as the number of divisors of 48, 49 and 50.This decimal is now correct up to 90717 decimal places because the first number with more than 99 divisors is 45360 which has 100 divisors.
The number of divisors of n is sometimes written as τ(n). For more values and more details see A000005.
The digits of the decimal sum are given in A073668.
Unfortunately, none of these decimals correspond to a proper fraction! We return to such non-fractional numbers later on this page.
For now, let's return to those series of number which do correspond to a proper fraction and we will discover some methods and techniques for finding a fraction which has the series as its decimal expansion.
How to turn a Series into a decimal fraction
There are lots of other series such as powers of 2: 0, 1, 2, 4, 8, 16, ... or the Fibonacci numbers 0,1,1,2,3,5,8,13,21,... which appear as the decimal form of some special fractions, but not all series! There is no fraction that gives the primes numbers for example. So which series can we find in our decimal fractions and which can we not find?A list of some of those we can find is given in the selection menu in the above Decimal Series to Fraction Calculator. Pick one and the decimal fraction with this as an initial segment in its periodic decimal expansion will be filled in for you in the calculator's boxes so you can use the other buttons to explore it.
In this section we look at various methods of finding a fraction and what kinds of series they can generate as a decimal fraction.
Start with the series of 1's
Let's look at the series S = 1 + x + x2 + x3 + x4 +...
If we multiply S by x we have
x S = x + x2 + x3 + x4 +...
But this is just S - 1 so
S - 1 = x Sbr> Collecting the S terms on the left:
(1 - x)S = 1
So S = 1/(1 - x):
1 | = 1 + x + x2 + x3 + x4 +... |
1 – x |
This is the basic formula for our powers-in-a-decimal form if we let x = p/10d for powers of p with d digits per power.
If we look at powers of 1 and d=2, we get
1 +
+
+ ... = 1.01 01 01 01 ... =
=
÷ 100 =
– 1 =
= 0.01 01 01 01 01
= 0. 1 1 1 1 ...
= 0.01 01 01 01 01 ...
= 0.001 001 001 001 ...
= 0. k k k k ...
= 0.0k 0k 0k 0k 0k ...
= 0.00k 00k 00k 00k ...
= 0. [k] if 0≤k≤10d-1
Add two series
If our series is a sum of two series, we can add their fractions.For example the series 2n + 3n is 0, 1+1, 2+3, 4+9, 8+27, ... = 2, 5, 13, 35, 97, ... (A007698).
With 3 digits per term, 2n and 3n appear in the fractions
=
= 0. 001 002 004 008 016 ...
=
= 0. 003 009 027 081 ...
+
=
= 0. 002 005 013 035 097 ...
Moving a series several places
To move a series, we merely multiply the fraction by a power of 10 to move it to the left in the decimal, or divide it by a power of 10 to move it to the right, introducing zeroes as the new decimal places after the decimal point. We can also just add an integer before we divide too.The series 0, 2, 5, 13, 35, 97, ... which is the series 2n+3n but starting with 0 is
= 0. 002 005 013 035 097 ...
= 0. 000 002 005 013 035 097 ...
= 0. 002 005 013 035 097 ...
= 2. 005 013 035 097 ...
0.005 013 035 097 ... =
– 2 =
Multiplying by a constant
To make our series more general, we can multiply a power series by a constant.For example, 1/7 = 0.142857 and this looks suspiciously like the beginning of the series
14, 28, 56, 112, ... = 14×1, 14×2, 14×22, 14×23,...
which is the powers of two with 2 digits each, multiplied by 14.The powers of 2, with 2 digits each is 1/98 = 0.0102040816326530612244897959183673469387755 and so multiplying by 14 gives
14/98 = 1/7 =0.142857
Our suspicion is proved correct!
The Accumulating sums of a series
Finding the successive sums of a series, or accumulating the sum as we progress down a series, is a useful technique: P(x) = a + b x + c x2 + d x3 + ...
Accumulating the sums:
a + (a + b) x + (a + b + c) x2 + (a + b + c + d ) x3 + ...
0. 01 01 01 01 01 01 ... =
0. 01 02 03 04 05 06 07 ... =
0. 00 01 02 03 04 05 06 ... =
=
0. 01 02 03 04 05 06 ... =
=
0. 00 01 03 06 10 15 21 =
=
Starting at 1 rather than 0, we move the series to the left: If we accumulate the sums of the constant series 2, 2, 2, 2, 2, ... we get the even numbers:
0. 02 02 02 02 02 ... =
0. 00 02 04 06 08 10 ... =
=
To get the odd numbers, we can add 1 to each of the even numbers because the series 2n+1 is double (the natural number series) + (the constant 1 series):
0. 01 03 05 07 09 ...
= 2 × ( 0. 00 01 02 03 04 05 ... ) + 0. 01 01 01 01 01 ...
=
+
=
0. 01 03 05 07 09 = 100 (0. 00 01 02 03 04 05 ...) + (0.00 01 02 03 04 05 ...)
=
=
for 1 digit per term
=
for 2 digits per term
=
for 3 digits per term
Why this works (optional)
Differences
Let's take a look at the series of square numbers 1, 22=4, 32=9, 42=16, 25, 36, ... . What proper fraction produces this series in its decimal fraction?Here we can find successive differences:
Squares: | 0 | 1 | 4 | 9 | 16 | 25 | 36 | ... | ||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Differences | 1 | 3 | 5 | 7 | 9 | 11 |
This is easily verified since we add an odd number to one square to get the next:
(n + 1)2 = n2 + 2n + 1
Let's then take the fraction for the odd numbers of two digits each: 101/9801 and apply the "accumulate the sums" operation of dividing by 99:0. 01 03 05 07 09 ... =
0. 00 01 04 09 16 25 ... =
=
0. 000 001 004 009 016 025 ... =
0. 000 001 003 006 010 015 ... | 1001/(998001×1000) | |||
+ | 0. 001 003 006 010 015 ... | + | 1001/998001 | |
= | 0. 001 004 009 016 025 ... | = | 1002001/998001000 |
If we take the cubes, we can find differences and then take their differences, the second differences, and when we take differences of the second differences (the third differences), we find a constant series:
Cubes: | 0 | 1 | 8 | 27 | 64 | 125 | 216 | ... | |||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1st Differences: | 1 | 7 | 19 | 37 | 61 | 91 | ... | ||||||||
2nd Differences: | 6 | 12 | 18 | 24 | 30 | ... | |||||||||
3rd Differences: | 6 | 6 | 6 | 6 | ... |
First, the constant series of 6's with 3 digits each:
0. 006 006 006 006 ... =
=
0. 000 006 012 018 ... =
=
0. 001 006 012 018 ... =
+
=
×
=
= 0. 001 007 019 037 ...
334 667 |
332 334 333 × 999 |
=
= 0. 000 001 008 027 064 125 ...
Why this works (optional)
Fibonacci Numbers
As an example of what we can do with series-in-a-fraction we will look at the decimal fractions for the Fibonacci Numbers: 0, 1, 1, 2, 3, 5, 8, 13, .... The next is just the sum of the previous two numbers in the series.On my Fibonacci pages, in the section The Fibonacci Series as a Decimal Fraction we saw how to prove that 1/89 was the Fibonacci series-in-a-fraction by using a generating function, which is a polynomial which encoded the Fibonacci numbers as its coefficients:
P(x)=F(0) x + F(1) x2 + F(2) x3 + ... ...+F(n-1)x n + ...
which we showed was If we let x = 1/10 then we have 0 + 1/10 + 1/100 + 2/1000 + 3/104 + ... = 1/100-10-1 = 1/89For two digits per Fibonacci number, we let x = 1/100 so that we have 0 + 1/102 + 1/104 + 2/106 + 3/108 + ... = 1/10000-100-1 = 1/9899
Fibonacci Numbers and Pascal's Triangle illustrated by decimal fractions
Another way of looking at this fraction, 1/89 is that it is 1/100-11 and so, from our results above on Summing Powers in a Decimal it is related to powers of 11, that is 1 + 11/10 + 112 /100 + 113 /1000 + ...:1/89 = | .01 | 110 = 1 |
+ | .0011 | 111 = 11 |
+ | .000121 | 112 = 121 |
+ | .00001331 | 113 = 1331 |
+ | .0000014641 | 114 = 14641 |
+ | ... |
Finally, why are powers of 11 related to Pascal's Triangle? Because if E is a power of 11 then the next power is 11 E or (10+1) E so we have the previous power's neighbouring digits added to get the digits of the next power of 11, just as we found elements in Pascal's triangle by adding the two in the previous row to get the one in the next row under them.
Reference:
- M Bicknell-Johnson's 1989 paper - see reference below
Lucas Numbers
The Lucas Numbers, L(n), are another Fibonacci-type series but begin with 2, 1, ... and use the Fibonacci Rule of add the lastest two numbers to get the next:2, 1, 3, 4, 7, 11, 18, 29, ... A000032
They are also just the sum of the two Fibonacci numbers on either side of a Fibonacci number:L(n) = F(n+1) + F(n-1)
Here are the steps for building a fraction for the Lucas Numbers with two digits per item:- The fraction for F(n) taken 2 digits at a time and starting at 0 is 1/9899 = 0. 00 01 01 02 03 05 08 13 21 ...
- F(n+1) is seen in the decimal fraction of 1/9899 × 100 = 100/9899 = 0. 01 01 02 03 05 08 13 21 ...
- F(n-1) is seen in the decimal fraction for 1/9899 ÷ 100 = 1/989900 = 0. 00 00 01 01 02 03 05 08 13 21 ... although we need to introduce 1 before the 0 term to make the Fibonacci rule apply:
1, 0, 1, 1, 2, 3, 5, ...
so our fraction for the F(n+1) series is (1 + 1/9899) ÷ 100 = 9900/989900 = 99/9899 = 0. 01 00 01 01 02 03 05 08 13 ... - the Lucas numbers L(n)=F(n+1)+F(n-1) are seen in the decimal fraction of 99/9899 + 100/9899 = 199/9899 = 0. 02 01 03 04 07 11 18 29 ...
General Fibonacci-type series
There are many other pairs of starting numbers that, with the Fibonacci Rule, give interesting series, called General Fibonacci series, G(a,b,n), where a and b are the two starting values. So- the Fibonacci numbers are F(n) = 0,1, 1,2,3,5,8,... = G(0,1,n)
- the Lucas numbers are L(n) = 2,1, 3,4,7,11,18,... = G(2,1,n)
- G(a,b,n) = a F(n-1) + b F(n) which we found on The General Fibonacci Numbers page.
G(a,b,n) = a, b, a+b, 2a+b, 3a+2b, ... , a F(n-1) + b F(n), ...
=
a 10d + b |
102 d – 10d – 1 |
d: | 1 | 2 | 3 | ||||||
---|---|---|---|---|---|---|---|---|---|
Fraction: |
|
|
|
Things to do
- The Pentagonal Numbers are 0, 1, 5, 12, 22, 35, 51, 70, ... A000326 and have constant second differences. Find a fraction which has this series in its decimal expansion with 3 digits per number.
- Look at the fractions (2 digits per number) for the triangular numbers, the square numbers and, from the previous question, the pentagonal numbers. What do you think is the next fraction in the sequence (the hexagonal numbers)?
- For the Lucas Numbers, 2,1,3,4,... what proper fraction expands to 2.01 03 04 07 11 ... ?
Other bases
If we consider bases other than 10, all our results still hold with some slight modifications. All fractions are terminating or purely recurring or mixed recurring.Here is a table of the fractions 1/n for n from 2 to 12 in bases from 2 to 12. For bases above 10 we use the letters A=10, B=11, ... , Z=35, either UPPERCASE or lower.
Base: | 1/2 | 1/3 | 1/4 | 1/5 | 1/6 | 1/7 | 1/8 | 1/9 | 1/10 | 1/11 | 1/12 |
---|---|---|---|---|---|---|---|---|---|---|---|
2 | 0.1 | 0.[01] | 0.01 | 0.[0011] | 0.0[01] | 0.[001] | 0.001 | 0.[000111] | 0.0[0011] | 0.[0001011101] | 0.00[01] |
3 | 0.[1] | 0.1 | 0.[02] | 0.[0121] | 0.0[1] | 0.[010212] | 0.[01] | 0.01 | 0.[0022] | 0.[00211] | 0.0[02] |
4 | 0.2 | 0.[1] | 0.1 | 0.[03] | 0.0[2] | 0.[021] | 0.02 | 0.[013] | 0.0[12] | 0.[01131] | 0.0[1] |
5 | 0.[2] | 0.[13] | 0.[1] | 0.1 | 0.[04] | 0.[032412] | 0.[03] | 0.[023421] | 0.0[2] | 0.[02114] | 0.[02] |
6 | 0.3 | 0.2 | 0.13 | 0.[1] | 0.1 | 0.[05] | 0.043 | 0.04 | 0.0[3] | 0.[0313452421] | 0.03 |
7 | 0.[3] | 0.[2] | 0.[15] | 0.[1254] | 0.[1] | 0.1 | 0.[06] | 0.[053] | 0.[0462] | 0.[0431162355] | 0.[04] |
8 | 0.4 | 0.[25] | 0.2 | 0.[1463] | 0.1[25] | 0.[1] | 0.1 | 0.[07] | 0.0[6314] | 0.[0564272135] | 0.0[52] |
9 | 0.[4] | 0.3 | 0.[2] | 0.[17] | 0.1[4] | 0.[125] | 0.[1] | 0.1 | 0.[08] | 0.[07324] | 0.0[6] |
10 | 0.5 | 0.[3] | 0.25 | 0.2 | 0.1[6] | 0.[142857] | 0.125 | 0.[1] | 0.1 | 0.[09] | 0.08[3] |
11 | 0.[5] | 0.[37] | 0.[28] | 0.[2] | 0.[19] | 0.[163] | 0.[14] | 0.[124986] | 0.[1] | 0.1 | 0.[0A] |
12 | 0.6 | 0.4 | 0.3 | 0.[2497] | 0.2 | 0.[186A35] | 0.16 | 0.14 | 0.1[2497] | 0.[1] | 0.1 |
13 | 0.[6] | 0.[4] | 0.[3] | 0.[27A5] | 0.[2] | 0.[1B] | 0.[18] | 0.[15A] | 0.[13B9] | 0.[12495BA837] | 0.[1] |
14 | 0.7 | 0.[49] | 0.37 | 0.[2B] | 0.2[49] | 0.2 | 0.1A7 | 0.[17AC63] | 0.1[58] | 0.[13B65] | 0.12[49] |
15 | 0.[7] | 0.5 | 0.[3B] | 0.3 | 0.2[7] | 0.[2] | 0.[1D] | 0.1A | 0.1[7] | 0.[156C4] | 0.1[3B] |
16 | 0.8 | 0.[5] | 0.4 | 0.[3] | 0.2[A] | 0.[249] | 0.2 | 0.[1C7] | 0.1[9] | 0.[1745D] | 0.1[5] |
17 | 0.[8] | 0.[5B] | 0.[4] | 0.[36DA] | 0.[2E] | 0.[274E9C] | 0.[2] | 0.[1F] | 0.[1BF5] | 0.[194ADF7C63] | 0.[17] |
18 | 0.9 | 0.6 | 0.49 | 0.[3AE7] | 0.3 | 0.[2A5] | 0.249 | 0.2 | 0.1[E73A] | 0.[1B834G69ED] | 0.19 |
19 | 0.[9] | 0.[6] | 0.[4E] | 0.[3F] | 0.[3] | 0.[2DAG58] | 0.[27] | 0.[2] | 0.[1H] | 0.[1DFA6H538C] | 0.[1B] |
20 | 0.A | 0.[6D] | 0.5 | 0.4 | 0.3[6D] | 0.[2H] | 0.2A | 0.[248HFB] | 0.2 | 0.[1G759] | 0.1[D6] |
21 | 0.[A] | 0.7 | 0.[5] | 0.[4] | 0.3[A] | 0.3 | 0.[2D] | 0.27 | 0.[2] | 0.[1J] | 0.1[F] |
Here is a table of the sizes of the fixed part and of the period of the decimals of 1/n for n from 2 to 21 and the type of the decimal fraction in each base from 2 to 21:
Base: 1/n | 1/2 | 1/3 | 1/4 | 1/5 | 1/6 | 1/7 | 1/8 | 1/9 | 1/10 | 1/11 | 1/12 | 1/13 | 1/14 | 1/15 | 1/16 | 1/17 | 1/18 | 1/19 | 1/20 | 1/21 | 1/22 | 1/23 | 1/24 | 1/25 | 1/26 | 1/27 | 1/28 | 1/29 | 1/30 |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
2 | 1 0 | 0 2 | 2 0 | 0 4 | 1 2 | 0 3 | 3 0 | 0 6 | 1 4 | 0 10 | 2 2 | 0 12 | 1 3 | 0 4 | 4 0 | 0 8 | 1 6 | 0 18 | 2 4 | 0 6 | 1 10 | 0 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20 | 1 0 | 0 2 | 1 0 | 1 0 | 1 2 | 0 2 | 2 0 | 0 6 | 1 0 | 0 5 | 1 2 | 0 12 | 1 2 | 1 2 | 2 0 | 0 16 | 1 6 | 0 1 | 1 0 | 0 2 | 1 5 | 0 22 | 2 2 | 2 0 | 1 12 | 0 18 | 1 2 | 0 7 | 1 2 |
21 | 0 1 | 1 0 | 0 1 | 0 1 | 1 1 | 1 0 | 0 2 | 2 0 | 0 1 | 0 2 | 1 1 | 0 4 | 1 1 | 1 1 | 0 4 | 0 4 | 2 1 | 0 18 | 0 1 | 1 0 | 0 2 | 0 22 | 1 2 | 0 5 | 0 4 | 3 0 | 1 1 | 0 28 | 1 1 |
We usually call the base-B digits in the expansion of a base-B fraction the decimal form of the fraction even if the base is not 10. We ought really to talk about the bimals for base 2 and the trimals for base 3, etc, but this sounds strange, so we opt for the easier base 2 decimal or base 3 decimal, etc.
Terminating Fractions in other bases
For prime bases such as 2,3,5,7 and 11, the only fractions which terminate must have a denominator which is a power of that prime.The same is also true for bases which are themselves a power of a prime such as base 4 = 22, base 8 = 23 and base 9 = 32. Their terminating fractions are those with a denominator which is a power of that same prime.
So what about bases whose factors involve more than one prime?
base | n where m/n terminates | OEIS | Description |
---|---|---|---|
2 | 2,4,8,16,32,... | A000079 | {2i|i≥0} |
3 | 3,9,27,81,... | A000244 | {3i|i≥0} |
4 | 2,4,8,16,32,... | A000079 | {2i|i≥0} |
5 | 5,25,125,... | A000351 | {5i|i≥0} |
6 | 2,3,4,6,8,9,12,16,18,24,... | A003586 | {2i3j|i,j≥0} |
7 | 7,49,... | A000420 | {7i|i≥0} |
8 | 2,4,8,16,32,... | A000079 | {2i|i≥0} |
9 | 3,6,9,27,54,81,... | A000244 | {3i|i≥0} |
10 | 2,4,5,8,10,16,20,... | A003592 | {2i5j|i,j≥0} |
11 | 11,121,... | A001020 | {11i|i≥0} |
12 | 2,3,4,6,8,9,12,16,18,24,... | A003586 | {2i3j|i,j≥0} |
{2i3j|i,j≥0} is the set of numbers which are a product of a power of 2 and a power of 3 where the power i of 2 and the power j of 3 are the (whole) numbers 0 or more.
The general rule is
The Terminating Fraction Rule
A fraction N/D terminates in base B if all the prime factors of the denominator D are also prime factors of the base B.
This describes all the terminating fractions in base B and therefore:
A fraction N/D recurs in base B if D has a prime factor that is not a prime factor of the base B
Decimal Fractions Calculator for any Base
C A L C U L A T O R for Decimal Fractions in any Base
fractions | with denominators | in bases |
from | from | |
Show periods as 123 : or [123]: |
R E S U L T S
Things to do
- What is 1/2 in bases 2 to 12?
Write your result mathematically. 1/22b+1 = 0.[b]
1/22b = 0.b - Which denominators that are terminating in base 10 (decimal) are also terminating in base 2 (binary)? All of them because they are just the powers of 2
- If all the recurring fraction's denominators in base B are also all the recurring fraction's denominators in base C, what can you say about B and C? Since recurring fraction's denominators have no prime factor in common with the base, then both B and C must have the same prime factors.
Are there any other types of numbers that are not fractional?
Are there numbers whose decimal fractions neither terminate nor recurr?Numbers whose decimal fraction terminate or end up recurring are always proper fractions as we have seen on this page. No other numbers have these properties.
So what about the decimal number 0.01 001 0001 00001 ... which does not end but also never repeats as each set of 0's-and-1's that we write has an extra 0 in it compared with the previous set.
But clearly no pattern of a fixed length repeats here and so this decimal does not represent any proper fraction.
Many important numbers that we use often in mathematics are non-fractional or non-ratio-nal numbers; they are called irrational numbers.
Probably the earliest number found to be irrational was √2 = 1.414213562373095... probably by Theodorus, the tutor of Plato, around 400BC.
- See section 4.5 in Introduction to the Theory of numbers by G H Hardy and E M Wright Oxford University Press, (6th edition, 2008)
- 1/√2 = 0.707106781... = cos(45°)
- 1+√2 = 2.414213562373095... = tan(67.5°)
- √3 = 1.732050807568877... = tan(60°)
- √3/2 = 0.866025403784 = sin(60°)
- π = 3.141592653589793... proved irrational by Lambert in 1761
- Φ = Phi = 1.6180339887..., φ = phi = 0..6180339887... the golden ratios
- e = 2.718281828459045..., the base of natural logarithms, proved irrational by Euler in 1737 who also introduced the use of the letter e for this number.
Things to do
- Find some more English words that begin with ir- where the ir- means not and negates the meaning of the rest of the word:
e.g. an irregular polygon is a polygon that is not regular (a regular polygon has all sides and all angles equal).This may be irrelevant or you may find it an irresistible challenge. ]
- Find some other words which begin with ir- which do not have this meaning.
I know an Irish man who likes to iron out such irritating questions.
No matter how far we go on expanding this number as an ever more precise decimal fraction, its decimal digits will never get into any repeating pattern.
There are lots of other irrational numbers too -- such as:
- the square root of any non-square number. The list of these begins 2, 3, 5, 6, 7, 8, 10, 11, 12, 13, 14, 15, 17, ... A000037
- the cube roots of any non-cube number. The list begins 2, 3, 4, 5, 6, 7, 9, 10, 11, 12, ... A004709 where we have omitted 23=8, 33=27, 43=64, ... A000578
- the fourth roots of any non-fourth-power number.
- and so on for all the nth-roots of non-nth-powers... 2, 3, 5, 6, 7, 10, 11, 12, 13, 14, ... A007916
where we omit 22=4, 23=8, 32=9, 24=42=16, 52=25, 33=27, 25=32, 62=36, ... A001597 - sines, cosines and tangents of most angles
- logs to any base of most numbers
Algebraic Numbers
Any number that is a root of a polynomial with integer or fractional coefficients is called an algebraic number
In finding methods of solving equations, we get a heirarchy from each type of polynomial with a different degree.The degree of a polynomial in x is the highest power of x in the polynomial.
For instance, a degree 1 polynomial in its most general form is a x = b for rational numbers (or integers) a and b.
It can be solved to give x = b/a which is a rational number or integer.
For degree 2, we have quadratic equations of the general form a x2 + b x + c = 0.
Here solutions involve square-roots in general and sometimes square-roots of negative numbers, which leads us to complex numbers x + i y where i = √ -1 .
If y is zero, the number is real and if not, it is complex.
Solving higher degree polynomial equations involvers no other types of number than complex numbers!
There are other numbers that are not the roots of any finite polynomial with rational coefficients: they are called transcendental numbers. Such numbers are π, e and many other trigonometric and logarithmic values.
It is generally quite hard to prove a number is transcendental since we have to show it is not the root of any polynomial with rational coefficients.
Fraction ↔ Decimal in any base Calculator
A Fractions to Decimal and Decimal to Fraction Calculators for any base not just base 10 (decimal) is on a separate page: Fractions - Decimal Calculator .
References
In date order, earliest first:- Of the Theory of Circulating Decimal Fractions Robertson, Philosophical Trans. (1768), pg 207
was perhaps the first to use the dot notation to indicate the periodic part of a decimal fraction.
See the next reference, footnote on page 379 - Disquisitiones Arithmeticae Carl Fredrich GAUSS, translated into English by Arthur A Clark, (Yale 1965)
The classic and famous book that astonished the mathematical world when it first came out (in Latin) dating from initial sections 1810 to the full book in 1863. It introduces the modulus, remainders and congruence arithmetic and all its many applications which were quite new when they first appeared.
Sections 309-18 deal with decimal fractions and periods. - The Enjoyment of Mathematics - Selections from Mathematics for the Amateur H Rademacher, O Toeplitz (Dover 1990).
This is the Dover edition of an English translation of the original German work of 1933. It is a great book of chapters on lots of mathematical topics suitable to the non-specialist-but-fairly-serious "amateur". Chapter 23 on Periodic Decimal Fractions is the fullest treatment of the subject that I have found and is recommended although all of it is incorporated into this page. - The Decimal Expansion of 1/89 and Related Results C T Long Fibonacci Quarterly 19 (1981) 53-55 (pdf )
- A Complete Characterization of the Decimal Fractions That Can be Represented as Σ 10-k(i+1) Fai where Fai Is the ai-th Fibonacci Number R H Hudson, C F Winans Fibonacci Quarterly 19 (1981) 414-422 (pdf )
- The General Solution to the Decimal Fraction of Fibonacci Series Pin-Yen Lin Fibonacci Quarterly 22 (1984) 229-234 (pdf )
- Generating Functions of Fibonacci-Like Sequences and Decimal Expansions of Some Fractions G Köhler Fibonacci Quarterly 23 (1985) 29-35 (pdf )
- Retrograde Renegades and the Pascal Connection: Repeating Decimals Represented by Fibonacci and Other Sequences Appearing from Right to Left M Bicknell-Johnson, Fibonacci Quarterly 27 (1989) 448-457 (pdf )
- Retrograde Renegades and the Pascal Connection II: Repeating Decimals Represented by Sequences of Diagonal Sums of Generalized Pascal Triangles Appearing from Right to Left M Bicknell-Johnson, Fibonacci Quarterly 31 (1993) 346-353 (pdf )
- Designer Decimals: Fractions which contain second order recursion sequences in their decimal expansions, reading left to right or right to left M Bicknell-Johnson, in Applications of Fibonacci Numbers Vol 5 eds G Bergum, A Philippou, A Horadam, Kluwer (1993) pgs 69-75.
- A Note on Some Irrational Decimal Fractions, A. McD. Mercer, American Mathematical Monthly Vol. 101 (1994), pages 567-8.
- Introduction to the Theory of numbers by G H Hardy and E M Wright Oxford University Press, (6th edition, 2008), paperback. Another classic book on Number Theory that covers decimal fractions and periods in detail.
© 2000-2019 Dr Ron Knott updated 30 December 2018
How To Get A Fraction To A Decimal
Source: http://www.maths.surrey.ac.uk/hosted-sites/R.Knott/Fractions/fractions.html
Posted by: williamsthring83.blogspot.com
0 Response to "How To Get A Fraction To A Decimal"
Post a Comment