OFFSET
0,2
COMMENTS
9^n may be retrieved as 9^n = Sum_{k=0..n} (binomial(n,k) mod 2)*a(k).
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..1000
FORMULA
a(n) = Sum_{k=0..n} (-1)^A010060(n-k) * (binomial(n, k) mod 2) * 9^k.
a(n) = Sum_{k=0..n} A106400(n-k) * (binomial(n, k) mod 2) * 9^k. - G. C. Greubel, Apr 06 2023
MATHEMATICA
Table[A100472[n], {n, 0, 30}] (* G. C. Greubel, Apr 06 2023 *)
PROG
(Magma)
A106400:= func< n | 1 - 2*(&+Intseq(n, 2) mod(2)) >;
[A100472(n): n in [0..30]]; // G. C. Greubel, Apr 06 2023
(SageMath)
@CachedFunction
def A010060(n): return (bin(n).count('1')%2)
[A100472(n) for n in range(31)] # G. C. Greubel, Apr 06 2023
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Paul Barry, Dec 06 2004
STATUS
approved