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.

A334871 Number of steps needed to reach 1 when starting from n and iterating with A334870.

Original entry on oeis.org

0, 1, 2, 2, 4, 3, 8, 3, 3, 5, 16, 4, 32, 9, 6, 3, 64, 4, 128, 6, 10, 17, 256, 5, 5, 33, 5, 10, 512, 7, 1024, 4, 18, 65, 12, 4, 2048, 129, 34, 7, 4096, 11, 8192, 18, 7, 257, 16384, 5, 9, 6, 66, 34, 32768, 6, 20, 11, 130, 513, 65536, 8, 131072, 1025, 11, 4, 36, 19, 262144, 66, 258, 13, 524288, 5, 1048576, 2049, 7, 130
Offset: 1

Views

Author

Antti Karttunen, Jun 08 2020

Keywords

Comments

Distance of n from the root (1) in binary trees like A334860 and A334866.
Each n > 0 occurs 2^(n-1) times.
a(n) is the size of the inner lining of the integer partition with Heinz number A225546(n), which is also the size of the largest hook of the same partition. (After Gus Wiseman's Apr 02 2019 comment in A252464).

Crossrefs

Programs

  • PARI
    A334870(n) = if(issquare(n),sqrtint(n),my(c=core(n), m=n); forprime(p=2, , if(!(c % p), m/=p; break, m*=p)); (m));
    A334871(n) = { my(s=0); while(n>1,s++; n = A334870(n)); (s); };
    
  • PARI
    \\ Much faster:
    A048675(n) = { my(f = factor(n)); sum(k=1, #f~, f[k, 2]*2^primepi(f[k, 1]))/2; };
    A334871(n) = { my(s=0); while(n>1, if(issquare(n), s++; n = sqrtint(n), s += A048675(core(n)); n /= core(n))); (s); };

Formula

a(1) = 0; for n > 1, a(n) = 1 + a(A334870(n)).
a(n) = A252464(A225546(n)).
a(n) = A048675(A007913(n)) + a(A008833(n)).
For n > 1, a(n) = 1 + A048675(A007913(n)) + a(A000188(n)).
For n > 1, a(n) = A070939(A334859(n)) = A070939(A334865(n)).
For all n >= 1, a(n) >= A299090(n).
For all n >= 1, a(n) >= A334872(n).