login
A354962
Number of acyclic n-multidigraphs on n labeled vertices.
2
1, 1, 5, 289, 267249, 5004309601, 2306766500044453, 30888553723078503825409, 13859983478324955468951984020417, 236220504431931018509832208799998200000001, 170953602414073201827802109472335543681457702850676901
OFFSET
0,3
LINKS
PROG
(Ruby)
def ncr(n, r)
return 1 if r == 0
(n - r + 1..n).inject(:*) / (1..r).inject(:*)
end
def A(k, n)
ary = [1]
(1..n).each{|i| ary << (1..i).inject(0){|s, j| s + (-1) ** (j + 1) * (k + 1) ** (j * (i - j)) * ncr(i, j) * ary[-j]}}
ary[-1]
end
def A354962(n)
(0..n).map{|i| A(i, i)}
end
p A354962(10)
CROSSREFS
Main diagonal of A339768.
Sequence in context: A265966 A376465 A337540 * A227579 A257045 A256422
KEYWORD
nonn
AUTHOR
Seiichi Manyama, Jun 13 2022
STATUS
approved