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.

A305824 Number of endofunctions on [n] whose cycle lengths are triangular numbers.

This page as a plain text file.
%I A305824 #12 Jun 15 2018 09:28:24
%S A305824 1,1,3,18,157,1776,24807,413344,8004537,176630400,4374300331,
%T A305824 120136735104,3623854678677,119102912981248,4236492477409935,
%U A305824 162152320065532416,6645233337842716273,290321208589666369536,13469914225467040015827,661442143465113960448000
%N A305824 Number of endofunctions on [n] whose cycle lengths are triangular numbers.
%H A305824 Alois P. Heinz, <a href="/A305824/b305824.txt">Table of n, a(n) for n = 0..386</a>
%p A305824 b:= proc(n) option remember; local r, f, g;
%p A305824       if n=0 then 1 else r, f, g:=$0..2;
%p A305824       while f<=n do r, f, g:= r+(f-1)!*
%p A305824          b(n-f)*binomial(n-1, f-1), f+g, g+1
%p A305824       od; r fi
%p A305824     end:
%p A305824 a:= n-> add(b(j)*n^(n-j)*binomial(n-1, j-1), j=0..n):
%p A305824 seq(a(n), n=0..20);
%t A305824 b[n_] := b[n] = Module[{r, f, g}, If[n == 0, 1, {r, f, g} = {0, 1, 2}; While[f <= n, {r, f, g} = {r + (f - 1)!*b[n - f]*Binomial[n - 1, f - 1], f + g, g + 1}]; r]];
%t A305824 a[0] = 1; a[n_] := Sum[b[j]*n^(n - j)*Binomial[n - 1, j - 1], {j, 0, n}];
%t A305824 Table[a[n], {n, 0, 20}] (* _Jean-François Alcover_, Jun 15 2018, after _Alois P. Heinz_ *)
%Y A305824 Cf. A000217, A060435, A116956, A193374, A205799, A273994, A273996, A273998.
%K A305824 nonn
%O A305824 0,3
%A A305824 _Alois P. Heinz_, Jun 10 2018