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.

A324804 a(n) is the number of endofunctions on a set of size n with preimage constraint {0, 1, 2, 3, 4}.

This page as a plain text file.
%I A324804 #25 May 31 2019 04:50:57
%S A324804 1,1,4,27,256,3120,46470,817950,16612120,382367160,9836517600,
%T A324804 279684716850,8709747354000,294818964039600,10777792243818600,
%U A324804 423193629950091000,17762853608696196000,793668469023770340000,37611450798744238416000,1884235285123539720372000
%N A324804 a(n) is the number of endofunctions on a set of size n with preimage constraint {0, 1, 2, 3, 4}.
%C A324804 A preimage constraint is a set of nonnegative integers such that the size of the inverse image of any element is one of the values in that set. Thus, the n-th term of the sequence is the number of endofunctions on a set of size n such that each preimage has at most 4 elements. Equivalently, it is the number of n-letter words from an n-letter alphabet such that no letter appears more than 4 times.
%H A324804 Alois P. Heinz, <a href="/A324804/b324804.txt">Table of n, a(n) for n = 0..386</a> (first 64 terms from Benjamin Otto)
%H A324804 B. Otto, <a href="https://arxiv.org/abs/1903.00542">Coalescence under Preimage Constraints</a>, arXiv:1903.00542 [math.CO], 2019, Corollaries 5.6 and 7.8.
%F A324804 a(n) = n! * [x^n] e_4(x)^n, where e_k(x) is the truncated exponential 1 + x + x^2/2! + ... + x^k/k!.
%F A324804 The link above yields explicit constants c_k, r_k so that the columns are asymptotically c_4 * n^(-1/2) * r_4^-n.
%p A324804 b:= proc(n, i) option remember; `if`(n=0 and i=0, 1, `if`(i<1, 0,
%p A324804       add(b(n-j, i-1)*binomial(n, j), j=0..min(4, n))))
%p A324804     end:
%p A324804 a:= n-> b(n$2):
%p A324804 seq(a(n), n=0..21);  # _Alois P. Heinz_, Apr 01 2019
%t A324804 b[n_, i_] := b[n, i] = If[n == 0 && i == 0, 1, If[i<1, 0, Sum[b[n-j, i-1]* Binomial[n, j], {j, 0, Min[4, n]}]]];
%t A324804 a[n_] := b[n, n];
%t A324804 Table[a[n], {n, 0, 21}] (* _Jean-François Alcover_, May 31 2019, after _Alois P. Heinz_ *)
%o A324804 (Python) # print first num_entries entries in the sequence import math, sympy; x=sympy.symbols('x') k=4; num_entries = 64 P=range(k+1); eP=sum([x**d/math.factorial(d) for d in P]); r = [1]; curr_pow = 1 for term in range(1,num_entries): ...curr_pow=(curr_pow*eP).expand() ...r.append(curr_pow.coeff(x**term)*math.factorial(term)) print(r)
%Y A324804 Column k=4 of A306800; see that entry for sequences related to other preimage constraints constructions.
%K A324804 easy,nonn
%O A324804 0,3
%A A324804 _Benjamin Otto_, Mar 15 2019