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.

A372033 The total number of levels visited by all Motzkin paths of length n.

This page as a plain text file.
%I A372033 #13 Apr 16 2024 19:05:17
%S A372033 1,1,3,7,18,46,121,323,875,2395,6611,18371,51337,144145,406420,
%T A372033 1150126,3265412,9298372,26547710,75978322,217921336,626287520,
%U A372033 1803176384,5200298000,15020569818,43447201226,125837214564,364911724264,1059404265599,3078918594707
%N A372033 The total number of levels visited by all Motzkin paths of length n.
%H A372033 Alois P. Heinz, <a href="/A372033/b372033.txt">Table of n, a(n) for n = 0..1000</a>
%H A372033 Wikipedia, <a href="https://en.wikipedia.org/wiki/Motzkin_number">Motzkin number</a>
%F A372033 a(n) = A001006(n) + A333498(n).
%p A372033 b:= proc(x, y, h) option remember; `if`(x=0, h+1, add(
%p A372033       b(x-1, y+j, max(h, y)), j=-min(1, y)..min(1, x-y-1)))
%p A372033     end:
%p A372033 a:= n-> b(n, 0$2):
%p A372033 seq(a(n), n=0..35);
%Y A372033 Row sums of A372014.
%Y A372033 Cf. A001006, A261003, A333498.
%K A372033 nonn
%O A372033 0,3
%A A372033 _Alois P. Heinz_, Apr 16 2024