login
Even numbers that are not perfect powers.
2

%I #19 Jan 24 2019 18:34:22

%S 2,6,10,12,14,18,20,22,24,26,28,30,34,38,40,42,44,46,48,50,52,54,56,

%T 58,60,62,66,68,70,72,74,76,78,80,82,84,86,88,90,92,94,96,98,102,104,

%U 106,108,110,112,114,116,118,120,122,124,126,130,132,134,136,138

%N Even numbers that are not perfect powers.

%C Perfect powers are of the form m^k where m > 0 and k > 1 (A001597).

%H Robert Israel, <a href="/A305634/b305634.txt">Table of n, a(n) for n = 1..10000</a>

%F A005843 \ A001597. - _Eric Chen_, Jun 14 2018

%e 10 is in the sequence since it is even and is not a power of an integer. 17 is not in the sequence since it is odd, and 36 is not in the sequence since it is a power of an integer (36 = 6^2).

%p N:= 1000:

%p S:={seq(i,i=2..N,2)} minus {seq(seq(e^m,m=2..floor(log[e](N))),e=2..floor(sqrt(N)),2)}:

%p sort(convert(S,list)); # _Robert Israel_, Jan 24 2019

%t radQ[n_]:=Or[n==1,GCD@@FactorInteger[n][[All,2]]==1];

%t Select[Range[200],EvenQ[#]&&radQ[#]&]

%o (PARI) isok(n) = !(n % 2) && !ispower(n); \\ _Michel Marcus_, Jun 08 2018

%Y Cf. A001597, A005117, A007916, A039956.

%Y Cf. A305630, A305631, A305632, A305633, A305635.

%Y Cf. A005843, A001597.

%K nonn

%O 1,1

%A _Gus Wiseman_, Jun 07 2018