Financial Mathematics 1 - Midterm Review
Instructor: Dr. Le Nhat Tan
1 Theory of Interest
1.1 Present & Future Values
Suppose you borrow a bank $\(P\) with the annual interest rate (discount rate) \(r\) of \(k\) periods per year. Denote \(\textrm{FV}_n\) the future value of this loan \(n\) periods from now, then:
- If the interest is simple, then \[\textrm{FV}_n=P\cdot\left(1+\frac{r}{k}\cdot n\right).\]
- If the interest compounds periodically, then \[\textrm{FV}_n=P\cdot\left(1+\frac{r}{k}\right)^n.\]
- If the interest compounds continuously, then \[\textrm{FV}_n=P\cdot e^{r\cdot n/k}.\]
1.2 Investment Analysis
Consider an investment of outlay (required capital) \(C_0\) that generates a stream of cashflows (without reinvestment) \(C_1,...,C_n\) in the next \(n\) year. Assume that other similar investments have the annually compounded interest rate \(r.\)
Its present value is given by \[\textrm{PV}=\sum_{i=1}^n\frac{C_i}{(1+r)^i}\] while its net present value is given by \[\textrm{NPV}=\textrm{PV}-C_0.\] We should invest in this investment if and only if \(\textrm{NPV}>0.\)
Its internal rate of return \(r_{\textrm{IRR}}\) should solves the equation \[C_0=\sum_{i=1}^n\frac{C_i}{(1+r_{\textrm{IRR}})^i}.\] We should invest in this investment if and only if \(r_{\textrm{IRR}}>r.\)
In comparison between multiple investments, we should invest in the one having the highest IRR/NPV.
2 Fixed Income Analysis
2.1 Annuity - Perpetuity
Annuity, in general, is a series of periodic payment $\(K\) made over \(n\) next periods, with the corresponding interest rate \(r\) compounded \(m\) times per year. Assume that a year has \(p\) periods, then the present value (before the occurrence of the first payment) of this annuity is given by \[\textrm{PV}=\sum_{i=1}^n\frac{K}{\left(1+r/m\right)^{i\cdot m/p}}\] while its future value (at the occurrence of the last payment) is given by \[\textrm{FV}=\textrm{PV}\cdot\left(1+\frac{r}{m}\right)^{n\cdot m/p}=\sum_{i=1}^nK\cdot\left(1+\frac{r}{m}\right)^{(n-i)\cdot m/p}.\] If \(n=\infty,\) then this annuity is called a perpetuity with the present value \[\textrm{PV}=\sum_{i=1}^{\infty}\frac{K}{\left(1+r/m\right)^{i\cdot m/p}}=\frac{K}{(1+r/m)^{m/p}-1}.\]
2.2 Loan Payment
Assume we admit an \(n-\)year mortgage of $\(B\) with periodic payment $\(P\) of \(k\) times per year. The annual interest rate is \(r,\) compounded \(m\) times per year.
- \(B\) and \(P\) must satisfy the equation \[B=\sum_{i=1}^{n\cdot k}\frac{P}{(1+r/m)^{i*m/k}}.\]
- The \(q^{\textrm{th}}\) unpaid loan balance is \[B_q=\sum_{i=1}^{n\cdot k-q}\frac{P}{(1+r/m)^{i*m/k}}\] which implies the \(q^{\textrm{th}}\) interest payment \[I_q=B_{q-1}\cdot\left(\sqrt[k]{(1+r/m)^m}-1\right)\] and the \(q^{\textrm{th}}\) principal payment \(P-I_q.\)
2.3 Bond Evaluation
Consider a coupon bond of \(n\) years to maturity with coupon rate \(c\) and face value \(F.\) Assume coupon payments are made \(p\) times annually.
If \(c=0,\) then the bond is called a zero-coupon bond.
If the interest rate p.a. is \(r\) compounded \(k\) times annually, then the bond’s price is the present value of all its generated cashflows: \[P(r)=\sum_{i=1}^{p\cdot n}\frac{c\cdot F/p}{(1+r/k)^{i\cdot k/p}}+\frac{F}{(1+r/k)^{n\cdot k}}.\]
Assume that the bond’s current price is \(P_0,\) its yield to maturity \(y\) is precisely the internal rate of return derived from considering an investment of buying that bond, i.e. \(y\) solves the equation \(P_0=P(y).\)
Assume that the bond yield \(y\) changes by a quantity \(\Delta y,\) then we derive the corresponding bond duration \[D=\frac{P(y-\Delta y)-P(y+\Delta y)}{2\cdot P(y)\cdot\Delta y}\] which then can be used to estimate the change in price as \[\frac{P(y-\Delta y)-P(y)}{P(y)}\approx-\frac{P(y+\Delta y)-P(y)}{P(y)}\approx D\cdot\Delta y.\] We can also derive the corresponding bond convexity \[C=\frac{P(y+\Delta y)+P(y-\Delta y)-2\cdot P(y)}{P(y)\cdot(\Delta y)^2}\] which gives better estimations for price change as \[\frac{P(y-\Delta y)-P(y)}{P(y)}\approx D\cdot\Delta y+0.5\cdot C\cdot(\Delta y)^2.\] and \[\frac{P(y+\Delta y)-P(y)}{P(y)}\approx-D\cdot\Delta y+0.5\cdot C\cdot(\Delta y)^2.\]
3 Capital Allocation
- Consider four investment projects as follows:
| Project | Expected Cashflow | Standard Deviation |
|---|---|---|
| A | 4200 | 3894 |
| B | 7000 | 1449 |
| C | 70000 | 14491 |
| D | 7000 | 1183 |
The coefficient of variation of each project is given by \[\left(\frac{3894}{4200},\frac{1449}{7000},\frac{14491}{70000},\frac{1183}{7000}\right)\approx(0.927,0.207,0.207,0.169)\] so project \(D\) is least risky and project \(A\) is riskiest.
- Consider a number of promising projects, which can either be chosen to invest or not, as follows:
| Project | 1 | 2 | 3 | 4 |
|---|---|---|---|---|
| Outlay 1 | 90 | 80 | 50 | 20 |
| Outlay 2 | 58 | 80 | 100 | 64 |
| NPV | 150 | 200 | 100 | 100 |
If budgets of $200 and $250 is available for the first and second year, then the decision yielding the maximum profit is the solution to the ILP \[\begin{matrix}\textrm{maximize} & 150x_1+200x_2+100x_3+100x_4\\\textrm{subject to} & 90x_1+80x_2+50x_3+20x_4\leq200\\& 58x_1+80x_2+100x_3+64x_4\leq250\\& x_i\in\left\{0,1\right\},i=\overline{1,4}\end{matrix}\]
my.lp = make.lp(0, 4)
lp.control(my.lp, sense = 'max')
set.objfn(my.lp, c(150, 200, 100, 100))
add.constraint(my.lp, c(90, 80, 50, 20), '<=', 200)
add.constraint(my.lp, c(58, 80, 100, 64), '<=', 250)
set.type(my.lp, 1:4, 'binary') #integer
solve(my.lp)
get.objective(my.lp)
get.variables(my.lp)- Suppose that you own both a lake and a fishing boat, and have three seasons (each season is a year) to fish. Each season you decide either to fish or not to fish. If you do not fish, the population will double by the start of the next season. If you do fish, you will extract 70% of the population. The fish will reproduce, and the population of the next season will be the same as the current season. The initial population is 10 tons. Your profit is $1 per ton. The interest rate is constant at 25% p.a. To maximize the profit, which of those seasons should you fish?
\[P_{13}=\max(0,28)=28,P_{23}=\max(0,14)=14,P_{33}=7\] \[P_{12}=\max\left(\frac{P_{13}}{1+0.25},14+\frac{P_{23}}{1+0.25}\right)=25.2\] \[P_{22}=\max\left(\frac{P_{23}}{1+0.25},7+\frac{P_{33}}{1+0.25}\right)=12.6\] \[P_1=\max\left(\frac{P_{12}}{1+0.25},7+\frac{P_{22}}{1+0.25}\right)=20.16.\] Thus the optimal profit is 20.16, and we should fish in seasons 2 and 3.
4 Portfolio Analysis
Suppose we invest $\(X\) in \(n\) assets of price \(S_1,...,S_n\) with corresponding amount \(X_1,...,X_n\) in the sense that \[X=\sum_{i=1}^nX_i.\]
The weight vector of this portfolio is \[\omega=(\omega_1,...,\omega_n)=\left(\frac{X_1}{X},...,\frac{X_n}{X}\right).\]
Let \(r_i\) be the (rate of) return on asset \(i,\) then the portfolio return is \[r=\sum_{i=1}^nr_i\omega_i.\]
If \(\omega=(\alpha,1-\alpha),\) i.e. there are two assets only, then with further assumptions that the assets have return volatilites \(\sigma_1,\sigma_2\) and correlation \(\rho_{12}\) we obtain the variance of portfolio return as \[\sigma^2=\alpha^2\cdot\sigma_1^2+(1-\alpha)^2\cdot\sigma_2^2+2\alpha(1-\alpha)\cdot\sigma_1\cdot\sigma_2\cdot\rho_{12}.\]
With the above assumption and short sell is not permitted, the portfolio of minimum variance is the optimal solution of the quadratic program \[\begin{matrix}\textrm{minimize} & -d^Tb+b^TDb/2\\\textrm{subject to} & A^Tb\geq b_0\end{matrix}\] where \[\omega=\begin{pmatrix}\alpha\\1-\alpha\end{pmatrix},b_0=\begin{pmatrix}1\\0\\0\end{pmatrix},d=\begin{pmatrix}0\\0\end{pmatrix},\] \[D=\begin{pmatrix}\sigma_1^2 & \rho_{12}\sigma_1\sigma_2\\\rho_{12}\sigma_1\sigma_2 & \sigma_2^2\end{pmatrix},A=\begin{pmatrix}1 & 1 & 0\\1 & 0 & 1\end{pmatrix}.\] If short sell is permitted, we make the adjustments \[A=\begin{pmatrix}1 & 0 & 0\\1 & 0 & 0\end{pmatrix}.\] An alternative approach is to determine the critical points of \(\sigma^2,\) which should be considered as a function of \(\alpha.\)
Dmat = matrix(c(0.04, 0.0108, 0.0108, 0.0324), 2, 2)
dvec = c(0, 0)
Amat = matrix(c(1, 1, 1, 0, 0, 1), 2, 3)
b0 = c(1, 0, 0)
n.eqs = 1 # no constraint is equality
result = solve.QP(2 * Dmat, dvec, Amat, bvec = b0, meq = n.eqs)
min_var_port = result$solution