UPDATED: Switched to lmgres iterative method