Refactoring

Refactoring the 'out' related codes in the solvers
Plot condition numbers