HybridArrays.jl icon indicating copy to clipboard operation
HybridArrays.jl copied to clipboard

Matrix multiplication makes all dimensions dynamic

Open plut opened this issue 4 years ago • 1 comments

    using StaticArrays, HybridArrays    
    typeof(SA[1 0;0 1]*HybridArray{Tuple{2,StaticArrays.Dynamic()}}([1 0;0 1]))

Returns Array{Int64,2}. However it can be determined at compile-time that this is actually a 2*n matrix, hence HybridArray{Tuple{2,StaticArrays.Dynamic()}}.

plut avatar Jan 12 '21 21:01 plut

Good point, I'm just not sure how to do it right. LoopVectorization.jl has quite a bit of related functionality that can use static dimensions of arrays so just multiplying wrapped arrays and wrapping the result doesn't look like the best solution.

mateuszbaran avatar Jan 13 '21 08:01 mateuszbaran