This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A061357 #63 Sep 03 2024 15:07:21 %S A061357 0,0,0,1,1,1,1,2,2,2,2,3,2,2,3,2,3,4,1,3,4,3,3,5,4,3,5,3,3,6,2,5,6,2, %T A061357 5,6,4,5,7,4,4,8,4,4,9,4,4,7,3,6,8,5,5,8,6,7,10,6,5,12,3,5,10,3,7,9,5, %U A061357 5,8,7,7,11,5,5,12,4,8,11,4,8,10,5,5,13,9,6,11,7,6,14,6,8,13,5,8,11,6,9 %N A061357 Number of 0<k<n such that n-k and n+k are both primes. %C A061357 Number of prime pairs (p,q) with p < n < q and q-n = n-p. %C A061357 The same as the number of ways n can be expressed as the mean of two distinct primes. %C A061357 Conjecture: for n>=4 a(n)>0. - _Benoit Cloitre_, Apr 29 2003 %C A061357 Conjectures from _Rick L. Shepherd_, Jun 24 2003: (Start) %C A061357 1) For each integer N>=1 there exists a positive integer m(N) such that for n>=m(N) a(n)>a(N). (After the first m(N)-1 terms, a(N) does not reappear). In particular, for N=1 (or 2 or 3), m(N)=4 and a(N)=0, giving Benoit Cloitre's conjecture. (cont.) %C A061357 (cont.) Conjectures based upon observing a(1),...,a(10000): %C A061357 m(4)=m(5)=m(6)=m(7)=m(19)=20 for a(4)=a(5)=a(6)=a(7)=a(19)=1, %C A061357 m(8)=...(7 others)...=m(34)=35 for a(8)=...(7 others)...=a(34)=2, %C A061357 m(12)=...(10 others)...=m(64)=65 for a(12)=...(10 others)...=a(64)=3, %C A061357 m(18)=...(10 others)...=m(79)=80 for a(18)=...(10 others)...=a(79)=4, %C A061357 m(24)=...(14 others)...=m(94)=95 for a(24)=...(14 others)...=a(94)=5, %C A061357 m(30)=...(17 others)...=m(199)=200 for a(30)=...(17 others)...=a(199)=6, etc. %C A061357 2) Each nonnegative integer appears at least once in the current sequence. %C A061357 3) Stronger than 2): A001477 (nonnegative integers) is a subsequence of the current sequence. (Supporting evidence: I've observed that 0,1,2,...,175 is a subsequence of a(1),...,a(10000)). %C A061357 (End) %C A061357 a(n) is also the number of k such that 2*k+1=p and 2*(n-k-1)+1=q are both odd primes with p < q with p*q = n^2 - m^2. [_Pierre CAMI_, Sep 01 2008] %C A061357 Also: Number of ways n^2 can be written as b^2+pq where 0<b<n-1 and p,q are primes. - Erin Noel and George Panos (erin.m.noel(AT)rice.edu), Jun 27 2006 %C A061357 a(n) = sum (A010051(2*n - p): p prime < n). [_Reinhard Zumkeller_, Oct 19 2011] %C A061357 a(n) is also the number of partitions of 2*n into two distinct primes. See the first formula by T. D. Noe, and the Alois P. Heinz, Nov 14 2012, crossreference. - _Wolfdieter Lang_, May 13 2016 %C A061357 All 0<k<n are coprime to n. - _Jamie Morken_, Jun 02 2017 %C A061357 a(n) is the number of appearances of n in A143836. - _Ya-Ping Lu_, Mar 05 2023 %H A061357 Pierre CAMI, <a href="/A061357/b061357.txt">Table of n, a(n) for n = 1..60000</a> %F A061357 a(n) = A045917(n) - A010051(n). - _T. D. Noe_, May 08 2007 %F A061357 a(n) = sum(A010051(n-k)*A010051(n+k): 1 <= k < n). - _Reinhard Zumkeller_, Nov 10 2012 %F A061357 a(n) = sum_{i=2..n-1} A010051(i)*A010051(2n-i). [_Wesley Ivan Hurt_, Aug 18 2013] %e A061357 a(10)= 2: there are two such pairs (3,17) and (7,13), as 10 = (3+17)/2 = (7+13)/2. %t A061357 Table[Count[Range[n - 1], k_ /; And[PrimeQ[n - k], PrimeQ[n + k]]], {n, 98}] (* _Michael De Vlieger_, May 14 2016 *) %o A061357 (Haskell) %o A061357 a061357 n = sum $ %o A061357 zipWith (\u v -> a010051 u * a010051 v) [n+1..] $ reverse [1..n-1] %o A061357 -- _Reinhard Zumkeller_, Nov 10 2012, Oct 19 2011 %o A061357 (PARI) a(n)=my(s);forprime(p=2,n-1,s+=isprime(2*n-p));s \\ _Charles R Greathouse IV_, Mar 08 2013 %o A061357 (Python) %o A061357 from sympy import primerange, isprime %o A061357 def A061357(n): return sum(1 for p in primerange(n) if isprime((n<<1)-p)) # _Chai Wah Wu_, Sep 03 2024 %Y A061357 Cf. A071681 (subsequence for prime n only). %Y A061357 Cf. A092953. %Y A061357 Bisection of A117929 (even part). - _Alois P. Heinz_, Nov 14 2012 %K A061357 nonn,easy %O A061357 1,8 %A A061357 _Amarnath Murthy_, Apr 28 2001 %E A061357 More terms from Larry Reeves (larryr(AT)acm.org), May 15 2001