Skip to content

Check for elementwise equality when comparing with UniformScaling #1369

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jishnub
Copy link
Member

@jishnub jishnub commented Jun 1, 2025

This works around issues with block matrices like:

julia> A = Diagonal(fill(I(2), 4))
4×4 Diagonal{Diagonal{Bool, Vector{Bool}}, Vector{Diagonal{Bool, Vector{Bool}}}}:
 Diagonal(Bool[1, 1])                 
                                      
                                      
                         Diagonal(Bool[1, 1])

julia> A == I
true

julia> A[1,1] == I[1,1]
false

The checks in this PR ensure that if a matrix is == a UniformScaling, their elements are equal as well.

This builds on top of #1367, and may be rebased once that is merged.

@jishnub jishnub changed the base branch from jishnub/uniformscaling_equality to master June 1, 2025 11:08
Copy link

codecov bot commented Jun 1, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 93.81%. Comparing base (5f449f5) to head (b38651a).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1369      +/-   ##
==========================================
- Coverage   93.81%   93.81%   -0.01%     
==========================================
  Files          34       34              
  Lines       15717    15716       -1     
==========================================
- Hits        14745    14744       -1     
  Misses        972      972              

☔ 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.

@jishnub jishnub force-pushed the jishnub/uniformscaling_equality_block branch from 9460105 to b38651a Compare June 1, 2025 14: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