-
-
Notifications
You must be signed in to change notification settings - Fork 11
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
+ and - throw error with UpperTriangular matrices #388
Comments
So should these just return a full matrix? |
@yuyichao yes, I think so. Probably something like |
not if the wrapped type is sparse. |
Sorry - |
@tkelman Is this the conclusion in one of the recent julia> typeof(sprandn(10,10,0.1) .+ 1)
Array{Float64,2}
julia> typeof(broadcast(+, sprandn(10,10,0.1), 1))
SparseMatrixCSC{Float64,Int64} but densifying seems more sensible for |
JuliaLang/julia#17623 fixed the inconsistency I believe julia> typeof(sprandn(10,10,0.1) .+ 1)
SparseMatrixCSC{Float64,Int64} Best! |
This works for the dot versions now that JuliaLang/julia#17623 is merged. Anybody knows why these wouldn't just call broadcast? |
Perhaps for the special |
Maybe @stevengj would now if we can get rid of them. |
The promotion rules are slightly different for abstract types, so I didn't want to change them in that PR. It seemed best to do it in a separate PR. |
Ref. related discussion https://github.com/JuliaLang/julia/issues/19595#issuecomment-268070182 and the forthcoming issue from |
See JuliaLang/julia#19669 re. the type behavior. |
Fixed by JuliaLang/julia#19746 |
The text was updated successfully, but these errors were encountered: