Can anyone solve this recurrence equation?

79 Views Asked by At

I would like to model compound interest where in each period part of the existing capital can be used to increase the annual interest rate. At first I tried to model this in a way such that in each step the optimal amount of capital would be used to increase the rate, but the equations quickly became exceedingly complex, so now I am trying to model the case where a percentage is fixed beforehand and in each period that percentage of capital is used to increase the rate, so

$x[t]:=x[t-1]*(1+\frac{r+ab\sum_{i=0}^{t-1} x[i]}{t_{max}})-bx[t-1]$

where $x[k]$ is the amount of capital at step $k$, $r$ is the initial rate, $a$ is some parameter regulating the efficiency with which capital can be converted into increase of interest rate, $b$ is the percentage of capital used at each step to increase the annual rate and $t_{max}$ is the amount of periods in a year, which I would ideally like to use to derive the continuous formula afterwards. Can anyone solve this?

1

There are 1 best solutions below

1
On

Some ideas.

The continuous formulation looks like

$$ \dot x = \left(\frac{r+ab\int_0^t x(\tau)d\tau}{t_{max}}-b\right)x $$

or

$$ \frac{d}{dt}\ln x = \left(\frac{r+ab\int_0^t x(\tau)d\tau}{t_{max}}-b\right) $$

or

$$ x = C_0 e^{\left(\frac{r}{t_{max}}-b\right)t}e^{\int_0^t\left(\frac{ab\int_0^{\tau} x(\eta)d\eta}{t_{max}}\right)d\tau} $$

Now calling $\gamma = C_0$ this integral equation can be solved iteratively because it is a contraction then the sequence

$$ x_0(t) = x^0\\ x_{k+1}(t) = \gamma e^{\left(\frac{r}{t_{max}}-b\right)t}e^{\int_0^t\left(\frac{ab\int_0^{\tau} x_k(\eta)d\eta}{t_{max}}\right)d\tau} $$

converges to a fixed function.

Attached a MATHEMATICA script showing the convergence

a = 1; tmax = 20; b = 2/tmax; r = 1;
x0 = 1;
gamma = 1;
Itera[x_, t_, tmax_] := Module[{f, f1, f2}, 
    f = FunctionInterpolation[x, {t, 0., tmax}]; 
    f1 = Integrate[f[t], t];
    f2 = Integrate[f1, t];
    Return[Exp[-(b - r/tmax) t] Exp[a b/tmax f2]]
]
x1 = gamma Itera[x0, t, tmax];
x2 = gamma Itera[x1, t, tmax];
x3 = gamma Itera[x2, t, tmax];
x4 = gamma Itera[x3, t, tmax];
Plot[{x0, x1, x2, x3, x4}, {t, 0, tmax}]

enter image description here