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.

A173426 a(n) is obtained by starting with 1, sequentially concatenating all decimal numbers up to n, and then, starting from n-1, sequentially concatenating all decimal numbers down to 1.

This page as a plain text file.
%I A173426 #82 Feb 19 2023 16:14:31
%S A173426 1,121,12321,1234321,123454321,12345654321,1234567654321,
%T A173426 123456787654321,12345678987654321,12345678910987654321,
%U A173426 123456789101110987654321,1234567891011121110987654321,12345678910111213121110987654321,123456789101112131413121110987654321
%N A173426 a(n) is obtained by starting with 1, sequentially concatenating all decimal numbers up to n, and then, starting from n-1, sequentially concatenating all decimal numbers down to 1.
%C A173426 The first prime in this sequence is the 20-digit number a(10) = 12345678910987654321. On Jul 20 2015, _Shyam Sunder Gupta_ reported on the Number Theory Mailing List that he has found what is probably the second prime in the sequence. This is the 2446th term, namely the 17350-digit probable prime 1234567..244524462445..7654321. See A359148. - _N. J. A. Sloane_, Jul 29 2015 - Aug 03 2015
%C A173426 There are no other (PR)prime members in this sequence for n<60000. - _Serge Batalov_, Jul 29 2015
%C A173426 _David Broadhurst_ gives heuristic arguments which suggest that this sequence contains infinitely many primes.
%C A173426 See A075023 and A075024 for the smallest and largest prime factor of the terms. - _M. F. Hasler_, Jul 29 2015
%C A173426 Using summation in decimal length clades, one can obtain analytical expressions for the sequence:
%C A173426 a(n) = A002275(n)^2, for 1 <= n < 10;
%C A173426 a(n) = (120999998998*10^(4*n-28) - 2*10^(2*n-9) + 8790000000121)/99^2, for 10 <= n < 10^2;
%C A173426 a(n) = (120999998998*10^(6*n-227) - (1099022*10^(6*n-406) + 242*10^(3*n-108) - 1087789*10^191)/111^2 + 8790000000121)/99^2, for 10^2 <= n < 10^3; etc. - _Serge Batalov_, Jul 29 2015
%C A173426 Curiously, 1234567891010987654321 is also a prime (see A259937). - _N. J. A. Sloane_, Nov 30 2021
%D A173426 D. Broadhurst, Primes from concatenation: results and heuristics, Number Theory List, Aug 01 2015 and later postings.
%H A173426 G. C. Greubel, <a href="/A173426/b173426.txt">Table of n, a(n) for n = 1..150</a>
%H A173426 FactorDB, <a href="http://factordb.com/index.php?query=%28121*10%5E%284*n-19%29+-+1002*10%5E%284*n-28%29+-+2*10%5E%282*n-9%29+%2B+879*10%5E10+%2B+121%29%2F99%5E2&amp;perpage=50">(121*10^(4*n-19) - 1002*10^(4*n-28) - 2*10^(2*n-9) + 879*10^10 + 121)/99^2</a>.
%H A173426 Shyam Sunder Gupta, <a href="http://www.primepuzzles.net/puzzles/puzz_794.htm">Puzzle 794. Prime Generalized Palindromes</a>, The Prime Puzzles and Problems Connection.
%H A173426 S. S. Gupta, <a href="https://listserv.nodak.edu/cgi-bin/wa.exe?A2=NMBRTHRY;46e44b27.1507">A new 17350 digit Symmetric Prime</a>, NmbrThry List, July 20, 2015.
%H A173426 Brady Haran and N. J. A. Sloane, <a href="https://youtu.be/vKlVNFOHJ9I">The Most Wanted Prime Number</a>, Numberphile series on YouTube, Dec 15 2021.
%H A173426 Bertrand Teguia Tabuguia, <a href="https://arxiv.org/abs/2201.07127">Explicit formulas for concatenations of arithmetic progressions</a>, arXiv:2201.07127 [math.CO], 2022.
%H A173426 <a href="/index/Mo#MWP">Index entries for sequences related to Most Wanted Primes video</a>
%F A173426 a(n) = concatenate(1,2,3,...,n-2,n-1,n,n-1,n-2,...,3,2,1).
%p A173426 a:= n-> parse(cat($1..n, n-i$i=1..n-1)):
%p A173426 seq(a(n), n=1..14);  # _Alois P. Heinz_, Dec 01 2021
%t A173426 Table[FromDigits[Flatten[IntegerDigits/@Join[Range[n],Reverse[Range[ n-1]]]]],{n,15}] (* _Harvey P. Dale_, Sep 02 2015 *)
%o A173426 (PARI) A173426(n)=eval(concat(vector(n*2-1,k,if(k<n,Str(k),n*2-k)))) \\ _M. F. Hasler_, Jul 29 2015
%o A173426 (Python)
%o A173426 def A173426(n): return int(''.join(str(d) for d in range(1,n+1))+''.join(str(d) for d in range(n-1,0,-1))) # _Chai Wah Wu_, Dec 01 2021
%Y A173426 This sequence and A002477 (Wonderful Demlo numbers) agree up to the 9th term.
%Y A173426 Cf. A002275, A007908, A075023, A075024, A259937, A359148.
%K A173426 nonn,base
%O A173426 1,2
%A A173426 _Umut Uludag_, Feb 18 2010
%E A173426 More terms from and minor edits by _M. F. Hasler_, Jul 29 2015