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!)
A162308 Number of twin primes A001097 smaller than the non-twin prime A007510(n). 1

%I

%S 0,7,9,11,11,13,15,15,15,15,19,19,19,23,23,23,23,29,29,31,33,33,33,35,

%T 37,37,39,39,39,41,41,41,41,41,41,41,41,41,41,45,45,45,45,47,47,47,47,

%U 47,47,47,49,49,49,49,51,51,51,53,53,55,57,57,59,59,59,59,59,59,59

%N Number of twin primes A001097 smaller than the non-twin prime A007510(n).

%e a(2)=7 counts the numbers 3, 5, 7, 11, 13, 17, 19 below 23=A007510(2).

%p isA007510 := proc(n) RETURN(isprime(n) and not isprime(n-2) and not isprime(n+2)) ; end:

%p isA001097 := proc(n) RETURN(isprime(n) and (isprime(n-2) or isprime(n+2)) ) ; end:

%p A007510 := proc(n) local a; if n = 1 then 2; else for a from procname(n-1)+1 do if isA007510(a) then RETURN(a) ; fi; od: fi; end:

%p A162308 := proc(n) local a,k; a := 0 ; for k from 3 to A007510(n)-1 do if isA001097(k) then a := a+1; fi; od; a; end:

%p seq(A162308(n),n=1..120) ; # _R. J. Mathar_, Jul 02 2009

%Y Cf. A000040, A073425.

%K nonn

%O 1,2

%A _Juri-Stepan Gerasimov_, Jul 01 2009

%E Edited by _R. J. Mathar_, Jul 02 2009

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 January 26 01:48 EST 2020. Contains 331270 sequences. (Running on oeis4.)