Minor change, renamed variables
Simplified solver, removed unnecessary parts