A120676 Number of prime factors of even squarefree numbers A039956.
1, 2, 2, 2, 2, 2, 3, 2, 2, 3, 2, 2, 2, 3, 3, 2, 3, 2, 2, 2, 3, 2, 3, 3, 2, 2, 3, 2, 3, 2, 2, 3, 2, 2, 3, 3, 2, 3, 3, 3, 2, 2, 2, 4, 2, 2, 3, 2, 3, 3, 3, 2, 3, 2, 3, 2, 2, 3, 3, 3, 2, 2, 3, 2, 3, 3, 2, 4, 2, 2, 3, 2, 2, 3, 3, 3, 2, 2, 4, 2, 2, 3, 3, 3, 3, 2, 3, 3, 3, 3, 3, 2, 2, 2, 4, 2, 3, 3, 2, 2, 3, 3, 2, 3, 4
Offset: 1
Keywords
Links
- G. C. Greubel, Table of n, a(n) for n = 1..10000
Programs
-
Maple
issquarefree := proc(n::integer) local nf, ifa ; nf := op(2,ifactors(n)) ; for ifa from 1 to nops(nf) do if op(2,op(ifa,nf)) >= 2 then RETURN(false) ; fi ; od : RETURN(true) ; end: A001221 := proc(n::integer) RETURN(nops(numtheory[factorset](n))) ; end: A039956 := proc(maxn) local n,a ; a := [2] ; for n from 4 to maxn by 2 do if issquarefree(n) then a := [op(a),n] ; fi ; od : RETURN(a) ; end: A120676 := proc(maxn) local a,n; a := A039956(maxn) ; for n from 1 to nops(a) do a := subsop(n=A001221(a[n]),a) ; od ; RETURN(a) ; end: nmax := 600 : a := A120676(nmax) : for n from 1 to nops(a) do printf("%d,",a[n]) ; od ; # R. J. Mathar, Aug 17 2006
-
Mathematica
A264387[n_] := (# - 2)/4 & /@ Select[2 Range@n, SquareFreeQ]; A039956[n_] := 2*(1 + 2*A264387[n]); PrimeNu[A039956[50]] (* G. C. Greubel, May 16 2017 *) PrimeOmega/@Select[2*Range[300],SquareFreeQ] (* Harvey P. Dale, Jul 28 2019 *)
Extensions
Corrected and extended by R. J. Mathar, Aug 17 2006