BUG: sparse matrices don't allow some operator overloads

This seems to fix #3580.