def present_value(amount, rate, t): cf = CashFlow(amount=amount, t=t) return cf.present_value(ir=rate)
def future_value(amount, rate, t): cf = CashFlow(amount=amount, t=0) return cf.shift(t=t, ir=rate)