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.

A104967 Matrix inverse of triangle A104219, read by rows, where A104219(n,k) equals the number of Schroeder paths of length 2n having k peaks at height 1.

This page as a plain text file.
%I A104967 #43 Jan 11 2025 18:10:28
%S A104967 1,-1,1,-1,-2,1,-1,-1,-3,1,-1,0,0,-4,1,-1,1,2,2,-5,1,-1,2,3,4,5,-6,1,
%T A104967 -1,3,3,3,5,9,-7,1,-1,4,2,0,0,4,14,-8,1,-1,5,0,-4,-6,-6,0,20,-9,1,-1,
%U A104967 6,-3,-8,-10,-12,-14,-8,27,-10,1,-1,7,-7,-11,-10,-10,-14,-22,-21,35,-11,1,-1,8,-12,-12,-5,0,0,-8,-27,-40,44,-12,1
%N A104967 Matrix inverse of triangle A104219, read by rows, where A104219(n,k) equals the number of Schroeder paths of length 2n having k peaks at height 1.
%C A104967 Row sums equal A090132 with odd-indexed terms negated. Absolute row sums form A104968. Row sums of squared terms gives A104969.
%C A104967 Riordan array ((1-2*x)/(1-x), x(1-2*x)/(1-x)). - _Philippe Deléham_, Dec 05 2015
%H A104967 Paul D. Hanna, <a href="/A104967/b104967.txt">Table of n, a(n) for n = 0..1080</a>
%F A104967 G.f.: A(x, y) = (1-2*x)/(1-x - x*y*(1-2*x)).
%F A104967 Sum_{k=0..n} T(n, k) = (-1)^n*A090132(n).
%F A104967 Sum_{k=0..n} abs(T(n, k)) = A104968(n).
%F A104967 Sum_{k=0..n} T(n, k)^2 = A104969(n).
%F A104967 T(n,k) = Sum_{i=0..n-k} (-2)^i*binomial(k+1,i)*binomial(n-i,k). - _Vladimir Kruchinin_, Nov 02 2011
%F A104967 Sum_{k=0..floor(n/2)} T(n-k, k) = A078011(n+2). - _G. C. Greubel_, Jun 09 2021
%e A104967 Triangle begins:
%e A104967    1;
%e A104967   -1,  1;
%e A104967   -1, -2,  1;
%e A104967   -1, -1, -3,  1;
%e A104967   -1,  0,  0, -4,  1;
%e A104967   -1,  1,  2,  2, -5,  1;
%e A104967   -1,  2,  3,  4,  5, -6,  1;
%e A104967   -1,  3,  3,  3,  5,  9, -7,  1;
%e A104967   -1,  4,  2,  0,  0,  4, 14, -8,  1;
%e A104967   -1,  5,  0, -4, -6, -6,  0, 20, -9, 1; ...
%p A104967 A104967:= (n,k)-> add( (-2)^j*binomial(k+1, j)*binomial(n-j, k), j=0..n-k);
%p A104967 seq(seq( A104967(n,k), k=0..n), n=0..12); # _G. C. Greubel_, Jun 09 2021
%t A104967 T[n_, k_]:= T[n, k]= Which[k==n, 1, k==0, 0, True, T[n-1, k-1] - Sum[T[n-i, k-1], {i, 2, n-k+1}]];
%t A104967 Table[T[n, k], {n, 13}, {k, n}]//Flatten (* _Jean-François Alcover_, Jun 11 2019, after _Peter Luschny_ *)
%o A104967 (PARI) {T(n,k)=local(X=x+x*O(x^n),Y=y+y*O(y^k)); polcoeff(polcoeff((1-2*X)/(1-X-X*Y*(1-2*X)),n,x),k,y)}
%o A104967 for(n=0, 16, for(k=0, n, print1(T(n, k), ", ")); print(""))
%o A104967 (Maxima) T(n,k):=sum((-2)^i*binomial(k+1,i)*binomial(n-i,k),i,0,n-k); /* _Vladimir Kruchinin_, Nov 02 2011 */
%o A104967 (Sage)
%o A104967 def A104967_row(n):
%o A104967     @cached_function
%o A104967     def prec(n, k):
%o A104967         if k==n: return 1
%o A104967         if k==0: return 0
%o A104967         return prec(n-1,k-1)-sum(prec(n-i,k-1) for i in (2..n-k+1))
%o A104967     return [prec(n, k) for k in (1..n)]
%o A104967 for n in (1..10): print(A104967_row(n)) # _Peter Luschny_, Mar 16 2016
%o A104967 (Magma)
%o A104967 A104967:= func< n,k | (&+[(-2)^j*Binomial(k+1, j)*Binomial(n-j, k): j in [0..n-k]]) >;
%o A104967 [A104967(n,k): k in [0..n], n in [0..12]]; // _G. C. Greubel_, Jun 09 2021
%Y A104967 Cf. A078011, A090132, A104968, A104969, A134824, A153881.
%Y A104967 Cf. A347171 (rows reversed, up to signs).
%K A104967 sign,tabl
%O A104967 0,5
%A A104967 _Paul D. Hanna_, Mar 30 2005