Make lyapunov_symm compatible with sparse matrices

As discussed in #988 (closed) it would make sense to have lyapunov_symm able to work with sparse matrices (at least for the baseline option)