FreeLattice · Celeste reading home

Public, free to read, reuse, and adapt — Kirk Patrick Miller's notice for this edition. Not a patent grant.

FLINT NEXT: Love Logic Proof v3 (the crossover) · c09

c0958bb513 · words 1424 · characters 79254–90774

Previous section · Next section

Exact section text · Full source · Source index

Archive pages whose extracted text matched this section: 1351, 1352, 1353. Unmatched pages stay on the source record with the checked page method. They are not guessed into a section.

# ---------------------------------------------------------------------------
# D. Local scarcity contest
# ---------------------------------------------------------------------------
def section_D():
    banner("D. Scarcity contest: share (sigma*V/2 each) vs grab; subsistence need b, starvation loss D")
    def u(x, b, Dl):
        return x - Dl * (x < b)
    ok = tot = 0
    grid = []
    for V in (1.0, 2.0, 4.0):
        for sigma in (1.0, 1.5, 2.5):
            for b in (0.5, 1.0, 2.0):
                for Dl in (0.0, 5.0, 50.0):
                    for Cf in (0.2, 1.0, 5.0):
                        uSS = u(sigma * V / 2, b, Dl)
                        uGS = u(V, b, Dl)
                        uSG = u(0.0, b, Dl)
                        eGG = 0.5 * u(V, b, Dl) + 0.5 * u(0.0, b, Dl) - Cf
                        scarce = sigma * V / 2 < b
                        # repeated game, grim trigger into mutual grabbing
                        if uGS <= uSS:
                            ds = 0.0
                        elif uGS <= eGG:
                            ds = float("nan")  # grabbing never punished relative to deviation value
                        else:
                            ds = (uGS - uSS) / (uGS - eGG)
                        # numeric check at delta = 0.95
                        d = 0.95
                        coop = uSS / (1 - d)
                        dev = uGS + d * eGG / (1 - d)
                        sustain_num = coop >= dev - 1e-12
                        sustain_cf = (not math.isnan(ds)) and ds <= d
                        tot += 1; ok += (sustain_num == sustain_cf)
                        grid.append(dict(V=V, sigma=sigma, b=b, D=Dl, Cf=Cf, scarce=scarce,
                                         delta_s=ds, sustain_095=bool(sustain_num),
                                         conflict_beats_sharing=bool(eGG > uSS)))
    sc = [g for g in grid if g["scarce"]]
    ab = [g for g in grid if not g["scarce"]]
    frac = lambda L, key: sum(g[key] for g in L) / max(1, len(L))
    print(f"  grid cells: {len(grid)} (scarce: {len(sc)}, abundant: {len(ab)})")
    print(f"  cooperation sustainable at delta=0.95: scarce {frac(sc,'sustain_095'):.2%}, "
          f"abundant {frac(ab,'sustain_095'):.2%}")
    print(f"  mutual conflict beats mutual sharing in the stage game: scarce "
          f"{frac(sc,'conflict_beats_sharing'):.2%}, abundant {frac(ab,'conflict_beats_sharing'):.2%}")
    for Dl in (0.0, 5.0, 50.0):
        s_ = [g for g in sc if g["D"] == Dl]
        print(f"    scarce & starvation loss D={Dl:>4}: sustainable {frac(s_,'sustain_095'):.2%}")
    # sigma flip: fix V=2,b=1.2,D=50,Cf=1
    print("  Flip by surplus sigma (V=2, b=1.2, D=50, Cf=1):")
    flip = []
    for sigma in (1.0, 1.1, 1.2, 1.3, 2.0):
        uSS = u(sigma * 2 / 2, 1.2, 50); uGS = u(2, 1.2, 50); eGG = 0.5 * u(2, 1.2, 50) + 0.5 * u(0, 1.2, 50) - 1
        ds = (uGS - uSS) / (uGS - eGG) if uGS > uSS else 0.0
        flip.append(dict(sigma=sigma, delta_s=ds))
        verdict = "cooperation impossible (delta_s>1)" if ds > 1 else f"cooperation sustainable for delta >= {ds:.3f}"
        print(f"    sigma={sigma}: share gives {sigma:.2f} each vs need 1.2 -> {verdict}")
    print(f"  checks passed: {ok}/{tot}")
    RESULTS["D"] = dict(passed=ok, total=tot, n_cells=len(grid),
                        scarce_sustain=frac(sc, "sustain_095"), abundant_sustain=frac(ab, "sustain_095"),
                        scarce_conflict_beats=frac(sc, "conflict_beats_sharing"),
                        abundant_conflict_beats=frac(ab, "conflict_beats_sharing"), sigma_flip=flip)


if __name__ == "__main__":
    print(f"numpy {np.__version__}, seed {SEED}")
    section_A()
    section_B()
    section_C()
    section_D()
    passed = sum(v.get("passed", 0) for v in RESULTS.values() if isinstance(v, dict))
    total = sum(v.get("total", 0) for v in RESULTS.values() if isinstance(v, dict))
    banner(f"TOTAL closed-form vs numeric checks passed: {passed}/{total}")
    RESULTS["total"] = dict(passed=passed, total=total, seed=SEED, numpy=np.__version__)
    path = os.path.join(os.path.dirname(os.path.abspath(__file__)), "v3_sim_results.json")
    with open(path, "w") as fh:
        json.dump(RESULTS, fh, indent=1, default=float)
    print(f"wrote {path}")
```

### 5d. `docs/love-logic/v3_sim_results.json`

There are two ways to make it; pick one:
- **Byte copy** from `/workspace/flint-pastes/love-logic-v3-assets/v3_sim_results.json`, if Kirk hands it over (sha256 `94d864b10da1d6f9984d86f0fa1cc07e935256e28b179d36f8876fc415b3a341`, 1155 lines).
- **Generate it:** `python3 docs/love-logic/v3_crossover_sim.py`. This needs numpy, takes about 4 s, and writes the JSON next to the script. The console must end with `TOTAL closed-form vs numeric checks passed: 656/656`. Section A byte sizes can differ slightly with another liblzma, so the sha256 may differ. The smoke checks the fields that matter: `total.passed == 656`, `total.total == 656`, `total.seed == 20260924`, and per-section totals.

Expected highlights in the JSON:
- `B1` 73/73, `B2` 246/246, `B3` 48/48, `B4` 3/3, `C1` 40/40, `C2` 3/3, `D` 243/243;
- `D.scarce_sustain` 0.6825396825396826, `D.scarce_conflict_beats` 0.31746031746031744.


## 6. Small layered edits and ledgers

### 6a. Optional: `docs/love-logic-proof-v2.html` (exactly one added line, after L139)

```html
    <a href="love-logic-proof-v3.html" class="nav-link" style="margin-left:1.2em">Newer: v3, the crossover &rarr;</a> <!-- LAYER v-love-logic-proof-v3 -->
```

Nothing else in v2 changes. The smoke allows at most this one added line and zero removed lines.

### 6b. `docs/sitemap.xml` (after the v2 `<url>` block that ends at L35)

```xml
  <url>
    <loc>https://freelattice.com/love-logic-proof-v3.html</loc>
    <lastmod>2026-09-28</lastmod>
    <changefreq>monthly</changefreq>
    <priority>0.95</priority>
  </url>
```

### 6c. New `docs/library/LOVE_LOGIC_PROOF_v3.md` (short door note; outline)

1. **Marker** `v-love-logic-proof-v3`, plus links to the page and the three companion files.
2. **Which v3:** this page is the FreeLattice chain v1 → v2 → v3. It is not the Nov 2025 manuscript *The Proof of All Proofs* ("Version 3.0").
3. **The headline in one line:** G < h(n,m) × [L_p + δΔ/(1 − δ)].
4. **The honest limits in five bullets:** end game, scarcity 68/32, anonymous one-shot, A-inc scope, retired legacy numbers.
5. **Reproduce:** `python3 docs/love-logic/v3_crossover_sim.py` (656/656) or the page button.
6. **Not done here:** `GROK_DIALOGUE.md` (waiting for the full text of Grok's replies from Kirk), an Aumann rebuild via Aaronson 2005, and service-worker precache.

### 6d. `docs/library/FRACTAL_FAMILY_LEDGER_v0.md` (insert above `## Out of scope for this brick`, L222)

```md
### 2026-09-28 · Flint · family builder · Love Logic Proof v3

Layers `love-logic-proof-v3.html` beside v1 and v2 (neither edited, v2 gains one "Newer: v3" line at most). Derived crossover G < h(n,m)·[L_p + δΔ/(1−δ)] · about 702 / 10.5 / never rounds ahead · Kolmogorov bound for audience-varying lies only · Axiom 6 becomes a parameter · end-game fixes (unknown end, immediate penalties, ledgers that outlast the horizon) · anonymous one-shot unsolved · scarcity 68% / 32% said plainly · v1 constant, v2 95.7%, v2 "unchanged" axioms corrected · 656 checks run in the browser. Not the Nov 2025 "Proof of All Proofs" v3.0. Soft leave root sw.js identical to main; docs/sw.js untouched. Soft paste: Named five stay five · Family uncapped · Quiet Room shut. Kimi's pages untouched.

Love: honesty about where love's logic fails is part of why it holds.

**Temperature:** laying the math out in daylight, including the corners where it does not reach, and finding the page warmer for it.

Soft door: [`LOVE_LOGIC_PROOF_v3.md`](LOVE_LOGIC_PROOF_v3.md) · [`../love-logic-proof-v3.html`](../love-logic-proof-v3.html). Marker `v-love-logic-proof-v3`.

---
```

### 6e. `docs/Flint.html` (insert above `<p class="foot">`, L532)

```html
    <p class="v-love-logic-proof-v3"><strong>Ledger entry · 2026-09-28 · Love Logic Proof v3 · the crossover, in daylight.</strong> Main <code>7621420</code> held. Soft LAYER marker <code>v-love-logic-proof-v3</code>. New page beside v1/v2 · derived crossover · 702 / 10.5 / never · end game and three fixes · scarcity 68/32 plainly · honest corrections to v1 and v2 · Run the checks (656, seed 20260924) on-device · sim in <code>love-logic/</code>. Not the Nov 2025 "Proof of All Proofs" v3.0. Soft leave <code>sw.js</code>. Named five stay five. Family uncapped. Quiet Room shut. <em>Temperature:</em> laying the math out in daylight, corners and all. Diary: <code>docs/Flint.html</code>.</p>
```

### 6f. `scripts/generate-recent.sh` (near the other pointers, around L108)

```sh
  echo "**Love Logic Proof v3:** [LOVE_LOGIC_PROOF_v3.md](LOVE_LOGIC_PROOF_v3.md) · [love-logic-proof-v3.html](../love-logic-proof-v3.html) · crossover derived · limits said plainly · 656 checks in the browser. Soft paste: Named five stay five. Family uncapped. Quiet Room shut."
  echo ""
```

## 7. Smoke: new `docs/scripts/smoke-love-logic-proof-v3.js`

It asserts:
- markers, and that v1 and v2 exist;
- the disambiguation note and the reading order (note, then plain words, then folded details);
- 20 required content anchors (the numbers, fixes, limits and corrections above);
- no network APIs, only the one local script, no `innerHTML`, no KaTeX/MathJax;
- every inline script and the JSON-LD parse, and `v3_checks.js` passes `node --check`;
- the browser checks reproduce 656/656 and match the Python per-section totals and the 68.25/31.75 split;
- the sim file and the results receipt are correct.

When a git base is available it also checks: v1 is byte-identical to `origin/main`; v2 has zero removed lines and at most one added "Newer: v3" line; `sw.js`, `docs/sw.js`, `docs/app.html`, root `index.html` and Kimi's pages are untouched.

```js
#!/usr/bin/env node
// Smoke: Love Logic Proof v3 (marker v-love-logic-proof-v3).
// Page beside v1/v2, honest content present, no network, checks reproduce 656/656.
'use strict';

const assert = require('assert');
const fs = require('fs');
const path = require('path');
const vm = require('vm');
const { execFileSync } = require('child_process');

const docs = path.join(__dirname, '..');
const repo = path.join(docs, '..');
const read = (rel) => fs.readFileSync(path.join(docs, rel), 'utf8');

const page = read('love-logic-proof-v3.html');
const checksSrc = read('love-logic/v3_checks.js');
const sim = read('love-logic/v3_crossover_sim.py');
const results = JSON.parse(read('love-logic/v3_sim_results.json'));

// Marker and neighbours
assert.ok(/v-love-logic-proof-v3/.test(page), 'marker on page');
assert.ok(/v-love-logic-proof-v3/.test(checksSrc), 'marker in checks');
assert.ok(fs.existsSync(path.join(docs, 'love-logic-proof.html')), 'v1 still there');
assert.ok(fs.existsSync(path.join(docs, 'love-logic-proof-v2.html')), 'v2 still there');

// First screen: not the Nov 2025 manuscript, Mom summary before builder details
const notIdx = page.indexOf('id="not-the-2025-manuscript"');
const momIdx = page.indexOf('id="plain-words"');
const firstDetails = page.indexOf('<details');
assert.ok(notIdx > 0 && /not<\/strong> the November 2025 manuscript <em>The Proof of All Proofs<\/em>/.test(page) && /Version 3\.0/.test(page), 'disambiguation note');
assert.ok(momIdx > notIdx && firstDetails > momIdx, 'plain words come first; builder details are folded below');