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-10 of 18 results. Next

A001850 Central Delannoy numbers: a(n) = Sum_{k=0..n} C(n,k)*C(n+k,k).

Original entry on oeis.org

1, 3, 13, 63, 321, 1683, 8989, 48639, 265729, 1462563, 8097453, 45046719, 251595969, 1409933619, 7923848253, 44642381823, 252055236609, 1425834724419, 8079317057869, 45849429914943, 260543813797441, 1482376214227923, 8443414161166173, 48141245001931263
Offset: 0

Views

Author

Keywords

Comments

Number of paths from (0,0) to (n,n) in an n X n grid using only steps north, northeast and east (i.e., steps (1,0), (1,1), and (0,1)).
Also the number of ways of aligning two sequences (e.g., of nucleotides or amino acids) of length n, with at most 2*n gaps (-) inserted, so that while unnecessary gappings: - -a a- - are forbidden, both b- and -b are allowed. (If only other of the latter is allowed, then the sequence A000984 gives the number of alignments.) There is an easy bijection from grid walks given by Dickau to such set of alignments (e.g., the straight diagonal corresponds to the perfect alignment with no gaps). - Antti Karttunen, Oct 10 2001
Also main diagonal of array A008288 defined by m(i,1) = m(1,j) = 1, m(i,j) = m(i-1,j-1) + m(i-1,j) + m(i,j-1). - Benoit Cloitre, May 03 2002
So, as a special case of Dmitry Zaitsev's Dec 10 2015 comment on A008288, a(n) is the number of points in Z^n that are L1 (Manhattan) distance <= n from any given point. These terms occur in the crystal ball sequences: a(n) here is the n-th term in the sequence for the n-dimensional cubic lattice. See A008288 for a list of crystal ball sequences (rows or columns of A008288). - Shel Kaphan, Dec 26 2022
a(n) is the number of n-matchings of a comb-like graph with 2*n teeth. Example: a(2) = 13 because the graph consisting of a horizontal path ABCD and the teeth Aa, Bb, Cc, Dd has 13 2-matchings: any of the six possible pairs of teeth and {Aa, BC}, {Aa, CD}, {Bb, CD}, {Cc, AB}, {Dd, AB}, {Dd, BC}, {AB, CD}. - Emeric Deutsch, Jul 02 2002
Number of ordered trees with 2*n+1 edges, having root of odd degree, nonroot nodes of outdegree at most 2 and branches of odd length. - Emeric Deutsch, Aug 02 2002
The sum of the first n coefficients of ((1 - x) / (1 - 2*x))^n is a(n-1). - Michael Somos, Sep 28 2003
Row sums of A063007 and A105870. - Paul Barry, Apr 23 2005
The Hankel transform (see A001906 for definition) of this sequence is A036442: 1, 4, 32, 512, 16384, ... . - Philippe Deléham, Jul 03 2005
Also number of paths from (0,0) to (n,0) using only steps U = (1,1), H = (1,0) and D =(1,-1), U can have 2 colors and H can have 3 colors. - N-E. Fahssi, Jan 27 2008
Equals row sums of triangle A152250 and INVERT transform of A109980: (1, 2, 8, 36, 172, 852, ...). - Gary W. Adamson, Nov 30 2008
Number of overpartitions in the n X n box (treat a walk of the type in the first comment as an overpartition, by interpreting a NE step as N, E with the part thus created being overlined). - William J. Keith, May 19 2017
Diagonal of rational functions 1/(1 - x - y - x*y), 1/(1 - x - y*z - x*y*z). - Gheorghe Coserea, Jul 03 2018
Dimensions of endomorphism algebras End(R^{(n)}) in the Delannoy category attached to the oligomorphic group of order preserving self-bijections of the real line. - Noah Snyder, Mar 22 2023
a(n) is the number of ways to tile a strip of length n with white squares, black squares, and red dominos, where we must have an equal number of white and black squares. - Greg Dresden and Leo Zhang, Jul 11 2025

Examples

			G.f. = 1 + 3*x + 13*x^2 + 63*x^3 + 321*x^4 + 1683*x^5 + 8989*x^6 + ...
		

References

  • Frits Beukers, Arithmetic properties of Picard-Fuchs equations, Séminaire de Théorie des nombres de Paris, 1982-83, Birkhäuser Boston, Inc.
  • Miklos Bona, editor, Handbook of Enumerative Combinatorics, CRC Press, 2015, page 593.
  • L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 81.
  • L. Moser and W. Zayachkowski, Lattice paths with diagonal steps, Scripta Math., 26 (1961), 223-229.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
  • R. P. Stanley, Enumerative Combinatorics, Wadsworth, Vol. 2, 1999; see Example 6.3.8 and Problem 6.49.
  • D. B. West, Combinatorial Mathematics, Cambridge, 2021, p. 28.

Crossrefs

Main diagonal of A064861.
Column k=2 of A262809 and A263159.

Programs

  • Maple
    seq(add(multinomial(n+k,n-k,k,k),k=0..n),n=0..20); # Zerinvary Lajos, Oct 18 2006
    seq(orthopoly[P](n,3), n=0..100); # Robert Israel, Nov 03 2015
  • Mathematica
    f[n_] := Sum[ Binomial[n, k] Binomial[n + k, k], {k, 0, n}]; Array[f, 21, 0] (* Or *)
    a[0] = 1; a[1] = 3; a[n_] := a[n] = (3(2 n - 1)a[n - 1] - (n - 1)a[n - 2])/n; Array[a, 21, 0] (* Or *)
    CoefficientList[ Series[1/Sqrt[1 - 6x + x^2], {x, 0, 20}], x] (* Robert G. Wilson v *)
    Table[LegendreP[n, 3], {n, 0, 22}] (* Jean-François Alcover, Jul 16 2012, from first formula *)
    a[n_] := Hypergeometric2F1[-n, n+1, 1, -1]; Table[a[n], {n, 0, 22}] (* Jean-François Alcover, Feb 26 2013 *)
    a[ n_] := With[ {m = If[n < 0, -1 - n, n]}, SeriesCoefficient[ (1 - 6 x + x^2)^(-1/2), {x, 0, m}]]; (* Michael Somos, Jun 10 2015 *)
  • Maxima
    a(n):=coeff(expand((1+3*x+2*x^2)^n),x,n);
    makelist(a(n),n,0,12); /* Emanuele Munarini, Mar 02 2011 */
    
  • PARI
    {a(n) = if( n<0, n = -1 - n); polcoeff( 1 / sqrt(1 - 6*x + x^2 + x * O(x^n)), n)}; /* Michael Somos, Sep 23 2006 */
    
  • PARI
    {a(n) = if( n<0, n = -1 - n); subst( pollegendre(n), x, 3)}; /* Michael Somos, Sep 23 2006 */
    
  • PARI
    {a(n) = if( n<0, n = -1 - n); n++; subst( Pol(((1 - x) / (1 - 2*x) + O(x^n))^n), x, 1);} /* Michael Somos, Sep 23 2006 */
    
  • PARI
    a(n)=if(n<0, 0, polcoeff((1+3*x+2*x^2)^n, n)) \\ Paul Barry, Aug 22 2007
    
  • PARI
    /* same as in A092566 but use */
    steps=[[1,0], [0,1], [1,1]]; /* Joerg Arndt, Jun 30 2011 */
    
  • PARI
    a(n)=sum(k=0,n,binomial(n,k)*binomial(n+k,k)); \\ Joerg Arndt, May 11 2013
    
  • PARI
    my(x='x+O('x^30)); Vec(1/sqrt(1 - 6*x + x^2)) \\ Altug Alkan, Oct 17 2015
    
  • Python
    # from Nick Hobson.
    def f(a, b):
        if a == 0 or b == 0:
            return 1
        return f(a, b - 1) + f(a - 1, b) + f(a - 1, b - 1)
    [f(n, n) for n in range(7)]
    
  • Python
    from gmpy2 import divexact
    A001850 = [1, 3]
    for n in range(2,10**3):
        A001850.append(divexact(A001850[-1]*(6*n-3)-(n-1)*A001850[-2],n))
    # Chai Wah Wu, Sep 01 2014
    
  • Sage
    a = lambda n: hypergeometric([-n, -n], [1], 2)
    [simplify(a(n)) for n in range(23)] # Peter Luschny, Nov 19 2014

Formula

a(n) = P_n(3), where P_n is n-th Legendre polynomial.
G.f.: 1 / sqrt(1 - 6*x + x^2).
a(n) = a(n-1) + 2*A002002(n) = Sum_{j} A063007(n, j). - Henry Bottomley, Jul 02 2001
Dominant term in asymptotic expansion is binomial(2*n, n)/2^(1/4)*((sqrt(2) + 1)/2)^(2*n + 1)*(1 + c_1/n + c_2/n^2 + ...). - Michael David Hirschhorn
a(n) = Sum_{i=0..n} (A000079(i)*A008459(n, i)) = Sum_{i=0..n} (2^i * C(n, i)^2). - Antti Karttunen, Oct 10 2001
a(n) = Sum_{k=0..n} C(n+k, n-k)*C(2*k, k). - Benoit Cloitre, Feb 13 2003
a(n) = Sum_{k=0..n} C(n, k)^2 * 2^k. - Michael Somos, Oct 08 2003
a(n - 1) = coefficient of x^n in A120588(x)^n if n>=0. - Michael Somos, Apr 11 2012
G.f. of a(n-1) = 1 / (1 - x / (1 - 2*x / (1 - 2*x / (1 - x / (1 - 2*x / (1 - x / ...)))))). - Michael Somos, May 11 2012
INVERT transform is A109980. BINOMIAL transform is A080609. BINOMIAL transform of A006139. PSUM transform is A089165. PSUMSIGN transform is A026933. First backward difference is A110170. - Michael Somos, May 11 2012
E.g.f.: exp(3*x)*BesselI(0, 2*sqrt(2)*x). - Vladeta Jovovic, Mar 21 2004
a(n) = Sum_{k=0..n} C(2*n-k, n)*C(n, k). - Paul Barry, Apr 23 2005
a(n) = Sum_{k>=n} binomial(k, n)^2/2^(k+1). - Vladeta Jovovic, Aug 25 2006
a(n) = a(-1 - n) for all n in Z. - Michael Somos, Sep 23 2006
D-finite with recurrence: a(-1) = a(0) = 1; n*a(n) = 3*(2*n-1)*a(n-1) - (n-1)*a(n-2). Eq (4) in T. D. Noe's article in JIS 9 (2006) #06.2.7.
Define general Delannoy numbers by (i,j > 0): d(i,0) = d(0,j) = 1 =: d(0,0) and d(i,j) = d(i-1,j-1) + d(i-2,j-1) + d(i-1,j). Then a(k) = Sum_{j >= 0} d(k,j)^2 + d(k-1,j)^2 = A026933(n)+A026933(n-1). This is a special case of the following formula for general Delannoy numbers: d(k,j) = Sum_{i >= 0, p=0..n} d(p, i) * d(n-p, j-i) + d(p-1, i) * d(n-p-1, j-i-1). - Peter E John, Oct 19 2006
Coefficient of x^n in (1 + 3*x + 2*x^2)^n. - N-E. Fahssi, Jan 11 2008
a(n) = A008288(A046092(n)). - Philippe Deléham, Apr 08 2009
G.f.: 1/(1 - x - 2*x/(1 - x - x/(1 - x - x/(1 - x - x/(1 - ... (continued fraction). - Paul Barry, May 28 2009
G.f.: d/dx log(1/(1 - x*A001003(x))). - Vladimir Kruchinin, Apr 19 2011
G.f.: 1/(2*Q(0) + x - 1) where Q(k) = 1 + k*(1-x) - x - x*(k + 1)*(k + 2)/Q(k+1); (continued fraction). - Sergei N. Gladkovskii, Mar 14 2013
a(n) = Sum_{k=0..n} C(n,k) * C(n+k,k). - Joerg Arndt, May 11 2013
G.f.: G(0), where G(k) = 1 + x*(6 - x)*(4*k + 1)/(4*k + 2 - 2*x*(6-x)*(2*k + 1)*(4*k + 3)/(x*(6 - x)*(4*k + 3) + 4*(k + 1)/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, Jun 22 2013
G.f.: 2/G(0), where G(k) = 1 + 1/(1 - x*(6 - x)*(2*k - 1)/(x*(6 - x)*(2*k - 1) + 2*(k + 1)/G(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Jul 16 2013
G.f.: G(0)/2, where G(k) = 1 + 1/(1 - x*(6 - x)*(2*k + 1)/(x*(6 - x)*(2*k + 1) + 2*(k + 1)/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, Jul 17 2013
a(n)^2 = Sum_{k=0..n} 2^k * C(2*k, k)^2 * C(n+k, n-k) = A243949(n). - Paul D. Hanna, Aug 17 2014
a(n) = hypergeom([-n, -n], [1], 2). - Peter Luschny, Nov 19 2014
a(n) = Sum_{k=0..n/2} C(n-k,k) * 3^(n-2*k) * 2^k * C(n,k). - Vladimir Kruchinin, Jun 29 2015
a(n) = A049600(n, n-1).
a(n) = Sum_{0 <= j, k <= n} (-1)^(n+j)*C(n,k)*C(n,j)*C(n+k,k)*C(n+k+j,k+j). Cf. A126086 and A274668. - Peter Bala, Jan 15 2020
a(n) ~ c * (3 + 2*sqrt(2))^n / sqrt(n), where c = 1/sqrt(4*Pi*(3*sqrt(2)-4)) = 0.572681... (Banderier and Schwer, 2005). - Amiram Eldar, Jun 07 2020
a(n+1) = 3*a(n) + 2*Sum_{l=1..n} A006318(l)*a(n-l). [Eq. (1.16) in Qi-Shi-Guo (2016)]
a(n) ~ (1 + sqrt(2))^(2*n+1) / (2^(5/4) * sqrt(Pi*n)). - Vaclav Kotesovec, Jan 09 2023
a(n-1) + a(n) = A241023(n) for n >= 1. - Peter Bala, Sep 18 2024
a(n) = Sum_{k=0..n} C(n+k, 2*k) * C(2*k, k). - Greg Dresden and Leo Zhang, Jul 11 2025

Extensions

New name and reference Sep 15 1995
Formula and more references from Don Knuth, May 15 1996

A262809 Number A(n,k) of lattice paths from {n}^k to {0}^k using steps that decrement one or more components by one; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, 13, 13, 1, 1, 1, 75, 409, 63, 1, 1, 1, 541, 23917, 16081, 321, 1, 1, 1, 4683, 2244361, 10681263, 699121, 1683, 1, 1, 1, 47293, 308682013, 14638956721, 5552351121, 32193253, 8989, 1, 1, 1, 545835, 58514835289, 35941784497263, 117029959485121, 3147728203035, 1538743249, 48639, 1, 1
Offset: 0

Views

Author

Alois P. Heinz, Oct 02 2015

Keywords

Comments

Also, A(n,k) is the number of alignments for k sequences of length n each (Slowinski 1998).
Row r > 0 is asymptotic to sqrt(r*Pi) * (r^(r-1)/(r-1)!)^n * n^(r*n+1/2) / (2^(r/2) * exp(r*n) * (log(2))^(r*n+1)), or equivalently to sqrt(r) * (r^(r-1)/(r-1)!)^n * (n!)^r / (2^r * (Pi*n)^((r-1)/2) * (log(2))^(r*n+1)). - Vaclav Kotesovec, Mar 23 2016
From Vaclav Kotesovec, Mar 23 2016: (Start)
Column k > 0 is asymptotic to sqrt(c(k)) * d(k)^n / (Pi*n)^((k-1)/2), where c(k) and d(k) are roots of polynomial equations of degree k, independent on n.
---------------------------------------------------
k d(k)
---------------------------------------------------
2 5.8284271247461900976033774484193...
3 56.9476283720414911685286267804411...
4 780.2794068067951456595241495989622...
5 13755.2719024115081712083954421541320...
6 296476.9162644200814909862281498491264...
7 7553550.6198338218721069097516499501996...
8 222082591.6017202421029000117685530884167...
9 7400694480.0494436216324852038000444393262...
10 275651917450.6709238286995776605620357737005...
---------------------------------------------------
d(k) is a root of polynomial:
---------------------------------------------------
k=2, 1 - 6*d + d^2
k=3, -1 + 3*d - 57*d^2 + d^3
k=4, 1 - 12*d - 218*d^2 - 780*d^3 + d^4
k=5, -1 + 5*d - 1260*d^2 - 3740*d^3 - 13755*d^4 + d^5
k=6, 1 - 18*d - 5397*d^2 - 123696*d^3 + 321303*d^4 - 296478*d^5 + d^6
k=7, -1 + 7*d - 24031*d^2 - 374521*d^3 - 24850385*d^4 + 17978709*d^5 - 7553553*d^6 + d^7
k=8, 1 - 24*d - 102692*d^2 - 9298344*d^3 + 536208070*d^4 - 7106080680*d^5 - 1688209700*d^6 - 222082584*d^7 + d^8
(End)
d(k) = (2^(1/k) - 1)^(-k). - David Bevan, Apr 07 2022
d(k) is asymptotic to (k/log(2))^k/sqrt(2). - David Bevan, Apr 07 2022
A(n,k) is the number of binary matrices with k columns and any number of nonzero rows with n ones in every column. - Andrew Howroyd, Jan 23 2020

Examples

			A(2,2) = 13: [(2,2),(1,2),(0,2),(0,1),(0,0)], [(2,2),(1,2),(0,1),(0,0)], [(2,2),(1,2),(1,1),(0,1),(0,0)], [(2,2),(1,2),(1,1),(0,0)], [(2,2),(1,2),(1,1),(1,0),(0,0)], [(2,2),(2,1),(1,1),(0,1),(0,0)], [(2,2),(2,1),(1,1),(0,0)], [(2,2),(2,1),(1,1),(1,0),(0,0)], [(2,2),(2,1),(2,0),(0,1),(0,0)], [(2,2),(2,1),(1,0),(0,0)], [(2,2),(1,1),(0,1),(0,0)], [(2,2),(1,1),(0,0)], [(2,2),(1,1),(1,0),(0,0)].
Square array A(n,k) begins:
  1, 1,    1,        1,             1,                   1, ...
  1, 1,    3,       13,            75,                 541, ...
  1, 1,   13,      409,         23917,             2244361, ...
  1, 1,   63,    16081,      10681263,         14638956721, ...
  1, 1,  321,   699121,    5552351121,     117029959485121, ...
  1, 1, 1683, 32193253, 3147728203035, 1050740615666453461, ...
		

Crossrefs

Columns: A000012 (k=0 and k=1), A001850 (k=2), A126086 (k=3), A263064 (k=4), A263065 (k=5), A263066 (k=6), A263067 (k=7), A263068 (k=8), A263069 (k=9), A263070 (k=10).
Rows: A000012 (n=0), A000670 (n=1), A055203 (n=2), A062208 (n=3), A062205 (n=4), A263061 (n=5), A263062 (n=6), A062204 (n=7), A263063 (n=8), A263071 (n=9), A263072 (n=10).
Main diagonal: A262810.

Programs

  • Maple
    A:= (n, k)-> add(add((-1)^i*binomial(j, i)*
         binomial(j-i, n)^k, i=0..j), j=0..k*n):
    seq(seq(A(n, d-n), n=0..d), d=0..10);
  • Mathematica
    A[, 0] =  1; A[n, k_] := Sum[Sum[(-1)^i*Binomial[j, i]*Binomial[j - i, n]^k, {i, 0, j}], {j, 0, k*n}];
    Table[Table[A[n, d - n], {n, 0, d}], {d, 0, 10}] // Flatten (* Jean-François Alcover, Jul 22 2016, after Alois P. Heinz *)
  • PARI
    T(n,k) = {my(m=n*k); sum(j=0, m, binomial(j,n)^k*sum(i=j, m, (-1)^(i-j)*binomial(i, j)))} \\ Andrew Howroyd, Jan 23 2020

Formula

A(n,k) = Sum_{j=0..k*n} Sum_{i=0..j} (-1)^i*C(j,i)*C(j-i,n)^k.
A(n,k) = Sum_{i >= 0} binomial(i,n)^k/2^(i+1). - Peter Bala, Jan 30 2018
A(n,k) = Sum_{j=0..n*k} binomial(j,n)^k * Sum_{i=j..n*k} (-1)^(i-j) * binomial(i,j). - Andrew Howroyd, Jan 23 2020

A227578 Number A(n,k) of lattice paths from {n}^k to {0}^k using steps that decrement one component such that for each point (p_1,p_2,...,p_k) we have p_1<=p_2<=...<=p_k; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 5, 4, 1, 1, 1, 14, 29, 8, 1, 1, 1, 42, 290, 185, 16, 1, 1, 1, 132, 3532, 7680, 1257, 32, 1, 1, 1, 429, 49100, 456033, 238636, 8925, 64, 1, 1, 1, 1430, 750325, 34426812, 77767945, 8285506, 65445, 128, 1
Offset: 0

Views

Author

Alois P. Heinz, Jul 16 2013

Keywords

Comments

Conjecture: column k is asymptotic to c(k) * (k+1)^(k*n)/n^((k^2-1)/2), where c(k) is a constant dependent only on k. - Vaclav Kotesovec, Jul 21 2013

Examples

			A(4,0) = 1: [()].
A(3,1) = 4: [(3),(0)], [(3),(1),(0)], [(3),(2),(0)], [(3),(2),(1),(0)].
A(2,2) = 5: [(2,2),(0,2),(0,0)], [(2,2),(0,2),(0,1),(0,0)], [(2,2),(1,2),(0,2),(0,0)], [(2,2),(1,2),(0,2),(0,1),(0,0)], [(2,2),(1,2),(1,1),(0,1),(0,0)].
A(1,3) = 1: [(1,1,1),(0,1,1),(0,0,1),(0,0,0)].
A(0,4) = 1: [(0,0,0,0)].
Square array A(n,k) begins:
  1,  1,    1,      1,        1,           1, ...
  1,  1,    1,      1,        1,           1, ...
  1,  2,    5,     14,       42,         132, ...
  1,  4,   29,    290,     3532,       49100, ...
  1,  8,  185,   7680,   456033,    34426812, ...
  1, 16, 1257, 238636, 77767945, 36470203156, ...
		

Crossrefs

Rows n=0+1, 2-10 give: A000012, A000108(k+1), A181197(k+2), A227584, A227602, A227603, A227604, A227605, A227606, A227607.
Main diagonal gives: A227579.
Cf. A060854 (steps decrement one component by 1), A262809, A263159.
A181196 is a similar but different array.

Programs

  • Maple
    b:= proc(l) option remember; `if`(l[-1]=0, 1, add(add(b(subsop(
          i=j, l)), j=`if`(i=1, 0, l[i-1])..l[i]-1), i=1..nops(l)))
        end:
    A:= (n, k)-> `if`(k=0, 1, b([n$k])):
    seq(seq(A(n, d-n), n=0..d), d=0..10);
  • Mathematica
    b[l_] := b[l] = If[ l[[-1]] == 0, 1, Sum[ Sum[ b[ReplacePart[l, i -> j]], {j, If[i == 1, 0, l[[i-1]]], l[[i]]-1}], {i, 1, Length[l]}]]; a[n_, k_] := If[k == 0, 1, b[Array[n&, k]]]; Table[Table[a[n, d - n], {n, 0, d}], {d, 0, 10}] // Flatten (* Jean-François Alcover, Dec 09 2013, translated from Maple *)

A227655 Number A(n,k) of lattice paths from {n}^k to {0}^k using steps that decrement one component by 1 such that for each point (p_1,p_2,...,p_k) we have abs(p_{i}-p_{i+1}) <= 1; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 6, 4, 1, 1, 1, 24, 44, 8, 1, 1, 1, 120, 896, 320, 16, 1, 1, 1, 720, 29392, 33904, 2328, 32, 1, 1, 1, 5040, 1413792, 7453320, 1281696, 16936, 64, 1, 1, 1, 40320, 93770800, 2940381648, 1897242448, 48447504, 123208, 128, 1, 1
Offset: 0

Views

Author

Alois P. Heinz, Jul 19 2013

Keywords

Examples

			A(2,2) = 2^2 = 4:
        (1,2)       (0,1)
       /     \     /     \
  (2,2)       (1,1)       (0,0)
       \     /     \     /
        (2,1)       (1,0)
Square array A(n,k) begins:
  1, 1,  1,     1,        1,            1, ...
  1, 1,  2,     6,       24,          120, ...
  1, 1,  4,    44,      896,        29392, ...
  1, 1,  8,   320,    33904,      7453320, ...
  1, 1, 16,  2328,  1281696,   1897242448, ...
  1, 1, 32, 16936, 48447504, 482913033152, ...
		

Crossrefs

Main diagonal gives A227673.

Programs

  • Maple
    b:= proc(l) option remember; `if`({l[]}={0}, 1, add(
          `if`(l[i]=0 or i>1 and 1 `if`(k<2, 1, b([n$k])):
    seq(seq(A(n, d-n), n=0..d), d=0..10);
  • Mathematica
    b[l_] := b[l] = If[Union[l] == {0}, 1, Sum[If[l[[i]] == 0 || i>1 && 1 < Abs[l[[i-1]] - l[[i]] + 1] || i l[[i]]-1]]], {i, 1, Length[l]}]]; a[n_, k_] := If[k<2, 1, b[Array[n&, k]]]; Table[Table[a[n, d - n], {n, 0, d}], {d, 0, 10}] // Flatten (* Jean-François Alcover, Dec 12 2013, translated from Maple *)

A229142 Number A(n,k) of lattice paths from {n}^k to {0}^k using steps that decrement one component or all components by 1; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, 7, 13, 1, 1, 1, 25, 115, 63, 1, 1, 1, 121, 2641, 2371, 321, 1, 1, 1, 721, 114121, 392641, 54091, 1683, 1, 1, 1, 5041, 7489441, 169417921, 67982041, 1307377, 8989, 1, 1, 1, 40321, 681120721, 137322405361, 308238414121, 12838867105, 32803219, 48639, 1, 1
Offset: 0

Views

Author

Alois P. Heinz, Sep 23 2013

Keywords

Comments

Column k is the diagonal of the rational function 1 / (1 - Sum_{j=1..k} x_j - Product_{j=1..k} x_j) for k>1. - Seiichi Manyama, Jul 10 2020

Examples

			A(1,3) = 3*2+1 = 7:
          (0,1,1)-(0,0,1)
         /       X       \
  (1,1,1)-(1,0,1) (0,1,0)-(0,0,0)
       \ \       X       / /
        \ (1,1,0)-(1,0,0) /
         `---------------´
Square array A(n,k) begins:
  1, 1,    1,       1,           1,               1, ...
  1, 1,    3,       7,          25,             121, ...
  1, 1,   13,     115,        2641,          114121, ...
  1, 1,   63,    2371,      392641,       169417921, ...
  1, 1,  321,   54091,    67982041,    308238414121, ...
  1, 1, 1683, 1307377, 12838867105, 629799991355641, ...
		

Crossrefs

Rows n=0-1 give: A000012, A038507 (for k>1).
Main diagonal gives: A229267.

Programs

  • Maple
    with(combinat):
    A:= (n,k)-> `if`(k<2, 1, add(multinomial(n+(k-1)*j, n-j, j$k), j=0..n)):
    seq(seq(A(n, d-n), n=0..d), d=0..10);
  • Mathematica
    a[, 0] = a[, 1] = 1; a[n_, k_] := Sum[Product[Binomial[n+j*m, m], {j, 0, k-1}], {m, 0, n}]; Table[a[n-k, k], {n, 0, 10}, {k, n, 0, -1}] // Flatten (* Jean-François Alcover, Dec 11 2013 *)

Formula

A(n,k) = Sum_{j=0..n} multinomial(n+(k-1)*j; n-j, {j}^k) for k>1, A(n,0) = A(n,1) = 1.
G.f. of column k: Sum_{j>=0} (k*j)!/j!^k * x^j / (1-x)^(k*j+1). for k>1. - Seiichi Manyama, Jul 10 2020

A225094 Number A(n,k) of lattice paths without interior points from {n}^k to {0}^k using steps that decrement one component by 1; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 2, 0, 1, 1, 6, 2, 0, 1, 1, 24, 54, 2, 0, 1, 1, 120, 1944, 384, 2, 0, 1, 1, 720, 99000, 132000, 2550, 2, 0, 1, 1, 5040, 6966000, 79716000, 8059800, 16506, 2, 0, 1, 1, 40320, 655678800, 78928416000, 57010275000, 471369024, 105840, 2, 0, 1
Offset: 0

Views

Author

Alois P. Heinz, Apr 27 2013

Keywords

Comments

An interior point p = (p_1, ..., p_k) has k>0 components with 0

Examples

			A(n,0) = 1: [()].
A(0,k) = 1: [{0}^k].
A(1,1) = 1: [(1), (0)].
A(2,1) = 0, there is no path from (2) to (0) without interior points.
A(1,2) = 2: [(1,1), (0,1), (0,0)], [(1,1), (1,0), (0,0)].
A(1,3) = 6: [(1,1,1), (0,1,1), (0,0,1), (0,0,0)], [(1,1,1), (0,1,1), (0,1,0), (0,0,0)], [(1,1,1), (1,0,1), (0,0,1), (0,0,0)], [(1,1,1), (1,0,1), (1,0,0), (0,0,0)], [(1,1,1), (1,1,0), (0,1,0), (0,0,0)], [(1,1,1), (1,1,0), (1,0,0), (0,0,0)].
Square array A(n,k) begins:
  1, 1, 1,     1,         1,              1, ...
  1, 1, 2,     6,        24,            120, ...
  1, 0, 2,    54,      1944,          99000, ...
  1, 0, 2,   384,    132000,       79716000, ...
  1, 0, 2,  2550,   8059800,    57010275000, ...
  1, 0, 2, 16506, 471369024, 38606650125120, ...
		

Crossrefs

Columns k=0, 2-4 give: A000012, A040000, A060774, A225220.
Rows n=0-4 give: A000012, A000142, A071798(k) (for k>0), A225096, A225221.
Main diagonal gives: A225111.
Cf. A089759 (unrestricted paths), A210472, A262809, A263159.

Programs

  • Maple
    b:= proc(n, l) option remember; local m; m:= nops(l);
          `if`(m=0 or l[m]=0, 1, `if`(l[1]>0 and l[m] b(n, [n$k]):
    seq(seq(A(n, d-n), n=0..d), d=0..10);
  • Mathematica
    b[n_, l_] := b[n, l] = With[{m = Length[l]}, If[m == 0 || l[[m]] == 0, 1, If[l[[1]] > 0 && l[[m]] < n, 0, Sum[If[l[[i]] == 0, 0, b[n, Sort[ReplacePart[l, i -> l[[i]] - 1]]]], {i, 1, m}]]] ]; a[n_, k_] := b[n, Array[n&, k]]; Table[Table[a[n, d-n], {n, 0, d}], {d, 0, 10}] // Flatten (* Jean-François Alcover, Dec 16 2013, translated from Maple *)

A210472 Number A(n,k) of paths starting at {n}^k to a border position where one component equals 0 using steps that decrement one component by 1; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

0, 1, 0, 1, 1, 0, 1, 2, 1, 0, 1, 3, 6, 1, 0, 1, 4, 33, 20, 1, 0, 1, 5, 196, 543, 70, 1, 0, 1, 6, 1305, 22096, 10497, 252, 1, 0, 1, 7, 9786, 1304045, 3323092, 220503, 924, 1, 0, 1, 8, 82201, 106478916, 1971644785, 574346824, 4870401, 3432, 1, 0
Offset: 0

Author

Alois P. Heinz, Jan 22 2013

Keywords

Examples

			A(0,3) = 1: [(0,0,0)].
A(1,1) = 1: [(1), (0)].
A(1,2) = 2: [(1,1), (0,1)], [(1,1), (1,0)].
A(1,3) = 3: [(1,1,1), (0,1,1)], [(1,1,1), (1,0,1)], [(1,1,1), (1,1,0)].
A(2,1) = 1: [(2), (1), (0)].
A(2,2) = 6: [(2,2), (1,2), (0,2)], [(2,2), (1,2), (1,1), (0,1)], [(2,2), (1,2), (1,1), (1,0)], [(2,2), (2,1), (1,1), (0,1)], [(2,2), (2,1), (1,1), (1,0)], [(2,2), (2,1), (2,0)].
Square array A(n,k) begins:
  0, 1,   1,      1,         1,             1, ...
  0, 1,   2,      3,         4,             5, ...
  0, 1,   6,     33,       196,          1305, ...
  0, 1,  20,    543,     22096,       1304045, ...
  0, 1,  70,  10497,   3323092,    1971644785, ...
  0, 1, 252, 220503, 574346824, 3617739047205, ...
		

Crossrefs

Columns k=0-4 give: A000004, A000012, A000984, A209245, A209288.
Rows n=0-3 give: A057427, A001477, A093964, A210486.
Main diagonal gives A276490.
Cf. A089759 (unrestricted paths), A225094, A262809, A263159.

Programs

  • Maple
    b:= proc() option remember; `if`(nargs=0, 0, `if`(args[1]=0, 1,
          add(b(sort(subsop(i=args[i]-1, [args]))[]), i=1..nargs)))
        end:
    A:= (n, k)-> b(n$k):
    seq(seq(A(n, d-n), n=0..d), d=0..10);
  • Mathematica
    b[] = 0; b[args__] := b[args] = If[First[{args}] == 0, 1, Sum[b @@ Sort[ReplacePart[{args}, i -> {args}[[i]] - 1]], {i, 1, Length[{args}]}]]; a[n_, k_] := b @@ Array[n&, k]; Table[Table[a[n, d-n], {n, 0, d}], {d, 0, 10}] // Flatten (* Jean-François Alcover, Dec 12 2013, translated from Maple *)

A255047 1 together with the positive terms of A000225.

Original entry on oeis.org

1, 1, 3, 7, 15, 31, 63, 127, 255, 511, 1023, 2047, 4095, 8191, 16383, 32767, 65535, 131071, 262143, 524287, 1048575, 2097151, 4194303, 8388607, 16777215, 33554431, 67108863, 134217727, 268435455, 536870911, 1073741823, 2147483647, 4294967295
Offset: 0

Author

Omar E. Pol, Feb 15 2015

Keywords

Comments

Also, right border of A246674 arranged as an irregular triangle.
Essentially the same as A168604, A126646 and A000225.
Total number of lambda-parking functions induced by all partitions of n. a(0)=1: [], a(1)=1: [1], a(2)=3: [1], [2], [1,1], a(4)=7: [1], [2], [3], [1,1], [1,2], [2,1], [1,1,1]. - Alois P. Heinz, Dec 04 2015
Also, the decimal representation of the diagonal from the origin to the corner of the n-th stage of growth of the two-dimensional cellular automaton defined by "Rule 645", based on the 5-celled von Neumann neighborhood, initialized with a single black (ON) cell at stage zero. - Robert Price, Jul 19 2017
Also number of multiset partitions of {1,1} U [n] into exactly 2 nonempty parts. a(2) = 3: 111|2, 11|12, 1|112. - Alois P. Heinz, Aug 18 2017
Also, the number of unlabeled connected P-series (equivalently, connected P-graphs) with n+1 elements. - Salah Uddin Mohammad, Nov 19 2021

References

  • S. Wolfram, A New Kind of Science, Wolfram Media, 2002; p. 170.

Crossrefs

Row n=1 of A263159.
Column k=2 of A291117.
Cf. A078485.

Programs

  • Magma
    [1] cat [2^n -1: n in [1..40]]; // G. C. Greubel, Feb 07 2021
    
  • Mathematica
    CoefficientList[Series[(1 -2*x +2*x^2)/((1-x)*(1-2*x)), {x, 0, 33}], x] (* or *) LinearRecurrence[{3, -2}, {1,1,3}, 40] (* Vincenzo Librandi, Jul 20 2017 *)
    Table[2^n -1 +Boole[n==0], {n, 0, 40}] (* G. C. Greubel, Feb 07 2021 *)
  • Python
    def A255047(n): return -1^(-1<Chai Wah Wu, Dec 21 2022
  • Sage
    [1]+[2^n -1 for n in (1..40)] # G. C. Greubel, Feb 07 2021
    

Formula

From Alois P. Heinz, Feb 19 2015: (Start)
O.g.f.: (1 -2*x +2*x^2)/((1-x)*(1-2*x)).
E.g.f.: exp(2*x) - exp(x) + 1. (End)
a(n) = A078485(n+1) for n > 2. - Georg Fischer, Oct 22 2018

A229345 Number A(n,k) of lattice paths from {n}^k to {0}^k using steps that decrement one component or all components by the same positive integer; square array A(n,k), n>=0, k>=0, read by antidiagonals.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 3, 2, 1, 1, 7, 22, 4, 1, 1, 25, 248, 188, 8, 1, 1, 121, 6506, 11380, 1712, 16, 1, 1, 721, 292442, 2359348, 577124, 16098, 32, 1, 1, 5041, 19450082, 1088626684, 991365512, 30970588, 154352, 64, 1
Offset: 0

Author

Alois P. Heinz, Sep 24 2013

Keywords

Examples

			A(2,2) = 22: [(2,2),(1,1),(0,0)], [(2,2),(1,1),(0,1),(0,0)], [(2,2),(1,1),(1,0),(0,0)], [(2,2),(0,0)], [(2,2),(1,2),(0,1),(0,0)], [(2,2),(1,2),(0,2),(0,1),(0,0)], [(2,2),(1,2),(0,2),(0,0)], [(2,2),(1,2),(1,1),(0,0)], [(2,2),(1,2),(1,1),(0,1),(0,0)], [(2,2),(1,2),(1,1),(1,0),(0,0)], [(2,2),(1,2),(1,0),(0,0)], [(2,2),(0,2),(0,1),(0,0)], [(2,2),(0,2),(0,0)], [(2,2),(2,1),(1,0),(0,0)], [(2,2),(2,1),(1,1),(0,0)], [(2,2),(2,1),(1,1),(0,1),(0,0)], [(2,2),(2,1),(1,1),(1,0),(0,0)], [(2,2),(2,1),(0,1),(0,0)], [(2,2),(2,1),(2,0),(1,0),(0,0)], [(2,2),(2,1),(2,0),(0,0)], [(2,2),(2,0),(1,0),(0,0)], [(2,2),(2,0),(0,0)].
Square array A(n,k) begins:
  1,  1,     1,        1,            1,                 1, ...
  1,  1,     3,        7,           25,               121, ...
  1,  2,    22,      248,         6506,            292442, ...
  1,  4,   188,    11380,      2359348,        1088626684, ...
  1,  8,  1712,   577124,    991365512,     4943064622568, ...
  1, 16, 16098, 30970588, 453530591824, 25162900228200976, ...
		

Crossrefs

Columns k=0-3 give: A000012, A011782, A132595(n+1), A229482.
Rows n=0-2 give: A000012, A038507 (for k>1), A229465.
Main diagonal gives: A229346.

Programs

  • Maple
    b:= proc(l) option remember; local m; m:= nops(l);
          `if`(m=0 or l[m]=0, 1,
          `if`(m>1, add(b(l-[j$m]), j=1..l[1]), 0)+
          add(add(b(sort(subsop(i=l[i]-j, l))), j=1..l[i]), i=1..m))
        end:
    A:= (n, k)-> b([n$k]):
    seq(seq(A(n, d-n), n=0..d), d=0..10);  # Alois P. Heinz, Sep 24 2013
  • Mathematica
    b[l_] := b[l] = With[{m = Length[l]}, If[m == 0 || l[[m]] == 0, 1, If[m > 1, Sum[b[l - Array[j&, m]], {j, 1, l[[1]]}],  0] + Sum[Sum[b[Sort[ReplacePart[l, i -> l[[i]] - j]]], {j, 1, l[[i]]}], {i, 1, m}]]]; a[n_, k_] := b[Array[n&, k]]; Table[Table[a[n, d-n], {n, 0, d}], {d, 0, 10}] // Flatten (* Jean-François Alcover, Dec 16 2013, translated from Maple *)

A115866 a(n) = g(n,n,n) where g(a, b, c) is defined as follows: if a = 0 or b = 0 or c = 0 then return 1 otherwise return g(a, b, c-1) + g(a, b-1, c) + g(a-1, b, c) + g(a, b-1, c-1) + g(a-1, b, c-1) + g(a-1, b-1, c) + g(a-1, b-1, c-1).

Original entry on oeis.org

1, 7, 157, 5419, 220561, 9763807, 454635973, 21894817147, 1080094827649, 54250971690007, 2763339510402637, 142338478909290187, 7399210542653679985, 387578046480606144079, 20433042381373273363477, 1083193405190852829195259, 57697563083258107660231681
Offset: 0

Author

Al Zimmermann, Apr 02 2006

Keywords

Comments

A generalization of the recurrence in A001850. The original description of this sequence was the same as that of A126086. The correct explanation for these terms was provided by Nick Hobson, Mar 03 2007.

Crossrefs

Column k=3 of A263159.

Programs

  • Maple
    g():= seq(convert(n, base, 2)[1..3], n=9..15):
    b:= proc(l) option remember;
          `if`(l[1]=0, 1, add(b(sort(l-h)), h=g()))
        end:
    a:= n-> b([n$3]):
    seq(a(n), n=0..25);  # Alois P. Heinz, Oct 14 2015
  • Mathematica
    g[] = Table[Reverse[IntegerDigits[n, 2]][[;; 3]], {n, 2^3 + 1, 2^4 - 1}];
    b[l_] := b[l] = If[l[[1]] == 0, 1, Sum[b[Sort[l - h]], {h, g[]}]];
    a[n_] := b[Table[n, {3}]];
    a /@ Range[0, 25] (* Jean-François Alcover, Apr 25 2020, after Alois P. Heinz *)

Formula

D-finite with recurrence: 2*(n-1)^2*(2*n-1)*(243*n^5 - 3159*n^4 + 16254*n^3 - 41325*n^2 + 51838*n - 25620)*a(n) = (53703*n^8 - 887922*n^7 + 6273882*n^6 - 24692601*n^5 + 59070956*n^4 - 87717383*n^3 + 78694087*n^2 - 38816698*n + 8003688)*a(n-1) + (94527*n^8 - 1549611*n^7 + 10848681*n^6 - 42278007*n^5 + 100087538*n^4 - 147021644*n^3 + 130465402*n^2 - 63678226*n + 13003980)*a(n-2) - (31833*n^8 - 541890*n^7 + 3945213*n^6 - 16007835*n^5 + 39486422*n^4 - 60435299*n^3 + 55812796*n^2 - 28273516*n + 5965068)*a(n-3) + (n-3)*(3159*n^7 - 48114*n^6 + 301212*n^5 - 1002003*n^4 + 1908157*n^3 - 2073535*n^2 + 1184960*n - 272792)*a(n-4) - 2*(n-4)^2*(n-3)*(243*n^5 - 1944*n^4 + 6048*n^3 - 9087*n^2 + 6529*n - 1769)*a(n-5). - Vaclav Kotesovec, Nov 27 2016
a(n) ~ (12*2^(2/3)+15*2^(1/3)+19)^n / (2^(4/3)*3^(1/2)*Pi*n). - Vaclav Kotesovec, Nov 27 2016

Extensions

Edited by N. J. A. Sloane following email from Nick Hobson, Mar 03 2007
More terms from Alois P. Heinz, Sep 30 2015
Showing 1-10 of 18 results. Next