← RoseCode

ROSECODE 488

Index of a Farey sequence

liuguangxi · Math ·

Let Fidx(n,k) denote the k-th term in the Farey sequence of order n. For example, the Farey sequence of order 5 is {0/1, 1/5, 1/4, 1/3, 2/5, 1/2, 3/5, 2/3, 3/4, 4/5, 1/1}, and the 7th term is 3/5, so Fidx(5,7)=3/5. You are also given Fidx(12,31)=7/11, Fidx(123,3141)=82/121.

Find Fidx(1234567890,314159265358979323). The answer should be represented as an irreducible fraction.
Thanks to czp for the idea.