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.

A227883 Number of permutations of [n] with exactly one occurrence of the consecutive step pattern up, down, up.

This page as a plain text file.
%I A227883 #19 Dec 20 2020 07:32:00
%S A227883 0,0,0,0,5,50,328,2154,16751,144840,1314149,12735722,134159743,
%T A227883 1519210786,18272249418,233231701166,3159471128588,45243728569842,
%U A227883 682183513506619,10807962134238068,179606706777512992,3123700853586733882,56737351453843424893
%N A227883 Number of permutations of [n] with exactly one occurrence of the consecutive step pattern up, down, up.
%H A227883 Alois P. Heinz and Vaclav Kotesovec, <a href="/A227883/b227883.txt">Table of n, a(n) for n = 0..460</a> (first 195 terms from Alois P. Heinz)
%F A227883 a(n) ~ c * d^n * n! * n, where d = A245758 = 0.782704180171521701844707..., c = 0.575076701401064911213333442496869737011... . - _Vaclav Kotesovec_, Aug 22 2014
%e A227883 a(4) = 5: 1324, 1423, 2314, 2413, 3412.
%e A227883 a(5) = 50: 12435, 12534, 13245, ..., 52314, 52413, 53412.
%p A227883 b:= proc(u, o, t) option remember;
%p A227883       `if`(t=7, 0, `if`(u+o=0, `if`(t in [4, 5, 6], 1, 0),
%p A227883       add(b(u-j, o+j-1, [1, 3, 1, 5, 6, 6][t]), j=1..u)+
%p A227883       add(b(u+j-1, o-j, [2, 2, 4, 4, 7, 4][t]), j=1..o)))
%p A227883     end:
%p A227883 a:= n-> b(n, 0, 1):
%p A227883 seq(a(n), n=0..25);
%t A227883 b[u_, o_, t_] := b[u, o, t] =
%t A227883     If[t == 7, 0, If[u + o == 0, If[4 <= t <= 6, 1, 0],
%t A227883     Sum[b[u - j, o + j - 1, {1, 3, 1, 5, 6, 6}[[t]]], {j, 1, u}] +
%t A227883     Sum[b[u + j - 1, o - j, {2, 2, 4, 4, 7, 4}[[t]]], {j, 1, o}]]];
%t A227883 a[n_] := b[n, 0, 1];
%t A227883 a /@ Range[0, 25] (* _Jean-François Alcover_, Dec 20 2020, after _Alois P. Heinz_ *)
%Y A227883 Column k=1 of A227884.
%Y A227883 Cf. A177477, A245758.
%K A227883 nonn
%O A227883 0,5
%A A227883 _Alois P. Heinz_, Oct 25 2013