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.

A101993 Indices k for which the numerator of Sum_{i=2..k} ( (-1)^i/(i * phi(i)) ) is a prime number.

Original entry on oeis.org

4, 6, 7, 9, 10, 13, 16, 21, 27, 35, 39, 41, 45, 48, 52, 76, 84, 94, 119, 150, 165, 190, 251, 260, 264, 306, 416, 428, 488, 513, 521, 523, 553, 615, 622, 640, 711, 714, 765, 797, 807, 888, 967, 1146, 1292, 1555, 1602, 1750, 1822, 1859, 1868, 1950, 2009, 2059
Offset: 1

Views

Author

Orges Leka (oleka(AT)students.uni-mainz.de), Dec 23 2004

Keywords

Examples

			a(1) = 4 because numerator of Sum_{i=2..4} ((-1)^i/(i * phi(i))) is 11 and 11 is a prime number.
		

Crossrefs

Cf. A000010 (Euler's totient function phi(n)).
Cf. A101992 (the sequence of the numerator of the sum described in the name of the current sequence).

Programs

  • Mathematica
    (* Defining the sum: *) f[n_Integer] /; n >= 2 := Sum[(-1)^(i)/(i EulerPhi[i]), {i, 2, n}] (* Generating the sequence: *) PhiPrimes[n_Integer] /; n >= 2 := Flatten[Table[If[PrimeQ[Numerator[f[i]]], i, {}], {i, 2, n}]] (* Checking if a given n is a phi-prime: *) PhiPrimeQ[n_Integer] /; n >= 2 := If[PrimeQ[ Numerator[f[n]]], Numerator[f[n]], "not a phi-prime"]
    Select[Range[2, 1300], PrimeQ[Numerator[Sum[(-1)^i/(i*EulerPhi[i]), {i, 2, #}]]] &] (* Stefan Steinerberger, Apr 02 2006 *)
  • PARI
    isok(n) = isprime(numerator(sum(k=2, n, (-1)^k/(k*eulerphi(k))))); \\ Michel Marcus, Aug 27 2015

Extensions

More terms from Stefan Steinerberger, Apr 02 2006
More terms from Amiram Eldar, Jul 13 2019