What does Merkle Trees for Manuscript Evidence conclude, in numbers, about “Closing the Loop: Writing the Hash Tree of Manuscripts and Programs into Receipts, the Small Tool and a Pre-Registered Test”?
Answer: Chapter 8 gives the procedure for writing the hash tree of each volume's manuscript and programs into its receipt, the Manuscript Merkle Prover and a pre-registered test plan: the revision-width test needs 116 events, and 31 or more wide revisions refute the empirical thesis. Marked boxes separate published evidence, runnable Python calculations (20 programs), classical sources and the author's hypotheses.
Scope of the numbers: Its manuscripts, timestamps, salts and parameters are illustrative, and all calculations are generated by its programs. Chapter 1 makes single-byte edits to a nine-file illustrative manuscript and guesses the edited file from the overall hash, with a hit rate of 0.1133, no better than the 0.1111 of blind guessing.
Data table
The numbers below are printed verbatim by the chapter's Python program and can be reproduced by running it. standard-library Python onlyprinted values that match the answer: 116, 20, 31
| audit of 100 receipts: draws needed to catch > | 1 mismatch |
| mismatched P > | 0.95 P >= 0.99 |
| 1 | 95 99 |
| 2 | 78 90 |
| 5 | 45 59 |
| 10 | 25 36 |
| 20 | 13 19 |
| edit-footprint test: n | 116 events, reject H0 if >= 31 are wide |
| size under p | 0.20: 0.0487 |
| power under p | 0.30: 0.8073 |
| wide = more than 0.1670 of the volume's files changed |
Show the full program
# Chapter 8. p82: sample sizes for the pre-registered checks.
# (1) Audit: a century has 100 volume receipts. If t of them no longer
# match their files, how many receipts s must an auditor re-hash,
# drawn at random without replacement, to catch at least one with
# probability >= 0.99 (or 0.95)? Exact hypergeometric.
# (2) Edit footprint: p32 found the tree loses to a flat list once more
# than about 0.167 of the leaves change. The book predicts that at
# most 0.20 of real revision events are that wide. One-sided exact
# binomial test of H0: p = 0.20 against p = 0.30, alpha 0.05, power
# 0.80: smallest number of events n and the rejection count c.
import math
VOL = 100
def catch(t, s):
return 1.0 - math.comb(VOL - t, s) / math.comb(VOL, s)
def upper_tail(n, c, p):
terms = [math.comb(n, j) * p ** j * (1 - p) ** (n - j)
for j in range(c, n + 1)]
return math.fsum(terms)
print("audit of %d receipts: draws needed to catch >= 1 mismatch" % VOL)
print("%10s %10s %10s" % ("mismatched", "P >= 0.95", "P >= 0.99"))
for t in (1, 2, 5, 10, 20):
need = []
for target in (0.95, 0.99):
s = 1
while catch(t, s) < target:
s += 1
need.append(s)
print("%10d %10d %10d" % (t, need[0], need[1]))
p0, p1, alpha, power = 0.20, 0.30, 0.05, 0.80
n = 10
while True:
c = 0
while upper_tail(n, c, p0) > alpha:
c += 1
if upper_tail(n, c, p1) >= power:
break
n += 1
print("edit-footprint test: n = %d events, reject H0 if >= %d are wide"
% (n, c))
print(" size under p = 0.20: %.4f" % upper_tail(n, c, p0))
print(" power under p = 0.30: %.4f" % upper_tail(n, c, p1))
print(" wide = more than %.4f of the volume's files changed" % 0.1670)Single source and citation
Fan, Y. (2026). Merkle Hash Trees and Trusted Timestamps: Tamper-Evidence for Monograph Versions and Minimal Proofs of Priority (Version 1.0.0), Chapter 8: Closing the Loop: Writing the Hash Tree of Manuscripts and Programs into Receipts, the Small Tool and a Pre-Registered Test. 5D Library. DOI pending
DOI pending · monograph page goes live after publication · 5DL-B-295 · v1.0.0 · CC-BY-NC-ND-4.0
BibTeX
@book{fan2026295,
author = {Fan, Yafu},
title = {Merkle Hash Trees and Trusted Timestamps: Tamper-Evidence for Monograph Versions and Minimal Proofs of Priority},
year = {2026},
publisher = {5D Library},
edition = {1.0.0},
note = {DOI pending}
}Other chapter answers in this book
- Chapter 1 · The Blind Spot of One Fingerprint: an Overall Hash Only Says Whether Something Changed
- Chapter 2 · The Merkle Tree: Construction, Domain Separation and Inclusion Proofs of Logarithmic Length
- Chapter 3 · The Least Number of Hashes to Locate a Difference: the Information Bound, Tree Descent and the Break-Even Point
- Chapter 4 · Hash Chains and Linked Timestamps: from the Linking Scheme of Haber and Stornetta to Anchoring Intervals
- Chapter 5 · The Birthday Bound: Collision Probability, Truncated Fingerprints and the Claimant as Adversary
- Chapter 6 · A Minimal Bundle of Evidence for Priority: Append-Only Consistency, a Two-Level Design and Salted Leaves
- Chapter 7 · Classical Sources East and West: Matched Fish Tallies and Hooke's Anagram