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.

A084126 Prime factor <= other prime factor of n-th semiprime.

This page as a plain text file.
%I A084126 #27 Apr 22 2025 03:49:06
%S A084126 2,2,3,2,2,3,3,2,5,2,3,2,5,2,3,2,7,3,5,3,2,2,5,3,2,7,2,5,2,3,7,3,2,5,
%T A084126 2,3,5,2,7,11,2,3,3,7,2,3,2,11,5,2,5,2,3,7,2,13,3,2,3,5,11,2,3,2,7,5,
%U A084126 2,11,3,2,5,7,2,3,13,2,5,3,13,3,11,2,7,2,5,3,2,2,7,17,3,5,2,13,7,2,3,5,3,2
%N A084126 Prime factor <= other prime factor of n-th semiprime.
%C A084126 Lesser of the prime factors of A001358(n). - _Jianing Song_, Aug 05 2022
%H A084126 Zak Seidov, <a href="/A084126/b084126.txt">Table of n, a(n) for n = 1..1000</a>
%H A084126 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/Semiprime.html">Semiprime</a>
%F A084126 a(n) = A020639(A001358(n)).
%F A084126 a(n) = A001358(n)/A006530(A001358(n)). [corrected by _Michel Marcus_, Jul 18 2020]
%F A084126 a(n) = A001358(n)/A084127(n).
%t A084126 FactorInteger[#][[1,1]]&/@Select[Range[500],PrimeOmega[#]==2&] (* _Harvey P. Dale_, Jun 25 2018 *)
%o A084126 (Haskell)
%o A084126 a084126 = a020639 . a001358  -- _Reinhard Zumkeller_, Nov 25 2012
%o A084126 (Python)
%o A084126 from sympy import primepi, primerange, primefactors
%o A084126 def A084126(n):
%o A084126     def bisection(f,kmin=0,kmax=1):
%o A084126         while f(kmax) > kmax: kmax <<= 1
%o A084126         kmin = kmax >> 1
%o A084126         while kmax-kmin > 1:
%o A084126             kmid = kmax+kmin>>1
%o A084126             if f(kmid) <= kmid:
%o A084126                 kmax = kmid
%o A084126             else:
%o A084126                 kmin = kmid
%o A084126         return kmax
%o A084126     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 A084126     return min(primefactors(bisection(f,n,n))) # _Chai Wah Wu_, Apr 03 2025
%Y A084126 Cf. A001358 (the semiprimes), A084127 (greater of the prime factors of the semiprimes).
%Y A084126 Cf. A068318, A087718, A087794, A089994, A089995, A096916, A106550, A106554, A108541, A131284, A138510, A138511.
%K A084126 nonn
%O A084126 1,1
%A A084126 _Reinhard Zumkeller_, May 15 2003