RecursiveArrayTools.jl
RecursiveArrayTools.jl copied to clipboard
ArrayPartition within ArrayPartition
Is using an ArrayPartition
within another ArrayPartition
supported? I'm having the following problem:
julia> using StaticArrays, RecursiveArrayTools
julia> x = ArrayPartition(ArrayPartition(@SMatrix [1.1 1.2; 1.3 1.4]), SVector(1.2))
([1.1 1.2; 1.3 1.4], [1.2])
julia> y = 1.1 * x
([1.21, 1.43, 1.32, 1.54], [1.32])
julia> typeof(x.x[1])
ArrayPartition{Float64,Tuple{SArray{Tuple{2,2},Float64,2,4}}}
julia> typeof(y.x[1])
Array{Float64,1}
Somehow the type of the underlying array is being changed. I would have expected that array type to remain the same.