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.

A046051 Number of prime factors of Mersenne number M(n) = 2^n - 1 (counted with multiplicity).

Original entry on oeis.org

0, 1, 1, 2, 1, 3, 1, 3, 2, 3, 2, 5, 1, 3, 3, 4, 1, 6, 1, 6, 4, 4, 2, 7, 3, 3, 3, 6, 3, 7, 1, 5, 4, 3, 4, 10, 2, 3, 4, 8, 2, 8, 3, 7, 6, 4, 3, 10, 2, 7, 5, 7, 3, 9, 6, 8, 4, 6, 2, 13, 1, 3, 7, 7, 3, 9, 2, 7, 4, 9, 3, 14, 3, 5, 7, 7, 4, 8, 3, 10, 6, 5, 2, 14, 3, 5, 6, 10, 1, 13, 5, 9, 3, 6, 5, 13, 2, 5, 8
Offset: 1

Views

Author

Keywords

Comments

Length of row n of A001265.

Examples

			a(4) = 2 because 2^4 - 1 = 15 = 3*5.
From _Gus Wiseman_, Jul 04 2019: (Start)
The sequence of Mersenne numbers together with their prime indices begins:
        1: {}
        3: {2}
        7: {4}
       15: {2,3}
       31: {11}
       63: {2,2,4}
      127: {31}
      255: {2,3,7}
      511: {4,21}
     1023: {2,5,11}
     2047: {9,24}
     4095: {2,2,3,4,6}
     8191: {1028}
    16383: {2,14,31}
    32767: {4,11,36}
    65535: {2,3,7,55}
   131071: {12251}
   262143: {2,2,2,4,8,21}
   524287: {43390}
  1048575: {2,3,3,5,11,13}
(End)
		

Crossrefs

bigomega(b^n-1): A057951 (b=10), A057952 (b=9), A057953 (b=8), A057954 (b=7), A057955 (b=6), A057956 (b=5), A057957 (b=4), A057958 (b=3), this sequence (b=2).

Programs

  • Mathematica
    a[q_] := Module[{x, n}, x=FactorInteger[2^n-1]; n=Length[x]; Sum[Table[x[i][2], {i, n}][j], {j, n}]]
    a[n_Integer] := PrimeOmega[2^n - 1]; Table[a[n], {n,200}] (* Vladimir Joseph Stephan Orlovsky, Jul 22 2011 *)
  • PARI
    a(n)=bigomega(2^n-1) \\ Charles R Greathouse IV, Apr 01 2013

Formula

Mobius transform of A085021. - T. D. Noe, Jun 19 2003
a(n) = A001222(A000225(n)). - Michel Marcus, Jun 06 2019