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.

A212397 Denominator of the average number of move operations required by an insertion sort of n (distinct) elements.

This page as a plain text file.
%I A212397 #21 May 29 2018 09:25:03
%S A212397 1,1,2,6,6,30,5,35,140,1260,1260,13860,13860,180180,180180,180180,
%T A212397 360360,6126120,2042040,38798760,7759752,2586584,2586584,59491432,
%U A212397 178474296,4461857400,4461857400,40156716600,40156716600,1164544781400,1164544781400
%N A212397 Denominator of the average number of move operations required by an insertion sort of n (distinct) elements.
%C A212397 The average number of move operations is 1/n! times the number of move operations required to sort all permutations of [n] (A212395), assuming that each permutation is equiprobable.
%H A212397 Alois P. Heinz, <a href="/A212397/b212397.txt">Table of n, a(n) for n = 0..1000</a>
%H A212397 Wikipedia, <a href="https://en.wikipedia.org/wiki/Insertion_sort">Insertion sort</a>
%H A212397 <a href="/index/So#sorting">Index entries for sequences related to sorting</a>
%F A212397 a(n) = denominator of A212395(n)/A000142(n).
%p A212397 b:= proc(n) option remember;
%p A212397       `if`(n=0, 0, b(n-1)*n + (n-1)! * (n-1)*(n+4)/2)
%p A212397     end:
%p A212397 a:= n-> denom(b(n)/n!):
%p A212397 seq(a(n), n=0..30);
%t A212397 a[n_] := Denominator[n (n + 7)/4 - 2 HarmonicNumber[n]];
%t A212397 Table[a[n], {n, 0, 30}] (* _Jean-François Alcover_, May 29 2018, from 2nd formula in A212396 *)
%Y A212397 Numerators are in A212396.
%Y A212397 Cf. A000142, A212395.
%K A212397 nonn,frac
%O A212397 0,3
%A A212397 _Alois P. Heinz_, May 14 2012