Why does compound interest usually have an $\frac{r}{n}$ term? I assume discrete time. Suppose I start with some amount of money $P_{0}$. Then, using a simple rate of interest $r$ for a given period of time, I would have
$$P_{t}= P_{0} (1+r)^{t}$$
Suppose $t$ represents years. Now, suppose I want the payments to happen more frequently, say $n$ times a year, but I want $t$ to still represent years. Then I can model the amount I get paid as
$$P_{t}= P_{0} (1+r)^{nt}$$
This model can't be right however because, as one user pointed out, as $n\rightarrow \infty$, then $P_{t} \rightarrow \infty$.
We want
\begin{align*}
t\rightarrow \infty &\Rightarrow P_{t} \rightarrow \infty\\
n\rightarrow \infty &\Rightarrow P_{t} \text{ converges to some limit}
\end{align*}
Ok, so we need a way to make it such that the limit exists as $n\rightarrow \infty$ and that necessitates adding a term $f(n)$ such that
$$P_{t}= P_{0} \left(1+\frac{r}{f(n)}\right)^{nt}$$
Why does compound interest typically involve a $f(n)=n$? I know the reason why we need $f(n)$ to have certain properties like $f(n)=n$ is because the purpose of this is to reduce the interest rate to prevent the infinity stated earlier.  But I don't get why that needs to take the form of $f(n)=n$ specifically as opposed to some general class of functions $f(n)$, where they could have certain restrictions to give the derivatives properties similar to the usual formula.
I also recognize that by choosing to use $f(n)=n$, then in the limit, we have the continuous case of $P_t = P_0 \cdot e^{rt}$. But that doesn't change the fact there could be many compound interest formulas for the discrete case, even if most can't be made into a continuous version.
Is the choice of $f(n)=n$ just by convention or is there a reason for this choice?
 A: In principle you could put any function $f(n)$ anywhere you like. The bank is allowed to pay interest according to any rule that it's willing to explain to confused clients. But using $\frac rn$ isn't arbitrary: it comes out of some generalizations of simple ideas about interest payments.

The idea is that - at least in principle - the number of payments per year doesn't have to match the number of times the interest is compounded (that is, the number of times the payment is adjusted).
Let's suppose we're looking at $t=1$ year (for simplicity) with $r$ annual interest. You go from $P_0$ to $P_1$ by receiving a payment of $r P_0$ at the end of the year, for a total of $P_0 (1+r)$.
You could say that you want to be paid more often than that. "Okay!" says the bank.  "We will give you $rP_0$ in monthly installments." So you instead go from $P_0$ to $P_1$ by receiving $12$ payments of $\frac r{12} P_0$.
It's likely that you take the first month's interest payment and put it in the bank along with your original balance. You might then complain that on the second month, you're getting a payment of only $\frac r{12}P_0$, based only on the initial amount $P_0$ that you put in - but at that point, you've already had $(1 + \frac r{12})P_0$ sitting in your account for a whole month! Shouldn't that be taken into consideration, too?
Of course, the bank doesn't have to listen to you. But if they decide to be nice to you (maybe because the other banks are also being nice, and they don't want to lose you as a client), they'll say "Okay! Each time we make a monthly payment, we'll also adjust the next payment to take your new balance into account." At the end of the second month, they pay you $\frac{r}{12}$ of $(1 + \frac r{12})P_0$, bringing your total balance to $(1 + \frac r{12})^2 P_0$.
And if this keeps going for the whole year, then you'll end the year with $P_1 = (1 + \frac r{12})^{12} P_0$ in your bank account.
The result, of course, is that the whole thing is a fancy and confusing way of getting a yearly interest of $r' =  (1 + \frac r{12})^{12}  - 1$. But this is the way that originally made sense to people as the process of paying interest was being developed.
The formula generalizes to $P_1 = (1 + \frac rn)^n P_0$ if we divide the year up into $n$ time periods, and it generalizes to $P_t = (1 + \frac rn)^{nt} P_0$ if we keep going for $t$ years.
A: 
Now, suppose I want the payments to happen more frequently, say $n$
times a year, but I want $t$ to still represent years. Then I can model the amount I get paid as $P_{t}= P_{0} (1+r)^{nt}$

No you cannot. As $n \rightarrow \infty$, the amount $P_t$ also tends to infinity. It means that it is not a right model. If you are paid $n$ times a year, $r$ must also depend on $n$.
If you want to accumulate the yearly interest $r$ in $n$ installments, each installment shall yield $\frac{r}{n}$ interest.
