# Greetings from The On-Line Encyclopedia of Integer Sequences! http://oeis.org/
Search: id:a286147
Showing 1-1 of 1
%I A286147 #17 Apr 30 2021 06:04:12
%S A286147 0,2,4,5,1,12,9,13,18,24,14,8,3,17,40,20,26,7,11,50,60,27,19,42,6,61,
%T A286147 49,84,35,43,52,62,73,85,98,112,44,34,25,51,10,72,59,97,144,54,64,33,
%U A286147 41,16,22,71,83,162,180,65,53,88,32,23,15,38,70,181,161,220,77,89,102,116,31,39,48,58,201,221,242,264,90,76,63,101,148,30,21,47,222,200,179,241,312
%N A286147 Square array read by antidiagonals: A(n,k) = T(n XOR k, n), where T(n,k) is sequence A001477 considered as a two-dimensional table, and XOR is bitwise-xor (A003987)
%C A286147 The array is read by descending antidiagonals as A(0,0), A(0,1), A(1,0), A(0,2), A(1,1), A(2,0), ...
%H A286147 Antti Karttunen, Table of n, a(n) for n = 0..10584; the first 145 antidiagonals of array
%H A286147 MathWorld, Pairing Function
%F A286147 A(n,k) = T(A003987(n,k), n), where T(n,k) is sequence A001477 considered as a two-dimensional table, that is, as a pairing function from [0, 1, 2, 3, ...] x [0, 1, 2, 3, ...] to [0, 1, 2, 3, ...].
%e A286147 The top left 0 .. 12 x 0 .. 12 corner of the array:
%e A286147 0, 2, 5, 9, 14, 20, 27, 35, 44, 54, 65, 77, 90
%e A286147 4, 1, 13, 8, 26, 19, 43, 34, 64, 53, 89, 76, 118
%e A286147 12, 18, 3, 7, 42, 52, 25, 33, 88, 102, 63, 75, 150
%e A286147 24, 17, 11, 6, 62, 51, 41, 32, 116, 101, 87, 74, 186
%e A286147 40, 50, 61, 73, 10, 16, 23, 31, 148, 166, 185, 205, 86
%e A286147 60, 49, 85, 72, 22, 15, 39, 30, 184, 165, 225, 204, 114
%e A286147 84, 98, 59, 71, 38, 48, 21, 29, 224, 246, 183, 203, 146
%e A286147 112, 97, 83, 70, 58, 47, 37, 28, 268, 245, 223, 202, 182
%e A286147 144, 162, 181, 201, 222, 244, 267, 291, 36, 46, 57, 69, 82
%e A286147 180, 161, 221, 200, 266, 243, 315, 290, 56, 45, 81, 68, 110
%e A286147 220, 242, 179, 199, 314, 340, 265, 289, 80, 94, 55, 67, 142
%e A286147 264, 241, 219, 198, 366, 339, 313, 288, 108, 93, 79, 66, 178
%e A286147 312, 338, 365, 393, 218, 240, 263, 287, 140, 158, 177, 197, 78
%t A286147 T[a_, b_]:=((a + b)^2 + 3a + b)/2; A[n_, k_]:=T[BitXor[n, k], k]; Table[A[n - k, k], {n, 0, 20}, {k, 0, n}] // Flatten (* _Indranil Ghosh_, May 21 2017 *)
%o A286147 (Scheme)
%o A286147 (define (A286147 n) (A286147bi (A002262 n) (A025581 n)))
%o A286147 (define (A286147bi row col) (let ((a (A003987bi row col)) (b row)) (/ (+ (expt (+ a b) 2) (* 3 a) b) 2))) ;; Where A003987bi implements bitwise-xor (A003987).
%o A286147 (Python)
%o A286147 def T(a, b): return ((a + b)**2 + 3*a + b)//2
%o A286147 def A(n, k): return T(n^k, k)
%o A286147 for n in range(21): print([A(n - k, k) for k in range(n + 1)]) # _Indranil Ghosh_, May 21 2017
%Y A286147 Transpose: A286145.
%Y A286147 Cf. A000096 (row 0), A046092 (column 0), A000217 (main diagonal).
%Y A286147 Cf. A003987, A001477, A286108, A286109, A286150, A286151.
%K A286147 nonn,tabl
%O A286147 0,2
%A A286147 _Antti Karttunen_, May 03 2017
# Content is available under The OEIS End-User License Agreement: http://oeis.org/LICENSE