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-4 of 4 results.

A132813 Triangle read by rows: A001263 * A127648 as infinite lower triangular matrices.

Original entry on oeis.org

1, 1, 2, 1, 6, 3, 1, 12, 18, 4, 1, 20, 60, 40, 5, 1, 30, 150, 200, 75, 6, 1, 42, 315, 700, 525, 126, 7, 1, 56, 588, 1960, 2450, 1176, 196, 8, 1, 72, 1008, 4704, 8820, 7056, 2352, 288, 9, 1, 90, 1620, 10080, 26460, 31752, 17640, 4320, 405, 10
Offset: 0

Views

Author

Gary W. Adamson, Sep 01 2007

Keywords

Comments

Also T(n,k) = binomial(n-1, k-1)*binomial(n, k-1), related to Narayana polynomials (see Sulanke reference). - Roger L. Bagula, Apr 09 2008
h-vector for cluster complex associated to the root system B_n. See p. 8, Athanasiadis and C. Savvidou. - Tom Copeland, Oct 19 2014

Examples

			First few rows of the triangle are:
  1;
  1,  2;
  1,  6,   3;
  1, 12,  18,   4;
  1, 20,  60,  40,   5;
  1, 30, 150, 200,  75,   6;
  1, 42, 315, 700, 525, 126, 7;
  ...
		

Crossrefs

Family of polynomials (see A062145): A008459 (c=1), this sequence (c=2), A062196 (c=3), A062145 (c=4), A062264 (c=5), A062190 (c=6).
Columns: A000012 (k=0), A002378 (k=1), A006011 (k=2), 4*A006542 (k=3), 5*A006857 (k=4), 6*A108679 (k=5), 7*A134288 (k=6), 8*A134289 (k=7), 9*A134290 (k=8), 10*A134291 (k=9).
Diagonals: A000027 (k=n), A002411 (k=n-1), A004302 (k=n-2), A108647 (k=n-3), A134287 (k=n-4).
Main diagonal: A000894.
Sums: (-1)^floor((n+1)/2)*A001405 (signed row), A001700 (row), A203611 (diagonal).
Cf. A103371 (mirrored).

Programs

  • GAP
    Flat(List([0..10],n->List([0..n], k->(k+1)*Binomial(n+1,k+1)*Binomial(n+1,k)/(n+1)))); # Muniru A Asiru, Feb 26 2019
    
  • Haskell
    a132813 n k = a132813_tabl !! n !! k
    a132813_row n = a132813_tabl !! n
    a132813_tabl = zipWith (zipWith (*)) a007318_tabl $ tail a007318_tabl
    -- Reinhard Zumkeller, Apr 04 2014
    
  • Magma
    /* triangle */ [[(k+1)*Binomial(n+1,k+1)*Binomial(n+1,k)/(n+1): k in [0..n]]: n in [0.. 15]]; // Vincenzo Librandi, Oct 19 2014
    
  • Maple
    P := (n, x) -> hypergeom([1-n, -n], [1], x): for n from 1 to 9 do PolynomialTools:-CoefficientList(simplify(P(n,x)),x) od; # Peter Luschny, Nov 26 2014
  • Mathematica
    T[n_,k_]=Binomial[n-1,k-1]*Binomial[n,k-1]; Table[Table[T[n,k],{k,1,n}],{n,1,11}]; Flatten[%] (* Roger L. Bagula, Apr 09 2008 *)
    P[n_, x_] := HypergeometricPFQ[{1-n, -n}, {1}, x]; Table[CoefficientList[P[n, x], x], {n, 1, 10}] // Flatten (* Jean-François Alcover, Nov 27 2014, after Peter Luschny *)
  • PARI
    tabl(nn) = {for (n = 1, nn, for (k = 1, n, print1(binomial(n-1, k-1)*binomial(n, k-1) , ", ");););} \\ Michel Marcus, Feb 12 2014
    
  • SageMath
    def A132813(n,k): return binomial(n,k)*binomial(n+1,k)
    print(flatten([[A132813(n,k) for k in range(n+1)] for n in range(13)])) # G. C. Greubel, Mar 12 2025

Formula

T(n,k) = (k+1)*binomial(n+1,k+1)*binomial(n+1,k)/(n+1), n >= k >= 0.
From Roger L. Bagula, May 14 2010: (Start)
T(n, m) = coefficients(p(x,n)), where
p(x,n) = (1-x)^(2*n)*Sum_{k >= 0} binomial(k+n-1, k)*binomial(n+k, k)*x^k,
or p(x,n) = (1-x)^(2*n)*Hypergeometric2F1([n, n+1], [1], x). (End)
T(n,k) = binomial(n,k) * binomial(n+1,k). - Reinhard Zumkeller, Apr 04 2014
These are the coefficients of the polynomials Hypergeometric2F1([1-n,-n], [1], x). - Peter Luschny, Nov 26 2014
G.f.: A(x,y) = A281260(x,y)/(1-A281260(x,y))/x. - Vladimir Kruchinin, Oct 10 2020

A110236 Number of (1,0) steps in all peakless Motzkin paths of length n (can be easily translated into RNA secondary structure terminology).

Original entry on oeis.org

1, 2, 4, 10, 24, 58, 143, 354, 881, 2204, 5534, 13940, 35213, 89162, 226238, 575114, 1464382, 3734150, 9534594, 24374230, 62377881, 159793932, 409717004, 1051405260, 2700168229, 6939388478, 17845927498, 45922416814, 118238842174
Offset: 1

Views

Author

Emeric Deutsch, Jul 17 2005

Keywords

Comments

Number of UHD's in all peakless Motzkin paths of length n+2; here U=(1,1), H=(1,0), and D=(1,-1). Example: a(2)=2 because in HHHH, HUHD, UHDH, and UHHD we have a total of 0+1+1+0 UHD's.

Examples

			a(3)=4 because in the 2 (=A004148(3)) peakless Motzkin paths of length 3, namely HHH and UHD (where U=(1,1), H=(1,0) and D=(1,-1)), we have altogether 4 H steps.
		

Crossrefs

Cf. A004148, A110235, A089732, A190172, A203611, bisection of A202411.

Programs

  • Maple
    T:=proc(n,k) if n+k mod 2 = 0 then 2*binomial((n+k)/2,k)*binomial((n+k)/2,k-1)/(n+k) else 0 fi end:seq(add(k*T(n,k),k=1..n),n=1..33);
  • Mathematica
    Rest[CoefficientList[Series[((1-x+x^2)*((x^2+x+1)*(x^2-3*x+1))^(-1/2)-1) /(2*x), {x, 0, 20}], x]] (* Vaclav Kotesovec, Feb 13 2014 *)
  • PARI
    x='x+O('x^66); Vec(((1-x+x^2)*((x^2+x+1)*(x^2-3*x+1))^(-1/2)-1)/(2*x)) /* Joerg Arndt, Mar 27 2013 */

Formula

a(n) = Sum_{k=1..n} k*T(n, k), where T(n, k) = floor(2/(n+k))*binomial((n+k)/2, k)*binomial((n+k)/2, k-1) for n+k mod 2 = 0 and T(n, k)=0 otherwise.
G.f.: (1-z+z^2-Q)/(2*z*Q), where Q = sqrt(1 - 2z - z^2 - 2z^3 + z^4).
a(n) = Sum_{k=1..n} k*A110235(n,k).
a(n) = Sum_{k>=0} k*A190172(n+2,k).
a(n+1) = Sum_{k=0..n} Sum_{j=0..n-k} C(k+j,n-k-j)*C(k,n-k-j). - Paul Barry, Oct 24 2006, index corrected Jul 13 2011
a(n+1) = Sum_{k=0..floor(n/2)} C(n-k+1,k+1)*C(n-k,k); a(n+1) := Sum_{k=0..n} C(k+1,n-k+1)*C(k,n-k). - Paul Barry, Aug 17 2009, indices corrected Jul 13 2011
G.f.: z*S^2/(1-z^2*S^2), where S = 1 + z*S + z^2*S*(S-1) (the g.f. of the RNA secondary structure numbers; A004148).
a(n) = -f_{n}(-n) with f_1(n)=n and f_{p}(n) = (n+p-1)*(n+p+1-1)^2 *(n+p+2-1)^2*...*(n+p+(p-1)-1)^2/(p!*(p-1)!) + f_{p-1}(n) for p > 1. - Alzhekeyev Ascar M, Jun 27 2011
Let A=floor(n/2), R=n-1, B=A-R/2+1, C=A+1, D=A-R and Z=1 if n mod 2 = 1, otherwise Z = n*(n+2)/4. Then a(n) = Z*Hypergeometric([1,C,C+1,D,D-1],[B,B,B-1/2,B-1/2],1/16). - Peter Luschny, Jan 14 2012
D-finite with recurrence (n+1)*a(n) -3*n*a(n-1) +2*(n-3)*a(n-2) +3*(-n+2)*a(n-3) +2*(n-1)*a(n-4) +3*(-n+4)*a(n-5) +(n-5)*a(n-6)=0. - R. J. Mathar, Nov 30 2012
G.f.: ((1-x+x^2)*((x^2+x+1)*(x^2-3*x+1))^(-1/2)-1)/(2*x). - Mark van Hoeij, Mar 27 2013
From Vaclav Kotesovec, Feb 13 2014: (Start)
Recurrence: (n-2)*(n-1)*(n+1)*a(n) = (n-2)*n*(2*n-1)*a(n-1) + (n-1)*(n^2 - 2*n - 2)*a(n-2) + (n-2)*n*(2*n-3)*a(n-3) - (n-3)*(n-1)*n*a(n-4).
a(n) ~ (sqrt(5)+3)^(n+1) / (5^(1/4) * sqrt(Pi*n) * 2^(n+2)). (End)

A202411 a(n) = Sum_{k=floor(n/4)..R} C(k, m*k - (-1)^n*(R - k)) * C(k + 1, m*(k + 2) - (-1)^n*(R - k + 1)) where m = (n + 1) mod 2 and R = (n + m - 3)/2 for n > 0 and a(0) = 1.

Original entry on oeis.org

1, 0, 1, 1, 1, 2, 3, 4, 7, 10, 16, 24, 39, 58, 95, 143, 233, 354, 577, 881, 1436, 2204, 3590, 5534, 9011, 13940, 22691, 35213, 57299, 89162, 145043, 226238, 367931, 575114, 935078, 1464382, 2380405, 3734150, 6068745, 9534594, 15492702, 24374230, 39598631
Offset: 0

Views

Author

Peter Luschny, Jan 14 2012

Keywords

Examples

			Fibonacci meanders classified by maximal run length of 1s (see the link) lead to the triangle
   0,  1;
   1,  1,  0, 1;
   2,  1,  1, 1, 0, 1;
   4,  3,  2, 1, 1, 1, 0, 1;
  10,  7,  4, 3, 2, 1, 1, 1, 0, 1;
  24, 16, 10, 7, 4, 3, 2, 1, 1, 1, 0, 1.
		

Crossrefs

Programs

  • Maple
    A202411 := proc(n) local A, R, B, C, D, Z, H, J; if n = 0 then RETURN(1) fi;
    H:=iquo(n,2); A:=iquo(H,2); R:=H-1; B:=A-R/2+1; C:=A+1; D:=A-R; J:=n mod 2; if J = 0 then Z:=`if`(H mod 2 = 1,(H+1)/2,H^2*(H+2)/16) else Z:=`if`(H mod 2 = 1,1, H*(H+2)/4) fi; Z*hypergeom([1,C,C+1,D,D-J],[B,B,B-1/2,B+1/2-J],1/16) end:
    seq(simplify(A202411(i)),i=0..42);
  • Mathematica
    A202411[0] = 1; A202411[n_] := Module[{A, R, B, C, D, Z, H, J}, H = Quotient[n, 2]; A = Quotient[H, 2]; R = H-1; B = A - R/2 + 1; C = A+1; D = A - R; J = Mod[n, 2]; If[J == 0, Z = If[Mod[H, 2] == 1, (H+1)/2, H^2*(H + 2)/16], Z = If[Mod[H, 2] == 1, 1, H*(H+2)/4]]; Z*HypergeometricPFQ[{1, C, C + 1, D, D - J}, {B, B, B - 1/2, B + 1/2 - J}, 1/16]]; Table[A202411[n], {n, 0, 42}]
    (* Jean-François Alcover, Jan 27 2014, translated from Maple *)

Formula

For n > 0 let H = floor(n/2), A = floor(H/2), R = H - 1, B = A - R/2 + 1, C = A + 1, D = A - R, J = n mod 2 and Z = if(H mod 2 = 1, (H + 1)/2, H^2*(H + 2)/16) if J = 0 else Z = if(H mod 2 = 1, 1, H*(H + 2)/4); then:
a(n) = Z*Hypergeometric([1, C, C+1, D, D-J], [B, B, B-1/2, B+1/2-J], 1/16).

A201631 a(n) is the number of Fibonacci meanders of length m*n and central angle 360/m degrees where m = 2.

Original entry on oeis.org

1, 3, 6, 13, 30, 70, 167, 405, 992, 2450, 6090, 15214, 38165, 96069, 242530, 613811, 1556856, 3956316, 10070871, 25674210, 65541142, 167517654, 428635032, 1097874434, 2814611701, 7221917871, 18544968768, 47655572191, 122544150258, 315313433594, 811792614547
Offset: 1

Views

Author

Peter Luschny, Jan 15 2012

Keywords

Comments

Empirically the partial sums of A051291. - Sean A. Irvine, Jul 13 2022
The above conjecture was proved by Baril et al., which also give a formal definition of the Fibonacci meanders and describe a bijection with a certain class of peakless grand Motzkin paths of length n. - Peter Luschny, Mar 16 2023

Examples

			a(3) = 6 = card({100001, 100100, 110000, 111001, 111100, 111111}).
		

Crossrefs

Programs

  • Maple
    A201631 := n -> add(A202411(k),k=0..2*n-1): seq(A201631(i),i=1..9);
    # Alternative, using the g.f. of Baril et al.:
    S := (x^2 - x + 1 - R)/((x - 1)*(x^2 - x - 1 + R)*R):
    R := (((x - 3)*x + 1)*(x^2 + x + 1))^(1/2): ser := series(S, x, 33):
    seq(coeff(ser, x, n), n = 1..31); # Peter Luschny, Mar 16 2023
    # Using a recurrence:
    a := proc(n) option remember; if n < 5 then return [0, 1, 3, 6, 13][n + 1] fi;
    (n*(2*n - 1)*(2*n - 3)*(n - 5)*a(n - 5) - (n - 4)*(2*n - 1)^2*(3*n - 5)*a(n - 4) + (2*n - 5)*(n - 3)*(2*n^2 - 3*n + 2)*a(n - 3) - (2*n - 3)*(n - 2)*(2*n^2 - 3*n + 5)*a(n - 2) + (3*n - 4)*(2*n - 1)*(2*n - 5)*(n - 1)*a(n - 1))/(n*(2*n - 3)*(2*n - 5)*(n - 1)) end: seq(a(n), n = 1..31); # Peter Luschny, Mar 16 2023
  • Mathematica
    a[n_] := Sum[A202411[k], {k, 0, 2 n - 1}];
    Array[a, 31] (* Jean-François Alcover, Jun 29 2019 *)

Formula

a(n) = Sum_{k=0..2n-1} A202411(k).
a(n) = [x^n] (x^2 - x + 1 - R)/((x - 1)*(x^2 - x - 1 + R) * R), where R = (((x - 3)*x + 1)*(x^2 + x + 1))^(1/2). (This is Theorem 21 in Baril et al.) - Peter Luschny, Mar 16 2023
Showing 1-4 of 4 results.