顯示具有 Black-Scholes Model 標籤的文章。 顯示所有文章
顯示具有 Black-Scholes Model 標籤的文章。 顯示所有文章

4/24/2014

[隨機分析] Black-Scholes PDE for European Call option (1)

延續上篇 [隨機分析] Black-Scholes PDE for European Call option (0),這次要來證明 Black-Scholes Formula
\[
{\scriptsize f(t,S_t) = S \Phi \left( \frac{\ln(S_t/K) + (r+\frac{1}{2} \sigma^2) (T-t) }{\sigma \sqrt{T-t}}\right) - K e^{-r (T-t)} \Phi \left( \frac{\ln(S_t/K) + (r - \frac{1}{2}\sigma^2) (T-t) }{\sigma \sqrt{T-t}}\right)}
\]其中 $\Phi (\cdot)$ 為 Standard Normal Cumulative distribution function (CDF)

現在令 $x= S_t$,上述的 Black-Scholes Formula 確實為 Black-Scholes PDE 的解,亦即上式為下列PDE的解:
\[
rf(t,x) = {f_t}(t,x) + rx{f_x}(t,x) + \frac{1}{2}{f_{xx}}(t,x){\sigma ^2}{x^2}
\]且滿足終端邊界條件 $f(T,x) = h(x), \ \forall x \in \mathbb{R}$


我們將分成下列幾個小步驟逐步完成此證明:


步驟1:首先證明下列等式成立:

Claim 1: $K e^{-r(T-t)} \Phi ' (d_2(T-t,x)) = x \Phi' (d_1(T-t,x))$
其中
\[
d_1 (T-t, x) =  \frac{\ln(x/K) + (r+\frac{1}{2} \sigma^2) (T-t) }{\sigma \sqrt{T-t}} \\
d_2 (T-t,x) =  \frac{\ln(x/K) + (r - \frac{1}{2}\sigma^2) (T-t) }{\sigma \sqrt{T-t}} \\
\]
Proof
我們證明
\[
K e^{-r(T-t)} \Phi ' (d_2(T-t,x))- x \Phi' (d_1(T-t,x))=0
\]由於 $\Phi (\cdot)$ 為 Standard Normal Cumulative distribution function (CDF) ,故 $\Phi '(\cdot)$ 即為 Standard Normal density,亦即
 \[\left\{ \begin{array}{l}
\Phi'\left( {{d_1}\left( {T - t,x} \right)} \right) = \frac{1}{{\sqrt {2\pi } }}{e^{ - \frac{{{d_1}{{\left( {T - t,x} \right)}^2}}}{2}}}\\
\Phi'\left( {{d_2}\left( {T - t,x} \right)} \right) = \frac{1}{{\sqrt {2\pi } }}{e^{ - \frac{{{d_2}{{\left( {T - t,x} \right)}^2}}}{2}}}
\end{array} \right.
\]現在觀察 $d_2(T-t,x) = d_1(T-t,x) - \sigma \sqrt{T-t}$,故直接計算
\[\begin{array}{l}
K{e^{ - r(T - t)}}\Phi '({d_2}(T - t,x)) - x\Phi '({d_1}(T - t,x))\\
 = K{e^{ - r(T - t)}}\frac{1}{{\sqrt {2\pi } }}{e^{ - \frac{{{d_2}{{\left( {T - t,x} \right)}^2}}}{2}}} - x\frac{1}{{\sqrt {2\pi } }}{e^{ - \frac{{{d_1}{{\left( {T - t,x} \right)}^2}}}{2}}}\\
 = \frac{1}{{\sqrt {2\pi } }}\left[ {K{e^{ - r(T - t)}}{e^{ - \frac{{{d_2}{{\left( {T - t,x} \right)}^2}}}{2}}} - x{e^{ - \frac{{{d_1}{{\left( {T - t,x} \right)}^2}}}{2}}}} \right]\\
 = \frac{1}{{\sqrt {2\pi } }}\left[ {K{e^{ - r(T - t)}}{e^{ - \frac{{{{\left[ {{d_1}\left( {T - t,x} \right) - \sigma \sqrt {T - t} } \right]}^2}}}{2}}} - x{e^{ - \frac{{{d_1}{{\left( {T - t,x} \right)}^2}}}{2}}}} \right]\\
 = \frac{1}{{\sqrt {2\pi } }}\left[ {K{e^{ - r(T - t)}}{e^{ - \frac{{{d_1}^2\left( {T - t,x} \right) - 2{d_1}\left( {T - t,x} \right)\sigma \sqrt {T - t}  + {\sigma ^2}\left( {T - t} \right)}}{2}}} - x{e^{ - \frac{{{d_1}{{\left( {T - t,x} \right)}^2}}}{2}}}} \right]\\
 = \frac{1}{{\sqrt {2\pi } }}{e^{ - \frac{{{d_1}{{\left( {T - t,x} \right)}^2}}}{2}}}\left[ {K{e^{ - r(T - t)}}{e^{\frac{{2{d_1}\left( {T - t,x} \right)\sigma \sqrt {T - t} }}{2}}}{e^{\frac{{ - {\sigma ^2}\left( {T - t} \right)}}{2}}} - x} \right]\\
 = \frac{1}{{\sqrt {2\pi } }}{e^{ - \frac{{{d_1}{{\left( {T - t,x} \right)}^2}}}{2}}}\left[ {K{e^{ - r(T - t)}}{e^{\frac{{\ln (x/K) + (r + \frac{1}{2}{\sigma ^2})\left( {T - t} \right)}}{{\sigma \sqrt {T - t} }}\sigma \sqrt {T - t} }}{e^{\frac{{ - {\sigma ^2}\left( {T - t} \right)}}{2}}} - x} \right]\\
 = \frac{1}{{\sqrt {2\pi } }}{e^{ - \frac{{{d_1}{{\left( {T - t,x} \right)}^2}}}{2}}}\left[ {K{e^{ - r(T - t)}}\left( {\frac{x}{K}} \right){e^{(r + \frac{1}{2}{\sigma ^2})\left( {T - t} \right)}}{e^{\frac{{ - {\sigma ^2}\left( {T - t} \right)}}{2}}} - x} \right]\\
 = \frac{1}{{\sqrt {2\pi } }}{e^{ - \frac{{{d_1}{{\left( {T - t,x} \right)}^2}}}{2}}}\left[ {{e^{ - r(T - t)}}x{e^{r\left( {T - t} \right)}} - x} \right] = 0. \ \ \ \ \square
\end{array}
\]

步驟2:證明下列Claim:
Claim 2: (Theta of the Option)
\[
{f_t}\left( {t,x} \right) =  - rK{e^{ - r(T - t)}}\Phi ({d_2}(T - t,x)) - \frac{{\sigma x}}{{2 \sqrt {T - t} }}\Phi '({d_1}(T - t,x))
\]
Proof
直接計算 $f(t,x)$ 的對 $t$ 偏導數
\[\begin{array}{l}
{f_t}(t,x) = \frac{\partial }{{\partial t}}f\left( {t,x} \right) = \frac{\partial }{{\partial t}}\left[ {x\Phi \left( {{d_1}(T - t,x)} \right) - K{e^{ - rT}}{e^{rt}}\Phi \left( {{d_2}(T - t,x)} \right)} \right]\\
 \Rightarrow {f_t}(t,x) = x\frac{{\partial \Phi }}{{\partial t}}\left( {{d_1}(T - t,x)} \right) \\
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ - K{e^{ - r(T)}}\left[ {r{e^{r(t)}}\Phi \left( {{d_2}(T - t,x)} \right) + {e^{r(t)}}\frac{{\partial \Phi }}{{\partial t}}\left( {{d_2}(T - t,x)} \right)} \right]\\
 \Rightarrow {f_t}(t,x) =  - rK{e^{ - r(T - t)}}\Phi \left( {{d_2}(T - t,x)} \right) + x\frac{{\partial \Phi \left( {{d_1}(T - t,x)} \right)}}{{\partial t}} \\
\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ - K{e^{ - r(T - t)}}\frac{{\partial \Phi \left( {{d_2}(T - t,x)} \right)}}{{\partial t}} \ \ \ \ (*)
\end{array}
\]由 Standard Normal CDF $\Phi(\cdot)$ 定義,我們可以分別計算:
\[\begin{array}{l}
\frac{{\partial \Phi \left( {{d_1}(T - t,x)} \right)}}{{\partial t}} = \frac{\partial }{{\partial t}}\left\{ {\frac{1}{{\sqrt {2\pi } }}\int_{ - \infty }^{{d_1}(T - t,x)} {{e^{\frac{{ - {z^2}}}{2}}}} dz} \right\} \\
\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \  = \frac{1}{{\sqrt {2\pi } }}\left[ {{e^{\frac{{ - {{\left( {{d_1}(T - t,x)} \right)}^2}}}{2}}}\frac{\partial }{{\partial t}}{d_1}(T - t,x)} \right]\\
\frac{{\partial \Phi \left( {{d_2}(T - t,x)} \right)}}{{\partial t}} = \frac{1}{{\sqrt {2\pi } }}\left[ {{e^{\frac{{ - {{\left( {{d_2}(T - t,x)} \right)}^2}}}{2}}}\frac{\partial }{{\partial t}}{d_2}(T - t,x)} \right]\\
\begin{array}{*{20}{c}}
{}&{}&{}&{}&{}&{}
\end{array} = \frac{1}{{\sqrt {2\pi } }}\left[ {{e^{\frac{{ - {{\left( {{d_2}(T - t,x)} \right)}^2}}}{2}}}\frac{\partial }{{\partial t}}\left[ {{d_1}(T - t,x) - \sigma \sqrt {T - t} } \right]} \right]\\
\begin{array}{*{20}{c}}
{}&{}&{}&{}&{}&{}
\end{array} = \frac{1}{{\sqrt {2\pi } }}{e^{\frac{{ - {{\left( {{d_2}(T - t,x)} \right)}^2}}}{2}}}\left[ {\frac{{\partial {d_1}(T - t,x)}}{{\partial t}} + \frac{\sigma }{{2\sqrt {T - t} }}} \right]
\end{array}
\]將上面計算出來的兩項偏導數式子帶回 $(*)$,並利用 Claim 1 的結果整理可得
\[
 \Rightarrow {f_t}(t,x) =  - rK{e^{ - r(T - t)}}\Phi \left( {{d_2}(T - t,x)} \right) \\
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ - \frac{\sigma }{{2\sqrt {T - t} }}K{e^{ - r(T - t)}}\frac{1}{{\sqrt {2\pi } }}{e^{\frac{{ - {{\left( {{d_2}(T - t,x)} \right)}^2}}}{2}}}\\
\]利用 $d_1(T-t,x) = d_2(T-t,x) - \sigma \sqrt{T-t}$,帶入上式
\[\begin{array}{l}
 \Rightarrow {f_t}(t,x) =  - rK{e^{ - r(T - t)}}\Phi \left( {{d_2}(T - t,x)} \right) \\
\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ - \frac{\sigma }{{2\sqrt {T - t} }}K{e^{ - r(T - t)}}\frac{1}{{\sqrt {2\pi } }}{e^{\frac{{ - {{\left( {{d_1}(T - t,x) - \sigma \sqrt {T - t} } \right)}^2}}}{2}}}\\
 \Rightarrow {f_t}(t,x) =  - rK{e^{ - r(T - t)}}\Phi \left( {{d_2}(T - t,x)} \right)\\
\begin{array}{*{20}{c}}
{}&{}&{}&{}&{}&{}
\end{array} - \frac{\sigma }{{2\sqrt {T - t} }}K{e^{ - r(T - t)}}\frac{1}{{\sqrt {2\pi } }}{e^{\frac{{ - {d_1}^2(T - t,x)}}{2}}}{e^{\frac{{2\sigma {d_1}(T - t,x)\sqrt {T - t} }}{2}}}{e^{\frac{{ - {\sigma ^2}\left( {T - t} \right)}}{2}}}\\
 \Rightarrow {f_t}(t,x) =  - rK{e^{ - r(T - t)}}\Phi \left( {{d_2}(T - t,x)} \right) - \frac{{\sigma x}}{{2\sqrt {T - t} }}\Phi '\left( {{d_1}(T - t,x)} \right)
\end{array}
\] $\square$

步驟3:證明下列Claim:
Claim 3: (Delta of the Option)
\[
{f_x}\left( {t,x} \right) =  \Phi ({d_1}(T - t,x))
\]
Proof
想法同Claim 2,直接計算對 $x$ 偏導數
\[\begin{array}{l}
{f_x}\left( {t,x} \right) = \frac{\partial }{{\partial x}}f(t,x) = \frac{\partial }{{\partial x}}\left[ {x\Phi \left( {{d_1}(T - t,x)} \right) - K{e^{ - r(T - t)}}\Phi \left( {{d_2}(T - t,x)} \right)} \right]\\
\begin{array}{*{20}{c}}
{}&{}&{}&{}
\end{array} = \Phi \left( {{d_1}(T - t,x)} \right) + x\frac{\partial }{{\partial x}}\Phi \left( {{d_1}(T - t,x)} \right)\\
\begin{array}{*{20}{c}}
{}&{}&{}&{}
\end{array} - K{e^{ - r(T - t)}}\frac{\partial }{{\partial x}}\Phi \left( {{d_2}(T - t,x)} \right) \ \ \ \ (**)
\end{array}
\]分別計算
\[\begin{array}{l}
\frac{{\partial \Phi \left( {{d_1}(T - t,x)} \right)}}{{\partial x}} = \frac{\partial }{{\partial x}}\left\{ {\frac{1}{{\sqrt {2\pi } }}\int_{ - \infty }^{{d_1}(T - t,x)} {{e^{\frac{{ - {z^2}}}{2}}}} dz} \right\}\\
\begin{array}{*{20}{c}}
{}&{}&{}&{}&{}&{}&{}
\end{array} = \frac{1}{{\sqrt {2\pi } }}\left[ {{e^{\frac{{ - {{\left( {{d_1}(T - t,x)} \right)}^2}}}{2}}}\frac{\partial }{{\partial x}}{d_1}(T - t,x)} \right]\\
\frac{{\partial \Phi \left( {{d_2}(T - t,x)} \right)}}{{\partial x}} = \frac{1}{{\sqrt {2\pi } }}\left[ {{e^{\frac{{ - {{\left( {{d_2}(T - t,x)} \right)}^2}}}{2}}}\frac{\partial }{{\partial x}}{d_2}(T - t,x)} \right]\\
\begin{array}{*{20}{c}}
{}&{}&{}&{}&{}&{}&{}
\end{array} = \frac{1}{{\sqrt {2\pi } }}\left[ {{e^{\frac{{ - {{\left( {{d_2}(T - t,x)} \right)}^2}}}{2}}}\frac{\partial }{{\partial x}}\left[ {{d_1}(T - t,x) - \sigma \sqrt {T - t} } \right]} \right]\\
\begin{array}{*{20}{c}}
{}&{}&{}&{}&{}&{}&{}
\end{array} = \frac{1}{{\sqrt {2\pi } }}{e^{\frac{{ - {{\left( {{d_2}(T - t,x)} \right)}^2}}}{2}}}\left[ {\frac{{\partial {d_1}(T - t,x)}}{{\partial x}}} \right]
\end{array}
\]帶回偏導式 $(**)$ 可得
\[\begin{array}{l}
{f_x}\left( {t,x} \right) = \Phi \left( {{d_1}(T - t,x)} \right) + \frac{1}{{\sqrt {2\pi } }}\left[ {x{e^{\frac{{ - {{\left( {{d_1}(T - t,x)} \right)}^2}}}{2}}}\frac{\partial }{{\partial x}}{d_1}(T - t,x)} \right]\\
\begin{array}{*{20}{c}}
{}&{}&{}&{}
\end{array} - K{e^{ - r(T - t)}}\frac{1}{{\sqrt {2\pi } }}{e^{\frac{{ - {{\left( {{d_2}(T - t,x)} \right)}^2}}}{2}}}\left[ {\frac{{\partial {d_1}(T - t,x)}}{{\partial x}}} \right]\\
 \Rightarrow {f_x}\left( {t,x} \right) = \Phi \left( {{d_1}(T - t,x)} \right)\\
\begin{array}{*{20}{c}}
{}&{}&{}&{}
\end{array} + \frac{1}{{\sqrt {2\pi } }}\left\{ {x{e^{\frac{{ - {{\left( {{d_1}(T - t,x)} \right)}^2}}}{2}}} - K{e^{ - r(T - t)}}{e^{\frac{{ - {{\left( {{d_2}(T - t,x)} \right)}^2}}}{2}}}} \right\}\left[ {\frac{{\partial {d_1}(T - t,x)}}{{\partial x}}} \right]
\end{array}
\]利用Claim 1的結果,我們可知
\[{f_x}\left( {t,x} \right) = \Phi \left( {{d_1}(T - t,x)} \right) \ \ \ \ \square
\]。

現在,由上述 Claim 2 的結果: ${f_x}\left( {t,x} \right) = \Phi \left( {{d_1}(T - t,x)} \right)$ 我們可立刻求得 $f_x(t,x)$ 對 $x$ 的二階偏導數 (Gamma of the Option):
\[{f_{xx}}\left( {t,x} \right) = \frac{{\partial \Phi \left( {{d_1}(T - t,x)} \right)}}{{\partial x}} = \frac{1}{{\sqrt {2\pi } }}\left[ {{e^{\frac{{ - {{\left( {{d_1}(T - t,x)} \right)}^2}}}{2}}}\frac{\partial }{{\partial x}}{d_1}(T - t,x)} \right]
\]由於
\[\frac{\partial }{{\partial x}}\left[ {\frac{{\ln (x/K) + (r + \frac{1}{2}{\sigma ^2})(T - t)}}{{\sigma \sqrt {T - t} }}} \right] = \frac{1}{{\sigma \sqrt {T - t} }}\frac{1}{x}
\]故
\[{f_{xx}}\left( {t,x} \right) = \frac{1}{{\sqrt {2\pi } }}\left[ {{e^{\frac{{ - {{\left( {{d_1}(T - t,x)} \right)}^2}}}{2}}}\frac{1}{{\sigma x\sqrt {T - t} }}} \right]\]

步驟4:證明下列 Claim:
Claim 4: Black-Scholes Formula satisfies Black-Scholes PDE

Proof
回憶 Black-Scholes PDE:
\[
rf(t,x) = {f_t}(t,x) + rx{f_x}(t,x) + \frac{1}{2}{f_{xx}}(t,x){\sigma ^2}{x^2}
\]現在將 Claim 2, 3 計算出來的結果 $f_t(t,x), f_x(t,x)$ 與 二階偏導數 $f_{xx}(t,x)$ 帶入PDE中
\[
rf(t,x) = {f_t}(t,x) + rx{f_x}(t,x) + \frac{1}{2}{f_{xx}}(t,x){\sigma ^2}{x^2}
\],我們得到
\[\begin{array}{l}
 \Rightarrow rf(t,x) =  - rK{e^{ - r(T - t)}}\Phi ({d_2}(T - t,x)) - \frac{{\sigma x}}{{2\sqrt {T - t} }}\Phi '({d_1}(T - t,x))\\
 \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ + rx\Phi \left( {{d_1}(T - t,x)} \right) + \frac{1}{2}\frac{1}{{\sqrt {2\pi } }}\left[ {{e^{\frac{{ - {{\left( {{d_1}(T - t,x)} \right)}^2}}}{2}}}\frac{1}{{\sigma x\sqrt {T - t} }}} \right]{\sigma ^2}{x^2}\\
 \Rightarrow f(t,x) = x\Phi \left( {{d_1}(T - t,x)} \right) - K{e^{ - r(T - t)}}\Phi ({d_2}(T - t,x))
\end{array}
\]$ \square$


步驟5:證明符合 Terminal condition:
Claim 5: $f(T,x) = h(x)$

Proof
考慮 $x>K$,我們得到
\[
\mathop {\lim }\limits_{t \to T} {d_1}\left( {T - t,x} \right) =  + \infty  \Rightarrow \mathop {\lim }\limits_{t \to T} {d_2}\left( {T - t,x} \right) =  + \infty
\]故
\[ \Rightarrow f(T,x) = S - K \ \ \ \ (1)
\]

考慮 $0<x<K$,
\[\mathop {\lim }\limits_{t \to T} {d_1}\left( {T - t,x} \right) =  - \infty  \Rightarrow \mathop {\lim }\limits_{t \to T} {d_2}\left( {T - t,x} \right) =  - \infty
\]故
\[ \Rightarrow f(T,x) = 0 \ \ \ \ (2)
\] 合併 $(1) + (2)$ 得到Terminal condition:
\[
f(T,x) = (x - K)_+ = h(x)
\] 

4/23/2014

[隨機分析] Black-Scholes PDE for European Call option (0)

這次要介紹 Black-Scholes Model for European Call option,也就是對於一個 歐式選擇權 (European Call option) 該如何為其制定價格。

由於 選擇權 本身是衍生商品的一種,也就是其本身的價值是隨某個標的資產 (Underlying asset)做變動,故如何對於此種衍生商品的做出合理的定價 (這邊所謂的合理指的是無套利機會的定價 亦即 No-arbitrage price) 就顯得相當不容易,在這邊我們考慮的是歐式股票選擇權,故其標的資產為股票,故可以想見此 European Call option 的定價在最後必定跟 股價有關,此定價公式被稱作 Black-Scholes Formula。在這邊我們需要兩種數學工具來幫助我們求解 Black-Scholes Formula:機率論隨機分析中的隨機微分方程 SDE 與 偏微分方程 PDE 求解邊界值問題



我們首先定義 $S_t$ 為在時間 $t$ 時的股價,且 $\beta_t$ 為在時間 $t$ 的債卷價格
且我們選取下列的隨機微分方程 (SDE) 來描述我們的 股價 與 債卷價格:

股票價格 模型: $dS_t = \mu S_t dt + \sigma S_t dB_t$
債卷價格 模型: $d \beta_t = r \beta_t dt$

其中 $r$ 為無風險利率(risk-free interest rate),實務上多以 LIBOR 或者 Treasury bond 的利率作為 $r$。

注意到上式中,股價模型為幾何布朗運動 (Geometric Brownian Motion),債卷模型則是一個為連續複利的確定(非隨機)過程。(WHY? 注意到債卷模型為ODE,可直接求解)
\[\begin{array}{l}
d{\beta _t} = r{\beta _t}dt \Rightarrow \int_0^t {\frac{{d{\beta _t}}}{{{\beta _t}}}}  = \int_0^t {rds} \\
 \Rightarrow \ln {\beta _t} - \ln {\beta _0} = rt\\
 \Rightarrow {\beta _t} = {\beta _0}{e^{rt}}
\end{array}
\]上述的解 $\beta_t$ 即為連續複利 在時間 $t$ 時的 債卷價格

現在,我們考慮執行價格為 $K$ 的 European Call option,且到期時間為 $T$,則在到期時的收益必須滿足
\[
h(S_T) = \max\{S_T - K, 0 \} = (S_T - K)_+
\]
基本上我們想法就是要建構一組投資組合(portfolio)使得我們的組合可以複製上述的European Call option 的到期收益 $h(S_T)$,且在到期之前不會收到/賠掉 任何資金 (維持淨現金流為零),但因為我們的股價與債卷模型都是連續時間隨機過程,故此投資組合必須隨時間不斷動態調整。

現在我們來看看該如何建構這樣的一組投資組合,
首先考慮
$a_t$ 為 在時間 $t$ 時,用來建構此組投資組合所需的 股票數量
$b_t$ 為 在時間 $t$ 時,用來建構此組投資組合所需的 債卷數量
則我們的投資組合在時間 $t$ 時的價值 $V_t$ 即為
\[
V_t = a_t S_t + b_t \beta_t
\]且此投資組合必須複製我們的European Call option 在到期時後的收益,故我們有一個terminal constraint
\[
V_T = h(S_T) = (S_T - K)_+
\]且投資組合在到期之前必須維持淨現金流為零 (no cash flow ! 透過 dynamic hedging 不斷買/賣 股票與債卷維持 no cash flow),此條件可視為在到期之前我們不斷地在進行自我融資 (self-financing),此條件可用隨機微分方程來表示:稱作 Self-financing condition
\[
dV_t = a_t dS_t + b_t d\beta_t
\]此條件加入了對於我們股票數量 $a_t$ 與 債卷數量 $b_t$ 上的限制,由上述的 terminal constraint 與 self-financing condition 我們可以求解 $a_t$ 與 $b_t$

現在注意到如果我們的投資組合的價值 $V_t$ 為時間 $t$ 與 股價 $S_t$ 的函數,可將其寫作
\[
V_t = f(t, S_t)
\]則由 Ito-formula,我們有
\[\begin{array}{l}
d{V_t} = {f_t}(t,{S_t})dt + {f_x}(t,{S_t})d{S_t} + \frac{1}{2}{f_{xx}}(t,{S_t})d{\left\langle S \right\rangle _t}\\
\begin{array}{*{20}{c}}
{}&{}
\end{array} = {f_t}(t,{S_t})dt + {f_x}(t,{S_t})\left( {\mu {S_t}dt + \sigma {S_t}d{B_t}} \right) + \frac{1}{2}{f_{xx}}(t,{S_t}){\sigma ^2}{S_t}^2dt\\
\begin{array}{*{20}{c}}
{}&{}
\end{array} = \left[ {{f_t}(t,{S_t}) + {f_x}(t,{S_t})\mu {S_t} + \frac{1}{2}{f_{xx}}(t,{S_t}){\sigma ^2}{S_t}^2} \right]dt + \sigma {S_t}{f_x}(t,{S_t})d{B_t}
\end{array}
\]但是我們由 Self-financing condition 可知
\[\begin{array}{l}
d{V_t} = {a_t}d{S_t} + {b_t}d{\beta _t}\\
\begin{array}{*{20}{c}}
{}&{}
\end{array} = {a_t}\left( {\mu {S_t}dt + \sigma {S_t}d{B_t}} \right) + {b_t}\left( {r{\beta _t}dt} \right)\\
\begin{array}{*{20}{c}}
{}&{}
\end{array} = \left( {{a_t}\mu {S_t} + {b_t}r{\beta _t}} \right)dt + {a_t}\sigma {S_t}d{B_t}
\end{array}
\]由 Ito formula 所求得的 $dV_t$ 必與上式相等,故比較係數可得 $a_t$ 與 $b_t$
\[\begin{array}{l}
\left\{ \begin{array}{l}
\sigma {S_t}{f_x}(t,{S_t}) = {a_t}\sigma {S_t}\\
{f_t}(t,{S_t}) + {f_x}(t,{S_t})\mu {S_t} + \frac{1}{2}{f_{xx}}(t,{S_t}){\sigma ^2}{S_t}^2 = {a_t}\mu {S_t} + {b_t}r{\beta _t}
\end{array} \right.\\
 \Rightarrow \left\{ \begin{array}{l}
{a_t} = {f_x}(t,{S_t})\\
{b_t} = \frac{1}{{r{\beta _t}}}\left[ {{f_t}(t,{S_t}) + \frac{1}{2}{f_{xx}}(t,{S_t}){\sigma ^2}{S_t}^2} \right]
\end{array} \right.
\end{array}
\]再者,由於我們的投資組合的價值 $V_t = f(t, S_t)$ (由Ito-formula) 且 $V_t = a_t S_t + b_t \beta_t$ (由 $V_t$ 定義),故此兩者亦相等,我們得到
\[\begin{array}{l}
{V_t} = {a_t}{S_t} + {b_t}{\beta _t} = f(t,{S_t})\\
 \Rightarrow f(t,{S_t}) = {f_x}(t,{S_t}){S_t} + \frac{1}{{r{\beta _t}}}\left[ {{f_t}(t,{S_t}) + \frac{1}{2}{f_{xx}}(t,{S_t}){\sigma ^2}{S_t}^2} \right]{\beta _t}\\
 \Rightarrow f(t,{S_t}) = {f_x}(t,{S_t}){S_t} + \frac{1}{r}\left[ {{f_t}(t,{S_t}) + \frac{1}{2}{f_{xx}}(t,{S_t}){\sigma ^2}{S_t}^2} \right]\\
 \Rightarrow rf(t,{S_t}) = r{f_x}(t,{S_t}){S_t} + {f_t}(t,{S_t}) + \frac{1}{2}{f_{xx}}(t,{S_t}){\sigma ^2}{S_t}^2
\end{array}
\]現在如果我們把 $S_t$ 用 $x$ 取代,則我們得到 Black-Scholes PDE:
\[
rf(t,x) = {f_t}(t,x) + rx{f_x}(t,x) + \frac{1}{2}{f_{xx}}(t,x){\sigma ^2}{x^2}
\]且有終端邊界條件 $f(T,x) = h(x), \ \forall x \in \mathbb{R}$

如果我們對 Black-Scholes PDE + 上述的終端邊界條件 求解 (借助PDE的 Diffusion equaiton),即會得到大名鼎鼎的 Black-Scholes Formula。亦即 European call option 在 時間 $t$ 時候的價格 $C_t = f(t,x)$ 可由下式求得
\[
{\small C_t = S \Phi \left( \frac{\ln(S/K) + (r+\frac{1}{2} \sigma^2) \tau }{\sigma \sqrt{\tau}}\right) - K e^{-r \tau} \Phi \left( \frac{\ln(S/K) + (r - \frac{1}{2}\sigma^2) \tau }{\sigma \sqrt{\tau}}\right)}
\]其中 $S$ 為當前股價,$T$ 為到期時間,$K$ 為執行價格,,$r$ 為無風險利率, $\sigma$ 為股價波動度,$\Phi(\cdot)$ 為 Standard normal cdf,$\tau$ 為到期之前的 剩餘時間,亦即 $\tau = T-t$

延伸閱讀
[隨機分析] Black-Scholes PDE for European Call option (1)

ref:
J. M. Steele, Stochastic Calculus and Financial Applications, Springer

5/11/2011

[衍生商品] 希臘值與動態避險 (2) - Gamma and Gamma Neutrality


延續上篇 [衍生商品] 希臘值與動態避險 (1)-Delta Hedging Example ,這次要介紹 希臘值 Gamma: $\Gamma$,此參數定義為
\[
\Gamma := \frac{\partial^2 f}{\partial S^2}
\] 亦即為標的資產價格 $S$ 的二次偏導數。

注意到之前我們定義過 $\Delta := \frac{\partial f}{\partial S}$,故 $\Gamma$ 可視為選擇權 $\Delta $ 的變化 與 標的資產價格 $S$ 變化的比率。

Comment
1. 當 $\Gamma $ 很小的時候,表示 $\Delta$ 變化緩慢 (stable $\Delta$) (亦即對標的資產價格變動不敏感),故此時對於 $\Delta$-Hedging 所需的 Rebalance 不需太過頻繁。但是若 $\Gamma$ 很大的時候,表示 $\Delta$ 變化劇烈,亦即對標的資產價格變動非常敏感,故此時 $\Delta$-Hedging 需要頻繁的做 Rebalance 來確保 Delta-Neutral ($\Delta =0$)。

2. 如果考慮的是一個 選擇權交易組合的 $\Gamma$,則其定義為
\[
\Gamma := \frac{\partial^2 \Pi}{\partial S^2}
\] 其中 $\Pi$ 為選擇權交易投資組合的價格。

假定且我們假設 標的資產的波動度為 Constant,則投資組合的價格為資產價格 $S$ 與 時間 $t$ 的函數,亦即我們可對 $\Delta \Pi$ 做泰勒展開求資產價格的變化
\[
\small{\Delta \Pi  = \underbrace {\frac{{\partial \Pi }}{{\partial S}}}_\Delta \Delta S + \underbrace {\frac{{\partial \Pi }}{{\partial t}}}_\Theta \Delta t + \frac{1}{2}\underbrace {\frac{{{\partial ^2}\Pi }}{{\partial {S^2}}}}_\Gamma \Delta {S^2} + \frac{1}{2}\frac{{{\partial ^2}\Pi }}{{\partial {t^2}}}\Delta {t^2} + \frac{1}{2}\frac{{{\partial ^2}\Pi }}{{\partial S\partial t}}\Delta S\Delta t + ...
}\]其中 $\Delta \Pi$ 與 $\Delta S$ 為 很小的時間區間 $\Delta t$ 內投資組合的價格與股票價格的變化。

現在如果此 投資組合為 Delta-Neutral,亦即 $\Delta=0$,且我們忽略高階項的效果,則上述泰勒展開可改寫為
\[\Delta \Pi  \approx \Theta \Delta t + \frac{1}{2}\Gamma \Delta {S^2} \ \ \ \ (*)
\]
下圖展示了 Delta Neutral 的投資組合 $\Delta \Pi$ 與 $\Delta S$的關係。


上圖顯示了如果是 Long option (則此時標的股價上升則投資組合價格跟著上升),則 $\Gamma >0, \Theta <0$
如果是 Short option ,則 $\Gamma <0, \Theta >0$

3. 對於 European Call option 與 European Put option,B-S formula 可直接求得 $\Gamma$ 的解析式如下:
\[
\Gamma  = \frac{{N'\left( {{d_1}} \right){e^{ - qT}}}}{{{S_0}\sigma \sqrt T }}
\] 其中 $N'(\cdot)$ 為 Standard Normal density function。
\[N'\left( {{d_1}} \right) = \frac{1}{{\sqrt {2\pi } }}{e^{\frac{{ - d_1^2}}{2}}}\]

現在我們看個例子:

=============================

Example (Gamma Neutrality)
假定某標的資產投資組合為 Delta Neutral,其對應的 Gamma 值為 $-10000$,現在假設標的資產價格 $\Delta S$ 在短時間內變化為 $+2$ 或者 $-2$ (假設短時間 $\Delta t \approx 0$),則交易組合的價值變動為何?

============================

Solution
由於此投資組合已經為 Delta Neutral,故 $\Delta =0$,我們可利用之前推導的結果: $(*)$
\[\begin{array}{l}
\Delta \Pi  \approx \Theta \Delta t + \frac{1}{2}\Gamma \Delta {S^2}\\
 \Rightarrow \Delta \Pi  \approx 0 + \frac{1}{2}\left( { - 10000} \right){\left( 2 \right)^2} = -20000
\end{array}\]亦即交易組合價值下跌 $20000$ 元。 $\square$

再者我們介紹如何使投資組合進一步具備 Gamma Neutral 的特性

Gamma Hedging and Gamma Neutral
假定一個 Delta Neutral 的投資組合的Gamma 值為 $\Gamma$,而某交易所的交易選擇權的Gamma 值為 $\Gamma_T$,現若決定將 $w_T$ 數量的選擇權加入到原本的投資組合中,則新的投資組合的 Gamma 值為 $\Gamma^*$
\[
\Gamma^* =\Gamma + w_T \Gamma_T
\]故如果我們要使投資組合為 Gamma-Neutral,亦即 $ \Gamma^* =0$則我們需用
\[\begin{array}{l}
{\Gamma ^*} = \Gamma  + {w_T}{\Gamma _T} = 0\\
 \Rightarrow {w_T} =  - \frac{\Gamma }{{{\Gamma _T}}}
\end{array}
\] 亦即須增加/減少 $w_T$ 個選擇權,但注意到當我們達成 Gamma Neutral 的時候,很可能會變動到原本的 Delta,故我們需回頭調整 Delta 來保證薪投資組合除了 Gamma Netural 之外亦維持 Delta Netural。

以下我們看個例子如何同時達成 Gamma 與 Delta Neutral。

Example: Delta & Gamma Neutrality
考慮一投資組合為 Delta Neutral,且其 $\Gamma = -3000$,而對應於交易所交易的選擇權的 $\Delta = 0.62, \Gamma=1.50$,試建立一個新的 投資組合使得其 Gamma 與 Delta Neutral

Solution
STEP1 : 首先對付 Gamma
令 $w_T$ 為需交易的選擇權數量。則我們要 $\Gamma^*=\Gamma  + {w_T}{\Gamma _T} = 0$故
\[
-3000 + w_T 1.50 = 0\\
\Rightarrow {\rm{ }}{w_T}{\rm{ }} = 2000
\] 故需買入 2000 份選擇權來達成 Gamma Neutral。

STEP2: 找出 Gamma Hedging 之後的 Delta 為多少?
再者由於我們對原本 Delta Neutral 的投資組合中 加入了 2000份的選擇權,故 Delta 被更動,不再是 Delta Neutral。新的 Delta 為
\[
2000 \times 0.62 = 1240
\]亦即透過 Gamma Hedging 之後我們新的投資組合多了 $1240 $ 的 Delta

STEP3 : 對付 Delta :
由於我們多了 1240 的 Delta ,故需賣出1240股達成 $\Delta$ hedging。
(注意到賣出標的股票並不會影響 $\Gamma$ (WHY?! 因為 $\frac{\partial^2}{\partial S^2} S =0$ ) $\square$


接著我們看個稍微複雜一點的例子:

Example (Delta/Gamma Neutral via Put and Call combination )
假定某公司股價最近經歷一連串的下跌,投資者預期該公司股價將持續下跌,故決定購買 $100$ 份  執行價格為 $20$,到期時間為三個月,價格 為 0.75 元的 European Put option 來獲利。現考慮市場條件為 無風險利率 $4 \%$,當前股價為 $22$,股價波動度為 $39 \%$,且該公司不配發股息。

(a) 如果當前股價突然上漲到 $25$ 元/ 每股,則投資人所購入的 Put option 策略 賺/賠 多少?

(b) 現在假設投資者採用 Delta Hedging (在股價原本為 $22$ 的時候) 來保護其購買的 Put option 策略,那麼其淨利為何?

(c) 假設投資人決定再使用執行價格為 $20$ 到期時間為三個月的 European Call option 來達成 Delta-Gamma Neutral  (在股價原本為 $22$ 的時候)。試求投資人應如何達成此策略? 其淨利為何?

Solution (a)
改寫已知資訊如下:
\[
K=20, T=3/12, P_{S=0.22}=0.75, r=0.04, S_0=22, \sigma=0.39, q=0
\] 由於股價上漲到 $25$,故連帶的 Put option 價格也會有所變動。
透過 B-S formula 計算 股價上漲到 $25$ 元後的 Put option 價格
首先計算
\[\left\{ {\begin{array}{*{20}{l}}
{{d_1} = \frac{{\ln \left( {{S_0}/K} \right) + \left( {r - q + {\sigma ^2}/2} \right)T}}{{\sigma \sqrt T }} = 1.2931}\\
{{d_2} = {d_1} - \sigma \sqrt T {\rm{ = 1}}{\rm{.0981}}}
\end{array}} \right.\]
帶入 B-S formula:
\[\begin{array}{l}
P = K{e^{ - rT}}N\left( { - {d_2}} \right) - S{e^{ - qT}}N\left( { - {d_1}} \right)\\
 \Rightarrow P = 20{e^{ - 0.04 \times \frac{3}{{12}}}}N\left( { - 1.0981} \right) - 25N\left( { - 1.2931} \right) = 0.2488
\end{array}
\]亦即股價上漲後的 Put option price 為 $P_{S=25} = 0.2448$ 元

故可知投資人的 Put option 投資策略 淨利為
\[ (0.2448-0.75)100=-50.52 \]

Solution (b)
現在由於投資人要進行 Delta-Hedging,故我們首先必須求得 Delta 值,由題意可知我們需計算上漲前的 Delta: $\Delta_{S=22, put}$
又由於 Put option 的 Delta 為 $\Delta_{S=22, put}=-e^{-qT} N(-d_1)$,故我們計算 $d_1$ (注意! 此時的 $d_1$ 為股價上漲前的,不可直接使用 part (a) 所計算出來的結果)
\[{d_1} = \frac{{\ln \left( {22/20} \right) + \left( {0.04 - 0 + \frac{{{{\left( {0.39} \right)}^2}}}{2}} \right)\frac{3}{{12}}}}{{0.39\sqrt {3/12} }} = 0.6376
\] 故
\[
\Delta_{S=22, put}=-e^{-qT} N(-d_1) = -0.2619
\] 又由於投資人購買了 100份 Put option,故此投資組合的總 $\Delta$ 為
\[
\Delta = -0.2619 \times 100 = -26.19
\] 所以若欲獲得 Delta-Neutralality,則必須 購入 26.19 股股票。


Solution (c)
現在由於投資人要進行 Delta-Gamma Hedging,故我們首先必須先對付 Gamma:
也就是要先求得 Gamma 值,由題意可知我們需計算上漲前的 Gamma :
\[\Gamma  = \frac{{N'\left( {{d_1}} \right){e^{ - qT}}}}{{{S_0}\sigma \sqrt T }}\]
其中
\[N'\left( {{d_1}} \right) = \frac{1}{{\sqrt {2\pi } }}{e^{\frac{{ - d_1^2}}{2}}} = \frac{1}{{\sqrt {2\pi } }}{e^{\frac{{ - \left( {0.6379} \right)_{}^2}}{2}}} = 0.3255\]
將上式代入 Gamma 可得
\[\Gamma  = \frac{{N'\left( {{d_1}} \right){e^{ - qT}}}}{{{S_0}\sigma \sqrt T }} = \frac{{0.3255}}{{22\left( {0.39} \right)\sqrt {3/12} }} = 0.0759
\]注意到上式的 Gamma for put $=$ Gamma for call;亦即 $\Gamma_{call} = \Gamma_{put}$

現在我們考慮加入 $w_T$ 份 Call option,其對應的 $\Gamma_{call} = \Gamma_{put} = 0.0759$,故總 Gamma 為 原本購買 100 份 Put option 的 Gamma 加上 $w_T$ 份 Call option 的 Gamma;又因為我們要達成 Gamma Neutral,故總 Gamma 必須為零;故我們可求解到底需要多少份 call option:
\[\begin{array}{l}
\Gamma  = 0.0759 \times 100 + {w_T}0.0759 = 0\\
 \Rightarrow {w_T} =  - 100
\end{array}
\] 亦即須要賣出 100 份 Call option 即可達成 Gamma Neutral。

但由於我們更動了 Gamma,故 Delta 亦會連帶受到更動;其更動後 (賣出 100 份 Call ) 的 Delta 為
\[
\Delta = -100 e^{-qT} N(d_1) = -100 N(0.6379) = -73.82
\] 故我們需要購入 73.82 股股票 ,即可達成 Delta-Neutral。

總結 Delta-Gamma Hedging 策略 如下:
買入 100 份 Put option (原始策略)
購入 26.19 股股票 (Delta-Neutral)

賣出 100 份 Call option (透過 Call option 達成 Gamma Neutral)
購入 73.82 份 股票 (修正 Gamma Neutral所造成的 Delta 變動)

故總計為
買入 100份 Put
賣出 100份 Call
購入 26.19+73.82=100 股股票

其淨利為: (股價為 $22$ 時 Call option 價格為 $2.9530$;股價上漲到 $25$ 元的 Call option 價格為 5.4438 (此兩數值可透過 B-S model 計算而得或者 Put-call parity))
\[\underbrace {(25 - 22) \times 100}_{Long\begin{array}{*{20}{c}}
{}
\end{array}stock} + \underbrace {\left( {0.2448 - 0.75} \right) \times 100}_{Long\begin{array}{*{20}{c}}
{}
\end{array}put} - \underbrace {\left( {5.4438 - 2.9530} \right) \times 100}_{Short\begin{array}{*{20}{c}}
{}
\end{array}Call} = 0.4\]




ref: John C. Hull, Options, Futures and Other Derivatives 7th.

[衍生商品] 希臘值與動態避險 (1)-Delta Hedging Example

回憶前篇 [衍生商品] 希臘值與動態避險 (0) - Delta and Delta Neutral ,這次要介紹如何利用 $\Delta$ 進行動態避險。

回憶 $\Delta$ 定義如下:
\[
\Delta := \frac{\partial f}{ \partial S}
\]亦即表示為 選擇權價格 $f$ 對 股價 $S$ 的變化率。(由於其為一階導數,故為斜率)

現在來看個例子:

Example 1 : (Delta Hedging)

如果 $\Delta = 0.6$ 則表示當股價 些微變化 的時候,對應的選擇權價格變化大約是股價變化值 的 $60 \%$。
下圖顯示了一組 $\Delta$ 值在某時刻的例子:


考慮上圖,假設股價為 $\$ 100 $,Call option 價格為 $ c= \$ 10$,現在考慮某金融機構的交易員賣出了 $20$ 份 Call option (一份選擇權對應其持有者可以有權購買 $100$ 股,亦即 $20$ 份call option 共 $x= 20 \times 100 = 2000$ 股)。此時如果不進行避險,則當股價上升時,該交易員會暴露風險之中:

簡單的說,現在有兩個人物:
  1. 賣出 call option 的交易員
  2. 跟交易員 購買 call option 的客戶
此時客戶的 $\Delta_{Customer} =0.6$ (因為購入call option,當股價上升對顧客有利,此時 $\Delta >0$)
而交易員的 $\Delta_{trader} = -0.6$, (由於交易員是 "賣出" 選擇權,故當股票價格上升,則選擇權會被執行,此情形時將對交易員產生風險。故此 $\Delta$ 對 交易員而言是負值)

現在,站在交易員的觀點,如果不進行避險,則交易員本身的潛在損失為
\[
-0.6 \times 2000 =-1200 \ \text{shares}
\]
我們必須消除賣出 Call option所帶來的 風險,此時交易員可進行 $\Delta$-Hedging  來補足缺少的 $1200$ 股 股票。:

由於交易員是 "賣出" Call option ,故避險方法便是進行反向操作,也就是可以透過 "買入" 一定量股票來抵銷當 股價上升時,Call option 被執行所帶來的損失風險,故
購買 $\Delta \times x = 0.6 \times 2000 =1200$ 股股票

此時如果 股票上漲 $1$ 元,則交易員 買入的股票會上升 $1200$ 元 (賺 $1200$ 元),而由 圖中 $\Delta =0.6$ 可知 Call option 會上漲 $0.6$ 元,故如果此時 Call option 被持有者執行,則交易員會損失 $0.6 \times 2000 = \$ 1200$ 此數值剛好會跟交易員進行避險時候買入的股票所賺取的 $1200$ 抵銷。

相反的如果股票下跌 $1$元,則交易員 買入的股票會下跌 $1200$ 元 (損失 $1200$ 元),而由圖中 $\Delta =0.6$ 可知 Call option 亦會下跌 $0.6$ 元,此時選擇權不會被執行,則交易員因為賣出選擇權 會賺得 $ \$ 1200$ 此數值剛好會跟交易員進行避險時候賣出的股票所損失的 $1200$ 抵銷。 $\square$

Comment:
1. 注意到上述例子中,由於 $\Delta$ 會變動,故抵銷後的 $\Delta$-Hedging 只能維持一段極短時間,也就是需要不斷的調整 $\Delta$-Hedging ,此稱為 Rebalancing。一般而言,隨時間不斷調整的 避險策略 統稱為 $Dynamic Hedging$,這邊展示的是利用 $\Delta$ 進行避險

2. $\Delta$ 在 Nondividend Black-Scholes formula 中等價為 $N(d_1)$;亦即
\[
\Delta := \frac{{\partial f}}{{\partial S}} = N\left( {{d_1}} \right)
\] 其中 $N(\cdot)$ 為 Cumulative normal distribution。

3. $\Delta$ -Hedging 並非 Perfect Hedging。(WHY!? 理由同 comment 1 )

Example 2 (Delta-Hedging )
考慮 造市商(market-maker) 賣出 $K=40$ 的 call-option on 100 股 股票,且
$ \sigma=0.3$, $r=0.08 $ 連續複利
現在考慮 Day 0,$S=\$40$, $c =\$2.78$, $\Delta=0.58$
如何進行 $\Delta$-hedging?
How much cost you to create such a $\Delta$-hedging ?

現在再考慮 Day 1,$S=40.5, c= \$ 3.06$, $\Delta=0.61$
如何進行 $\Delta$-hedging?
Overnight Mark-to-market profit/loss ?

現在再考慮 Day 2,$S=39.25, c= \$2.328$, $\Delta=0.53$
Overnight Mark-to-market profit/loss ?

Solution:
考慮 時刻為 DAY 0
首先考慮不進行避險情況,market-maker 本身為 $-\Delta \times 100 = -58$,故需要補足此 $58$ 股股票,亦即需要購買 $58$ 股 股票即可達成 DAY0 $\Delta$-Hedging。

接著我們可以計算要花多少錢才可以建構此避險策略: ( 賣出選擇權 與 購入 股票之後的花費):
\[
58 \times 40 - 2.78 \times 100 = \$ 2042
\]故我們知道建構此避險策略需要花費 $\$ 2042$,故我們可借入此金額並考慮利率,亦即我們借入 $2042 \times e^{8\%/365} = 2042.45$,故利息為 $2042.45-2042=\$ 0.45$。現在總結 Day 0 如下:

購入 $58$ 股股票 達成避險,然後我們需要借入 $2042$  元 並支付利息 $0.45$ 來達成此避險策略。

接著考慮 DAY 1
此時相關資訊(股價、選擇權價格、Delta)變動為 $S=40.5, c= \$ 3.06$, $\Delta=0.61$

我們可以先行計算 Overnight mark-market profits/loss :
\[
(40.5-40) \cdot (58) - (3.06-2.78) \cdot (100) - 0.45 = 0.55
\] 由於此時 $\Delta =0.61$ 已經改變,故我們需要重新調整股票數來消除風險。
首先考慮不進行避險情況,market-maker 本身為 $-\Delta \times 100 = -61$,故需要補足此 $61$ 股股票,但由於在 DAY0 已經購入 $58$ 股,故我們只需再購買 $61-58 = 3$ 股 股票即可達成 DAY1 $\Delta$-Hedging。

現在我們來計算達成此避險策略所需的花費 (DAY1 total cost ):
\[
61 \times 40.5 - 3.06 \times 100 = 2164.5
\] 同樣地,我們可以得知需要借入 $2164.5$ 元 且須支付利息為 $2164.5e^{8\%/365} - 2164.5=0.47$

考慮 DAY2 Mark-market Profits/loss:
此時相關資訊(股價、選擇權價格、Delta)變動為 $S=39.25, c= \$2.328$, $\Delta=0.53$
\[
 (39.25-40.5) \cdot 61 - (2.328-3.06) \cdot 100 - 0.47 = -3.52 \ \ \ \ \square
\]


ref: John C. Hull, Options, Futures and Other Derivatives 7th.

4/28/2011

[衍生商品] 希臘值與動態避險 (0) - Delta and Delta Neutral

這次要介紹的是財務中的 希臘值 Greek Letters:
\[ \Delta, \Gamma, \Theta, \rho, \nu
\],上述的這些希臘字母被用作財務中衍生商品的 避險 (Hedging) 的指標。

那麼問題是這些希臘字母到底如何跟避險扯上關係呢? 這必須要回歸 Black-Scholes Formula:
\[\left\{ \begin{array}{l}
C = S{e^{ - qT}}N \left( {{d_1}} \right) - K{e^{ - rT}}N \left( {{d_2}} \right)\\
P = K{e^{ - r(T)}}N \left( { - {d_2}} \right) - S{e^{ - qT}}N \left( { - {d_1}} \right)
\end{array} \right.\]
其中 $C$ 為 Call option 價格,$P$ 為 Put Option 價格, $N(\cdot)$ 為 Standard Normal Cumulative distribution function (CDF),且\[\left\{ \begin{array}{l}
{d_1} = \frac{{\ln (S/K) + (r - q + \frac{1}{2}{\sigma ^2})(T)}}{{\sigma \sqrt T }}\\
{d_2} = {d_1} - \sigma \sqrt T
\end{array} \right.\]

觀察上述 Black-Scholes Formula,我們知道 選擇權價格 $C, P$ 可表為一個多變數的函數
\[
f(S,K,T,r,q,\sigma)
\]其中 $S$ 為現時股價,$K$ 為執行價格, $T$ 為到期時間, $r$ 為連續複利的無風險年利率, $q$ 為連續複利的年股息,$\sigma$ 為 波動度。


想法:對於 B-S formula 所求得的 $f(S,K,T,r,q,\sigma)$ 對特定參數的變動,我們用一個特定希臘字母來表示他,這些變動用來測量不同的風險:

這邊先介紹 $\Delta$
\[
\Delta := \frac{\partial f}{ \partial S}
\]亦即表示為選擇權價格對股價的變化率。(由於其為一階導數,故為斜率)

回憶先前介紹過,
對於 Long Call Position: $0 \leq \Delta \leq 1$ (Short call 則對左式同取負號)
對於 Long Put Position : $-1 \leq \Delta \leq 0$ (Short put 則對左式同取負號)

上述結果可繪製如下圖:




Comment: 
1. 如果 $\Delta =0$,則表示股票些微變化 不影響 選擇權價格。且此狀態稱為 Delta Neutral
2. $\Delta$ 在 Black-Scholes Call opton formula 中等價為 $e^{-qT}N(d_1)$;亦即
\[
\Delta := \frac{{\partial f}}{{\partial S}} = e^{-qT}N\left( {{d_1}} \right)
\] 其中 $N(\cdot)$ 為 Cumulative normal distribution。
3. 關於 Put Option 與 Call Option 的 $\Delta$ 值之間存在一固定關係,我們將此關係寫成下面的 Claim :

Claim:
對於 Call option 與 Put Option 的 $\Delta$ 有如下關係:
\[
\Delta_c - \Delta_p = e^{-qT}
\]Proof
上述關係可以很簡潔的利用 Put-Call Parity 來證明,現在回憶 Put-Call Parity 如下:
\[
C-P = Se^{-qT} - Ke^{-rT}
\]對上式兩邊取對 $S$ 偏導數 $\frac{{\partial }}{{\partial {\rm{S}}}}$:
\[\begin{array}{l}
C - P = S{e^{ - qT}} - K{e^{ - rT}}\\
 \Rightarrow \underbrace {\frac{{\partial C}}{{\partial S}}}_{{\Delta _c}} - \underbrace {\frac{{\partial P}}{{\partial S}}}_{{\Delta _p}} = {e^{ - qT}}\\
 \Rightarrow {\Delta _c} - {\Delta _p} = {e^{ - qT}}
\end{array}\] $\square$


投資組合 的 Delta 與 Superposition (Delta of Portfolio)
現在考慮 $\Pi $ 為投資組合的價值,則對單一資產 (價格為 $S$) 的 選擇權或其他衍生商品所組成的投資組合之 $\Delta$ 定義為
\[
\frac{\partial \Pi}{\partial S}
\] 投資組合的 $\Delta$ 值可由投資組合中,可先分別計算各自單一的 Options 的 $\Delta$ 值在做線性組合:亦即若考慮投資組合由數量為 $w_i$ 的選擇權所組合而成 $(1 \leq i \leq n)$ 且對應地 $i$ 個 Option 的 $\Delta$ 值為 $\Delta_i$,則此投資組合的總 $\Delta$ 值為
\[
\Delta = \displaystyle \sum_{i=1}^{n} w_i \Delta_i \ \ \ \ (*)
\]

現在我們看個例子:

Example
考慮某金融機構持有下列三種某標的資產股票:
  1. Long 100,000 call options ,執行價格為 $K=55$,到期時間 $T=3$ 個月,$\Delta=0.533$
  2. Short 200,000 Call options﹑,執行價格為 $K=56$,到期時間 $T=5$ 個月,$\Delta=0.468$
  3. Short 50,000 Call options﹑,執行價格為 $K=56$,到期時間 $T=2$ 個月,$\Delta=-0.508$

則此金融機構的總 $\Delta$ 可由 $(*)$ 計算而得
\[
\Delta = 100,000 \times 0.533 - 200,000 \times 0.468 - 50,000 \times (-0.508) = -14,900
\]亦即,如果要達到使此投資組合為 Delta Neutral,則必須 購入 $14,900$ 股 股票。

ref: John C. Hull, Options, Futures and Other Derivatives 7th.

5/12/2010

[衍生商品] 淺談 Black-Scholes Model 的性質 (1) - Equivalence of Put Call Parity and Black-Scholes Formula.

延續上篇的 Black-Scholes Model 的性質,這次要介紹 Put-Call parity 與 Black-Scholes Formula 兩者等價。

回憶 Black-Scholes Formula
\[\left\{ \begin{array}{l}
C = {S_0}N\left( {{d_1}} \right) - K{e^{ - rT}}N\left( {{d_2}} \right)\\
P = K{e^{ - rT}}N\left( { - {d_2}} \right) - {S_0}N\left( { - {d_1}} \right)
\end{array} \right.
\] 其中 $C$ 為 Call option 價格,$P$ 為 Put Option 價格,$r$ 為無風險利率,$\sigma$ 為股價波動度,$K$ 為執行價格,$T$ 為到期時間, $N(\cdot)$ 為 Standard Normal Cumulative distribution function (CDF),且\[\left\{ \begin{array}{l}
{d_1} = \frac{{\ln (S/K) + (r - q + \frac{1}{2}{\sigma ^2})(T)}}{{\sigma \sqrt T }}\\
{d_2} = {d_1} - \sigma \sqrt T
\end{array} \right.\]

與 Put-Call parity
\[C - P = {S_0} - K{e^{ - rT}}
\]
===================
Claim: 
Black-Scholes Formula 滿足 Put-Call parity。
===================

Proof
計算 $C-P$:
將 Black-Scholes Formula 的結果帶入上式,可得
\[C - P = \left[ {{S_0}N\left( {{d_1}} \right) - K{e^{ - rT}}N\left( {{d_2}} \right)} \right] - \left[ {K{e^{ - rT}}N\left( { - {d_2}} \right) - {S_0}N\left( { - {d_1}} \right)} \right] \ \ \ \ (*)
\]現在利用 Standard Normal Cumulative distribution function 的特性
\[\left\{ \begin{array}{l}
N\left( { - {d_2}} \right) = 1 - N\left( {{d_2}} \right)\\
N\left( { - {d_1}} \right) = 1 - N\left( {{d_1}} \right)
\end{array} \right.
\]我們可改寫 $(*)$ 如下
\[\begin{array}{l}
 \Rightarrow C - P = {S_0}N\left( {{d_1}} \right) - K{e^{ - rT}}N\left( {{d_2}} \right)\\
\begin{array}{*{20}{c}}
{}&{}
\end{array} - \left[ {K{e^{ - rT}} - K{e^{ - rT}}N\left( {{d_2}} \right) - {S_0} + {S_0}N\left( {{d_1}} \right)} \right]\\
 \Rightarrow C - P =  - K{e^{ - rT}} + {S_0}
\end{array}
\] 上式即為 Put-Call parity。 $\square$

4/27/2010

[衍生商品] 淺談 Black-Scholes Model 的性質 (0)

這次要跟大家介紹衍生商品市場的 Black-Scholes Model (B-S model),此 Formula 是由 Professor Fisher Black, Myron Scholes 與 Robert Merton 在選擇權定價領域的重大突破,此模型亦指引了衍生商品該如何透過無套利機會來獲得合理價格的研究大門。

事實上, B-S model 本質上是用來作為進行 歐式選擇權 (European Option) 定價公式。

在介紹之前,我們需先知道使用 B-S model 的一些假設:

對於股價分布的假設
  1. 股價服從連續複利 Log-normal 分布
  2. 波動度(Volatility)為已知常數
  3. 未來的股息已知
對於市場的假設
  1. 無交易手續費用、無稅收
  2. 證卷交易為連續進行
  3. 短期無風險利率 $r$ 為已知常數
  4. 可以基於無風險利率執行 short sell or borrow
  5. 不存在無風險套利機會 
Comment:
1. 股價的 Log-normal 分布假設: (此 Comment 需要隨機過程與隨機分析的背景知識,有興趣的讀者請參考BLOG中相關隨機分析的文章)

考慮股價模型為 Geometric Brownian Motion,故可寫做下列隨機微分方程 SDE
\[
dS_t := \mu S_t dt + \sigma S_t dB_t, \ 0 \leq t \leq T
\]其中 $S_t$ 為時刻 $t$ 的股價, $\mu :=$ 股價每年的收益率期望值 (或稱 drift rate),$\sigma:=$ 股價每年的波動度 (volatility),$B_t$ 為標準布朗運動。注意到這邊我們假設 $\mu, \sigma$ 為固定常數。

上述隨機微分方程可解得 (Proof: omitted,有興趣讀者請參閱
[隨機分析] How to solve SDE practically (4) - Geometric Brownian Motion
\[
S_t = S_0 \exp \left\{ {\left( {\mu  - \frac{{{\sigma ^2}}}{2}} \right)t + \sigma {B_t}} \right\}
\]改寫上式
\[ \Rightarrow \ln \frac{{{S_t}}}{{{S_0}}} = \left( {\mu  - \frac{{{\sigma ^2}}}{2}} \right)t + \sigma {B_t}
\]由於 $B_t$ 為標準布朗運動,由定義可知標準布朗運動為 Gaussian process with mean 0, variance $t$ 與 covariance $\min{(s,t)}$,故我們可推論
\[\begin{array}{l}
\ln \frac{{{S_T}}}{{{S_0}}}\sim {{\cal N}}((\mu  - \frac{{{\sigma ^2}}}{2})T,{\sigma ^2}T)\\
 \Rightarrow \ln {S_T}\sim {{\cal N}}(\ln{S_0} + (\mu  - \frac{{{\sigma ^2}}}{2})T,{\sigma ^2}T)
\end{array}
\]其中 $S_T$ 是未來時間 $T$ 時的股價,$S_0$ 是時間 $0$ 時的股價。上式表明 $\ln {S_T}$ 服從 normal distribution,故 $S_T$ 為Log-normal (亦即 取Log之後為normal),

2. 關於 波動度 (Volatility) $\sigma$
股價的波動度 $\sigma$ 用於測量股價收益的不確定性。一般而言介於 $15 \% \sim 50 \%$。
B-S formula 假設:給定任意 $K,S,T,r..$, $\sigma$ 均為常數不變。

另外值得一提的是波動度有兩種,一種是 歷史資料波動度 (Historical Volatility) 與 隱含波動度 (Implied Volatility),其中歷史波動度是由歷史資料股價計算收益再由此歷史收益計算標準差將其定為波動度。但是隱含波動度則是透過 Black-Scholes Formula 反推而得。此波動度會在之後再作介紹。

3. 關於 Black-Scholes Formula 本質:
透過 購買/賣出 股票與債卷  來複製 選擇權的收益。透過此法可建構一組無風險投資組合,且此組合收益僅為無風險利率 (亦及無套利機會),相關推導請參閱此文: [隨機分析] Black-Scholes PDE for European Call option (0)

Black-Scholes-Metron Formula: 

B-S Model For Stock Option with Constant Dividend: 
以下為  對 European Call option 與 European put option 的 B-S formula
\[\left\{ \begin{array}{l}
c = {S_0}{e^{ - qT}}N\left( {{d_1}} \right) - K{e^{ - rT}}N\left( {{d_2}} \right)\\
p = K{e^{ - rT}}N\left( {{-d_2}} \right) - {S_0}{e^{ - qT}}N\left( {{-d_1}} \right)
\end{array} \right.
\]其中 $c$ 為 European Call option 的價格、$p$ 為 European Put option 價格、$q$ 為連續複利的固定股息、$r$ 為連續複利的無風險利率、 $S_0$ 為現時股價、$T$ 到期時間(以年為單位)、$K$ 為執行價格、$\sigma$ 為股價波動度;且 $N(\cdot)$ 為 Standard Normal cumulative distirbuiton function,其中
\[\left\{ \begin{array}{l}
{d_1} = \frac{{\ln \left( {{S_0}/K} \right) + \left( {r - q + {\sigma ^2}/2} \right)T}}{{\sigma \sqrt T }}\\
{d_2} = {d_1} - \sigma \sqrt T
\end{array} \right.
\]關於上式的證明有興趣的讀者請參考
 [隨機分析] Black-Scholes PDE for European Call option (1)

如果是要計算的話,讀者可以使用 MATLAB 指令 blsprice 協助計算,在此不贅述

Comment:
1. 仔細觀察 B-S Formula,我們可發現需要的參數有
$S_0, K, T, r, q, \sigma$ ,亦即選擇權 $f$ 為
\[
f(S,K,T,r,q,\sigma)
\]注意到其中只有 $\sigma$ 無法被直接觀測獲得,其餘參數都可直接獲得。但是事實上選擇權的報價是知道的 $c,p$已知,故我們可以透過代入選擇權價格以及其餘已知資訊來反推 $\sigma$,此法求得的 $\sigma$ 即為之前所提及的隱含波動度( Implied Volatility)

2. 關於上述 B-S formula的性質:
首先考慮 $S_0$ 很大 (deep in the money for call option, and out of money for put option) 的時候,
則上述 $d_1, d_2 \rightarrow \infty$ 故 $N(d_1), N(d_2) \rightarrow 1$,$N(-d_1), N(-d_2) \rightarrow 0$亦即
\[\left\{ \begin{array}{l}
c = {S_0}{e^{ - qT}}N\left( {{d_1}} \right) - K{e^{ - rT}}N\left( {{d_2}} \right) \to {S_0}{e^{ - qT}} - K{e^{ - rT}}\\
p = K{e^{ - rT}}N\left( { - {d_2}} \right) - {S_0}{e^{ - qT}}N\left( { - {d_1}} \right) \to 0
\end{array} \right.
\]可發現此情況確實為 $c, p$ 的收益價格。

當 $S_0$ 非常小的時候 (deep in the money for put option, and out of money for call option)
則上述 $d_1, d_2 \rightarrow -\infty$ 故 $N(d_1), N(d_2) \rightarrow 0$,$N(-d_1), N(-d_2) \rightarrow 1$亦即
\[\left\{ \begin{array}{l}
c = {S_0}{e^{ - qT}}N\left( {{d_1}} \right) - K{e^{ - rT}}N\left( {{d_2}} \right) \to 0\\
p = K{e^{ - rT}}N\left( { - {d_2}} \right) - {S_0}{e^{ - qT}}N\left( { - {d_1}} \right) \to K{e^{ - rT}} - {S_0}{e^{ - qT}}
\end{array} \right.
\]可發現此情況確實為 $c, p$ 的收益價格。

當 $T \rightarrow 0$ 的時候 :
如果 $S_0 \geq K$ 則 ${{d_1}} \rightarrow \infty \Rightarrow d_2 \rightarrow \infty$,故
\[
N(d_1) \rightarrow 1, N(d_2) \rightarrow 1
\]且
\[\begin{array}{l}
\left\{ {\begin{array}{*{20}{l}}
{c = {S_0}{e^{ - qT}}N\left( {{d_1}} \right) - K{e^{ - rT}}N\left( {{d_2}} \right)}\\
{p = K{e^{ - rT}}N\left( { - {d_2}} \right) - {S_0}{e^{ - qT}}N\left( { - {d_1}} \right)}
\end{array}} \right.
 \Rightarrow \left\{ {\begin{array}{*{20}{l}}
{c = {S_0} - K}\\
{p = 0}
\end{array}} \right.
\end{array}\]
如果 $S_0 < K$ 則 ${{d_1}} \rightarrow -\infty \Rightarrow d_2 \rightarrow -\infty$,故
\[
N(d_1) \rightarrow 0, N(d_2) \rightarrow 0
\]且
\[\begin{array}{l}
\left\{ {\begin{array}{*{20}{l}}
{c = {S_0}{e^{ - qT}}N\left( {{d_1}} \right) - K{e^{ - rT}}N\left( {{d_2}} \right)}\\
{p = K{e^{ - rT}}N\left( { - {d_2}} \right) - {S_0}{e^{ - qT}}N\left( { - {d_1}} \right)}
\end{array}} \right.
 \Rightarrow \left\{ {\begin{array}{*{20}{l}}
{c = 0}\\
{p = K - {S_0}}
\end{array}} \right.
\end{array}\]
故總結上述兩種情況,我們得到 當 $T \rightarrow 0$ ,選擇權價格為
\[\left\{ {\begin{array}{*{20}{l}}
{c = \max \left\{ {{S_0} - K,0} \right\}}\\
{p = \max \left\{ {K - {S_0},0} \right\}}
\end{array}} \right.\]


3. 現在如果考慮B-S model 用到其他商品上的情況

B-S Model For Currency Option
此時 $S_0$ 為現時匯率;$q$ 為外幣利率(foreign currency interest rate)。

B-S Model For Future Option
此時 $S_0 = F_0$ 為現時期貨價格、$q = r$ 

以下我們看兩個例子:

Example 1:
使用 B-S model 來計算 European Put Option on the euro currencies 
考慮 現時匯率 $1.05/euro$、執行價格 $1.1/ euro$、歐元利率 $3.1 \%$、美金利率 $5.5 \%$、波動度 $10 \%$、到期時間 $4$個月

Solution
首先改寫已知資訊 $S=1.05, K=1.1, q=3.1\%, r=5.5\%, \sigma=10\%, T=4/12$,

接著計算 $d_1, d_2$:
\[\left\{ \begin{array}{l}
{d_1} = \frac{{\ln \left( {1.05/1.1} \right) + \left( {5.5\%  - 3.1\%  + {{\left( {0.1} \right)}^2}/2} \right)\left( {4/12} \right)}}{{\left( {0.1} \right)\sqrt {(4/12)} }} =  - 0.6383\\
{d_2} =  - 0.6961
\end{array} \right.
\]帶入 B-S formula 可得 $p=0.05/euro$. $\square$

Example 2:
使用 B-S formula 計算 Put Options on Futures
考慮 期貨現時價格 $\$ 31$、執行價格 $31$、利率 $2 \%$、波動度 $30 \%$、到期時間 $6$個月

Solution
首先改寫已知資訊 $S=31, K=31, q=r=2\%, \sigma=30\%, T=6/12$,(注意到在期貨中 $q=r$ !!)

接著計算 $d_1, d_2$:
\[\left\{ \begin{array}{l}
{d_1} = \frac{{\ln \left( {31/31} \right) + \left( {2\%  - 2\%  + {{\left( {0.3} \right)}^2}/2} \right)\left( {6/12} \right)}}{{\left( {0.3} \right)\sqrt {(6/12)} }} =  0.1061\\
{d_2} =  - 0.1060
\end{array} \right.
\]帶入 B-S formula 可得 Put Future Option 價格 $p= \$ 2.59 $. $\square$



ref: John C. Hull, Options, Futures and Other Derivatives 7th.

[Claude] 國小數學加減乘除法計算小遊戲:數學怪獸大亂鬥

心血來潮用 Anthropic Claude Opus 4.6 做的簡單國小數學乘除法計算小遊戲,感嘆AI工具之強大與便利。原本可能要耗時幾天的工作轉眼就完成,時代的巨輪確實在飛速轉動。  數學怪獸大亂鬥(Math Monster Brawl)對戰的國小數學 加減乘除 小遊戲連結...