cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A328732 Irregular table read by rows; for any n >= 0, the n-th row contains the numbers of the form u - v with u + v = n and u AND v = 0 (where AND denotes the bitwise AND operator), in ascending order.

This page as a plain text file.
%I A328732 #17 Dec 18 2024 09:27:20
%S A328732 0,-1,1,-2,2,-3,-1,1,3,-4,4,-5,-3,3,5,-6,-2,2,6,-7,-5,-3,-1,1,3,5,7,
%T A328732 -8,8,-9,-7,7,9,-10,-6,6,10,-11,-9,-7,-5,5,7,9,11,-12,-4,4,12,-13,-11,
%U A328732 -5,-3,3,5,11,13,-14,-10,-6,-2,2,6,10,14
%N A328732 Irregular table read by rows; for any n >= 0, the n-th row contains the numbers of the form u - v with u + v = n and u AND v = 0 (where AND denotes the bitwise AND operator), in ascending order.
%C A328732 The n-th row:
%C A328732 - has A001316(n) terms,
%C A328732 - has -n as first term and n as last term,
%C A328732 - has least positive term T(n, A001316(n)/2+1) = A080079(n) (when n > 0).
%H A328732 Rémy Sigrist, <a href="/A328732/b328732.txt">Table of n, a(n) for n = 0..6562</a> (Rows for n = 0..256)
%H A328732 Rémy Sigrist, <a href="/A328732/a328732.png">Scatterplot of (n, T(n, k)) for n = 0..1024 and k = 1..A001316(n)</a>
%e A328732 Table begins:
%e A328732     0;
%e A328732    -1,   1;
%e A328732    -2,   2;
%e A328732    -3,  -1,   1,   3;
%e A328732    -4,   4;
%e A328732    -5,  -3,   3,   5;
%e A328732    -6,  -2,   2,   6;
%e A328732    -7,  -5,  -3,  -1,   1,   3,   5,   7;
%e A328732    -8,   8;
%e A328732    -9,  -7,   7,   9;
%e A328732   -10,  -6,   6,  10;
%e A328732   -11,  -9,  -7,  -5,   5,   7,   9,  11;
%e A328732   -12,  -4,   4,  12;
%e A328732   -13, -11,  -5,  -3,   3,   5,  11,  13;
%e A328732   ...
%o A328732 (PARI) row(n) = my (r=[0], b=Vecrev(binary(n))); for (k=0, #b-1, if (b[k+1], r=concat(apply(v -> [v-2^k,v+2^k], r)))); Set(r)
%Y A328732 Cf. A001316, A080079.
%K A328732 sign,base,tabf
%O A328732 0,4
%A A328732 _Rémy Sigrist_, Oct 26 2019