ProtocolPhase
Phase 5b API: the phase-keyed family with its QBER simulated, not pinned
8/8 passed in 557ms
| Test | What it does | Result |
|---|---|---|
test_alice_plane | The rate is built on Alice's mu, not mu_bob = T*mu, and sits below the Bob-plane rate. | ✅ pass |
test_click_provenance | Before a run every simulated quantity is labelled still to compute, after one it is derived. | ✅ pass |
test_dead_time_reaches | A microsecond of dead time at a 1 GHz clock costs clicks and key, while afterpulsing adds counts and raises the QBER until no key is left. | ✅ pass |
test_doubles_squashed | Double clicks are kept with a random bit (squashing model): clicks = sifted + doubles, and p_click equals the sift rate. | ✅ pass |
test_engine_agreement | Every reported number is bit for bit what _core.run_clicks and _core.dps_rate return for the same hardware. | ✅ pass |
test_linewidth_costs | The QBER rises monotonically with laser linewidth and the key falls, reaching zero at 10 MHz. | ✅ pass |
test_one_definition | The simulated p_click matches p_ideal = 1 - (1 - dark)^2exp(-muT*eta) to 5 sigma, and dead time only lowers it. | ✅ pass |
test_pinned_closed_form | Pinning the error rate gives the Waks-Takesue-Yamamoto closed form (PRA 73, 012344): at e = 0 the rate is p_click*(1 - 2mu) with p_click = 1 - (1 - dark)^2exp(-muTeta), and no clicks counted. | ✅ pass |