a <- Matrix::sparseVector(1:2, i = 1:2, length = 2)
b <- Matrix::sparseVector(1:2, i = 1:2, length = 2)
class(a * b)
#> [1] "dsparseVector"
#> attr(,"package")
#> [1] "Matrix"
class(a / b) # bug? numeric instead of sparseVector
#> [1] "numeric"
Created on 2019-07-05 by the reprex package (v0.3.0)