IRR function and how it is related to NPV