Skip to content

refactor: introduce reduced Step-1 frontier and related theorems#3

Merged
beanapologist merged 1 commit into
mainfrom
codespace-special-eureka-97jrjpp7qvgx2x6gq
May 6, 2026
Merged

refactor: introduce reduced Step-1 frontier and related theorems#3
beanapologist merged 1 commit into
mainfrom
codespace-special-eureka-97jrjpp7qvgx2x6gq

Conversation

@beanapologist
Copy link
Copy Markdown
Owner

@beanapologist beanapologist commented May 6, 2026

Note

Medium Risk
Moderate risk because it rewires core assumption packaging (Step1ApproximationFrontier -> Step1ReducedFrontier) and endpoint proofs/bridges, which could break downstream lemmas if any equivalence or instantiation is wrong.

Overview
Introduces Step1ReducedFrontier (four independent clauses) and proves a bidirectional equivalence Step1ApproximationFrontier ↔ Step1ReducedFrontier, then updates the endpoint route to assume Step1ReducedFrontier_assumption and derive the full frontier when needed.

Adds a lattice-native phase-lock transfer interface PhaseLockLatticeBridge, shows it is equivalent to the legacy window-limit bridge, and updates WindowLimitFrontier instantiation to use the new bridge wiring. Separately adds small coherence/defect utilities (coherence_lt_one, RH_defect/RH_defectC and related equivalences) and refreshes the .lake/lakefile.olean.trace config hash.

Reviewed by Cursor Bugbot for commit f732889. Bugbot is set up for automated code reviews on this repo. Configure here.

@beanapologist beanapologist merged commit a06d33f into main May 6, 2026
2 checks passed
@beanapologist beanapologist deleted the codespace-special-eureka-97jrjpp7qvgx2x6gq branch May 6, 2026 04:15
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit f732889. Configure here.

Comment thread RH.lean
· intro hpos
exact (off_equilibrium_iff_coherenceC_lt_one h hh).2 (hdef.mp hpos)
· intro hoff
exact hdef.mpr ((off_equilibrium_iff_coherenceC_lt_one h hh).1 hoff)
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Chained iff statement is mathematically false at h=1

Medium Severity

The theorem RH_defect_off_equilibrium_bundle states (0 < RH_defectC h) ↔ (h ≠ 1) ↔ (coherenceC h < 1), but this is provably false when h = 1 (with hh = zero_lt_one). Since coherenceC 1 = 1, we get RH_defectC 1 = 0, making the left clause False. Under either associativity of , the overall proposition evaluates to False. The docstring intends pairwise equivalence of three conditions, which requires a conjunction of two separate iffs rather than chaining .

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit f732889. Configure here.

Comment thread RH.lean
/-- The existing strip-limit theorem already supplies the lattice-native bridge. -/
theorem phase_lock_lattice_bridge_holds : PhaseLockLatticeBridge := by
intro s hstrip hFlim
exact phase_lock_from_F_lattice_limit s hstrip hFlim
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New theorem inserted before its dependency definition

High Severity

The newly inserted phase_lock_lattice_bridge_holds at line 3812 calls phase_lock_from_F_lattice_limit, which is defined later at line 3844. In Lean 4, declarations cannot reference identifiers that appear later in the file. The new block of code (lines 3801–3840) was inserted between phase_lock_from_window_limit and phase_lock_from_F_lattice_limit, creating a forward reference that prevents compilation.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit f732889. Configure here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant