%I #6 Nov 14 2015 08:12:19
%S 1,12,103,811,6273,48806,386041,3122069,25900188,220791812,1935811756,
%T 17461471292,162038542377,1546528485770,15174625184321,
%U 152994813139537,1584120732683571,16834244135840106,183496533502593453,2050337555698723711,23470542944212951050
%N Number of permutations of [n] with exactly three (possibly overlapping) occurrences of the generalized pattern 12-3.
%H Alois P. Heinz, <a href="/A264452/b264452.txt">Table of n, a(n) for n = 4..500</a>
%e a(4) = 1: 1234.
%e a(5) = 12: 12534, 12543, 13245, 13425, 13452, 21345, 23145, 23415, 23451, 31245, 41235, 51234.
%p b:= proc(u, o) option remember; `if`(u+o=0, 1, add(
%p b(u-j, o+j-1), j=1..u)+add(convert(series(
%p b(u+j-1, o-j)*x^(o-j), x, 4), polynom), j=1..o))
%p end:
%p a:= n-> coeff(b(n, 0), x, 3):
%p seq(a(n), n=4..25);
%Y Column k=3 of A260665.
%K nonn
%O 4,2
%A _Alois P. Heinz_, Nov 14 2015