cp's OEIS Frontend

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.

A135284 Sum of staircase twin primes according to the rule: top + bottom - next top.

This page as a plain text file.
%I A135284 #5 Sep 10 2016 15:56:06
%S A135284 3,1,7,7,19,25,49,43,97,79,127,121,169,187,169,217,211,259,253,277,
%T A135284 277,409,403,403,475,541,583,595,625,511,799,817,799,835,745,1009,
%U A135284 1015,1039,1033,1033,1075,1183,1267,1279,1285,1213,1405,1423,1477,1369,1597,1573
%N A135284 Sum of staircase twin primes according to the rule: top + bottom - next top.
%C A135284 The case for bottom - top + next top produces A006512(n+1), the upper twin primes > 5.
%F A135284 We list the twin primes in staircase fashion as in A135283. Then a(n) = tl(n) + tu(n) + (-tl(n+1)).
%F A135284 a(n) = A054735(n)-A001359(n+1). - _R. J. Mathar_, Sep 10 2016
%o A135284 (PARI) g(n) = for(x=1,n,y=twinu(x) + twinl(x) - twinl(x+1);print1(y",")) twinl(n) = / *The n-th lower twin prime. */ { local(c,x); c=0; x=1; while(c<n, if(ispseudoprime(prime(x)+2),c++); x++; ); return(prime(x-1)) } twinu(n) = /* The n-th upper twin prime. */ { local(c,x); c=0; x=1; while(c<n, if(isprime(prime(x)+2),c++); x++; ); return(prime(x)) }
%K A135284 nonn
%O A135284 1,1
%A A135284 _Cino Hilliard_, Dec 03 2007