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 A006048 M2519 #42 Aug 13 2025 21:57:06 %S A006048 1,3,6,8,12,18,21,27,36,38,42,48,52,60,72,78,90,108,111,117,126,132, %T A006048 144,162,171,189,216,218,222,228,232,240,252,258,270,288,292,300,312, %U A006048 320,336,360,372,396,432,438,450,468,480,504,540,558,594,648,651,657,666,672,684,702,711,729,756,762,774,792,804,828,864,882,918,972,981,999,1026,1044,1080,1134,1161,1215,1296 %N A006048 Number of entries in first n rows of Pascal's triangle not divisible by 3. %D A006048 N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence). %H A006048 J.-P. Allouche and J. Shallit, <a href="http://dx.doi.org/10.1016/0304-3975(92)90001-V">The ring of k-regular sequences</a>, Theoretical Computer Sci., 98 (1992), 163-197. %H A006048 Hsien-Kuei Hwang, Svante Janson, and Tsung-Hsi Tsai, <a href="https://arxiv.org/abs/2210.10968">Identities and periodic oscillations of divide-and-conquer recurrences splitting at half</a>, arXiv:2210.10968 [cs.DS], 2022, p. 53. %H A006048 Hsien-Kuei Hwang, Svante Janson, and Tsung-Hsi Tsai, <a href="https://arxiv.org/abs/2408.06817">Periodic minimum in the count of binomial coefficients not divisible by a prime</a>, arXiv:2408.06817 [math.NT], 2024. See p. 1. %H A006048 Akhlesh Lakhtakia and Russell Messier, <a href="http://dx.doi.org/10.1016/0097-8493(89)90038-1">Self-similar sequences and chaos from Gauss sums</a>, Computers & graphics 13.1 (1989): 59-62. %H A006048 Akhlesh Lakhtakia and Russell Messier, <a href="/A005821/a005821.pdf">Self-similar sequences and chaos from Gauss sums</a>, Computers & Graphics 13.1 (1989), 59-62. (Annotated scanned copy) %H A006048 Akhlesh Lakhtakia and Russell Messier, <a href="/A006046/a006046.pdf">Self-similar sequences and chaos from Gauss sums</a>, Computers & Graphics 13.1 (1989), 59-60. (Annotated scanned copy) %H A006048 A. Lakhtakia et al., <a href="http://dx.doi.org/10.1088/0305-4470/21/8/030">Fractal sequences derived from the self-similar extensions of the Sierpinski gasket</a>, J. Phys. A 21 (1988), 1925-1928. %o A006048 (Python) %o A006048 from math import prod %o A006048 from gmpy2 import digits %o A006048 def A006048(n): return sum(prod(int(d)+1 for d in digits(m,3)) for m in range(n+1)) # _Chai Wah Wu_, Aug 10 2025 %o A006048 (Python) %o A006048 from math import prod %o A006048 from gmpy2 import digits %o A006048 def A006048(n): %o A006048 d = list(map(lambda x:int(x)+1,digits(n+1,3)[::-1])) %o A006048 return sum((b-1)*prod(d[a:])*6**a for a, b in enumerate(d))>>1 # _Chai Wah Wu_, Aug 13 2025 %Y A006048 Partial sums of A006047. %K A006048 nonn %O A006048 0,2 %A A006048 _Jeffrey Shallit_ %E A006048 More terms from _N. J. A. Sloane_, Apr 23 2025