Problem

Source: Iran 2024 3rd round number theory exam P1

Tags: number theory



Given a sequence $x_1,x_2,x_3,\cdots$ of positive integers, Ali proceed the following algorythm: In the i-th step he markes all rational numbers in the interval $[0,1]$ which have denominator equal to $x_i$. Then he write down the number $a_i$ equal to the length of the smallest interval in $[0,1]$ which both two ends of that is a marked number. Find all sequences $x_1,x_2,x_3,\cdots$ with $x_5=5$ and such that for all $n\in \mathbb N$ we have $$ a_1+a_2+\cdots+a_n= 2-\dfrac{1}{x_n}. $$ Proposed by Mojtaba Zare