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.

A078444 Floor of geometric mean of two consecutive primes.

Original entry on oeis.org

2, 3, 5, 8, 11, 14, 17, 20, 25, 29, 33, 38, 41, 44, 49, 55, 59, 63, 68, 71, 75, 80, 85, 92, 98, 101, 104, 107, 110, 119, 128, 133, 137, 143, 149, 153, 159, 164, 169, 175, 179, 185, 191, 194, 197, 204, 216, 224, 227, 230, 235, 239, 245, 253, 259, 265, 269, 273, 278
Offset: 1

Views

Author

Lior Manor, Dec 31 2002

Keywords

Comments

For n > 1, a(n) = prime(n) iff prime(n) and prime(n+1) are twin primes.

Examples

			a(7) = floor(sqrt(prime(7)*prime(8))) = 17.
		

Crossrefs

Programs

  • Magma
    [Floor(Sqrt(NthPrime(n)*NthPrime(n+1))): n in [1..60]]; // Vincenzo Librandi, Dec 12 2015
    
  • Maple
    seq(floor(sqrt(ithprime(i)*ithprime(i+1))), i=1..100); # Robert Israel, Dec 12 2015
  • Mathematica
    Table[Floor[Sqrt[Prime[n] Prime[n + 1]]], {n, 60}] (* Vincenzo Librandi, Dec 12 2015 *)
    Table[Ceiling[(Prime[n] + Prime[n + 1])/2 - 1], {n, 100}] (* Miko Labalan, Dec 14 2015 *)
  • PARI
    a(n) = sqrtint(prime(n)*prime(n+1)); \\ Michel Marcus, Dec 12 2015

Formula

a(n) = floor(sqrt(prime(n)*prime(n+1))).
From Miko Labalan, Dec 12 2015: (Start)
a(n) = A006254(A028310(n - 1)) + A067076(n);
a(n) = A067076(A028310(n - 1)) + A006254(n);
a(n) = A005097(A028310(n - 1)) + A005097(n).
(End)
For n >= 2 these formulas are equivalent to sqrt(prime(n)*prime(n+1)) > (prime(n)+prime(n+1))/2 - 1, and thus to A001223(n) <= 2 + 2*sqrt(2*prime(n)). This would be implied by Andrica's conjecture, but is as yet unproven. - Robert Israel, Dec 13 2015