fSolver function

User-Specified Loss Function