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.

A053047 a(n) is the first (and maximal) power of 2 arising during iterations of the Euler phi function with initial value n!.

Original entry on oeis.org

1, 2, 2, 8, 32, 64, 128, 1024, 1024, 8192, 65536, 262144, 1048576, 4194304, 16777216, 268435456, 4294967296, 8589934592, 17179869184, 274877906944, 549755813888, 8796093022208, 140737488355328, 1125899906842624
Offset: 1

Views

Author

Labos Elemer, Feb 25 2000

Keywords

Examples

			For n = 10, the initial value is 10! = 3628800 and the iteration chain is {3628800, 829440, 221184, 73728, 24576, 8192, 4096, 2048, 1024, 512, 256, 128, 64, 32, 16, 8, 4, 2, 1}. The first power of 2 is the 6th element, arising after 5 iterations of phi, and its value is 8192.
		

Crossrefs

Formula

a(n) = 2^A053048(n). - Amiram Eldar, Aug 17 2024

A053099 When the Euler phi function is iterated with initial value A002110(n) = n-th primorial, a(n) = exponent of largest power of 2 arising in the iteration.

Original entry on oeis.org

1, 1, 3, 4, 7, 9, 13, 14, 18, 21, 24, 26, 31, 33, 38, 42, 46, 50, 54, 58, 61, 64, 70, 76, 81, 87, 92, 97, 99, 104, 106, 111, 118, 123, 127, 132, 136, 137, 144, 148, 155, 159, 163, 169, 173, 177, 181, 184, 190, 193, 199, 205, 211, 218, 226, 232, 238, 241, 247, 253
Offset: 1

Views

Author

Labos Elemer, Feb 28 2000

Keywords

Comments

Analogous to A053048.

Examples

			For n = 6, A002110(6) = 30030, the corresponding iteration chain is {30030, 5760, 1536, 512, 256, 128, 64, 32, 16, 8, 4, 2, 1}. The first power of 2 is the 4th item after 3 iterations. It is 512, therefore a(6) = log_2(512) = 9 and a(6) + 1 = 10 iterations is needed to reach the stationary value = 1.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := Max@ IntegerExponent[ FixedPointList[ EulerPhi, Times @@ Prime[ Range@ n]], 2]; Array[a, 60] (* Giovanni Resta, May 30 2018 *)
  • PARI
    a(n) = {my(p = prod(i=1, n, prime(i))); while(p >> valuation(p, 2) > 1, p = eulerphi(p)); valuation(p, 2);} \\ Amiram Eldar, Nov 19 2024

Formula

a(n) = log_2(A053098(n)). - Amiram Eldar, Nov 19 2024
Showing 1-2 of 2 results.