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.
%I A374173 #32 Jan 02 2025 09:35:04 %S A374173 3,13,683,3907,55987,960803,19173967,435848051,11111111113, %T A374173 1540683021299,19453310068921,328114698808283,45302797058044219, %U A374173 469172025408063623,19676527011956855059,878942778254232811943,120353718818554114936591,109912203092239643840221 %N A374173 a(n) is the smallest prime whose base-n representation contains a run of at least n identical digits. %C A374173 a(2) to a(18) are all increasing, but a(19) is smaller than a(18). %C A374173 a(n) = A023037(n) for n in A088790. - _Robert Israel_, Dec 31 2024 %H A374173 Robert Israel, <a href="/A374173/b374173.txt">Table of n, a(n) for n = 2..385</a> %e A374173 a(2) = 3 = 11_2. %e A374173 a(3) = 13 = 111_3. %e A374173 a(11) = 1540683021299 = 544444444444_11. %e A374173 a(18) = 120353718818554114936591 = 3111111111111111111_18. %e A374173 a(19) = 109912203092239643840221 = 1111111111111111111_19. %p A374173 f:= proc(n) local t,Q,i,j; %p A374173 t:= (n^n-1)/(n-1); %p A374173 if isprime(t) then return t fi; %p A374173 for i from 1 to n-1 do %p A374173 Q:= select(isprime, [seq(i*t*n+j,j=1..n-1), %p A374173 seq(i*n^n+j*t,j=1..n-1)]); %p A374173 if Q <> [] then return min(Q) fi; %p A374173 od; %p A374173 FAIL %p A374173 end proc: %p A374173 map(f, [$2..20]); # _Robert Israel_, Dec 31 2024 %t A374173 d[n_]:=d[n]=Table[Table[m,n],{m,0,n-1}]; %t A374173 dpre[n_]:=Flatten[Table[{m}~Join~#&/@d[n],{m,0,n-1}],1]; %t A374173 dpost[n_]:=Flatten[Table[Map[#~Join~{m}&,d[n]],{m,0,n-1}],1]; %t A374173 dprepost[n_]:=Flatten[Table[Map[{j}~Join~#~Join~{m}&,d[n]],{m,0,n-1},{j,0,n-1}],2]; %t A374173 c[n_]:=c[n]=DeleteDuplicates[Sort[Select[FromDigits[#,n]&/@Join[d[n],dpre[n],dpost[n],dprepost[n]],#>n&]]]; %t A374173 a[n_]:=a[n]=Do[If[PrimeQ[q],Return[q];Break[];],{q,c[n]}]; %t A374173 Table[a[n],{n,2,19}] %Y A374173 Cf. A023037, A088790. %K A374173 base,nonn %O A374173 2,1 %A A374173 _Robert P. P. McKone_, Jun 30 2024