The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A171715 Absolute value of (n-th prime of form 3*m-1 minus n-th prime of form 3*k+1/2+-1/2). 3
1, 2, 2, 2, 8, 8, 2, 14, 14, 14, 8, 14, 14, 8, 20, 26, 20, 20, 14, 14, 20, 20, 20, 26, 2, 8, 32, 26, 26, 44, 44, 50, 44, 38, 50, 26, 26, 38, 26, 32, 32, 20, 26, 20, 38, 38, 56, 62, 56, 68, 68, 80, 50, 50, 50, 44, 50, 62, 56, 50, 62, 74, 74, 62, 68, 56, 50, 44, 50, 50, 32, 44, 38 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
Also, the absolute value of (n-th generalized cuban prime minus n-th generalized non-cuban prime). Or, the absolute value of n-th prime of form 6*m-3/2-+5/2 minus n-th prime of form 6*k-2-+1. A003627 U A007645 = A045375 U A045410 = A000040.
LINKS
FORMULA
a(n)=abs(A003627(n)-A007645(n))=abs(A045375(n)-A045410(n)).
EXAMPLE
a(1)=abs(3*1-1-(3*1+1/2-1/2))=1; a(2)=abs(3*2-1-(3*2+1/2+1/2))=2.
MAPLE
Contribution from R. J. Mathar, Apr 24 2010: (Start)
A003627 := proc(n) if n <= 2 then op(n, [2, 5]) ; ; else for a from procname(n-1)+2 by 2 do if isprime(a) and (a mod 3) =2 then return a ; end if; end do: end if; end proc:
A007645 := proc(n) if n <= 2 then op(n, [3, 7]) ; ; else for a from procname(n-1)+2 by 2 do if isprime(a) and (a mod 3) <> 2 then return a ; end if; end do: end if; end proc:
A171715 := proc(n) abs(A003627(n)-A007645(n)) ; end proc: (End)
MATHEMATICA
Module[{nn=500, p1, p2, len}, p1=Select[3*Range[nn]-1, PrimeQ]; p2=Select[Flatten[#+{0, 1}&/@ (3*Range[nn])], PrimeQ]; len=Min[Length[p1], Length[p2]]; Abs[#[[1]]-#[[2]]]&/@ Thread[ {Take[p1, len], Take[p2, len]}]] (* Harvey P. Dale, Aug 29 2023 *)
CROSSREFS
Sequence in context: A008293 A185811 A011140 * A264605 A353245 A275928
KEYWORD
nonn
AUTHOR
Juri-Stepan Gerasimov, Dec 17 2009, Feb 09 02 2010.
EXTENSIONS
Entries checked by R. J. Mathar, Apr 24 2010
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | 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 May 13 11:29 EDT 2024. Contains 372504 sequences. (Running on oeis4.)