OFFSET
1,3
LINKS
Frank M Jackson, Table of n, a(n) for n = 1..10000
EXAMPLE
a(9) = 34. Consider the following sequence of 16 even multiples of 9 namely (18, 36, 54, . . . , 288, 306), all are practical numbers but only 9*34 = 306 is a primitive practical number. This is because 306 when divided by 3 is no longer practical whereas the other 15 even multiples remain practical when divided by 3.
MATHEMATICA
PracticalQ[n_] := Module[{f, p, e, prod=1, ok=True}, If[n<1||(n>1&&OddQ[n]), False, If[n==1, True, f=FactorInteger[n]; {p, e}=Transpose[f]; Do[If[p[[i]]>1+DivisorSigma[1, prod], ok=False; Break[]]; prod=prod*p[[i]]^e[[i]], {i, Length[p]}]; ok]]];
DivFreeQ[n_] := Module[{plst=First/@Select[FactorInteger[n], #[[2]]>1&], m, ok=False}, Do[If[!PracticalQ[n/plst[[m]]], ok=True, ok=False; Break[]], {m, 1, Length@plst}]; ok];
PPracticalQ[n_] := PracticalQ[n]&&(SquareFreeQ[n]||DivFreeQ[n]);
lst={}; Do[m=1; While[!PPracticalQ[n*m], m++]; AppendTo[lst, m], {n, 1, 100}]; lst
CROSSREFS
KEYWORD
nonn
AUTHOR
Frank M Jackson, Oct 24 2024
STATUS
approved