login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


A167511
The count of isolated primes between n-th non-isolated nonprime and n-th isolated nonprime.
4
1, 1, 0, 0, 1, 2, 4, 5, 9, 9, 12, 11, 15, 15, 15, 17, 18, 21, 22, 24, 27, 36, 36, 40, 47, 51, 54, 55, 56, 58, 76, 76, 75, 77, 79, 96, 96, 97, 97, 99, 105, 114, 116, 117, 118, 119, 127, 130, 132, 132, 146, 147, 151, 151, 152, 159, 166, 166, 169, 169, 173, 176, 180, 180, 181
OFFSET
1,6
FORMULA
a(n) = #{ A007510(i): A164276(n) < A007510(i) < A014574(n)}. [From R. J. Mathar, Mar 18 2010]
a(n) = SUM{A010051(k)*(1-A164292(k)): A164276(n)<=k<=A014574(n)}. [From Reinhard Zumkeller, Apr 02 2010]
EXAMPLE
a(1)=1 (0<2<4); a(2)=1 (1<2<6); a(3)=0 (8<no<12); a(4)=0 (9<no<18); a(5)=1 ( 10<23<30); a(5)=2 (14<23&37<42); a(5)=4 (15<23&37&47&53<60).
MAPLE
Contribution from R. J. Mathar, Mar 18 2010: (Start)
isA007510 := proc(n) isprime(n) and not isprime(n+2) and not isprime(n-2) ; end proc:
isA001359 := proc(n) isprime(n) and isprime(n+2) ; end proc:
A001359 := proc(n) if n = 1 then 3 ; else for a from procname(n-1)+2 do if isA001359(a) then return a; end if; end do: end if: end proc:
isA164276 := proc(n) not isprime(n) and (not isprime(n-1) or not isprime(n+1)) ; end proc:
A164276 := proc(n) if n = 1 then 0; else for a from procname(n-1)+1 do if isA164276(a) then return a; end if; end do: end if: end proc:
A014574 := proc(n) A001359(n)+1 ; end proc:
A167511 := proc(n) a := 0 ; for i from A164276(n)+1 to A014574(n)-1 do if isA007510(i) then a :=a +1 ; end if; end do; a ; end proc:
seq(A167511(n), n=1..80) ; (End)
CROSSREFS
KEYWORD
nonn
AUTHOR
EXTENSIONS
a(12), a(31) and a(32) corrected by R. J. Mathar, Mar 18 2010
STATUS
approved

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

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 22 05:46 EDT 2024. Contains 376097 sequences. (Running on oeis4.)