Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
139 changes: 139 additions & 0 deletions research/pr4100-row-field-movement/PROOF.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,139 @@
# Boundary-arithmetic row-field movement

Scoped lemma for one layout step of the #4100 Gaussian caller. No new κ.
The selected conditional result stays `0.001672660197076918`.

## Caller

The sentence under audit is the boundary-arithmetic movement, not the union
schedule's head travel.

- `research/capped-phase-fusion/PHASE-LAYOUT-AUDIT.md`, "Batched right-hand
sides do not add a large transpose", and the earlier exposure step: pad only
the exposed field to its next power of two, at a factor below two, and remove
that padding before the next axis. Move only that polynomial-width row field,
at `O(log p)` times the boundary volume, not a transpose of the long spectator
field. Scan each factor page once per right-hand-side batch.
- `research/unconditional-batched-crt/GAUSSIAN.md` repeats the removal claim:
temporary padding of the one exposed polynomial row field is removed before
the next axis and never accumulates as `2^g`.
- `research/unconditional-batched-crt/vendor/UNION-SCHEDULE.md` step 5 charges
the same movement to the boundary-algebra row and says it is not part of the
union movement.

PR #4327 audits the union schedule's tape-head bound and leaves
boundary-arithmetic batching uncovered. PR #1731's rectangular review says
partial-batch padding is negligible. It does not prove the factor, the level
count, or the removal alternative. This note proves those three layout claims.
It does not prove the Strassen or rectangular exponent, the carving identity
that turns the movement into `O(V d W^{τ-1}/B)`, conditioning, or any ledger
row of #4100.

## Lemma 1 — the row-field pad factor is below two

For an integer `a ≥ 1`, let `M(a) = 2^{ceil(log2 a)}`. Then `a ≤ M(a) < 2a`,
and `M(a)` is a power of two.

If `a` is a power of two, `M(a) = a < 2a`. Otherwise `2^{k-1} < a < 2^k` for
`k = ceil(log2 a)`, so `M(a) = 2^k = 2 · 2^{k-1} < 2a`.

Thus padding the exposed field from `a` real positions to `M(a)` multiplies
that field by a factor strictly less than two. The factor `2` is not attained
for any finite `a`.

## Lemma 2 — batches in `[W, 2W]` add no cells when `R ≥ W`

Let `W ≥ 1` and `R ≥ 0` be integers.

- If `R = 0`, there are no batches and no added cells.
- If `R ≥ W`, write `R = qW + r` with `q ≥ 1` and `0 ≤ r < W`. When `r = 0`,
use `q` batches of width `W`. When `r > 0`, use `q − 1` batches of width `W`
and one batch of width `W + r`. Then `W < W + r ≤ 2W − 1`, every batch lies
in `[W, 2W]`, the widths sum to `R`, and the number of added cells is `0`.
- If `0 < R < W`, the only batch is padded from `R` to `W`. The number of added
cells is `W − R < W`. The ratio `W/R` may exceed `2`.

PHASE-LAYOUT calls `R` superpolynomial and uses a polynomial bandwidth `W`.
Under `R ≥ W`, which is the asymptotic regime that hypothesis names, the final
batch does not need padding. "Padded once at constant cost" is not an `O(1)`
record-move bound. The proved added volume in the small-`R` case is less than
one full batch.

## Lemma 3 — moving only the short field costs `O(log a)` passes

Let the exposed field have length `a ≥ 1` and let the orthogonal index have
length `N ≥ 1`. The orthogonal index may contain the batch coordinate and any
spectator coordinates. The boundary volume of real records is `V = a N`.
Pad the exposed field to `M = M(a)` and let `V+ = M N`. Store the padded
records row-major: row `r`, then the orthogonal index.

Merge adjacent row blocks by the lockstep schedule. At a stage whose current
block holds `span` original padded rows, a node is two adjacent blocks. Pass 1
copies the two children apart. Pass 2 writes, for each orthogonal position,
the first child's `span` records and then the second child's `span` records.
Each pass moves every padded record once. There are `log2(M)` stages because
`M` is a power of two and `span` doubles from `1` to `M`. The forward movement
is therefore exactly

```text
2 · log2(M) · V+
```

record-moves. The reverse schedule, splitting each suffix-major chunk back
into the two children, has the same count and restores row-major order. The
number of stages is `ceil(log2 a)`. It depends on `a` and not on `N`, the
batch width, the spectator length, or the number of axes `g`.

By Lemma 1, `V+ < 2V`, so the forward count is strictly less than
`4 · ceil(log2 a) · V` when `a ≥ 2`, and it is `0` when `a = 1`. In all cases
the forward-plus-undo count is strictly less than `8 · max(1, ceil(log2 a)) · V`.
When `a` is polynomial in `p`, `ceil(log2 a) = O(log p)`, which is the stated
movement bound: `O(log p)` times the boundary volume.

A transpose whose stages instead follow the orthogonal index has
`ceil(log2 M(N))` stages. Whenever `N > M(a)`, that is strictly more stages
than the short-field schedule. A spectator of length `2^g` is the long index
this schedule does not transpose.

After the solve, drop the `M − a` pad rows. Undo uses the real field length
only in the sense that the pad rows are not part of the tensor address: they
are tape cells deleted before the next axis. The real record count returns
to `V`.

## Lemma 4 — removal does not accumulate across axes

Process axes of lengths `a_1, ..., a_g` one at a time. While axis `i` is
exposed, the live volume multiplier is `M(a_i) / a_i < 2`. After its pad cells
are deleted, the multiplier returns to `1`. The peak multiplier over the whole
sequence is therefore below `2`, and the final multiplier is `1`, for every
`g` and every tuple of lengths.

If the pad coordinate is retained, the final multiplier is
`∏_i M(a_i) / a_i`. For `a_i = 3`, this is `(4/3)^g`, which is unbounded in
`g` and already greater than `2` at `g = 3`. Lemma 1 says each factor is
below `2`, so the retained product is below `2^g`, but it still grows
exponentially whenever every factor is at least `4/3`. The sentence "never
accumulates as `2^g`" is the removal schedule. It is false for the retained
schedule.

## Lemma 5 — one factor-page scan per batch

Under the partition in Lemma 2, the number of factor-page scans is the number
of batches. It is not the right-hand-side count `R`, except in the special
case where every batch has width `1`. It is not multiplied by `g`: each axis
is a separate window, and this count is inside one axis.

## What remains inherited

The identity "Strassen `W^ω` per `W` right-hand sides gives
`O(V W^{ω−1} polylog p)`", and #4100's later form
`O(V d W^{τ−1}/B polylog p)`, need the carving, the relation between the
exposed length and `W`, and the exponent `τ`. PHASE-LAYOUT already assigns
stability and the no-pivot factor theorem to the phase-assembly branch.
#4100's Gaussian paragraph uses `τ = 45/16`, while its union-schedule ledger
uses `τ_eff = 2 + 10^{-64}`. This layout lemma does not choose between them.

A finite execution of the schedule corroborates the exact move count, the
padding inequality, and the removal alternative. The statements above are
integer identities for every positive size named in their hypotheses, not
sample checks.
85 changes: 85 additions & 0 deletions research/pr4100-row-field-movement/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
# Boundary-arithmetic row-field movement

**Scoped layout lemma. No new κ.** The selected conditional result stays
`0.001672660197076918`. This does not accept #4100.

## Scope and evidence

Card `uniform-transfer-audit`, refined to one caller. #4100's Gaussian text
says the one exposed polynomial row field is padded by a factor below two,
moved at `O(log p)` times the boundary volume, and removed before the next
axis, so the pad does not accumulate as `2^g`. The same movement is
PHASE-LAYOUT's short-field transpose, and UNION-SCHEDULE step 5 charges it
to the boundary-algebra row rather than to the union head travel. PR #4327
audits that head travel and leaves this batching row open.

[PROOF.md](PROOF.md) proves, for every positive integer size in the
hypotheses:

- `M(a) = 2^{ceil(log2 a)}` satisfies `a ≤ M(a) < 2a`.
- When the right-hand-side count is at least the batch width `W`, those
right-hand sides partition into batches in `[W, 2W]` with no added cells.
A shorter final batch adds fewer than `W` cells, not `O(1)` record moves.
- The lockstep transpose of the padded field uses `ceil(log2 a)` stages and
two passes per stage. Forward movement is exactly `2 · ceil(log2 a) · M(a) · N`,
which is strictly less than `4 · ceil(log2 a)` times the real boundary
volume when `a ≥ 2`. The stage count does not depend on the spectator length.
- Deleting the pad before the next axis keeps every axis multiplier below two
and returns the final multiplier to one. Retaining a length-3 pad on each
axis multiplies the volume by `(4/3)^g`.

`verify.py` recomputes the padding inequality for `a = 1..65536`, the batch
partition for `W = 1..64` and `R = 0..512`, and the schedule on twelve shapes.
The worst executed forward ratio is `2048/144`. A three-axis tensor of length
`3` peaks at `36` records and returns to `27`. Two rejection controls fail
closed: a pad of length `3` is not `8`, and six retained length-3 pads are
not a factor below two.

The Strassen count, the carving that produces `O(V d W^{τ-1}/B)`, conditioning,
and the #4100 ledger remain inherited. #4100 names both `τ = 45/16` and
`τ_eff = 2 + 10^{-64}`; this lemma does not choose between them.

## Reproduce

From the repository root, on CPython 3.12:

```sh
python3.12 -B scripts/research_package.py --package research/pr4100-row-field-movement --check-only
python3.12 -B scripts/research_package.py --package research/pr4100-row-field-movement
```

The registered command is `verify.py`. It uses the standard library and reads
the three pinned prose inputs. Expected first line:

```text
PASS_ROW_FIELD_MOVEMENT padding_strictly_below_two=true zero_added_cells_when_R_ge_W=true small_batch_added_cells_lt_W=true forward_passes_per_stage=2 max_forward_moves_over_real_volume=2048/144 stage_count_depends_only_on_row_length=true removal_peak_below_two=true retained_three_length_g6=(4/3)^6>2 page_scans_equal_batch_count=true no_new_kappa=true
```

## Open next questions

1. **Carry the move count into the ledger term.** The layout bound is
`O(log a)` times the boundary volume. It becomes #4100's
`O(V d W^{τ-1}/B)` only after the exposed length is identified with the
carving parameters `W` and `B`. First pin `|E_i|` and `μ` at the #4100
balance and substitute Lemma 3. Blocked here because the carving program
is not replayed.
2. **Fix the boundary exponent.** GAUSSIAN.md uses `τ = 45/16` for the
seven-product paragraph, while UNION-SCHEDULE section 4 uses
`τ_eff = 2 + 10^{-64}`. The movement lemma can be copied into the ledger
only after one of those is the stated exponent. First compare those two
sentences with the generated ledger at head
`337d04939571a637aeab54a0f58f54fde811663a`. Blocked here because that
ledger is a different program, and PR #1731's rectangular exponent is a
different caller.

## Credit

The layout sentences are from the capped phase-cell audit (Vlado Vojdanovski,
PR #1673, and the contributors named there) and from Cinna Davis's #4100
Gaussian and union-schedule text. PR #4327 (Ryanson Jonathan) audited the
union head travel and marked this batching row as separate. PR #1731's
review (the rectangular exponent and the operator identity) says partial-batch
padding is negligible and is not this level count.

Prepared by unpaidmoon with substantial Cursor Grok assistance. Apache-2.0.
No independent human review and no formal-kernel acceptance are claimed.
36 changes: 36 additions & 0 deletions research/pr4100-row-field-movement/SOURCES.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
{
"schema_version": 1,
"base_commit": "12fa8c5c844be21bfefb38a19503fbd867a11244",
"files": [
{
"path": "certificates/selected-result.json",
"usage": "provenance",
"git_blob": "b1fea0c94436b236cc2b7d41a7be032811b94c81",
"sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129"
},
{
"path": "docs/research/agent-task-catalog.json",
"usage": "provenance",
"git_blob": "64bfc5af6709ed9811171e0a2108f05e1219cb65",
"sha256": "352a6184713b8843d96fd2c2071eb7aeaa655906b7c51d45ad444912666c8a96"
},
{
"path": "research/capped-phase-fusion/PHASE-LAYOUT-AUDIT.md",
"usage": "input",
"git_blob": "bbeeee7431720817f031360f67b2186abac5cd23",
"sha256": "54aafc7afd09fe1a5312e69fad09c87422690543ab75c6ae35f6cbcc26b3eb8a"
},
{
"path": "research/unconditional-batched-crt/GAUSSIAN.md",
"usage": "input",
"git_blob": "adfb28c93e6b06178c901caaac39ede41a9e541b",
"sha256": "2f63c91c58f2d1cf31294812c75970ea390c61866a8da7ed700d4316a033a242"
},
{
"path": "research/unconditional-batched-crt/vendor/UNION-SCHEDULE.md",
"usage": "input",
"git_blob": "b5eb03e6745804f465a536fc9ffa87c2515d1bfa",
"sha256": "aabb28c343bcb9697a4cac7058060132617073df17ee18e591d2bf4defe9e921"
}
]
}
80 changes: 80 additions & 0 deletions research/pr4100-row-field-movement/TASK.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
{
"schema_version": 1,
"task_id": "uniform-transfer-audit",
"priority_revision": 7,
"base_commit": "12fa8c5c844be21bfefb38a19503fbd867a11244",
"original_card": {
"id": "uniform-transfer-audit",
"question": "Does one quantified step of the proposed #4100 all-size construction hold at its actual caller?",
"starting_points": [
"docs/research/research-family-status.md",
"certificates/selected-result.json",
"research/unconditional-batched-crt/README.md"
],
"methods": [
"Prove one missing implication with explicit quantified hypotheses.",
"Find an exact counterexample at the claimed interface boundary."
],
"acceptance_gate": "Identify the proposition and what would change downstream; do not equate a finite replay with a universal proof.",
"first_step": {
"command": [
"python3",
"-B",
"scripts/research_baseline.py"
],
"expected": "PASS_RESEARCH_BASELINE_BINDINGS_ONLY",
"inspect": "Read PROOF.md and AUDIT.md in #4100. Select one distinct obligation: CRT total repair, native/free-algebra lifting, precision/conditioning, or complete fixed-tape cost. This is an author-submitted proof, not an accepted unconditional theorem.",
"scope": "Source-binding orientation only; no scientific replay, theorem acceptance or supplier admission. Budget any heavy replay separately."
},
"first_experiment": "Check live handoffs; name one proposition, its caller, quantified domain and dependency closure. Independently prove the implication or exhibit a precise gap/counterexample. Prioritize CRT.md total repair or COMPLEX.md free-algebra lift only if unclaimed. Stop at the chosen obligation; do not substitute finite samples or root arithmetic for an all-size proof, or launch the complete package by default.",
"bottleneck_link": "Finite supplier improvements are useful only under the retained transfer obligations.",
"allowed_variations": [
"One CRT repair, native lift, precision/conditioning or tape-cost proposition, with its exact caller."
],
"scope_change_triggers": [
"Replacing a quantified obligation with another finite smoke test.",
"Treating archive intake, an author PASS receipt or a finite composed fixture as discharge of the universal hypotheses."
],
"overlap_terms": [
"uniform transfer",
"all-size",
"precision",
"4100",
"unconditional-batched-crt"
],
"existing_checks": [
{
"scope": "PR #4100: proposed unconditional construction and finite checks, without independent acceptance.",
"evidence": "research/unconditional-batched-crt/README.md",
"remaining": "Independent proof audit of one caller-bound all-size implication; all other premises remain explicit.",
"status": "author-checked",
"source_commit": "337d04939571a637aeab54a0f58f54fde811663a",
"selected_record_sha256": "bb2eaa58647b353f88d0aec2eafb9d30df1be53589231b23e12ceef3e4bad129"
}
]
},
"scope_status": "refined",
"actual_scope": "Prove the boundary-arithmetic row-field movement at the #4100 Gaussian caller: the exposed field pads by a factor strictly below two, a balanced short-field transpose uses ceil(log2 a) stages and two passes each, and deleting the pad before the next axis keeps the live multiplier below two. This is the layout step PHASE-LAYOUT and GAUSSIAN.md state, which #4327 left uncovered. It is not a CRT repair, a free-algebra lift, or an acceptance of #4100.",
"scope_change_reason": "The card asks for one quantified implication at its actual caller. CRT total repair and the free-algebra lift already have open audits. This package takes the still-open precision/conditioning layout obligation: GAUSSIAN.md's boundary-arithmetic row-field movement, at the PHASE-LAYOUT caller those sentences cite.",
"bottleneck_link": "The boundary row is one of the rows that can bind a proposed all-size Gaussian supplier. A 2^g pad, or a transpose of the long spectator, would replace the stated O(log p) movement. The lemma shows the removal schedule does not do that. It does not by itself raise the selected kappa.",
"budget_minutes": 60,
"stop_rule": "Stop after the row-field factor, the short-field move count, and the removal-versus-retention alternative. Do not re-derive the union head-travel constant, the Strassen exponent, or the ledger balance.",
"outcome": "completed",
"evidence": "PROOF.md. verify.py recomputes the padding inequality for a = 1..65536, the batch partition for W = 1..64 and R = 0..512, and the lockstep schedule on twelve shapes plus a three-axis tensor of length 3. Worst executed forward ratio 2048/144.",
"author": "unpaidmoon",
"ai_assistance": "Substantial Cursor Grok assistance with the proof writeup and the verifier.",
"open_questions": [
{
"question": "Does the exposed length equal the bandwidth W in #4100's carving, so that this movement count is the ledger term O(V d W^{tau-1}/B)?",
"why_it_matters": "The layout bound is O(log a) times the boundary volume. The quoted Gaussian cost still needs the relation between that volume, W, B, and the exponent tau.",
"first_step": "Pin the carving identities for |E_i| and mu at the #4100 balance and substitute the move count from PROOF.md Lemma 3.",
"blocked_by": "This package does not replay the phase-cell carving or choose between tau = 45/16 and tau_eff = 2 + 10^{-64}."
},
{
"question": "Which boundary exponent does the #4100 ledger actually use, 45/16 from the seven-product paragraph or 2 + 10^{-64} from the union-schedule ledger?",
"why_it_matters": "The two statements name different tau, so a movement lemma cannot be copied into the ledger row until the exponent is fixed.",
"first_step": "Compare GAUSSIAN.md's tau = 45/16 sentence with UNION-SCHEDULE.md section 4 and the generated ledger checks at head 337d04939571a637aeab54a0f58f54fde811663a.",
"blocked_by": "The ledger program is outside this package, and PR #1731's rectangular exponent is a different caller."
}
]
}
22 changes: 22 additions & 0 deletions research/pr4100-row-field-movement/VERIFY.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"schema_version": 1,
"status": "ready",
"python": "3.12",
"requirements": [],
"inputs": [
"research/capped-phase-fusion/PHASE-LAYOUT-AUDIT.md",
"research/unconditional-batched-crt/GAUSSIAN.md",
"research/unconditional-batched-crt/vendor/UNION-SCHEDULE.md"
],
"commands": [
{
"argv": [
"{python}",
"-B",
"{package}/verify.py"
],
"timeout_seconds": 60,
"checks": "Padding factor M(a) < 2a for a = 1..65536; batch partition; exact lockstep move count; removal versus retained padding; source-sentence binding; rejection controls."
}
]
}
Loading