Define the tolerances of lsmr as parameters of the interface
Remove wrong loop