%I #35 Oct 23 2024 17:03:25
%S 2,3,3,5,7,5,7,11,5,13,11,17,7,19,13,23,7,17,11,19,29,31,13,23,37,11,
%T 41,17,43,29,13,31,47,19,53,37,23,59,17,11,61,41,43,19,67,47,71,13,29,
%U 73,31,79,53,23,83,13,59,89,61,37,17,97,67,101,29,41,103,19,71,107,43,31
%N Prime factor >= other prime factor of n-th semiprime.
%C Largest nontrivial divisor of n-th semiprime. [_Juri-Stepan Gerasimov_, Apr 18 2010]
%C Greater of the prime factors of A001358(n). - _Jianing Song_, Aug 05 2022
%H Zak Seidov, <a href="/A084127/b084127.txt">Table of n, a(n) for n = 1..1000</a>
%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/Semiprime.html">Semiprime</a>
%F a(n) = A006530(A001358(n)).
%F a(n) = A001358(n)/A020639(A001358(n)). [corrected by _Michel Marcus_, Jul 18 2020]
%F a(n) = A001358(n)/A084126(n).
%t FactorInteger[#][[-1, 1]]& /@ Select[Range[1000], PrimeOmega[#] == 2&] (* _Jean-François Alcover_, Nov 17 2021 *)
%o (Haskell)
%o a084127 = a006530 . a001358 -- _Reinhard Zumkeller_, Nov 25 2012
%o (PARI) lista(nn) = {for (n=2, nn, if (bigomega(n)==2, f = factor(n); print1(f[length(f~),1], ", ")););} \\ _Michel Marcus_, Jun 05 2013
%o (Python)
%o from math import isqrt
%o from sympy import primepi, primerange, primefactors
%o def A084127(n):
%o def bisection(f,kmin=0,kmax=1):
%o while f(kmax) > kmax: kmax <<= 1
%o while kmax-kmin > 1:
%o kmid = kmax+kmin>>1
%o if f(kmid) <= kmid:
%o kmax = kmid
%o else:
%o kmin = kmid
%o return kmax
%o def f(x): return int(n+x+((t:=primepi(s:=isqrt(x)))*(t-1)>>1)-sum(primepi(x//p) for p in primerange(s+1)))
%o return max(primefactors(bisection(f,n,n))) # _Chai Wah Wu_, Oct 23 2024
%Y Cf. A001358 (the semiprimes), A084126 (lesser of the prime factors of the semiprimes).
%Y Cf. A014673, A061299, A068318, A087718, A087794, A089994, A089995, A096932, A106550, A106554, A108542, A126663, A131284, A138510, A138511.
%K nonn
%O 1,1
%A _Reinhard Zumkeller_, May 15 2003
%E Corrected by _T. D. Noe_, Nov 15 2006