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.

A051632 Rows of triangle formed using Pascal's rule except we begin and end the n-th row with n-2.

This page as a plain text file.
%I A051632 #15 Oct 27 2023 22:00:44
%S A051632 -2,-1,-1,0,-2,0,1,-2,-2,1,2,-1,-4,-1,2,3,1,-5,-5,1,3,4,4,-4,-10,-4,4,
%T A051632 4,5,8,0,-14,-14,0,8,5,6,13,8,-14,-28,-14,8,13,6,7,19,21,-6,-42,-42,
%U A051632 -6,21,19,7,8,26,40,15,-48,-84,-48,15,40,26,8,9,34,66,55,-33,-132,-132
%N A051632 Rows of triangle formed using Pascal's rule except we begin and end the n-th row with n-2.
%C A051632 Row sums are -2.
%H A051632 Reinhard Zumkeller, <a href="/A051632/b051632.txt">Rows n=0..100 of triangle, flattened</a>
%H A051632 <a href="/index/Pas#Pascal">Index entries for triangles and arrays related to Pascal's triangle</a>
%F A051632 -t(n,k)=((2*k + 1 - n)/(k + 1))*Binomial[n, k] + ((1 - n + 2 (-k + n))/(1 - k + n)) Binomial[n, -k + n]. [From _Roger L. Bagula_, Feb 17 2009]
%e A051632 Contribution from Roger L. Bagula, Feb 17 2009: (Start)
%e A051632 The rows of the triangle, negated, are:
%e A051632 {2},
%e A051632 {1, 1},
%e A051632 {0, 2, 0},
%e A051632 {-1, 2, 2, -1},
%e A051632 {-2, 1, 4, 1, -2},
%e A051632 {-3, -1, 5,5, -1, -3},
%e A051632 {-4, -4, 4, 10, 4, -4, -4},
%e A051632 {-5, -8, 0, 14, 14, 0, -8, -5},
%e A051632 {-6, -13, -8, 14, 28, 14, -8, -13, -6},
%e A051632 {-7, -19, -21, 6, 42,42, 6, -21, -19, -7},
%e A051632 {-8, -26, -40, -15, 48, 84, 48, -15, -40, -26, -8} (End)
%t A051632 t[n_, k_] = ((2*k + 1 - n)/(k + 1))*Binomial[n, k] + ((1 - n + 2 (-k + n))/(1 - k + n)) Binomial[n, -k + n];
%t A051632 Table[Table[t[n, k], {k, 0, n}], {n, 0, 10}];
%t A051632 Flatten[%] (* Roger L. Bagula , Feb 17 2009 *)
%o A051632 (Haskell)
%o A051632 a051632 n k = a051632_tabl !! n !! k
%o A051632 a051632_list = concat a051632_tabl
%o A051632 a051632_tabl = iterate (\rs -> zipWith (+) ([1] ++ rs) (rs ++ [1])) [-2]
%o A051632 -- _Reinhard Zumkeller_, Aug 21 2011
%Y A051632 A156644 [From Roger L. Bagula, Feb 17 2009]
%Y A051632 Cf. A007318.
%K A051632 easy,nice,sign,tabl
%O A051632 0,1
%A A051632 _Asher Auel_