OFFSET
0,6
COMMENTS
"Add" (meaning here to add the numerators and add the denominators, not to add the fractions) 1/0 to 1/1 to make the fraction bigger: 2/1, 3/1. Now 3/1 is too big, so add 2/1 to make the fraction smaller: 5/2, 8/3, 11/4. Now 11/4 is too small, so add 8/3 to make the fraction bigger: 19/7, ...
LINKS
Dave Rusin, Farey fractions on sci.math [Broken link]
Dave Rusin, Farey fractions on sci.math [Cached copy]
EXAMPLE
The fractions are 1/0, 0/1, 1/1, 2/1, 3/1, 5/2, 8/3, 11/4, 19/7, ...
MATHEMATICA
f[x_, n_] := (m = Floor[x]; f0 = {m, m+1/2, m+1}; r = ({a___, b_, c_, d___} /; b < x < c) :> {b, (Numerator[b] + Numerator[c]) / (Denominator[b] + Denominator[c]), c};
Join[{m, m+1}, NestList[# /. r &, f0, n-3][[All, 2]]]);
Join[{0, 1, 1}, f[E, 43] // Denominator]
(* Jean-François Alcover, May 18 2011 *)
CROSSREFS
KEYWORD
easy,frac,nonn
AUTHOR
Joshua Zucker, May 08 2006
STATUS
approved