OFFSET
1,1
COMMENTS
LINKS
R. Zumkeller, Table of n, a(n) for n = 1..10000
Peter Luschny, Zumkeller Numbers
MATHEMATICA
ZumkellerQ[n_] := Module[{d = Divisors[n], t, ds, x}, ds = Total[d]; If[Mod[ds, 2] > 0, False, t = CoefficientList[Product[1 + x^i, {i, d}], x]; t[[1 + ds/2]] > 0]];
a[n_] := Boole[ZumkellerQ[n]];
Array[a, 105] (* Jean-François Alcover, Apr 30 2017, after T. D. Noe *)
PROG
(Other) PolyML (the leading dots are just for readability):
fun A179527(n) =
... let fun ch(m, k) =
........... if k <= m
.............. then ch(m, k+1) orelse (n mod k = 0 andalso ch(m-k, k+1))
.............. else (m = 0)
.......... then 1
.......... else 0
... end;
CROSSREFS
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Jul 19 2010
STATUS
approved