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.

A235109 Averages q of twin prime pairs, such that q concatenated to q is also the average of a twin prime pair.

This page as a plain text file.
%I A235109 #9 Jan 14 2014 00:10:54
%S A235109 42,102,108,180,192,270,312,420,522,660,822,882,1230,1482,4242,4788,
%T A235109 8820,10332,11550,13692,14550,14562,14868,15732,17910,18522,20550,
%U A235109 21648,22620,23670,23832,26262,27738,35838,38922,39042,40128,42018,43962,44532,46440
%N A235109 Averages q of twin prime pairs, such that q concatenated to q is also the average of a twin prime pair.
%H A235109 Michael G. Kaarhus, <a href="/A235109/b235109.txt">Table of n, a(n) for n = 1..770</a>
%e A235109 192 is in this sequence, because 192 is an average of a twin prime pair, and so is 192192.
%o A235109 (Maxima) q:0$ for n:1 thru 800 step 0 do (q:q+6, if(primep(q-1) and primep(q+1)) then (b:concat(q,q), c:eval_string(b), if(primep(c-1) and primep(c+1)) then (if c>341550071728321 then (print("# ", c, " not determ."), n:5000), print(n, ", ", q), n:n+1 ) ) )$
%o A235109 (PARI) cat(n)=eval(concat(Str(n),n))
%o A235109 istwin(n)=n%6==5&&isprime(n)&&isprime(n+2)
%o A235109 v=List();p=2;forprime(q=3,1e10,if(q-p==2 && istwin(cat(p+1)-1), listput(v,p+1); if(#v==10^4,return));p=q) \\ _Charles R Greathouse IV_, Jan 03 2014
%Y A235109 Subsequence of A014574.
%K A235109 base,nonn
%O A235109 1,1
%A A235109 _Michael G. Kaarhus_, Jan 03 2014