cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A354962 Number of acyclic n-multidigraphs on n labeled vertices.

Original entry on oeis.org

1, 1, 5, 289, 267249, 5004309601, 2306766500044453, 30888553723078503825409, 13859983478324955468951984020417, 236220504431931018509832208799998200000001, 170953602414073201827802109472335543681457702850676901
Offset: 0

Views

Author

Seiichi Manyama, Jun 13 2022

Keywords

Crossrefs

Main diagonal of A339768.

Programs

  • 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)