TITLE: Given dividend and divisor, can we know the length of nonrepeating part and repeating part?
QUESTION [12 upvotes]: $13/92=0.14\overline{1304347826086956521739}$
In this example, the length of nonrepeating part is $2$. The length of repeating part (repeating period) is $22$.
I collected some properties related to repeating decimals.

The repeating period must be less than divisor.-- It doesn't give me
the exact period. 
If divisor d is a multiple of $2^m 5^n$, the length of non-repeating part of
$1\div d$ is $\max(m,n)$. -- It only applies to $1\div d$.
If $1 \leqslant  b < a$, and $a$ is not a multiple of $2$ or $5$, and $a$ and $b$ are  relatively prime, then the repeating period of $b\div a$ equals $\operatorname{min}\left \{ e\in \mathbb{N}:10^e\equiv 1 \pmod{a}  \right \}$. -- It has many conditions.

Without calculating the decimal, can we determine the length of the two parts of any dividend and divisor?

REPLY [2 votes]: You mean "are relatively prime" in your third point?
In general, take any non-negative rational $r = \frac{p}{q}$ such that $\gcd(p,q) = 1$.
Let $a,b,c \in \mathbb{N}$ such that $q = 2^a 5^b c$ and $\gcd(c,10) = 1$.
Then $10^{\phi(c)} \equiv 1 \pmod{c}$, by Fermat's little theorem.
Let $k = ord_c(10) = \min \{ x : x \in \mathbb{N}_{>0} \wedge 10^x \equiv 1 \pmod{c} \}$.
Then $k \mid \phi(c)$, but in general is hard to compute.
Let $m = \max(a,b)$.
Then $q \mid (10^k-1)10^m$.
Let $n = p \dfrac{(10^k-1)10^m}{q} \in \mathbb{N}$.
Let $s,t \in \mathbb{N}$ such that $n = (10^k-1)s+t$ and $0 \le t < 10^k-1$.
Then $r = \dfrac{n}{(10^k-1)10^m} = 10^{-m} ( s + t \sum_{i=1}^\infty 10^{-ik} ) $.
If $r < 1$, $r = 0.s\overline{t}$ where $s,t$ are padded with zeros if necessary to total $m,k$ digits respectively.
Now the remaining question is whether the last part of $s$ concides with the last part of $t$, which would mean that the repeat starts earlier than after $m$ decimal places. That is not possible because any repeating decimal can be expressed as a fraction with denominator of that same form (power of ten times one less than another power of ten), which would contradict the minimality of $k$ and $m$ above.