login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A065357 a(n) = (-1)^pi(n) where pi(n) is the number of primes <= n. 3
1, 1, -1, 1, 1, -1, -1, 1, 1, 1, 1, -1, -1, 1, 1, 1, 1, -1, -1, 1, 1, 1, 1, -1, -1, -1, -1, -1, -1, 1, 1, -1, -1, -1, -1, -1, -1, 1, 1, 1, 1, -1, -1, 1, 1, 1, 1, -1, -1, -1, -1, -1, -1, 1, 1, 1, 1, 1, 1, -1, -1, 1, 1, 1, 1, 1, 1, -1, -1, -1, -1, 1, 1, -1, -1, -1, -1, -1, -1, 1, 1, 1, 1, -1, -1, -1, -1, -1, -1, 1, 1, 1, 1, 1, 1, 1, 1, -1, -1, -1, -1, 1, 1 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,1

LINKS

N. J. A. Sloane, Table of n, a(n) for n = 0..10000 (First 1000 terms from Harry J. Smith)

MATHEMATICA

(-1)^PrimePi[Range[0, 110]] (* Harvey P. Dale, Nov 02 2015 *)

PROG

(PARI) { for (n=0, 1000, if (n, a=(-1)^primepi(n), a=1); write("b065357.txt", n, " ", a) ) } \\ Harry J. Smith, Sep 30 2009

CROSSREFS

Cf. A000720, A065358.

Sequence in context: A130151 A143431 A064179 * A119665 A121241 A122188

Adjacent sequences:  A065354 A065355 A065356 * A065358 A065359 A065360

KEYWORD

easy,sign

AUTHOR

Jason Earls, Oct 31 2001

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 4 07:20 EDT 2021. Contains 346442 sequences. (Running on oeis4.)