This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A138703 #21 Apr 14 2023 10:53:32 %S A138703 1,2,6,0,30,0,42,0,30,0,18,0,37,0,7,0,28,0,96,0,559,0,6210,0,86617,0, %T A138703 1425523,0,27298263,0,601580913,0,15116315788,0,429614643067,0, %U A138703 13711655205344,0,488332318973599,0,19296579341940107,0,841693047573684421,0,40338071854059455479 %N A138703 a(n) is the sum of the terms in the continued fraction of the absolute value of B_n, the n-th Bernoulli number. %C A138703 For all odd n >=3, a(n) = 0. %H A138703 Jinyuan Wang, <a href="/A138703/b138703.txt">Table of n, a(n) for n = 0..635</a> %e A138703 The 12th Bernoulli number is -691/2730. Now 691/2730 = the continued fraction 0 + 1/(3 + 1/(1 + 1/(19 + 1/(3 + 1/11)))). So a(12) = 0 + 3 + 1 + 19 + 3 + 11 = 37. %p A138703 A138701row := proc(n) local B; B := abs(bernoulli(n)) ; numtheory[cfrac](B,20,'quotients') ; end: A138703 := proc(n) add(c,c=A138701row(n)) ; end: seq(op(A138703(n)),n=0..80) ; # _R. J. Mathar_, Jul 20 2009 %t A138703 Table[ ContinuedFraction[ BernoulliB[n] // Abs] // Total, {n, 0, 50}] (* _Jean-François Alcover_, Mar 27 2013 *) %o A138703 (PARI) a(n) = vecsum(contfrac(abs(bernfrac(n)))); \\ _Jinyuan Wang_, Aug 07 2021 %o A138703 (Python) %o A138703 from sympy import continued_fraction, bernoulli %o A138703 def A138703(n): return sum(continued_fraction(abs(bernoulli(n)))) # _Chai Wah Wu_, Apr 14 2023 %Y A138703 Cf. A027641/A027642, A138701, A138702, A138706. %K A138703 nonn %O A138703 0,2 %A A138703 _Leroy Quet_, Mar 26 2008 %E A138703 Extended beyond a(15) by _R. J. Mathar_, Jul 20 2009 %E A138703 More terms from _Jean-François Alcover_, Mar 27 2013