login
Semiprime powers with special exponents: k^(j-1) where both j and k are arbitrary semiprime numbers.
1

%I #12 Sep 12 2024 14:37:30

%S 64,216,729,1000,1024,2744,3375,7776,9261,10648,15625,17576,35937,

%T 39304,42875,54872,59049,59319,65536,97336,100000,117649,132651,

%U 166375,185193,195112,238328,262144,274625,328509,405224,456533,537824,551368,614125,636056,658503,753571,759375,804357,830584,857375

%N Semiprime powers with special exponents: k^(j-1) where both j and k are arbitrary semiprime numbers.

%C Semiprime analog of A036454: prime powers with special exponents: q^(p-1) where both p and q are arbitrary prime numbers.

%F {a(n)} = {A001358(i) ^ A186621(j)}.

%F {a(n)} = {a^b where a and b are elements of A001358} = {(p*q)^((r*s)-1) for primes p, q, r, s, not necessarily distinct}.

%e a(1) = smallest semiprime to power of (smallest semiprime - 1) = 4^(4-1) = 4^3 = 64.

%o (Python)

%o from math import isqrt

%o from sympy import primepi, primerange, integer_nthroot, factorint

%o def A186637(n):

%o def A072000(n): return int(-((t:=primepi(s:=isqrt(n)))*(t-1)>>1)+sum(primepi(n//p) for p in primerange(s+1)))

%o def f(x): return int(n+x-sum(A072000(integer_nthroot(x, p-1)[0]) for p in range(4,x.bit_length()+1) if sum(factorint(p).values())==2))

%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 return bisection(f,n,n) # _Chai Wah Wu_, Sep 12 2024

%Y Cf. A001358, A036454, A113877, A186621.

%K nonn,easy

%O 1,1

%A _Jonathan Vos Post_, Feb 24 2011