login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A263173
Number of Dyck paths of semilength n having exactly two (possibly overlapping) DUDU's (with U=(1,1), D=(1,-1)).
2
1, 3, 15, 58, 231, 891, 3403, 12870, 48318, 180356, 670014, 2479302, 9143885, 33627777, 123366789, 451612846, 1650111453, 6019100025, 21922936343, 79740801036, 289690000380, 1051250045960, 3811012240380, 13802994382860, 49950211130905, 180617997397887
OFFSET
4,2
LINKS
EXAMPLE
a(4) = 1: UDUDUDUD.
a(5) = 3: UDUDUDUUDD, UUDDUDUDUD, UUDUDUDUDD.
a(6) = 15: UDUDUDUUDDUD, UDUDUDUUDUDD, UDUDUDUUUDDD, UDUDUUDDUDUD, UDUDUUDUDUDD, UDUUDDUDUDUD, UDUUDUDUDUDD, UUDDUDUDUUDD, UUDUDDUDUDUD, UUDUDUDDUDUD, UUDUDUDUDDUD, UUDUDUDUUDDD, UUUDDDUDUDUD, UUUDDUDUDUDD, UUUDUDUDUDDD.
MAPLE
a:= proc(n) option remember; `if`(n<5, `if`(n=4, 1, 0),
((2*n-7)*a(n-1) +(5*n-15)*a(n-2) +(2*n-5)*a(n-3)
-(n-2)*a(n-4))/(n-4))
end:
seq(a(n), n=4..30);
CROSSREFS
Column k=2 of A102405.
Sequence in context: A121695 A343994 A017949 * A049178 A049150 A309564
KEYWORD
nonn
AUTHOR
Alois P. Heinz, Oct 11 2015
STATUS
approved