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.

A240797 Total number of occurrences of the pattern 1=2 in all preferential arrangements (or ordered partitions) of n elements.

This page as a plain text file.
%I A240797 #20 Feb 07 2017 08:27:55
%S A240797 0,1,9,78,750,8115,98343,1324204,19650060,318926745,5623615965,
%T A240797 107093749818,2191142272410,47944109702671,1117341011896515,
%U A240797 27633982917342360,722929036749464280,19946727355457792853,578926427416920550233,17632301590672398115270
%N A240797 Total number of occurrences of the pattern 1=2 in all preferential arrangements (or ordered partitions) of n elements.
%C A240797 There are A000670(n) preferential arrangements of n elements - see A000670, A240763.
%C A240797 The number that avoid the pattern 1=2 is n! (these are the permutations on n elements).
%H A240797 Alois P. Heinz, <a href="/A240797/b240797.txt">Table of n, a(n) for n = 1..420</a>
%F A240797 a(n) ~ n! * n / (4 * (log(2))^n). - _Vaclav Kotesovec_, May 03 2015
%e A240797 The 13 preferential arrangements on 3 points and the number of times the pattern 1=2 occurs are:
%e A240797 1<2<3, 0
%e A240797 1<3<2, 0
%e A240797 2<1<3, 0
%e A240797 2<3<1, 0
%e A240797 3<1<2, 0
%e A240797 3<2<1, 0
%e A240797 1=2<3, 1
%e A240797 1=3<2, 1
%e A240797 2=3<1, 1
%e A240797 1<2=3, 1
%e A240797 2<1=3, 1
%e A240797 3<1=2, 1
%e A240797 1=2=3, 3,
%e A240797 for a total of a(3) = 9.
%p A240797 b:= proc(n) option remember; `if`(n=0, [1, 0], add((p-> p+
%p A240797       [0, p[1]*j*(j-1)/2])(b(n-j))*binomial(n, j), j=1..n))
%p A240797     end:
%p A240797 a:= n-> b(n)[2]:
%p A240797 seq(a(n), n=1..25);  # _Alois P. Heinz_, Dec 08 2014
%t A240797 b[n_] := b[n] = If[n == 0, {1, 0}, Sum[Function[p, p + {0, p[[1]]*j*(j - 1)/2}][b[n - j]]*Binomial[n, j], {j, 1, n}]]; a[n_] := b[n][[2]]; Table[a[n], {n, 1, 25}] (* _Jean-François Alcover_, Feb 07 2017, after _Alois P. Heinz_ *)
%Y A240797 Cf. A000670, A240763, A240796-A240800.
%K A240797 nonn
%O A240797 1,3
%A A240797 _N. J. A. Sloane_, Apr 13 2014
%E A240797 a(8)-a(20) from _Alois P. Heinz_, Dec 08 2014