login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A120710 A GF(2) polynomial analog of triangular numbers. 0
0, 0, 0, 2, 0, 4, 8, 14, 0, 8, 16, 26, 32, 44, 56, 70, 0, 16, 32, 50, 64, 84, 104, 126, 128, 152, 176, 202, 224, 252, 280, 310, 0, 32, 64, 98, 128, 164, 200, 238, 256, 296, 336, 378, 416, 460, 504, 550, 512, 560, 608, 658, 704, 756, 808, 862, 896, 952, 1008, 1066, 1120 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,4

COMMENTS

The k-th bit in a(n) is one just if there are an odd number of pairs of distinct one bits i#j in n such that i+j=k. GF(2) polynomial ("XOR numbral") multiplication can be implemented as A048720(i,j) = A000695(i AND j) XOR a(i AND j) XOR a(i IOR j) XOR a(i AND NOT j) XOR a(NOT i AND j), analogously to ordinary multiplication (A003991) ij = tri(i+j)-tri(i)-tri(j) via triangular numbers (A000217).

REFERENCES

Posting by Richard C. Schroeppel to math-fun mailing list, Jun 26 2006.

LINKS

Table of n, a(n) for n=0..60.

FORMULA

a(0)=0; a(n + 2^k) = a(n) XOR (n * 2^k), 0<=n<2^k.

EXAMPLE

a(15)=54 because 15=2^0+2^1+2^2+2^3, the four one-bits giving six distinct pairs 01 02 03 12 13 23, which sum to 1 2 3 3 4 5, of which 1 2 4 and 5 occur oddly, yielding 2^1+2^2+2^4+2^5=54.

CROSSREFS

Cf. A048720, A000695, A003991, A000217.

Sequence in context: A021087 A120558 A120554 * A115780 A101189 A295321

Adjacent sequences:  A120707 A120708 A120709 * A120711 A120712 A120713

KEYWORD

base,easy,nonn

AUTHOR

Marc LeBrun, Jun 28 2006

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified February 20 14:37 EST 2018. Contains 299380 sequences. (Running on oeis4.)