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.

A073640 a(1) = 2; a(n) = smallest prime greater than the previous term such that concatenation of two successive terms is a prime.

This page as a plain text file.
%I A073640 #24 Apr 25 2024 14:03:35
%S A073640 2,3,7,19,31,37,61,73,127,139,199,211,229,283,397,433,439,463,523,541,
%T A073640 547,577,601,607,619,739,751,787,811,919,937,991,1009,1021,1039,1093,
%U A073640 1201,1213,1297,1447,1453,1459,1471,1483,1657,1663,1723,1783,1867,1879
%N A073640 a(1) = 2; a(n) = smallest prime greater than the previous term such that concatenation of two successive terms is a prime.
%C A073640 All terms after 3 must have the form 6k + 1. - _Mauro Fiorentini_, Mar 27 2024
%e A073640 a(1)=2, the next prime is 3 and when 2 and 3 are concatenated we get 23, another prime. Hence a(2)=3. Likewise, a(3)=7 because 37 is prime, whereas the next prime after 3 is "5" which would lead to the nonprime "35".
%p A073640 pout := [2]: nout := [1]: for n from 2 to 1000 do: p := ithprime(n): d := parse(cat(pout[nops(pout)],p)): if (isprime(d)) then pout := [op(pout),p]: nout := [op(nout),n]: fi: od:
%t A073640 t = {i = 2}; Do[While[! PrimeQ[FromDigits[Flatten[IntegerDigits[{Last[t], x = Prime[i]}]]]], i++]; AppendTo[t, x], {49}]; t (* _Jayanta Basu_, Jul 03 2013 *)
%K A073640 base,nonn
%O A073640 1,1
%A A073640 _Amarnath Murthy_, Aug 09 2002
%E A073640 More terms from Mark Hudson (mrmarkhudson(AT)hotmail.com), Jan 31 2003