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.

A236670 Start with 6; thereafter, primes obtained by concatenating to the end of previous term the next smallest number that will produce a prime.

This page as a plain text file.
%I A236670 #16 May 22 2025 10:21:36
%S A236670 6,61,613,6131,613141,61314119,6131411917,61314119171,6131411917181,
%T A236670 613141191718127,61314119171812789,613141191718127893,
%U A236670 61314119171812789379,6131411917181278937929,61314119171812789379291,61314119171812789379291111
%N A236670 Start with 6; thereafter, primes obtained by concatenating to the end of previous term the next smallest number that will produce a prime.
%C A236670 a(n+1) is the next smallest prime beginning with a(n). Initial term is 6. After a(1), these are the primes arising in A069608.
%e A236670 a(1) = 6 by definition.
%e A236670 a(2) is the next smallest prime beginning with 6, so a(2) = 61.
%e A236670 a(3) is the next smallest prime beginning with 61, so a(3) = 613.
%o A236670 (Python)
%o A236670 import sympy
%o A236670 from sympy import isprime
%o A236670 def b(x):
%o A236670   num = str(x)
%o A236670   n = 1
%o A236670   while n < 10**3:
%o A236670     new_num = str(x) + str(n)
%o A236670     if isprime(int(new_num)):
%o A236670       print(int(new_num))
%o A236670       x = new_num
%o A236670       n = 1
%o A236670     else:
%o A236670       n += 1
%o A236670 b(6)
%Y A236670 Cf. A069608,  A048553, A110773.
%K A236670 nonn,base
%O A236670 1,1
%A A236670 _Derek Orr_, Jan 29 2014