OFFSET
0,1
LINKS
Alois P. Heinz, Table of n, a(n) for n = 0..1000
FORMULA
a(0) = 2, a(n) = 3+n+n^2/2+n^3+n^4/2 for n>0.
G.f.: (x^5-3*x^4+3*x^3+13*x^2-4*x+2)/(1-x)^5.
EXAMPLE
a(2) = 23: only one of 4! = 24 permutations of {1,2,3,4} has no increasing subsequence of length 2: 4321.
MAPLE
a:= n-> 3+(2+(1+(n+2)*n)*n)*n/2-`if`(n=0, 1, 0):
seq(a(n), n=0..60);
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Alois P. Heinz, Sep 27 2012
STATUS
approved