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.

A014234 Largest prime <= 2^n.

Original entry on oeis.org

2, 3, 7, 13, 31, 61, 127, 251, 509, 1021, 2039, 4093, 8191, 16381, 32749, 65521, 131071, 262139, 524287, 1048573, 2097143, 4194301, 8388593, 16777213, 33554393, 67108859, 134217689, 268435399, 536870909, 1073741789, 2147483647, 4294967291, 8589934583, 17179869143, 34359738337, 68719476731, 137438953447
Offset: 1

Views

Author

Keywords

Comments

For n>1 largest prime factor of the denominator of A027611(2^n) = 2^n*(2^n)-th harmonic number. - Alexander Adamchuk, Aug 02 2006

References

  • D. E. Knuth, The Art of Computer Programming. Addison-Wesley, Reading, MA, Vol. 2, p. 390.

Crossrefs

Cf. A013603 (2^n - a(n)).
See comment for the relationship to A027611.
These primes have indices A007053 = number of primes <= 2^n.
The opposite is A104080, delta A092131, indices A372684.
For squarefree instead of prime we have A372889, indices A143658.
A036378 counts primes between powers of 2, A293697 adds them up.

Programs

  • Maple
    a:= n-> prevprime(2^n+1):
    seq(a(n), n=1..40);  # Alois P. Heinz, Apr 23 2020
  • Mathematica
    PrevPrim[n_] := Block[{k = n - 1}, While[ !PrimeQ[k], k-- ]; k]; Table[ Abs[ PrevPrim[2^n]], {n, 1, 30} ]
    Join[{2},NextPrime[2^Range[2,40],-1]] (* Harvey P. Dale, Jun 26 2011 *)
  • PARI
    a(n) = precprime(2^n) \\ Michel Marcus, Aug 08 2013

Extensions

Terms for n=31, n=32 added by Fred Curtis (fred(AT)f2.org), Dec 08 2009