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.

A026521 a(n) = T(n, n-1), T given by A026519. Also a(n) = number of integer strings s(0), ..., s(n), counted by T, such that s(n) = 1.

This page as a plain text file.
%I A026521 #18 Dec 20 2021 09:43:23
%S A026521 1,1,4,6,19,33,98,180,526,990,2887,5502,16073,30863,90386,174456,
%T A026521 512128,992304,2918954,5673140,16716998,32571858,96119927,187675644,
%U A026521 554524660,1084649644,3208254571,6284986554,18607536319,36501029265
%N A026521 a(n) = T(n, n-1), T given by A026519. Also a(n) = number of integer strings s(0), ..., s(n), counted by T, such that s(n) = 1.
%H A026521 G. C. Greubel, <a href="/A026521/b026521.txt">Table of n, a(n) for n = 1..1000</a>
%H A026521 Veronika Irvine, Stephen Melczer, and Frank Ruskey, <a href="https://arxiv.org/abs/1804.08725">Vertically constrained Motzkin-like paths inspired by bobbin lace</a>, arXiv:1804.08725 [math.CO], 2018.
%F A026521 a(n) = A026519(n, n-1).
%F A026521 a(n) = A026537(n+1)/2.
%t A026521 T[n_, k_]:= T[n, k]= If[k==0 || k==2*n, 1, If[k==1 || k==2*n-1, Floor[(n+1)/2], If[EvenQ[n], T[n-1, k-2] + T[n-1, k], T[n-1, k-1] + T[n-1, k-2] + T[n-1, k]]]]; (* T = A026519 *)
%t A026521 Table[T[n, n-1], {n,40}] (* _G. C. Greubel_, Dec 19 2021 *)
%o A026521 (Sage)
%o A026521 @CachedFunction
%o A026521 def T(n,k): # T = A026552
%o A026521     if (k==0 or k==2*n): return 1
%o A026521     elif (k==1 or k==2*n-1): return (n+1)//2
%o A026521     elif (n%2==0): return T(n-1, k) + T(n-1, k-2)
%o A026521     else: return T(n-1, k) + T(n-1, k-1) + T(n-1, k-2)
%o A026521 [T(n,n-1) for n in (1..40)] # _G. C. Greubel_, Dec 19 2021
%Y A026521 Cf. A026519, A026520, A026522, A026523, A026524, A026525, A026526, A026527, A026528, A026529, A026530, A026531, A026533, A026534, A027262, A027263, A027264, A027265, A027266.
%Y A026521 Cf. A026537.
%K A026521 nonn
%O A026521 1,3
%A A026521 _Clark Kimberling_