PDMats.jl
PDMats.jl copied to clipboard
Stop using StidedMatrix?
StridedMatrix
is a annoying impossible extend union type.
it is not too hard for a custom array type to implement all the required methods.
(especially if it is a wrapper type that just delegates them all),
However it is not possible for a new type to join a Union
.
I suggest that all dispatches on StridedMatrix
in the package be replaced with AbstractMatrix
.
If that throws an error deeper in the code because they hit some method that actually needs a StridedMatrix
and they don't have the methods needed then so be it.
A specific example that would benefit from this change:
n = 8
a = rand(n, n)
a = PDMat(a * a')
b = UpperTriangular(rand(n, n))
X_A_Xt(a, b)
should be faster than
X_A_Xt(a, Matrix(b))
Was fixed by #163.