A339846 Number of even-length factorizations of n into factors > 1.
1, 0, 0, 1, 0, 1, 0, 1, 1, 1, 0, 2, 0, 1, 1, 3, 0, 2, 0, 2, 1, 1, 0, 4, 1, 1, 1, 2, 0, 3, 0, 3, 1, 1, 1, 5, 0, 1, 1, 4, 0, 3, 0, 2, 2, 1, 0, 6, 1, 2, 1, 2, 0, 4, 1, 4, 1, 1, 0, 6, 0, 1, 2, 6, 1, 3, 0, 2, 1, 3, 0, 8, 0, 1, 2, 2, 1, 3, 0, 6, 3, 1, 0, 6, 1, 1, 1, 4, 0, 6, 1, 2, 1, 1, 1, 10, 0, 2, 2, 5, 0, 3, 0, 4, 3
Offset: 1
Keywords
Examples
The a(n) factorizations for n = 12, 16, 24, 36, 48, 72, 96, 120: 2*6 2*8 3*8 4*9 6*8 8*9 2*48 2*60 3*4 4*4 4*6 6*6 2*24 2*36 3*32 3*40 2*2*2*2 2*12 2*18 3*16 3*24 4*24 4*30 2*2*2*3 3*12 4*12 4*18 6*16 5*24 2*2*3*3 2*2*2*6 6*12 8*12 6*20 2*2*3*4 2*2*2*9 2*2*3*8 8*15 2*2*3*6 2*2*4*6 10*12 2*3*3*4 2*3*4*4 2*2*5*6 2*2*2*12 2*3*4*5 2*2*2*2*2*3 2*2*2*15 2*2*3*10
Links
Crossrefs
Programs
-
Maple
g:= proc(n, k, t) option remember; `if`(n>k, 0, t)+ `if`(isprime(n), 0, add(`if`(d>k, 0, g(n/d, d, 1-t)), d=numtheory[divisors](n) minus {1, n})) end: a:= n-> `if`(n=1, 1, g(n$2, 0)): seq(a(n), n=1..100); # Alois P. Heinz, Dec 30 2020
-
Mathematica
facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]]; Table[Length[Select[facs[n],EvenQ@Length[#]&]],{n,100}]
-
PARI
A339846(n, m=n, e=1) = if(1==n, e, sumdiv(n, d, if((d>1)&&(d<=m), A339846(n/d, d, 1-e)))); \\ Antti Karttunen, Oct 22 2023
Extensions
Data section extended up to a(105) by Antti Karttunen, Oct 22 2023
Comments