login
Composite numbers whose least prime factor appears with multiplicity 1.
3

%I #22 Jan 09 2022 11:29:17

%S 6,10,14,15,18,21,22,26,30,33,34,35,38,39,42,46,50,51,54,55,57,58,62,

%T 65,66,69,70,74,75,77,78,82,85,86,87,90,91,93,94,95,98,102,105,106,

%U 110,111,114,115,118,119,122,123,126,129,130,133,134,138,141,142,143,145,146

%N Composite numbers whose least prime factor appears with multiplicity 1.

%C Density is Sum_{p >= 2} 1/p * Product_{q <= p} (1 - 1/q) which is around 0.65. (In the sum and product, p and q are restricted to primes.) - _Charles R Greathouse IV_, Jan 09 2022

%H Harvey P. Dale, <a href="/A080364/b080364.txt">Table of n, a(n) for n = 1..1000</a>

%e 50 = 2^1 * 5^2; least prime factor is 2, whose exponent is 1, so 50 is a term.

%t mi[x_] := Part[Flatten[FactorInteger[x]], 1] k=0; Do[s=mi[n]; If[Equal[GCD[s, n/s], 1]&&!PrimeQ[n], Print[n]], {n, 2, 256}]

%t Select[Range[150],CompositeQ[#]&&FactorInteger[#][[1,2]]==1&] (* Requires Mathematica version 10 or later *) (* _Harvey P. Dale_, Jan 23 2021 *)

%o (PARI) is(n,f=factor(n))=n>1 && f[1,2]==1 \\ _Charles R Greathouse IV_, Jan 09 2022

%o (PARI) is(n)=forprime(p=2,97, if(n%p==0, return(n%p^2>0))); !ispower(n) && factor(n)[1,2]==1 \\ _Charles R Greathouse IV_, Jan 09 2022

%Y Cf. A034444, A056169, A020639, A080363.

%K nonn,easy

%O 1,1

%A _Labos Elemer_, Feb 21 2003

%E Edited by _Jon E. Schoenfield_, Jul 10 2018