This is related to https://github.com/JuliaLang/julia/issues/28432
kron returns a dense matrix if the adjoint is provided, example
id = spzeros(2,2)+I
kron(id,id')
this returns
4×4 Array{Float64,2}:
1.0 0.0 0.0 0.0
0.0 1.0 0.0 0.0
0.0 0.0 1.0 0.0
0.0 0.0 0.0 1.0
while it should output
4×4 SparseMatrixCSC{Float64,Int64} with 4 stored entries:
[1, 1] = 1.0
[2, 2] = 1.0
[3, 3] = 1.0
[4, 4] = 1.0
is this behaviour expected?