I have read the documentation on the topic but still don't get how I can calculate the current DAI Savings Rate myself.
dsr value is stored in the pot contract. At time of this writing it amounts to
1000000000000000000000000000. I think I have to divide this value by the
RAY, which is a
1 followed by 27 zeroes (
1000000000000000000000000000). So the
RAY are equal at the moment.
Next, I have to take the result of this operation (which is 1) and power it to the number of seconds per year (
31536000). Obviously this equals to 1 again. So does this mean the current rate is set to 1 percent? It should really amount to zero at the moment.
Another problem I have with this calculation is that once the
dsr changes to a weird value, then taking the power of seconds per year might take a really long time to calculate.
Where is my mistake here?