Use nil instead of 0 for initial guess value