FAILURE MAP
← Case archive

FA-40640 / Heap invariants / Member archive

Heap hole preserves the displaced original key for the later upward phase · case 05

The bounded hole descent certificate reports an incorrect displaced.

Member previewVariant 5 · 3 implementations · 7 checks per implementation

Case contract

A binary heap hole descent receives array keys and starting internal or leaf index. Repeatedly choose smaller existing child (left on ties), move that child into the hole, and stop at a leaf; the displaced root value is returned separately for later upward placement. Return path, moved keys, leaf slot, displaced value, remaining untouched slots, and comparison count between sibling pairs.

Why this case matters

This isolates an internal heap representation or priority-structure invariant using deterministic finite records.

One recorded failure

Sample boundary fixture

This sample comes from the broken implementation of a controlled reproducer.

Boundary fixtureActualExpectedOutcome
regression certificate 2{"comparisons": 0, "displaced": 2, "leaf_slot": 1, "moved_keys": [2], "path": [0, 1], "untouched": []}{"comparisons": 0, "displaced": 9, "leaf_slot": 1, "moved_keys": [2], "path": [0, 1], "untouched": []}Failed

MEMBER ARCHIVE

The complete case is available to members.

This record includes three runnable implementations, regression fixtures, execution results, and source hashes.

Member access is invitation-based. Sign in with your invited account to inspect the sources.

Sign in to the archive ↗