Optimize Cash Flow with Dynamic Discounting