Skip to content

Pin the asymmetric-cover gauge per support component#33

Merged
timholy merged 2 commits into
mainfrom
teh/components
Jul 19, 2026
Merged

Pin the asymmetric-cover gauge per support component#33
timholy merged 2 commits into
mainfrom
teh/components

Conversation

@timholy

@timholy timholy commented Jul 19, 2026

Copy link
Copy Markdown
Member

The gauge a -> γ*a, b -> b/γ of an asymmetric cover acts independently on each connected component of the bipartite support graph of A, so the balance convention determines the split only when imposed within each component. As a single global constraint it pinned one of the k gauge directions and left the rest to solver internals — the native solver's ridge, the heuristic's tightening passes, or whichever vertex the LP solver returned — so cover_min([B 0; 0 C]) did not reproduce the blockwise covers of B and C in the returned factors.

A union-find helper, _support_components, now backs _balance_cover!, the native exact solver's closed-form shift, and post-solve shifts in the JuMP and Ipopt extensions (whose global balance model constraint pins only the one direction). The split is now a deterministic function of the support and the products, and block-diagonal assembly commutes with cover_min. The isbalanced test helper checks every component, and new tests cover component labeling, block-assembly consistency, offset axes, and the extension solvers.

This PR also includes a second (unrelated) commit polishing an overly-verbose docstring.

Assisted-by: Claude Fable 5 (claude-fable-5) noreply@anthropic.com

timholy added 2 commits July 19, 2026 02:17
The gauge a -> γ*a, b -> b/γ of an asymmetric cover acts independently
on each connected component of the bipartite support graph of A, so the
balance convention determines the split only when imposed within each
component. As a single global constraint it pinned one of the k gauge
directions and left the rest to solver internals — the native solver's
ridge, the heuristic's tightening passes, or whichever vertex the LP
solver returned — so cover_min([B 0; 0 C]) did not reproduce the
blockwise covers of B and C in the returned factors.

A union-find helper, _support_components, now backs _balance_cover!,
the native exact solver's closed-form shift, and post-solve shifts in
the JuMP and Ipopt extensions (whose global balance model constraint
pins only the one direction). The split is now a deterministic function
of the support and the products, and block-diagonal assembly commutes
with cover_min. The isbalanced test helper checks every component, and
new tests cover component labeling, block-assembly consistency, offset
axes, and the extension solvers.

Assisted-by: Claude Fable 5 (claude-fable-5) <noreply@anthropic.com>
@codecov

codecov Bot commented Jul 19, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.77%. Comparing base (fb27898) to head (277db04).
⚠️ Report is 25 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #33      +/-   ##
==========================================
+ Coverage   98.55%   98.77%   +0.21%     
==========================================
  Files          13       13              
  Lines        2070     2196     +126     
==========================================
+ Hits         2040     2169     +129     
+ Misses         30       27       -3     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@timholy
timholy merged commit f354454 into main Jul 19, 2026
5 checks passed
@timholy
timholy deleted the teh/components branch July 19, 2026 11:06
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