%I #35 Aug 12 2021 05:40:44
%S 1,0,1,2,3,44,55,1434,3913,39752,392481,5109290,34683451,914698212,
%T 5777487703,91494090674,1504751645265,31764834185744,379862450767873,
%U 12634073744624082,132945783064464691,2753044719709341980,64135578414076991031,1822831113987975441482
%N E.g.f.: exp( Sum_{n>=1} x^prime(n) / prime(n) ).
%C Conjecture: a(n) = number of degree-n permutations of prime order.
%C The conjecture is false. Cf. A214003. This sequence gives the number of n-permutations whose cycle lengths are restricted to the prime numbers. - _Geoffrey Critzer_, Nov 08 2015
%H Alois P. Heinz, <a href="/A218002/b218002.txt">Table of n, a(n) for n = 0..450</a>
%H Ljuben Mutafchiev, <a href="https://arxiv.org/abs/2108.05291">A Note on the Number of Permutations whose Cycle Lengths Are Prime Numbers</a>, arXiv:2108.05291 [math.CO], 2021.
%e E.g.f.: A(x) = 1 + x^2/2! + 2*x^3/3! + 3*x^4/4! + 44*x^5/5! + 55*x^6/6! + 1434*x^7/7! + ...
%e where
%e log(A(x)) = x^2/2 + x^3/3 + x^5/5 + x^7/7 + x^11/11 + x^13/13 + x^17/17 + x^19/19 + x^23/23 + x^29/29 + ... + x^prime(n)/prime(n) + ...
%e a(5) = 44 because there are 5!/5 = 24 permutations that are 5-cycles and there are 5!/(2*3) = 20 permutations that are the disjoint product of a 2-cycle and a 3-cycle. - _Geoffrey Critzer_, Nov 08 2015
%p a:= proc(n) option remember; `if`(n=0, 1, add(`if`(isprime(j),
%p a(n-j)*(j-1)!*binomial(n-1, j-1), 0), j=1..n))
%p end:
%p seq(a(n), n=0..25); # _Alois P. Heinz_, May 12 2016
%t f[list_] :=Total[list]!/Apply[Times, list]/Apply[Times, Map[Length, Split[list]]!]; Table[Total[Map[f, Select[Partitions[n], Apply[And, PrimeQ[#]] &]]], {n, 0,23}] (* _Geoffrey Critzer_, Nov 08 2015 *)
%o (PARI) {a(n)=n!*polcoeff(exp(sum(k=1,n,x^prime(k)/prime(k))+x*O(x^n)),n)}
%o for(n=0,31,print1(a(n),", "))
%Y Cf. A000040, A214003, A273001, A273998, A317131, A329944.
%K nonn
%O 0,4
%A _Paul D. Hanna_, Oct 17 2012
|