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.

A334640 a(n) is the total number of down steps between the 2nd and 3rd up steps in all 2-Dyck paths of length 3*n. A 2-Dyck path is a nonnegative lattice path with steps (1, 2), (1, -1) that starts and ends at y = 0.

This page as a plain text file.
%I A334640 #30 Aug 08 2020 01:42:37
%S A334640 0,0,9,19,72,324,1595,8307,44982,250648,1427679,8274825,48644310,
%T A334640 289334160,1738043892,10529070020,64252519830,394601627376,
%U A334640 2437058926871,15126463230165,94306717535940,590318477063700,3708527622652755,23374587898663155,147770791807427880
%N A334640 a(n) is the total number of down steps between the 2nd and 3rd up steps in all 2-Dyck paths of length 3*n. A 2-Dyck path is a nonnegative lattice path with steps (1, 2), (1, -1) that starts and ends at y = 0.
%C A334640 For n = 2, there is no 3rd up step, a(2) = 9 enumerates the total number of down steps between the 2nd up step and the end of the path.
%H A334640 Alois P. Heinz, <a href="/A334640/b334640.txt">Table of n, a(n) for n = 0..1212</a>
%H A334640 A. Asinowski, B. Hackl, and S. Selkirk, <a href="https://arxiv.org/abs/2007.15562">Down step statistics in generalized Dyck paths</a>, arXiv:2007.15562 [math.CO], 2020.
%F A334640 a(0) = a(1) = 0 and a(n) = 2*Sum_{j=1..2} binomial(3*j+1,j) * binomial(3*(n-j),n-j) / ((3*j+1)*(n-j+1)) for n > 1.
%e A334640 For n = 2, there are the 2-Dyck paths UUDDDD, UDUDDD, UDDUDD. Between the 2nd up step and the end of the path there are a(2) = 4 + 3 + 2 = 9 down steps in total.
%p A334640 b:= proc(x, y, u, c) option remember; `if`(x=0, c,
%p A334640      `if`(y+2<x, b(x-1, y+2, min(u+1,3), c), 0)+
%p A334640      `if`(y>0, b(x-1, y-1, u, c+`if`(u=2, 1, 0)), 0))
%p A334640     end:
%p A334640 a:= n-> b(3*n, 0$3):
%p A334640 seq(a(n), n=0..24);  # _Alois P. Heinz_, May 09 2020
%p A334640 # second Maple program:
%p A334640 a:= proc(n) option remember; `if`(n<3, [0$2, 9][n+1],
%p A334640      (3*(n-1)*(3*n-8)*(3*n-7)*(13*n-20)*a(n-1))/
%p A334640      (2*(13*n-33)*(n-2)*(2*n-3)*n))
%p A334640     end:
%p A334640 seq(a(n), n=0..24);  # _Alois P. Heinz_, May 09 2020
%t A334640 a[0] = a[1] = 0; a[n_] := 2 * Sum[Binomial[3*j + 1, j] * Binomial[3*(n - j), n - j]/((3*j + 1)*(n - j + 1)), {j, 1, 2}]; Array[a, 25, 0] (* _Amiram Eldar_, May 09 2020 *)
%o A334640 (PARI) a(n) = if (n<=1, 0, 2*sum(j=1, 2, binomial(3*j+1,j) * binomial(3*(n-j),n-j)/((3*j+1)*(n-j+1)))); \\ _Michel Marcus_, May 09 2020
%Y A334640 Cf. A007226, A007228, A124724, A334641, A334642, A334682.
%K A334640 nonn,easy
%O A334640 0,3
%A A334640 _Benjamin Hackl_, May 07 2020