login
A111903
The work performed by a partial function f:{1,...,n}->{1,...,n} is defined to be work(f)=sum(|i-f(i)|,i in dom(f)); a(n) is equal to sum(work(f)) where the sum is over all order-preserving partial functions f:{1,...,n}->{1,...,n}.
3
0, 4, 48, 424, 3312, 24204, 169632, 1155152, 7702944, 50550932, 327591504, 2101442808, 13367744784, 84438657820, 530179314240, 3311794268320, 20594613427776, 127564892050212, 787394746252656
OFFSET
1,2
FORMULA
Sum(i, j=1...n;k, l=0...n, |i-j|*(i-1 choose k)*(j+k-1 choose k)*(n-i choose l)*(n-j+l choose l))
EXAMPLE
When n=2 there are 8 order-preserving partial maps {1,2}->{1,2}. these are (1 2), (1 1), (2 2), (1 -), (2 -), (- 1), (- 2) (- -). Adding up the work performed by these maps (from left to right as arranged above) gives a(2)=0+1+1+0+1+1+0+0=4.
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
James East, Nov 23 2005
STATUS
approved