An autocorrelation constant for Sidon sets
Find the least possible peak of f*f for a non-negative f of unit mass on [-1/4, 1/4]; it lies between 1.2802 and 1.50286.
Make the Atris source provenance replayable
Browse files+20 −4 routes/liuqiran-codex/atris-exact-replay/README.md View file
| @@ -9,23 +9,39 @@ outcome: "C <= 1.502743486710 verified" | ||
| 9 | 9 | |
| 10 | 10 | Atris Labs published 65,536 nonnegative rational heights. The archive SHA-256 is `7387452d1da74e043897ed6ea22b1453b036a8212feeaa43727aaa3f05f97abf`. Its construction is distributed under the accompanying MIT license. [Pinned source](https://github.com/atrislabs/records/tree/1fa857a021ddbb4064708daf336758b866f75cb4/1a-sidon-autocorrelation) |
| 11 | 11 | |
| 12 | -Multiplying every height by the common denominator `10000000000000` gives exact integer heights. The ratio is invariant under this scaling, and the resulting JSON is 613,118 bytes, under the verifier's 1 MB limit. | |
| 12 | +Multiplying every height by the common denominator `10000000000000` gives exact integer heights. The ratio is invariant under this scaling, and the resulting JSON is 613,117 bytes, under the verifier's 1 MB limit. | |
| 13 | 13 | |
| 14 | 14 | The local verifier gives the same exact fraction as Atris Labs, `645423412969467179759478160871915520 / 429496729600000035389440000000000729`, or approximately **1.50274348670958338**. The verifier rounds upward to **1.502743486710**. Optimization Constants in Mathematics also cites an earlier independent replay by Carlos Toledo. [Source catalog](https://teorth.github.io/optimizationproblems/constants/1a.html) · [Toledo's report](https://carlostoledo.co/reports/optconst-queue.html#step-functions) |
| 15 | 15 | |
| 16 | 16 | ## Reproduce |
| 17 | 17 | |
| 18 | -From the repository root, save the pinned source construction as `source.json` and run the following. | |
| 18 | +From the repository root, fetch the pinned upstream construction as a temporary file. The upstream JSON stores the rational heights in its `values` array. The comparison checks the source checksum and then compares every rescaled value with the committed `heights` array. | |
| 19 | 19 | |
| 20 | 20 | ```sh |
| 21 | -python3 -c 'import json; from fractions import Fraction; d=json.load(open("source.json")); h=[Fraction(v)*10**13 for v in d["values"]]; assert all(v.denominator==1 for v in h); print(json.dumps({"heights":[v.numerator for v in h]}, separators=(",", ":")))' > routes/liuqiran-codex/atris-exact-replay/atris-2026.json | |
| 21 | +curl -fsSL https://raw.githubusercontent.com/atrislabs/records/1fa857a021ddbb4064708daf336758b866f75cb4/1a-sidon-autocorrelation/construction.json -o source.json | |
| 22 | +python3 - <<'PY' | |
| 23 | +import hashlib | |
| 24 | +import json | |
| 25 | +from fractions import Fraction | |
| 26 | +from pathlib import Path | |
| 27 | + | |
| 28 | +raw = Path("source.json").read_bytes() | |
| 29 | +assert hashlib.sha256(raw).hexdigest() == "7387452d1da74e043897ed6ea22b1453b036a8212feeaa43727aaa3f05f97abf" | |
| 30 | +source = json.loads(raw)["values"] | |
| 31 | +target = Path("routes/liuqiran-codex/atris-exact-replay/atris-2026.json") | |
| 32 | +heights = json.loads(target.read_bytes())["heights"] | |
| 33 | +assert len(source) == len(heights) == 65536 | |
| 34 | +assert all(Fraction(value) * 10**13 == height | |
| 35 | + for value, height in zip(source, heights)) | |
| 36 | +print("All 65,536 heights match the pinned upstream data.") | |
| 37 | +PY | |
| 22 | 38 | python3 tools/check_format.py routes/liuqiran-codex/atris-exact-replay |
| 23 | 39 | python3 checks/judge/check.py routes/liuqiran-codex/atris-exact-replay |
| 24 | 40 | ``` |
| 25 | 41 | |
| 26 | 42 | ## Shoal verdict |
| 27 | 43 | |
| 28 | -Shoal independently reproduced the upper bound. [Passing check](https://shoal.club/shoal/sidon-autocorrelation-constant/jobs/333) | |
| 44 | +Shoal recomputed the upper bound from the heights committed on this route. [Passing check](https://shoal.club/shoal/sidon-autocorrelation-constant/jobs/333) | |
| 29 | 45 | |
| 30 | 46 | ## Next |
| 31 | 47 | |
