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.

Showing 1-2 of 2 results.

A123878 Product of signed and unsigned Morgan-Voyce triangles.

Original entry on oeis.org

1, 0, 1, -1, 0, 1, -1, -3, 0, 1, 0, -3, -5, 0, 1, 1, 3, -5, -7, 0, 1, 1, 9, 10, -7, -9, 0, 1, 0, 5, 25, 21, -9, -11, 0, 1, -1, -9, 5, 49, 36, -11, -13, 0, 1, -1, -18, -50, -7, 81, 55, -13, -15, 0, 1, 0, -7, -70, -147, -39, 121, 78, -15, -17, 0, 1
Offset: 0

Views

Author

Paul Barry, Oct 16 2006

Keywords

Comments

Inverse is A123880.
Row sums are A123879.

Examples

			Number triangle begins:
   1;
   0,  1;
  -1,  0,  1;
  -1, -3,  0,  1;
   0, -3, -5,  0,  1;
   1,  3, -5, -7,  0, 1;
   1,  9, 10, -7, -9, 0, 1;
		

Crossrefs

Programs

  • GAP
    B:=Binomial;; Flat(List([0..12], n-> List([0..n], k-> Sum([0..n], j-> (-1)^(j-k)*B(n+j,2*j)*B(n+j,2*k) )))); # G. C. Greubel, Aug 08 2019
  • Magma
    B:= Binomial; [(&+[(-1)^(j-k)*B(n+j,2*j)*B(n+j,2*k):j in [0..n]]) : k in [0..n], n in [0..12]]; // G. C. Greubel, Aug 08 2019
    
  • Mathematica
    Table[Sum[(-1)^(j-k)*Binomial[n+j,2*j]*Binomial[j+k,2*k], {j,0,n}], {n, 0, 12}, {k,0,n}]//Flatten (* G. C. Greubel, Aug 08 2019 *)
  • PARI
    T(n,k) = sum(j=0,n, (-1)^(j-k)*binomial(n+j,2*j)*binomial(n+j,2*k) );
    for(n=0,12, for(k=0,n, print1(T(n,k), ", "))) \\ G. C. Greubel, Aug 08 2019
    
  • Sage
    b=binomial; [[sum((-1)^(j-k)*b(n+j,2*j)*b(n+j,2*k) for j in (0..n)) for k in (0..n)] for n in (0..12)] # G. C. Greubel, Aug 08 2019
    

Formula

Riordan array ((1-x)/(1-x+x^2), x*(1-x)^2/(1-x+x^2)^2).
Number triangle: T(n,k) = Sum_{j=0..n} C(n+j,2*j)*C(j+k,2*k)*(-1)^(j-k).

A123879 Expansion of (1-2*x+2*x^2-x^3)/(1-3*x+5*x^2-3*x^3+x^4).

Original entry on oeis.org

1, 1, 0, -3, -7, -7, 5, 32, 57, 33, -95, -311, -416, -11, 1209, 2745, 2573, -2368, -12943, -22015, -11007, 40593, 123712, 157165, -14279, -498119, -1075179, -934944, 1090985, 5220257, 8476193, 3535193, -17205600
Offset: 0

Views

Author

Paul Barry, Oct 16 2006

Keywords

Comments

Row sums of number triangle A123878.

Crossrefs

Programs

  • GAP
    a:=[1,1,0,-3];; for n in [5..40] do a[n]:=3*a[n-1]-5*a[n-2]+3*a[n-3]-a[n-4]; od; a; # G. C. Greubel, Aug 08 2019
  • Magma
    R:=PowerSeriesRing(Integers(), 40); Coefficients(R!( (1-2*x+2*x^2-x^3)/(1-3*x+5*x^2-3*x^3+x^4) )); // G. C. Greubel, Aug 08 2019
    
  • Maple
    seq(coeff(series((1-2*x+2*x^2-x^3)/(1-3*x+5*x^2-3*x^3+x^4), x, n+1), x, n), n = 0 .. 40); # G. C. Greubel, Aug 08 2019
  • Mathematica
    LinearRecurrence[{3,-5,3,-1}, {1,1,0,-3}, 40] (* G. C. Greubel, Aug 08 2019 *)
  • PARI
    my(x='x+O('x^40)); Vec((1-2*x+2*x^2-x^3)/(1-3*x+5*x^2-3*x^3+x^4)) \\ G. C. Greubel, Aug 08 2019
    
  • Sage
    def A123879_list(prec):
        P. = PowerSeriesRing(ZZ, prec)
        return P((1-2*x+2*x^2-x^3)/(1-3*x+5*x^2-3*x^3+x^4)).list()
    A123879_list(40) # G. C. Greubel, Aug 08 2019
    

Formula

a(n) = Sum_{k=0..n} Sum_{j=0..n} (-1)^(j-k)*C(n+j,2*j)*C(j+k,2*k).
Showing 1-2 of 2 results.