This site is supported by donations to The OEIS Foundation.

 Annual Appeal: Please make a donation to keep the OEIS running. In 2018 we replaced the server with a faster one, added 20000 new sequences, and reached 7000 citations (often saying "discovered thanks to the OEIS"). Other ways to donate

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A049084 0 unless n is a prime p(k) when a(n) = k. 264
 0, 1, 2, 0, 3, 0, 4, 0, 0, 0, 5, 0, 6, 0, 0, 0, 7, 0, 8, 0, 0, 0, 9, 0, 0, 0, 0, 0, 10, 0, 11, 0, 0, 0, 0, 0, 12, 0, 0, 0, 13, 0, 14, 0, 0, 0, 15, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 17, 0, 18, 0, 0, 0, 0, 0, 19, 0, 0, 0, 20, 0, 21, 0, 0, 0, 0, 0, 22, 0, 0, 0, 23, 0, 0, 0, 0, 0, 24, 0, 0, 0 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,3 COMMENTS Equals row sums of triangle A143541. [Gary W. Adamson, Aug 23 2008] LINKS Reinhard Zumkeller, Table of n, a(n) for n = 1..10000 FORMULA a(n) = pi(n)*(pi(n)-pi(n-1)), pi=A000720. - Reinhard Zumkeller, Nov 30 2003 a(n) = A000720(n*A010051(n)). - Labos Elemer, Jan 09 2004 a(n) = A000720(n)*A010051(n). - R. J. Mathar, Mar 01 2011 MAPLE A049084 := proc(n) local i; if(isprime(n)) then for i from 1 to 1000000 do if(ithprime(i) = n) then RETURN(i); fi; od; else RETURN(0); fi; end; MATHEMATICA a[n_] := PrimePi[n]*Boole[PrimeQ[n]]; Table[a[n], {n, 1, 92}] (* Jean-François Alcover, Nov 07 2011, after R. J. Mathar *) PROG (Haskell) import Data.List (unfoldr) a049084 n = a049084_list !! (fromInteger n - 1) a049084_list = unfoldr x (1, 1, a000040_list) where    x (i, z, ps'@(p:ps)) | i == p = Just (z, (i + 1, z + 1, ps))                         | i /= p = Just (0, (i + 1, z, ps')) -- Reinhard Zumkeller, Apr 17 2012, Mar 31 2012, Sep 15 2011 (PARI) a(n)=if(isprime(n), primepi(n), 0) \\ Charles R Greathouse IV, Jan 08 2013 CROSSREFS a(n) = A091227(A091202(n)). Cf. A143541. Sequence in context: A253274 A137303 A175682 * A234580 A108416 A215395 Adjacent sequences:  A049081 A049082 A049083 * A049085 A049086 A049087 KEYWORD nonn,easy AUTHOR 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.

Last modified December 19 06:03 EST 2018. Contains 318245 sequences. (Running on oeis4.)