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-4 of 4 results.

A283364 Numbers m such that both numbers 2^m +- 1 have at most 2 distinct prime factors.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 9, 11, 13, 17, 19, 23, 31, 61, 101, 127, 167, 199, 347
Offset: 1

Views

Author

Vladimir Shevelev, Mar 06 2017

Keywords

Comments

If a(n) > 9 then a(n) is prime. Proof: If k = 2*m > 9 then 2^(2*m)-1 has at least 3 factors; being 3, (2^m - 1) / 3 and 2^m + 1 which excludes even numbers > 9.
If k = 2*m + 1 > 9 is not prime then k = p*q, q, p > 3 so 2^(p*q) + 1 is divisible by 3, 2^p + 1 and 2^q + 1. If p = q then 2^(p^2) + 1 is divisible by 3, 2^p + 1 and (2^p^2 + 1) / (2^p + 1) > 2^p + 1. Which excludes odd composite numbers > 9 and completes the proof. [comments reworded by David A. Corneth, Nov 23 2019]
Any further terms are > 1122. - Lucas A. Brown, Oct 21 2024

Crossrefs

Programs

  • Mathematica
    Select[Range@ 200, Times @@ Boole@ Map[PrimeNu@ # <= 2 &, 2^# + {-1, 1}] == 1 &] (* Michael De Vlieger, Mar 06 2017 *)
    Select[Range[350],Max[PrimeNu[2^#+{1,-1}]]<3&] (* Harvey P. Dale, Dec 23 2017 *)
  • PARI
    isok(n) = omega(2^n+1)<=2 && omega(2^n-1)<=2;
    for(n=1, 347, if(isok(n)==1, print1(n,", "))); \\ Indranil Ghosh, Mar 06 2017

Extensions

More terms from Peter J. C. Moses, Mar 06 2017

A337811 Numbers k such that the number of distinct prime factors of 2^k - 1 is less than the corresponding count for 2^k + 1.

Original entry on oeis.org

1, 5, 7, 13, 17, 19, 25, 26, 31, 34, 35, 37, 38, 41, 46, 49, 59, 61, 62, 65, 67, 77, 78, 83, 85, 89, 91, 93, 97, 98, 103, 107, 109, 118, 122, 123, 125, 127, 131, 133, 134, 137, 139, 143, 145, 147, 149, 153, 157, 170, 173, 175, 177, 185, 186, 189, 193, 194, 195
Offset: 1

Views

Author

Hugo Pfoertner, Sep 23 2020

Keywords

Crossrefs

Programs

  • Mathematica
    Select[Range[200],PrimeNu[2^#-1]Harvey P. Dale, Nov 04 2023 *)
  • PARI
    for(n=1,200,if(omega(2^n-1)
    				

A337813 Numbers k such that the number of distinct prime factors of 2^k - 1 is greater than the corresponding count for 2^k + 1.

Original entry on oeis.org

4, 8, 10, 12, 16, 20, 22, 24, 28, 30, 32, 36, 39, 40, 43, 44, 45, 48, 50, 52, 55, 56, 58, 60, 63, 64, 66, 68, 70, 72, 75, 76, 79, 80, 84, 87, 88, 90, 92, 94, 96, 99, 100, 102, 104, 106, 108, 110, 112, 116, 117, 119, 120, 124, 126, 128, 132, 135, 136, 140, 144
Offset: 1

Views

Author

Hugo Pfoertner, Sep 23 2020

Keywords

Crossrefs

Programs

  • PARI
    for(n=1,150,if(omega(2^n-1)>omega(2^n+1),print1(n,", ")))

A309942 Numbers k such that 2^k - 1 and 2^k + 1 have the same number of prime factors, counted with multiplicity.

Original entry on oeis.org

2, 10, 11, 14, 21, 23, 29, 39, 47, 50, 53, 55, 63, 71, 73, 74, 75, 82, 86, 95, 101, 105, 113, 115, 121, 142, 147, 150, 167, 169, 179, 181, 182, 190, 199, 203, 209, 233, 235, 253, 277, 285, 303, 307, 311, 317, 335, 337, 339, 342, 343, 347, 349, 353, 355, 358
Offset: 1

Views

Author

Hugo Pfoertner, Aug 24 2019

Keywords

Examples

			a(1) = 2: 2^2 - 1 = 3 and 2^2 + 1 are both prime,
a(2) = 10: 2^10 - 1 = 1023 = 3 * 11 * 31 and 2^10 + 1 = 1025 = 5^2 * 41 both have 3 prime factors.
		

Crossrefs

Programs

  • Magma
    [m:m in [2..400]| &+[p[2]: p in Factorization(2^m-1)] eq &+[p[2]: p in Factorization(2^m+1)]]; // Marius A. Burtea, Aug 24 2019
  • Mathematica
    Select[Range[200], PrimeOmega[2^# - 1 ] == PrimeOmega[2^# + 1 ] &] (* Amiram Eldar, Aug 24 2019 *)
  • PARI
    for(k=1, 209, my(f=bigomega(2^k-1),g=bigomega(2^k+1));if(f==g,print1(k,", ")))
    

Extensions

More terms from Amiram Eldar, Aug 24 2019
Showing 1-4 of 4 results.