Skip to content

Switch to inequality bounds#5

Merged
timholy merged 11 commits intomainfrom
teh/fastineq
Mar 7, 2026
Merged

Switch to inequality bounds#5
timholy merged 11 commits intomainfrom
teh/fastineq

Conversation

@timholy
Copy link
Member

@timholy timholy commented Mar 7, 2026

This PR switches from an unconstrained formulation to a constrained one, requiring that a[i] * b[j] >= abs(A[i, j]) for all i, j. This was motivated by the observation that near-zero values could greatly distort the former solution; adding the constraint means the solution is dominated by "largest" entries (in a scale-invariant sense).

This also:

  • changes terminology from "scale" to "cover"
  • provides fast, scale-invariant, but non-optimal implementations as the workhorse
  • adds optimal solutions that require JuMP
  • Add tests for the new API (symcover, cover, lobjective, qobjective, dotabs, divmag, *_qmin variants, quality vs optimal on testmatrices)
  • Drop tests for removed functions (symscale, matrixscale, condscale)
  • Add Statistics to test dependencies
  • Rewrite README to summarize key highlights and link to docs
  • Rewrite docs/src/index.md with motivation, examples, algorithm table, and divmag description

Co-Authored-By: Claude Sonnet 4.6 noreply@anthropic.com

timholy and others added 10 commits March 5, 2026 09:56
May not be very close to optimal
The biggest change is the balanced covers should start out tighter than
before. Also includes code simplifications and possible performance
improvements.
- Replace max-based cover initialization with log-geometric-mean
  initialization, giving diagonal-scaling covariance up to gauge
- Add tests for the new API (symcover, cover, lobjective, qobjective,
  dotabs, divmag, *_qmin variants, quality vs optimal on testmatrices)
- Drop tests for removed functions (symscale, matrixscale, condscale)
- Add Statistics to test dependencies
- Rewrite README to summarize key highlights and link to docs
- Rewrite docs/src/index.md with motivation, examples, algorithm table,
  and divmag description

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@codecov
Copy link

codecov bot commented Mar 7, 2026

Codecov Report

❌ Patch coverage is 98.86364% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 98.91%. Comparing base (861538f) to head (89525ad).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
src/covers.jl 98.01% 2 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##              main       #5      +/-   ##
===========================================
- Coverage   100.00%   98.91%   -1.09%     
===========================================
  Files            2        3       +1     
  Lines           90      185      +95     
===========================================
+ Hits            90      183      +93     
- Misses           0        2       +2     

☔ View full report in Codecov by Sentry.
📢 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 69ed90e into main Mar 7, 2026
3 of 5 checks passed
@timholy timholy deleted the teh/fastineq branch March 7, 2026 19:46
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