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 A020986 #49 Feb 16 2025 08:32:34 %S A020986 1,2,3,2,3,4,3,4,5,6,7,6,5,4,5,4,5,6,7,6,7,8,7,8,7,6,5,6,7,8,7,8,9,10, %T A020986 11,10,11,12,11,12,13,14,15,14,13,12,13,12,11,10,9,10,9,8,9,8,9,10,11, %U A020986 10,9,8,9,8,9,10,11,10,11,12,11,12,13,14,15,14,13,12,13,12,13,14,15,14,15,16 %N A020986 a(n) = n-th partial sum of Golay-Rudin-Shapiro sequence A020985. %H A020986 Reinhard Zumkeller, <a href="/A020986/b020986.txt">Table of n, a(n) for n = 0..10000</a> %H A020986 John Brillhart and Patrick Morton, <a href="http://projecteuclid.org/euclid.ijm/1256048841">Über Summen von Rudin-Shapiroschen Koeffizienten</a>, (German) Illinois J. Math. 22 (1978), no. 1, 126--148. MR0476686 (57 #16245). - From _N. J. A. Sloane_, Jun 06 2012 %H A020986 J. Brillhart and P. Morton, <a href="http://www.maa.org/programs/maa-awards/writing-awards/a-case-study-in-mathematical-research-the-golay-rudin-shapiro-sequence">A case study in mathematical research: the Golay-Rudin-Shapiro sequence</a>, Amer. Math. Monthly, 103 (1996) 854-869. %H A020986 Philip Lafrance, Narad Rampersad, and Randy Yee, <a href="http://arxiv.org/abs/1408.2277">Some properties of a Rudin-Shapiro-like sequence</a>, arXiv:1408.2277 [math.CO], 2014. %H A020986 Narad Rampersad and Jeffrey Shallit, <a href="https://arxiv.org/abs/2302.00405">Rudin-Shapiro Sums Via Automata Theory and Logic</a>, arXiv:2302.00405 [math.NT], February 1 2023. %H A020986 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/Rudin-ShapiroSequence.html">Rudin-Shapiro Sequence</a> %H A020986 <a href="/index/Con#coordinates_2D_curves">Index entries for sequences related to coordinates of 2D curves</a> %F A020986 Brillhart and Morton (1978) list many properties. %t A020986 a[n_] := 1 - 2 Mod[Length[FixedPointList[BitAnd[#, # - 1] &, BitAnd[n, Quotient[n, 2]]]], 2]; Accumulate@ Table[a@ n, {n, 0, 85}] (* _Michael De Vlieger_, Nov 30 2015, after _Jan Mangaldan_ at A020985 *) %t A020986 Table[RudinShapiro[n], {n, 0, 100}] // Accumulate (* _Jean-François Alcover_, Jun 30 2022 *) %o A020986 (Haskell) %o A020986 a020986 n = a020986_list !! n %o A020986 a020986_list = scanl1 (+) a020985_list %o A020986 -- _Reinhard Zumkeller_, Jan 02 2012 %o A020986 (Python) %o A020986 def A020986(n): return sum(-1 if (m&(m>>1)).bit_count()&1 else 1 for m in range(n+1)) # _Chai Wah Wu_, Feb 11 2023 %Y A020986 Cf. A020985, A020990. %K A020986 nonn,nice %O A020986 0,2 %A A020986 _N. J. A. Sloane_ %E A020986 Minor edits by _N. J. A. Sloane_, Jun 06 2012