# [seqfan] Re: Asymptotic formula

allouche at math.jussieu.fr allouche at math.jussieu.fr
Tue May 3 12:49:43 CEST 2011

```Right. This is what I alluded to with the sum of the
binary digits, and what Benoit made a bit more precise
when alluding to the Thue-Morse sequence.
jpa

Aai <bradypus at xs4all.nl> a écrit :

> Ignoring the 0's of the sequence and the first 1, the sign pattern of
> the numbers is as follows:
>
> *Main> take 4 \$ iterate (ap (++) (map negate)) [-1]
> [[-1],[-1,1],[-1,1,1,-1],[-1,1,1,-1,1,-1,-1,1]]
>
> This is: every next sub sequence is itself extended with its negation:
>   [-1,1] -->   [-1, 1,1,-1]
>
>
> Using this, the non-zero elements are simply obtained iteratively.
> e.g. for r=2:
>
> an r = (1:). concat
>   \$ zipWith (map. (*)) (map (r^)[1..]) (iterate (ap (++) (map negate)) [-1])
>
> *Main> take 16 \$ an (2)
> [1,-2,-4,4,-8,8,8,-8,-16,16,16,-16,16,-16,-16,16]
>
>
>

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

```