|
Search: id:A112865
|
|
|
| A112865 |
|
a(n) = (-1)^(n + [n/4] + [n/4^2] + ...). |
|
+0 1
|
|
| 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, 1, -1, -1, 1, -1, 1, -1, 1, -1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, 1, -1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, 1, -1, -1, 1, -1, 1, -1, 1, -1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, 1, -1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, 1, -1, -1, 1, -1, 1, -1, 1, -1, 1, 1, -1
(list; graph; listen)
|
|
|
OFFSET
|
0,1
|
|
|
COMMENT
|
The n-th term t(n)=(-1)^S(n). S(n)=Sum[ b(k)*a(k), k=0,L-1] where n=Sum[a(k)*2^k, k=0,L-1] (Binary expansion of n) and b(k)=1 only if mod(k,2)=0, b(k)=0 otherwise. Closely related to the Thue-Morse sequence where all b(k) are 1. Also appears as the column at the ``one-third'' position of the Walsh-Hadamard matrix.
|
|
FORMULA
|
a(n) = (-1)^n * a([n/4]). - Michael Somos Aug 15 2008
Euler transform of sequence b(n) where b(1) = 1, b(2^(2*k-1)) = -1, b(2^(2*k)) = 2 unless k=0, b(n) = 0 otherwise.
G.f.: (Product_{k>0} 1 - x^(4^k)) / (Product_{k>=0} 1 + x^(4^k)). - Michael Somos Aug 15 2008
|
|
PROGRAM
|
(PARI) {a(n) = if( n<1, n==0, (-1)^n * a(n \ 4))} /* Michael Somos Aug 15 2008 */
(PARI) {a(n) = local(A); if( n<0, 0, A = Vecrev(binary(n)); (-1)^sum(k=1, #A, A[k] * (k%2)))} /* Michael Somos Aug 15 2008 */
|
|
CROSSREFS
|
Sequence in context: A008836 A064179 A106400 this_sequence A121241 A122188 A130151
Adjacent sequences: A112862 A112863 A112864 this_sequence A112866 A112867 A112868
|
|
KEYWORD
|
easy,sign
|
|
AUTHOR
|
Arul Lakshminarayan (arul(AT)physics.iitm.ac.in), Sep 27 2005
|
|
EXTENSIONS
|
Edited by Michael Somos Aug 15 2008
|
|
|
Search completed in 0.002 seconds
|