Renamed temp variables and make them private in LinearSolver.