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.

A280609 Odd prime powers with prime exponents.

This page as a plain text file.
%I A280609 #15 Feb 16 2025 08:33:39
%S A280609 9,25,27,49,121,125,169,243,289,343,361,529,841,961,1331,1369,1681,
%T A280609 1849,2187,2197,2209,2809,3125,3481,3721,4489,4913,5041,5329,6241,
%U A280609 6859,6889,7921,9409,10201,10609,11449,11881,12167,12769,16129,16807,17161,18769,19321,22201,22801,24389,24649,26569,27889,29791,29929
%N A280609 Odd prime powers with prime exponents.
%C A280609 Intersection of A053810 and A061345.
%H A280609 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/PrimePower.html">Prime Power</a>.
%F A280609 a(n) = p^q, where p, q are primes and p > 2.
%F A280609 Sum_{n>=1} 1/a(n) = Sum_{p prime} P(p) - A051006 = 0.25699271237062131298..., where P(s) is the prime zeta function. - _Amiram Eldar_, Sep 13 2024
%e A280609 9 is in the sequence because 9 = 3^2;
%e A280609 25 is in the sequence because 25 = 5^2;
%e A280609 27 is in the sequence because 27 = 3^3, etc.
%t A280609 Select[Range[30000], PrimePowerQ[#1] && PrimeQ[PrimeOmega[#1]] && Mod[#1, 2] == 1 & ]
%o A280609 (Python)
%o A280609 from sympy import primepi, integer_nthroot, primerange
%o A280609 def A280609(n):
%o A280609     def f(x): return int(n+x-sum(primepi(integer_nthroot(x, p)[0])-1 for p in primerange(x.bit_length())))
%o A280609     def bisection(f,kmin=0,kmax=1):
%o A280609         while f(kmax) > kmax: kmax <<= 1
%o A280609         while kmax-kmin > 1:
%o A280609             kmid = kmax+kmin>>1
%o A280609             if f(kmid) <= kmid:
%o A280609                 kmax = kmid
%o A280609             else:
%o A280609                 kmin = kmid
%o A280609         return kmax
%o A280609     return bisection(f,n,n) # _Chai Wah Wu_, Sep 12 2024
%Y A280609 Cf. A000961, A034785, A051006, A053810, A061345, A078422, A246547, A246551, A246655.
%K A280609 nonn,easy
%O A280609 1,1
%A A280609 _Ilya Gutkovskiy_, Jan 06 2017