login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A246718 a(n) is the number of different ways of concatenating the numbers {3^k, k=0,...,n} so as to produce a prime number. 0

%I #22 Apr 04 2015 01:35:51

%S 2,2,3,44,128,619,4134,28628,229132,2107538,21438790,238754555

%N a(n) is the number of different ways of concatenating the numbers {3^k, k=0,...,n} so as to produce a prime number.

%C A PARI program distinct from that below was used to compute a(14) using four windows in under a month, but the value was lost.

%C It is neither trivial nor very difficult to establish that distinct permutations lead to distinct values.

%e The a(1)+a(2)+a(3)+a(4)=51 primes corresponding to the first four terms are, in increasing order, 13, 31, 139, 193, 12739, 19273, 32719, 1273981, 1278139, 1279813, 1381279, 1398127, 1812793, 1819273, 1927813, 2713981, 2718139, 2718193, 2731819, 2738119, 2738191, 2739181, 2781139, 2781193, 2781913, 2793181, 2793811, 2798113, 3127819, 3127981, 3192781, 3271981, 3279811, 3811279, 3812719, 3812791, 3912781, 3918127, 8113279, 8113927, 8119273, 8127319, 8131927, 8139127, 8193127, 9127813, 9181327, 9273181, 9327181, 9812731 and 9813127. Concatenations not shown, such as 931 = 7^2 * 19 and 1392781 = 13 * 107137, are all composite.

%o (PARI) a(n,v=vector(n+1,k,Str(3^(k-1))))=sum(k=1,(n+1)!,ispseudoprime(eval(concat(vecextract(v,numtoperm(n+1,k)))))) \\ _M. F. Hasler_, Jan 13 2015

%K base,nonn

%O 1,1

%A _James G. Merickel_, Nov 15 2014

%E Edited and verified up to n=9 by _M. F. Hasler_, Jan 13 2015

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 24 13:00 EDT 2024. Contains 371945 sequences. (Running on oeis4.)