login
A278169
Characteristic function for A000960.
7
1, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1
OFFSET
1
FORMULA
a(1) = 1; for n > 1, a(n) = A100617(n) - A100617(n-1).
MATHEMATICA
b[n_] := (For[m = n; i = 1, i <= n-1, i++, d = n-i; m = d*Ceiling[m/d+1]]; m); A000960 = Array[b, 12]; Boole[MemberQ[A000960, #]]& /@ Range[A000960 // Last] (* Jean-François Alcover, Nov 24 2016 *)
PROG
(Scheme) (define (A278169 n) (if (= 1 n) n (- (A100617 n) (A100617 (- n 1)))))
CROSSREFS
Characteristic function of A000960.
Cf. A100617 (partial sums).
Sequence in context: A355943 A102242 A005369 * A262693 A267423 A108340
KEYWORD
nonn
AUTHOR
Antti Karttunen, Nov 23 2016
STATUS
approved