FA-41283 / Heap invariants / Member archive
Rank-loss recomputation distinguishes equal from unequal child ranks · case 03
The bounded rank loss propagation certificate reports an incorrect computed.
Case contract
A stipulated rank-balanced heap repair trace supplies bottom-up nodes [id,stored_rank,left_rank,right_rank], with null child rank -1. Recomputed rank is max child rank if child ranks differ, otherwise child rank+1. A decrease propagates while computed rank is smaller, stopping at first unchanged node. Report local recomputed ranks, decreased ids, stopping id, new prefix ranks, rank drops, and visited count. This models the stated rule only, not every rank-pairing heap variant.
Why this case matters
This isolates an internal heap representation or priority-structure invariant using deterministic finite records.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| regression certificate 3 | {"computed": [1, 3, 3], "decreased": ["a", "b"], "drops": [2, 2], "prefix_ranks": [1, 2, 3], "stop": "c", "visited": 3} | {"computed": [1, 2, 3], "decreased": ["a", "b"], "drops": [2, 2], "prefix_ranks": [1, 2, 3], "stop": "c", "visited": 3} | 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 ↗