OFFSET
1,1
COMMENTS
While there is multiplication in the generation of this sequence, it is still called a sum because the arithmetic processes -,*,/ are derived from addition.
FORMULA
We list the twin primes in staircase fashion as in A135283. Then a(n) = tl(n) * tu(n) + tl(n+1).
PROG
(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)) }
CROSSREFS
KEYWORD
nonn
AUTHOR
Cino Hilliard, Dec 03 2007
EXTENSIONS
All the entries were wrong. They have been corrected by Franklin T. Adams-Watters, Apr 29 2008
STATUS
approved