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.

A239775 Number of pairs of functions f, g from a size n set into itself satisfying f(f(g(x))) = f(f(x)).

This page as a plain text file.
%I A239775 #13 Dec 19 2024 13:55:03
%S A239775 1,1,10,297,13264,851325,74078496,8325102331,1169885964640,
%T A239775 200545429514697,41101718746949920
%N A239775 Number of pairs of functions f, g from a size n set into itself satisfying f(f(g(x))) = f(f(x)).
%p A239775 s:= proc(n, i) option remember; `if`(i=0, [[]],
%p A239775        map(x-> seq([j, x[]], j=1..n), s(n, i-1)))
%p A239775     end:
%p A239775 a:= proc(n) (l-> add(add(`if`([true$n]=[seq(evalb(
%p A239775        f[f[g[i]]]=f[f[i]]), i=1..n)], 1, 0), g=l), f=l))(s(n$2))
%p A239775     end:
%p A239775 seq(a(n), n=0..5);  # _Alois P. Heinz_, Jul 16 2014
%o A239775 (Sage) # from _Max Alekseyev_, Dec 19 2024
%o A239775 from collections import Counter
%o A239775 def a239775(n): return sum( prod(k^k for k in Counter(f[t] for t in f).values()) for f in Tuples(range(n),n) )
%Y A239775 Cf. A181162, A239769, A239773.
%K A239775 nonn,more
%O A239775 0,3
%A A239775 _Chad Brewbaker_, Mar 26 2014
%E A239775 a(6)-a(7) from _Giovanni Resta_, Mar 28 2014
%E A239775 a(8)-a(10) from _Max Alekseyev_, Dec 19 2024