%I M2889 #50 Aug 02 2024 12:04:21
%S 3,11,37,101,271,37,4649,137,333667,9091,513239,9901,265371653,909091,
%T 2906161,5882353,5363222357,333667,1111111111111111111,27961,10838689,
%U 513239,11111111111111111111111,99990001,182521213001,1058313049
%N Largest prime factor of 10^n - 1.
%D J. Brillhart et al., Factorizations of b^n +- 1. Contemporary Mathematics, Vol. 22, Amer. Math. Soc., Providence, RI, 2nd edition, 1985; and later supplements.
%D N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
%H <a href="/A005422/b005422.txt">Table of n, a(n) for n = 1..352</a>
%H K. Beschorner, <a href="http://www.kurtbeschorner.de">Factorizations of Repunit Numbers of the form (10^n-1)/9 (111111...)</a>. [Retrieved July 30, 2015]
%H J. Brillhart et al., <a href="http://dx.doi.org/10.1090/conm/022">Factorizations of b^n +- 1</a>, Contemporary Mathematics, Vol. 22, Amer. Math. Soc., Providence, RI, 3rd edition, 2002.
%H Yousuke Koide, <a href="https://repunit-koide.jimdofree.com/">Factorizations of Repunit Numbers</a>.
%H S. S. Wagstaff, Jr., <a href="http://www.cerias.purdue.edu/homes/ssw/cun/index.html">The Cunningham Project</a>
%F For n > 1, a(n) = A003020(n). For 1 < n < 10, a(n) = A075024(n). - _M. F. Hasler_, Jul 30 2015
%F a(n) = A006530(A002283(n)). - _Vincenzo Librandi_, Jul 13 2016
%F a(A004023(n)) = A002275(A004023(n)). - _Bernard Schott_, May 24 2022
%p A005422 := proc(n)
%p 10^n-1 ;
%p A006530(%) ;
%p end proc: # _R. J. Mathar_, Dec 02 2016
%t Table[FactorInteger[10^n - 1][[-1, 1]], {n, 1, 40}] (* _Vincenzo Librandi_, Jul 13 2016 *)
%o (PARI) a(n)=vecmax(factor(10^n-1)[,1]) \\ Simplified by _M. F. Hasler_, Jul 30 2015
%o (Magma) [Maximum(PrimeDivisors(10^n-1)): n in [1..45]]; // _Vincenzo Librandi_, Jul 13 2016
%Y Same as A003020 except for the additional a(1) = 3.
%Y Cf. A002275, A002283, A004023, A006530, A067063, A075024, A102380.
%Y Cf. similar sequences listed in A274906.
%K nonn
%O 1,1
%A _N. J. A. Sloane_
%E Terms to a(100) in b-file from Yousuke Koide added by _T. D. Noe_, Dec 06 2006
%E Edited by _M. F. Hasler_, Jul 30 2015
%E a(101)-a(322) in b-file from _Ray Chandler_, Apr 22 2017
%E a(323)-a(352) in b-file from _Max Alekseyev_, Apr 26 2022