OFFSET
3,3
COMMENTS
LINKS
Reinhard Zumkeller, Table of n, a(n) for n = 3..1000
Paul Yiu, Recreational Mathematics, 24.3.1 Appendix: Two enumerations of the rational numbers in (0,1), page 633.
EXAMPLE
. ----+----------------------------------+---------+---------+--------
. 3 | 1/2 | 1 | 2 | 0
. 4 | 1/3 | 1 | 3 | 0
. 5 | 1/4, 2/3 | 11 | 12 | 0
. 6 | 1/5 | 1 | 5 | 0
. 7 | 1/6, 2/5, 3/4 | 79 | 60 | 1
. 8 | 1/7, 3/5 | 26 | 35 | 0
. 9 | 1/8, 2/7, 4/5 | 339 | 280 | 1
. 10 | 1/9, 3/7 | 34 | 63 | 0
. 11 | 1/10, 2/9, 3/8, 4/7, 5/6 | 5297 | 2520 | 2
. 12 | 1/11, 5/7 | 62 | 77 | 0
. 13 | 1/12, 2/11, 3/10, 4/9, 5/8, 6/7 | 69071 | 27720 | 2
. 14 | 1/13, 3/11, 5/9 | 1165 | 1287 | 0
. 15 | 1/14, 2/13, 4/11, 7/8 | 11723 | 8008 | 1
. 16 | 1/15, 3/13, 5/11, 7/9 | 9844 | 6435 | 1 .
PROG
(Haskell)
import Data.Ratio ((%), numerator)
a245677 n = numerator $ sum
[num % den | num <- [1 .. div n 2], let den = n - num, gcd num den == 1]
CROSSREFS
KEYWORD
nonn,frac
AUTHOR
Reinhard Zumkeller, Jul 30 2014
STATUS
approved