It may be easiest to describe a simple situation. You financed your car, and you know your monthly payment, how much you financed, and how many months you financed, but you cannot recall your interest rate. There is a method for that. Same with the other 3. So we end up with the following functions:
- finance.calculatePayment - calculate the monthly payment
- finance.calculateAmount - calculate the amount financed
- finance.calculateMonths - calculate the number of months financed
- finance.calculateInterest - calculate the interest rate
- finance.calculateAmortization - calculate an amortization schedule of each month's interest and balance.
- finance.calculateAccruedInterest - calculate the interest money one would gain in an interest bearing account over X months.
Aside from these finance methods are simple number and currency formatting methods. Provided are USD, GBP, and EUR currency formats and add/remove methods to manage more. Enjoy!