cp's OEIS Frontend

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.

A356248 Image of 1 under repeated application of the map k -> (2k-1,2k,2k-1).

This page as a plain text file.
%I A356248 #20 Aug 01 2022 16:40:31
%S A356248 1,2,1,3,4,3,1,2,1,5,6,5,7,8,7,5,6,5,1,2,1,3,4,3,1,2,1,9,10,9,11,12,
%T A356248 11,9,10,9,13,14,13,15,16,15,13,14,13,9,10,9,11,12,11,9,10,9,1,2,1,3,
%U A356248 4,3,1,2,1,5,6,5,7,8,7,5,6,5,1,2,1,3,4,3,1,2,1
%N A356248 Image of 1 under repeated application of the map k -> (2k-1,2k,2k-1).
%F A356248 If A(n) = (a(0),a(1),...,a(3^n-1)), then A(n+1) = (A(n),2^n+A(n),A(n)).
%F A356248 a(n) = A289813(n) + 1. - _Rémy Sigrist_, Jul 31 2022
%e A356248 1 --> 1 2 1 --> 1 2 1 3 4 3 1 2 1 --> 1 2 1 3 4 3 1 2 1 5 6 5 7 8 7 5 6 5 1 2 1 3 4 3 1 2 1 -->...
%o A356248 (Python)
%o A356248 def aupton(terms):
%o A356248     a, n = [1], 0
%o A356248     while len(a) < 3*terms: a, n = a + [(1<<n) + ai for ai in a] + a, n+1
%o A356248     return a[:terms]
%o A356248 print(aupton(81)) # _Michael S. Branicky_, Jul 31 2022
%o A356248 (PARI) a(n) = fromdigits(digits(n,3)%2,2) + 1; \\ _Kevin Ryde_, Jul 31 2022
%Y A356248 Cf. A289813.
%K A356248 nonn
%O A356248 0,2
%A A356248 _Arie Bos_, Jul 31 2022