Nominal Interest¶
So far, what we have called the annual effective interest rate is also called the APY, or annual percentage yield. However, in practice, banks often quote what is called the annual percentage rate (APR), which is not the same thing as the APY.
For example, the bank might quote something like an APR of 6% compounded twice a year. In reality, this means that after 6 months of opening an account, each dollar is compounded at %6 / 2 = 3%, and then compounded again at the same rate after another 6 months:
Which is equivalent to an APY of 6.09%.
This concept is generalized in interest theory with a term called the nominal interest rate. We denote this rate as compounded times per year. For example, an APR of 6% compounded twice per year is the same as a nominal interest rate of compounded times per year. In each period, money grows at a factor of:
The nominal and effective interest rates are related by the following equations:
Examples¶
Now that we’ve introduced the concept of nominal interest, we can demonstrate how to define a nominal interest rate by using TmVal’s Rate
class by setting the pattern
argument. Nominal interest is one of the valid patterns that you can provide to Rate
.
Let’s define a nominal interest rate of 6%, compounded twice per year.
In [1]: from tmval import Rate
In [2]: nom = Rate(
...: rate=.06,
...: pattern="Nominal Interest",
...: freq=2
...: )
...:
In [3]: print(nom)
Pattern: Nominal Interest
Rate: 0.06
Compounding Frequency: 2 times per year
We can also demonstrate some more interesting rate conversions than we had previously. What annual effective interest rate is equivalent to a nominal interest rate of 6%, compounded twice per year?
In [4]: i = nom.convert_rate(
...: pattern="Effective Interest",
...: interval=1
...: )
...:
In [5]: print(i)
Pattern: Effective Interest
Rate: 0.060899999999999954
Unit of time: 1 year
Let’s do the reverse to confirm that it’s working:
In [6]: nom2 = i.convert_rate(
...: pattern="Nominal Interest",
...: freq=2
...: )
...:
In [7]: print(nom2)
Pattern: Nominal Interest
Rate: 0.06000000000000005
Compounding Frequency: 2 times per year
There are some shortcut aliases that you can provide to the pattern
argument to shorten the amount of typing you need to do. One of them is ‘apr,’ if you are more comfortable using calling a nominal interest rate the annual percentage rate:
In [8]: nom3 = Rate(
...: rate=.06,
...: pattern='apr',
...: freq=2
...: )
...:
In [9]: print(nom3)
Pattern: Nominal Interest
Rate: 0.06
Compounding Frequency: 2 times per year