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.

A249780 Product of lowest and highest prime factors of 2^n-1.

Original entry on oeis.org

9, 49, 15, 961, 21, 16129, 51, 511, 93, 2047, 39, 67092481, 381, 1057, 771, 17179607041, 219, 274876858369, 123, 2359, 2049, 8388607, 723, 55831, 24573, 1838599, 381, 486737, 993, 4611686014132420609, 196611, 4196353, 393213, 3810551, 327, 137438953471, 1572861, 849583, 185043
Offset: 2

Views

Author

Jacob Vecht, Nov 05 2014

Keywords

Examples

			The lowest and higest prime factors of 2^6-1 are 3 and 7, so A(6) = 21
		

Programs

  • Maple
    a:= proc(n) local F; F:= numtheory:-factorset(2^n-1); min(F)*max(F) end proc:
    seq(a(n),n=2..50); # Robert Israel, Nov 05 2014
  • Mathematica
    plhpf[n_]:=Module[{fn=FactorInteger[n]},fn[[1,1]]fn[[-1,1]]]; Table[plhpf [2^n-1],{n,2,40}] (* Harvey P. Dale, May 23 2020 *)
  • PARI
    for(n=2, 50, p=2^n-1; print1(factor(p)[1, 1]*factor(p)[#factor(p)[, 1], 1], ", ")) \\ Derek Orr, Nov 05 2014
    
  • Python
    from sympy import primefactors
    A249780_list, x = [], 1
    for n in range(2,10):
        x = 2*x + 1
        p = primefactors(x)
        A249780_list.append(max(p)*min(p)) # Chai Wah Wu, Nov 05 2014

Formula

a(n) = A005420(n) * A049479(n)

Extensions

More terms from Derek Orr, Nov 05 2014