Recently I have been thinking about the following problem:
Given a loan with an annual interest rate that is compounded daily, and given a payment to be made at fixed intervals, how much money is actually paid to recover the loan and over how long?
Hence I came up with the simple calculator below (thanks to jw for pointing out the function to use; this should run slightly faster if the log operation in javascript is implemented in less than O(n), otherwise no speed gain):
Now, the harder question is finding the converse: given a loan with an interest rate compounded daily, a target duration to completely repay the loan, and the fixed interval to make payments, how much should one pay per interval to completely repay the loan by the target duration?