login

Revision History for A372641

(Bold, blue-underlined text is an addition; faded, red-underlined text is a deletion.)

Showing entries 1-10 | older changes
Number of defective (binary) heaps on n elements from the set {0,1} where exactly n ancestor-successor pairs do not have the correct order.
(history; published version)
#14 by Alois P. Heinz at Thu May 09 15:55:53 EDT 2024
STATUS

proposed

approved

#13 by Jean-François Alcover at Thu May 09 13:19:53 EDT 2024
STATUS

editing

proposed

#12 by Jean-François Alcover at Thu May 09 13:19:47 EDT 2024
MATHEMATICA

b[n_, t_] := b[n, t] = If[n == 0, 1, Function[g, Function [f,

Expand[b[f, t]*b[n-1-f, t]*x^t + b[f, t+1]*b[n-1-f, t+1]]][

Min[g-1, n-g/2]]][2^(Length@IntegerDigits[n, 2]-1)]];

a[n_] := Coefficient[b[n, 0], x, n];

Table[a[n], {n, 0, 37}] (* Jean-François Alcover, May 09 2024, after Alois P. Heinz *)

STATUS

approved

editing

#11 by OEIS Server at Wed May 08 15:03:43 EDT 2024
LINKS

Alois P. Heinz, <a href="/A372641/b372641_1.txt">Table of n, a(n) for n = 0..2000</a>

#10 by Alois P. Heinz at Wed May 08 15:03:43 EDT 2024
STATUS

editing

approved

Discussion
Wed May 08
15:03
OEIS Server: Installed first b-file as b372641.txt.
#9 by Alois P. Heinz at Wed May 08 15:02:16 EDT 2024
LINKS

Alois P. Heinz, <a href="/A372641/b372641_1.txt">Table of n, a(n) for n = 0..2000</a>

#8 by Alois P. Heinz at Wed May 08 14:36:41 EDT 2024
MAPLE

b:= proc(n, t) option remember; `if`(n=0, 1, (g-> (f->

expand(b(f, t)*b(n-1-f, t)*x^t+b(f, t+1)*b(n-1-f, t+1)

))(min(g-1, n-g/2)))(2^ilog2(n)))

end:

a:= n-> coeff(b(n, 0), x, n):

seq(a(n), n=0..37);

#7 by Alois P. Heinz at Wed May 08 14:34:39 EDT 2024
LINKS

Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/Heap.html">Heap</a>

Wikipedia, <a href="https://en.wikipedia.org/wiki/Binary_heap">Binary heap</a>

#6 by Alois P. Heinz at Wed May 08 14:34:05 EDT 2024
EXAMPLE

(The examples use max-heaps.)

#5 by Alois P. Heinz at Wed May 08 14:33:33 EDT 2024
NAME

Number of defective (binary) heaps on n, elements from the set {0,1} where exactly n ancestor-successor pairs do not have the correct order.