Refactor SR and add more options for least-squares solvers
Created by: femtobit
This PR refactors the code in the SR
class by introducing generic methods for constructing the S matrix and solving the least-squares update equation which work for both the real and complex case.
This makes the code easier to read and allows changes to regularization and solvers in one place in the code.
Further, this PR makes available more of the solvers available in Eigen and adds an option to store the rank of the S matrix and even the full S matrix (which might be useful for debugging purposes).