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.

A217908 Semiprime powers of distinct semiprimes.

This page as a plain text file.
%I A217908 #18 Sep 12 2024 15:58:35
%S A217908 1296,4096,6561,10000,38416,50625,194481,234256,262144,390625,456976,
%T A217908 531441,1000000,1048576,1185921,1336336,1500625,2085136,2313441,
%U A217908 4477456,5764801,6765201,7529536,9150625,10077696,10556001,11316496,11390625,14776336,17850625
%N A217908 Semiprime powers of distinct semiprimes.
%C A217908 Subset of A113877.
%H A217908 Christian N. K. Anderson, <a href="/A217908/b217908.txt">Table of n, a(n) for n = 1..9006</a>, for a(n) < 1.5*10^18
%e A217908 6561=9^4, and 9 and 4 are both semiprime. 46656 = 6^6 is excluded because the semiprimes are not distinct.
%o A217908 (Python)
%o A217908 from math import isqrt
%o A217908 from sympy import primepi, primerange, integer_nthroot, factorint
%o A217908 def A217908(n):
%o A217908     def A072000(n): return int(-((t:=primepi(s:=isqrt(n)))*(t-1)>>1)+sum(primepi(n//p) for p in primerange(s+1)))
%o A217908     def f(x): return int(n+x-sum(A072000(integer_nthroot(x, p)[0])-(p**p<=x) for p in range(4,x.bit_length()) if sum(factorint(p).values())==2))
%o A217908     def bisection(f,kmin=0,kmax=1):
%o A217908         while f(kmax) > kmax: kmax <<= 1
%o A217908         while kmax-kmin > 1:
%o A217908             kmid = kmax+kmin>>1
%o A217908             if f(kmid) <= kmid:
%o A217908                 kmax = kmid
%o A217908             else:
%o A217908                 kmin = kmid
%o A217908         return kmax
%o A217908     return bisection(f,n,n) # _Chai Wah Wu_, Sep 12 2024
%Y A217908 Cf. A113877.
%K A217908 nonn
%O A217908 1,1
%A A217908 _Kevin L. Schwartz_ and _Christian N. K. Anderson_, Mar 25 2013