Quote:
Originally Posted by swerdna Hi Roxoff. I see the compound interest formulae on your reference. I was using the population-growth formula with growth parameter set to 0.3 per 365 days. Why would bank interest be more relevant?
Swerdna |
lol, I think you're overcomplicating it somewhat. It's a simple algorithm.
Value N grows by X% per year over Y years...
In pseudocode:
Code:
int value = N
const rate = X
const years = Y
for (i = 1 to years)
value = value+((value*rate)/100)
next i
return value
As you're looking at a timescale measured in years, you dont need to worry about numbers of days.