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.

A198069 Table read by rows, T(0,0) = 1 and for n>0, 0<=k<=2^(n-1) T(n,k) = gcd(k,2^(n-1)).

This page as a plain text file.
%I A198069 #14 Oct 30 2021 17:43:48
%S A198069 1,1,1,2,1,2,4,1,2,1,4,8,1,2,1,4,1,2,1,8,16,1,2,1,4,1,2,1,8,1,2,1,4,1,
%T A198069 2,1,16,32,1,2,1,4,1,2,1,8,1,2,1,4,1,2,1,16,1,2,1,4,1,2,1,8,1,2,1,4,1,
%U A198069 2,1,32,64,1,2,1,4,1,2,1,8,1,2,1,4,1,2
%N A198069 Table read by rows, T(0,0) = 1 and for n>0, 0<=k<=2^(n-1) T(n,k) = gcd(k,2^(n-1)).
%H A198069 Reinhard Zumkeller, <a href="/A198069/b198069.txt">Rows n = 0..13 of triangle, flattened</a>
%F A198069 For n > 0: Let S be the n-th row, S' = replace the initial term by its double, then row (n+1) = concatenation of S' and the reverse of S' without the initial term. - _Reinhard Zumkeller_, May 26 2013
%e A198069                          1
%e A198069                         1, 1
%e A198069                       2, 1, 2
%e A198069                    4, 1, 2, 1, 4
%e A198069              8, 1, 2, 1, 4, 1, 2, 1, 8
%e A198069 16, 1, 2, 1, 4, 1, 2, 1, 8, 1, 2, 1, 4, 1, 2, 1, 16
%p A198069 # In triangular form:
%p A198069 seq(print(seq(gcd(k,2^(n-1)),k=0..2^(n-1))),n=0..6);
%t A198069 Join[{1},Flatten[Table[GCD[k,2^(n-1)],{n,10},{k,0,2^(n-1)}]]] (* _Harvey P. Dale_, Oct 30 2021 *)
%o A198069 (Haskell)
%o A198069 a198069 n k = a198069_tabf !! n !! k
%o A198069 a198069_row n = a198069_tabf !! n
%o A198069 a198069_tabf = [0] : iterate f [1, 1] where
%o A198069    f (x:xs) = ys ++ tail (reverse ys) where ys = (2 * x) : xs
%o A198069 -- _Reinhard Zumkeller_, May 26 2013
%Y A198069 Cf. A094373 (row lengths), A045623 (row sums), A011782 (edges and central terms).
%K A198069 nonn,tabf
%O A198069 0,4
%A A198069 _Peter Luschny_, Nov 12 2011