login
Numbers that are not powers of primes p^k (k >= 0); complement of A000961.
177

%I #99 Jul 23 2024 14:58:24

%S 6,10,12,14,15,18,20,21,22,24,26,28,30,33,34,35,36,38,39,40,42,44,45,

%T 46,48,50,51,52,54,55,56,57,58,60,62,63,65,66,68,69,70,72,74,75,76,77,

%U 78,80,82,84,85,86,87,88,90,91,92,93,94,95,96,98,99,100,102,104,105,106,108,110,111,112

%N Numbers that are not powers of primes p^k (k >= 0); complement of A000961.

%C The sequence of numbers divisible by a prime number of primes coincides with this up to 210, which has 4 prime factors. - _Lior Manor_ Aug 23 2001

%C A085970(n) = Max{k: a(k)<=n}.

%C Numbers n such that LCM of proper divisors of n equals neither 1 nor n. - _Labos Elemer_, Dec 01 2004

%C a(n) provides bases b in which automorphic numbers m^2 ending with m in base b exist. In the complement there aren't any automorphic numbers. - _Martin Renner_, Dec 07 2011

%C Numbers with at least 2 distinct prime factors. - _Jonathan Sondow_, Oct 17 2013

%C There exists an equiangular n-gon whose edge lengths form a permutation of 1, 2, ..., n if and only if n is in the sequence (see Woeginger's survey and Munteanu & Munteanu). - _Jonathan Sondow_, Oct 17 2013

%C Numbers that are the product of two relatively prime factors. These numbers are used in testing a sequence for multiplicativity. - _Michael Somos_, Jun 02 2015

%C A theorem from Donald McCarthy: Let d be any positive integer which is not a prime power; then there exists a finite group whose order is divisible by d but which contains no subgroup of order d (see link and A340511). - _Bernard Schott_, Dec 04 2021

%H Reinhard Zumkeller, <a href="/A024619/b024619.txt">Table of n, a(n) for n = 1..10000</a> (first 8719 terms from Daniel Forgues)

%H Donald McCarthy, <a href="https://www.semanticscholar.org/paper/Sylow%27s-theorem-is-a-sharp-partial-converse-to-McCarthy/a3d0f68ffeeff6389c44110a6d2b3a3c35388ec1">Sylow's theorem is a sharp partial converse to Lagrange's theorem</a>, Mathematische Zeitschrift, 113, 383-384 (1970).

%H Marius Munteanu and Laura Munteanu, <a href="http://dx.doi.org/10.4236/am.2013.410197">Rational equiangular polygons</a>, Applied Math., 4 (2013), 1460-1465.

%H Laurentiu Panaitopol, <a href="http://dx.doi.org/10.1216/rmjm/1021249445">Some of the properties of the sequence of powers of prime numbers</a>, Rocky Mountain Journal of Mathematics, Volume 31, Number 4, Winter 2001.

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/PrimePower.html">Prime Power</a>

%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Prime_power">Prime power</a>

%H G. J. Woeginger, <a href="http://dx.doi.org/10.4169/amer.math.monthly.120.09.849">Nothing new about equiangular polygons</a>, Amer. Math. Monthly, 120 (2013), 849-850.

%H Günter Ziegler and Brady Haran, <a href="https://www.youtube.com/watch?v=5SfXqTENV_Q">Cannons and Sparrows</a>, Numberphile video (2018).

%F A001221(a(n)) > 1.

%F A014963(a(n)) = 1.

%F A020500(a(n)) = 1. - _Benoit Cloitre_, Aug 26 2003

%F A010055(a(n)) = 0. - _Reinhard Zumkeller_, Nov 17 2011

%F a(n) ~ n. - _Charles R Greathouse IV_, Mar 21 2013

%F a(n) ~ n - pi(n) [See Panaitopol]. - _N. J. A. Sloane_, Sep 27 2020

%F A118887(a(n)) > 0. - _Jonathan Sondow_, Oct 17 2013

%p a := proc(n) numtheory[factorset](n); if 1 < nops(%) then n else NULL fi end:

%p seq(a(i), i=1..110); # _Peter Luschny_, Aug 11 2009

%t Select[Range@111, Length@FactorInteger@# > 1 &] (* _Robert G. Wilson v_, Dec 07 2005 *)

%o (Magma) IsA024619:=func< n | not IsPrime(n) and not (t and IsPrime(b) where t, b, _:=IsPower(n)) >; [ n: n in [2..200] | IsA024619(n) ]; // _Klaus Brockhaus_, Feb 25 2011

%o (Haskell)

%o a024619 n = a024619_list !! (n-1)

%o a024619_list = filter ((== 0) . a010055) [1..]

%o -- _Reinhard Zumkeller_, Nov 17 2011

%o (Sage)

%o def A024619_list(n) :

%o return [k for k in (2..n) if not k.is_prime() and not k.is_prime_power()]

%o A024619_list(112) # _Peter Luschny_, Feb 03 2012 [corrected by _Terry D. Grant_, Sep 16 2020]

%o (PARI) is(n)=n>5 && !isprimepower(n) \\ _Charles R Greathouse IV_, Mar 21 2013

%o (Python)

%o from sympy import primepi

%o from sympy.ntheory.primetest import integer_nthroot

%o def A024619(n):

%o def f(x): return int(n+1+sum(primepi(integer_nthroot(x,k)[0]) for k in range(1,x.bit_length())))

%o m, k = n, f(n)

%o while m != k:

%o m, k = k, f(k)

%o return m # _Chai Wah Wu_, Jul 23 2024

%Y Cf. A000040, A000961 (complement), A001221, A014963, A020500, A085970.

%Y Cf. A340511.

%Y Subsequence of A080257.

%K nonn,easy

%O 1,1

%A _Clark Kimberling_