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.

A362372 Inventory of powers. Initialize the sequence with '1'. Then record the number of powers of 1 thus far, then do the same for powers of 2 (2, 4, 8, ...), powers of 3, etc. When the count is zero, do not record a zero; rather start the inventory again with the powers of 1.

This page as a plain text file.
%I A362372 #42 May 06 2023 06:58:09
%S A362372 1,1,2,1,3,1,1,5,1,1,7,1,1,9,1,2,10,2,2,10,4,2,1,1,12,6,2,1,1,1,1,16,
%T A362372 8,2,2,1,1,1,1,1,2,21,12,2,2,1,1,1,1,1,2,26,15,2,2,1,1,1,1,1,2,31,18,
%U A362372 2,2,1,1,1,1,1,2,36,21,2,2,1,2,1,1,1
%N A362372 Inventory of powers. Initialize the sequence with '1'. Then record the number of powers of 1 thus far, then do the same for powers of 2 (2, 4, 8, ...), powers of 3, etc. When the count is zero, do not record a zero; rather start the inventory again with the powers of 1.
%C A362372 A variant of the inventory sequence, A342585.
%C A362372 The graph exhibits sharp jumps followed by a rapid decline forming a periodic hockey stick pattern. Larger-scale, near-linear structures also appear.
%C A362372 Periodic patterns in the relative frequency of any given number also are present. For example, perform a rolling count of the number of times 2 appears in the previous 40 entries.
%C A362372 Open question: will all positive integers appear in the sequence?
%H A362372 Michael S. Branicky, <a href="/A362372/b362372.txt">Table of n, a(n) for n = 0..10000</a> (first 4330 terms from Damon Lay)
%e A362372 As an irregular triangle, the table begins:
%e A362372    1;
%e A362372    1;
%e A362372    2, 1;
%e A362372    3, 1, 1;
%e A362372    5, 1, 1;
%e A362372    7, 1, 1;
%e A362372    9, 1, 2;
%e A362372   10, 2, 2;
%e A362372   10, 4, 2, 1, 1;
%e A362372   12, 6, 2, 1, 1, 1, 1;
%e A362372   16, 8, 2, 2, 1, 1, 1, 1, 1, 2;
%e A362372   ...
%e A362372 Initialize the sequence with '1'.
%e A362372 Powers of 1 are counted in the first column, powers of 2 in the second, powers of 3 in the third, etc.
%o A362372 (Python)
%o A362372 from collections import Counter
%o A362372 from sympy import divisors, perfect_power
%o A362372 def powers_in(n):
%o A362372     t = perfect_power(n) # False for n == 1
%o A362372     return [n] if not t else [t[0]**d for d in divisors(t[1])]
%o A362372 def aupton(nn):
%o A362372     num, alst, inventory = 1, [1], Counter([1])
%o A362372     while len(alst) <= nn:
%o A362372         c = inventory[num]
%o A362372         if c == 0: num = 1
%o A362372         else: num += 1; alst.append(c); inventory.update(powers_in(c))
%o A362372     return alst
%o A362372 print(aupton(100)) # _Michael S. Branicky_, May 05 2023
%Y A362372 Cf. A342585 and similar variants thereof: A345730, A347791, A348218, A352799, A353092.
%K A362372 easy,nonn,tabf
%O A362372 0,3
%A A362372 _Damon Lay_, Apr 17 2023