Private Sub PresentValueVerify() 'Verify that the PresentValue function works correctly. Debug.Assert Approx(PresentValue(0.1 / 12, 4 * 12, 400, 0, 0), -15771.264036612) Debug.Assert Approx(PresentValue(0.1 / 12, 4 * 12, 400, 0, 1), -15902.6912369171) Debug.Assert Approx(PresentValue(0.1 / 12, 4 * 12, -400, 0, 0), 15771.264036612) Debug.Assert Approx(PresentValue(0.1 / 12, 4 * 12, -400, 0, 1), 15902.6912369171) Debug.Assert Approx(PresentValue(0.1 / 12, 4 * 12, 400, 5000, 0), -19128.4240327982) Debug.Assert Approx(PresentValue(0.1 / 12, 4 * 12, 400, 5000, 1), -19259.8512331033) Debug.Assert Approx(PresentValue(0.1 / 12, 4 * 12, 400, -5000, 0), -12414.1040404257) Debug.Assert Approx(PresentValue(0.1 / 12, 4 * 12, 400, -5000, 1), -12545.5312407308) Debug.Assert Approx(FutureValue(0, 4 * 12, 400, 0, 0), -19200) Debug.Assert Approx(FutureValue(0, 4 * 12, 400, 0, 1), -19200) Debug.Assert Approx(FutureValue(0, 4 * 12, 400, 12300, 0), -31500) Debug.Assert Approx(FutureValue(0, 4 * 12, 400, -12300, 1), -6900) End Sub
Copyright 1996-1999 Entisoft
Entisoft Tools is a trademark of Entisoft.