Posts

NUS-ECON320 Inter-Temporal Choice

Last edited: August 8, 2025

We want to construct a combined agent

\begin{equation} (k_1+k_2)x^{*}(k_1+k_2, \gamma^{*}) = x^{*}(k_1,\gamma_{1})k_1+x^{*}(k_2, \gamma_{2})k_2 \end{equation}

which combines the relative risk of \(\gamma_{1}, \gamma_{2}\) into some new \(\gamma^{*}\), which produces the same combined consumption of both agents \(k_1+k_2\).

Let us create some CAS tools to solve the inter-temporal choice problem generically for 10 steps in the past.

We do this by solving backwards. We will create a variable \(k\) to measure asset, and \(k_{t}\) the remaining asset at time \(t\).

NUS-ECON320 Linearity Tests

Last edited: August 8, 2025

Let’s begin. We want to create test for the linearity of a few assets, for whether or not they follow the CAPM.

Note that we will be using the Sharpe-Linter version of CAPM:

\begin{equation} E[R_{i}-R_{f}] = \beta_{im} E[(R_{m}-R_{f})] \end{equation}

\begin{equation} \beta_{im} := \frac{Cov[(R_{i}-R_{f}),(R_{m}-R_{f})]}{Var[R_{m}-R_{f}]} \end{equation}

Recall that we declare \(R_{f}\) (the risk-free rate) to be non-stochastic.

Let us begin. We will create a generic function to analyze some given stock.

We will first import our utilities

NUS-ECON320 Stochastic Integration

Last edited: August 8, 2025

The code created for this problem can be found here.

Problem 1

Let’s begin with a normal function:

\begin{equation} f(x) = (\sqrt{x}-1)^{2} \end{equation}

Taking just a normal Riemann sum, we see that, as expected, it converges to about \(0.167\) by the following values between bounds \([0,1]\) at different \(N\):

NValue
100.23
1000.172
10000.167
100000.167
1000000.167

Problem 2

First, as we are implementing a discrete random walk, here’s a fun example; \(p=0.51\), \(\epsilon=0.001\).

NUS-ECON320 Volatility Hedging

Last edited: August 8, 2025

Let \(X\) denote price and \(Y\) denote volatility. The two objects obey the following process:

\begin{equation} \begin{cases} \dd{X} = \mu X \dd{t} + XY \dd{W} \\ \dd{Y} = \sigma Y \dd{B} \end{cases} \end{equation}

where, \(W\) and \(B\) are correlated Brownian motions with correlation \(\rho\) — \(E[(\dd{W})(\dd{B})] = \rho \dd{t}\).


Let’s work with \(Y\) first. We understand that \(Y\) is some continuous variable \(e^{a}\). Therefore, \(\dv{Y}{t}=ae^{a}\). Therefore, \(dY = ae^{a}dt\). Finally, then \(\frac{\dd{Y}}{Y} = \frac{ae^{a}}{e^{a}}\dd{t} = a\).

NUS-ENG401 Childbirth

Last edited: August 8, 2025

The doctor-patient ratio in Haiti is 1 out of 67,000; a combination of malnutrition and malpractice results in a fatality rate of 47%.

In Breath, Eyes, Memory, the high rate of fatalities from birth is included as a part of a proverb in Sophie’s village. Ife tells that, of “three children” conceived by an old woman, “one dies in her body.” (Danticat 118)

Next Steps

Token: s_6285_15

Follow this link for the next step. You maybe able to continue to the next phrase of the game; it is also possible that you may have died during birth and would have to restart.