Optimal life history models: effects of nonlinearities in the response of reproductive success to investment