# Periodic decimal numbers as series: generating fractions

The periodic decimal numbers as every kind of decimal numbers have own generating fraction. In this post, we provide a general proof of the method usually used for converting them to fractions. Let us remember what consists this method.

To calculate the generating fraction of a generic periodic decimal number, i.e. \(i_n\cdots i_0.d_1\cdots d_m\overline{d_{m+1}\cdots d_p}\), where \(i_h, d_k\in \lbrace 0, 1, 2, 3, 4, 5, 6, 7, 8, 9\rbrace\) and the overlined digits constitute the period of the number, it is necessary to:

- write the number without both the decimal separator (here represented by the dot) and overlining, i.e. \(i_n\cdots i_0d_1\cdots d_m d_{m+1}\cdots d_p\)
- substract, from the number obtained at the previous point 1, the number made of all the digits that precede the period, i.e. \(i_n\cdots i_0d_1\cdots d_m d_{m+1}\cdots d_p-i_n\cdots i_0d_1\cdots d_m\)
- divide the result found by a number formed by \(p-m\) digits equal to \(9\) (the number of the digits of the period) followed by \(m\) digits equal to \(0\) for each digit of the fractional part that precedes the period, i.e.

\(\displaystyle \frac{i_n\cdots i_0d_1\cdots d_m d_{m+1}\cdots d_p-i_n\cdots i_0d_1\cdots d_m}{\underbrace{9\cdots9}_\text{$p-m$ times}\underbrace{0\cdots0}_\text{$m$ times}}\).

All the three points of the method are here synthesized in the following theorem.

**Theorem ***Let \(i_n\cdots i_0,d_1\cdots d_m\overline{d_{m+1}\cdots d_p}\) be a generic periodic decimal number, where \(i_h, d_k\in \lbrace 0, 1, 2, 3, 4, 5, 6, 7, 8, 9\rbrace\) and the overlined digits constitute the period, then its generating fraction is given by the equation *

*\(\displaystyle i_n\cdots i_0,d_1\cdots d_m\overline{d_{m+1}\cdots d_p}=\\\)*

*\(\displaystyle\frac{i_n\cdots i_0d_1\cdots d_md_{m+1}\cdots d_p-i_n\cdots i_0d_1\cdots d_m}{\underbrace{9\cdots9}_\text{$p-m$ times}\underbrace{0\cdots0}_\text{$m$ times}}\).*

**Proof **Let us use the polynomial expansion of \(i_n\cdots i_0,d_1\cdots d_m\overline{d_{m+1}\cdots d_p}\), which reads

\(\displaystyle i_n\cdots i_0+\sum_{h=1}^m \frac{d_h}{10^h}+\\\)

\(\displaystyle\frac{1}{10^m}\sum_{r=0}^{+\infty}\sum_{q=1}^{p-m}\frac{d_{m+q}}{10^{q+r\left(p-m\right)}}\).

At the aim to better highlight the presence of a geometric series, let us interchange the order of the double summation

\(\displaystyle i_n\cdots i_0+\sum_{h=1}^m \frac{d_h}{10^h}+\\\)

\(\displaystyle\frac{1}{10^m}\sum_{q=1}^{p-m}\frac{d_{m+q}}{10^q}\sum_{r=0}^{+\infty}\frac{1}{10^{r\left(p-m\right)}}\).

Since, the sum of the geometric series

\(\displaystyle\sum_{r=0}^{+\infty}\frac{1}{10^{r\left(p-m\right)}}\)

is equal to

\(\displaystyle \frac{1}{1-\displaystyle\frac{1}{10^{p-m}}}=\frac{10^{p-m}}{10^{p-m}-1}\),

we get

\(\displaystyle i_n\cdots i_0+\sum_{h=1}^m \frac{d_h}{10^h}+\\\)

\(\displaystyle\frac{1}{10^m}\sum_{q=1}^{p-m}\frac{d_{m+q}}{10^q}\frac{10^{p-m}}{10^{p-m}-1}\).

Focusing on the last term of the previous expression, it is possible to observe at the denominator that the factor \(10^{p-m}-1\) does not depend on the index \(q\) of the summation and for this reason we will move it out of the sum. Moreover, we can write the ratio \(\displaystyle\frac{10^{p-m}}{10^q}\) as the unique decimal power \(10^{p-m-q}\). All this leads to

\(\displaystyle i_n\cdots i_0+\sum_{h=1}^m \frac{d_h}{10^h}+\\\)

\(\displaystyle\frac{1}{10^m}\cdot\frac{1}{10^{p-m}-1}\sum_{q=1}^{p-m}d_{m+q}\cdot 10^{p-m-q}\).

Reducing the last expression as a unique fraction with denominator equal to \(10^m\left(10^{p-m}-1\right)\), we obtain

\(\frac{\displaystyle 10^m\left(10^{p-m}-1\right)\left(i_n\cdots i_0\right)}{\displaystyle 10^m\left(10^{p-m}-1\right)}+\\\)

\(\frac{\displaystyle \left(10^{p-m}-1\right)\sum_{h=1}^m d_h 10^{-h}}{\displaystyle 10^m\left(10^{p-m}-1\right)}+\\\)

\(\frac{\displaystyle \sum_{q=1}^{p-m}d_{m+q}10^{p-m-q}}{\displaystyle 10^m\left(10^{p-m}-1\right)}\).

However, the latter expression still needs some algebraic manipulation. In fact, multiplying the decimal powers between them, eventually moving them inside the summations where it is necessary, and grouping the terms with the positive sign separately from those with the negative sign, we reach the following expression

\(\frac{\displaystyle 10^p\left(i_n\cdots i_0\right)}{\displaystyle 10^m\left(10^{p-m}-1\right)}+\\\)

\(\frac{\displaystyle \sum_{h=1}^m d_h 10^{p-h}+\sum_{q=1}^{p-m}d_{m+q}10^{p-m-q}}{\displaystyle 10^m\left(10^{p-m}-1\right)}-\\\)

\(\frac{\displaystyle \left(i_n\cdots i_0\right)10^m+\sum_{h=1}^m d_h 10^{m-h}}{\displaystyle 10^m\left(10^{p-m}-1\right)} \).

We have reached the end of the proof. In fact, it is possible to see that the numerator of the first two fractions represents the given number \(i_n\cdots i_0d_1\cdots d_m d_{m+1}\cdots d_p\) without both the decimal separator and overlining, while the third one reproduces that integer number \(i_n\cdots i_0d_1\cdots d_m\) made of all the digits that precede the period of the given decimal periodic number. Lastly, as it is possible to recognize, the common denominator \(10^m\left(10^{p-m}-1\right)\) of the three fractions is equal to

\(\underbrace{9\cdots9}_\text{$p-m$ times}\underbrace{0\cdots0}_\text{$m$ times}\).

*Q.E.D.*

©Stefano Spezia. This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License.