Editor rules updated (.cursorrules, .clinerules, copilot-instructions, .roo): - Build: 3571 jobs, 0 errors - Sorry inventory: 8 across 4 files (all documented) - Q16_16 compliance, new modules list, FPGA info - Fixed stale path in copilot-instructions Opencode agents: - 3 marked RESOLVED (pist-simulation, qfactor, ssms) - 2 new agents created (adjugate-matrix, hamiltonian-mechanics) - 1 updated (hyperbolic-statesurface) SORRY_AUDIT.md: updated to 8 sorries across 4 files
1.5 KiB
| description | mode | model | permission | ||||||
|---|---|---|---|---|---|---|---|---|---|
| Fix HyperbolicStateSurface.lean sqrt error-bound sorry. Use ONLY when asked to fix HyperbolicStateSurface. | subagent | anthropic/claude-sonnet-4-6 |
|
Fix HyperbolicStateSurface.lean
One remaining issue (Issue 2 was resolved previously):
Issue 1 (line 85, sorry) — STILL OPEN
ko_preserves_hyperbola_approx — needs a formal error-bound lemma for Q16_16.sqrt:
(Q16_16.sqrt r)² ≈ r up to 1 LSB rounding.
The theorem has been restructured: onHyperbolaApprox is now an explicit premise
(h_sqrt_sq_error) rather than a sorry in the conclusion. The sorry at line 85
is where the premise should be discharged from a formal Q16_16.sqrt squaring bound.
Available lemmas: Q16_16.sqrt_zero, Q16_16.sqrt_one. The sqrt implementation
is at FixedPoint.lean:289 (Newton approximation). The lemma can be weaker:
|(sqrt r)² - r| ≤ ε for some small ε, or just prove the specific case needed
by the calling theorem.
Issue 2 (lines 207/215) — RESOLVED
Type mismatch: Fixed in prior session.Vector HyperState n vs List.Vector HyperState n.
Steps
- Read the full file:
Semantics/Extensions/HyperbolicStateSurface.lean - Focus on line 85: prove
Q16_16.abs (Q16_16.sqrt x * Q16_16.sqrt x - x) ≤ Q16_16.epsilonfor non-negativex, or prove the specific instance used byko_preserves_hyperbola_approx - Build:
lake build Semantics.Extensions.HyperbolicStateSurface - Build:
lake build Compiler