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.

Showing 1-2 of 2 results.

A373094 a(n) is the least number k such that A373092(k) = n.

Original entry on oeis.org

1, 4, 7, 12, 24, 120, 1260, 1829520
Offset: 0

Views

Author

Amiram Eldar, May 23 2024

Keywords

Comments

a(n) is the least number k such that the number of iterations of the map x -> A093653(x) required to reach from k to a fixed point is n.
a(8) > 4*10^10.

Examples

			The iterations for the n = 0..7 are:
  n     a(n)  iterations
  -  -------  --------------------------------------------------
  0        1   1
  1        4   4 -> 3
  2        7   7 -> 4 -> 3
  3       12   12 -> 9 -> 5 ->3
  4       24   24 -> 12 -> 9 -> 5 -> 3
  5      120   120 -> 36 -> 15 -> 9 -> 5 -> 3
  6     1260   1260 -> 120 -> 36 -> 15 -> 9 -> 5 -> 3
  7  1829520   1829520 -> 1260 -> 120 -> 36 -> 15 -> 9 -> 5 -> 3
		

Crossrefs

Cf. A093653, A095347 (decimal analog), A373092.

Programs

  • Mathematica
    d[n_] := d[n] = DivisorSum[n, Plus @@ IntegerDigits[#, 2] &];
    f[n_] := -2 + Length@ FixedPointList[d, n];
    seq[len_] := Module[{s = Table[0, {len}], c = 0, i, n = 1}, While[c < len, i = f[n] + 1; If[i <= len && s[[i]] == 0, c++; s[[i]] = n]; n++]; s]; seq[7]
  • PARI
    f(n) = {my(c = 0); while(6 % n, n = sumdiv(n, d, hammingweight(d)); c++); c;}
    lista(len) = {my(s = vector(len), c = 0, i, n = 1); while(c < len, i = f(n) + 1; if(i <= len && s[i] == 0, c++; s[i] = n); n++); s;}

A373093 The fixed point of the iterations of the map x -> A093653(x) that start at n.

Original entry on oeis.org

1, 2, 3, 3, 3, 6, 3, 3, 3, 6, 3, 3, 3, 3, 3, 3, 3, 6, 3, 3, 3, 3, 3, 3, 6, 3, 3, 3, 3, 6, 6, 6, 3, 6, 3, 3, 3, 3, 6, 3, 3, 6, 3, 3, 3, 6, 6, 3, 3, 3, 3, 3, 3, 6, 3, 3, 6, 6, 6, 3, 6, 3, 3, 3, 3, 3, 3, 3, 6, 6, 3, 3, 3, 3, 3, 3, 3, 3, 6, 3, 3, 3, 3, 3, 3, 6, 3
Offset: 1

Views

Author

Amiram Eldar, May 23 2024

Keywords

Comments

Except for n = 1 and 2, all terms are either 3 or 6.
Do the asymptotic densities of the occurrences of 3 and 6 exist? The numbers of occurrences of 6 for n that do not exceed 10^k, for k = 1, 2, ..., are 2, 24, 234, 2735, 25321, 242398, 2605532, 27441386, 268518855, 2561508455, ... .

Examples

			The iterations for the n = 1..7 are:
  n  a(n)  iterations
  -  ----  -----------
  1    1   1
  2    2   2
  3    3   3
  4    3   4 -> 3
  5    3   5 -> 3
  6    6   6
  7    3   7 -> 4 -> 3
		

Crossrefs

Programs

  • Mathematica
    d[n_] := DivisorSum[n, Plus @@ IntegerDigits[#, 2] &]; a[n_] := FixedPointList[d, n][[-1]]; Array[a, 100]
  • PARI
    a(n) = {while(6 % n, n = sumdiv(n, d, hammingweight(d))); n;}
Showing 1-2 of 2 results.