## Vasicek Homogeneous Portfolio

In this section, we first derive the distribution of portfolio loss under the Vasicek's assumptions. We then proceed, using the properties of the derived distribution and our knowledge of options from the Black Scholes section, to price CDOs and kth/nth to default swaps under the simplifying assumptions. The goal is to develop a good understanding of these portfolio products under the simplified settings, pretty much what we aimed to achieve in the Black Scholes sections but for options on single underlying (in contrast to portfolio).

### Simplified n-th to default swap: Greeks

In this section, we derive the formulae for the derivatives of the price of the simplified k-th to default swap with respect to PD and $$\rho$$. The price of the kth to default swap was shown to be:

$$V_{0}=e^{-r T}LGD \;\int_{-\infty}^{\infty} { \sum_{i=k}^{m}{ {m \choose i} {\left( N\left[\frac{N^{-1}\left[ \tilde{PD}_{T} \right]-\sqrt{2\rho} y}{\sqrt{1-\rho} } \right] \right) }^{i} {\left( N\left[-\frac{N^{-1}\left[ \tilde{PD}_{T} \right]-\sqrt{2 \rho} y}{\sqrt{1-\rho} } \right] \right) }^{m-i} } \frac{e^{-y^2}}{\sqrt{\pi}} d y }$$

We set $$PD\left(y\right)=N\left[\frac{N^{-1}\left[ \tilde{PD}_{T} \right]-\sqrt{2\rho} y}{\sqrt{1-\rho} } \right]$$ to simplify the presentation.

The binomial distribution in the above can be computed using incomplete Beta function

$$\sum_{i=k}^{m}{ {m \choose i} {PD\left(y\right)}^{i} {\left( 1-PD\left(y\right) \right)}^{m-i} }= I_{PD\left(y\right)} \left( k,n-k+1 \right) =\frac{1}{B\left(k,n-k+1\right)} \int_{0}^{PD\left(y\right)}{t^{k-1}{\left(1-t \right)}^{n-k}dt}$$

The price formula then becomes:

$$V_{0}=e^{-r T}LGD \;\int_{-\infty}^{\infty} {{ I_{PD\left(y\right)} \left( k,n-k+1 \right) } \frac{e^{-y^2}}{\sqrt{\pi}} d y }$$

### Derivative with respect to PD (unconditional PD)

To simplify the presentation, we first differentiate the incomplete Beta function with respect to PD:

$$\frac{\partial}{\partial PD} I_{PD\left(y\right)} \left( k,n-k+1 \right) =\frac{\partial}{\partial PD\left(y\right)} I_{PD\left(y\right)} \left( k,n-k+1 \right) \frac{\partial PD\left(y\right)}{\partial PD}$$ $$= \frac{1}{B\left(k,n-k+1\right)} \frac{\partial}{\partial PD\left(y\right)} \int_{0}^{PD\left(y\right)}{t^{k-1}{\left(1-t \right)}^{n-k}dt} \frac{\partial PD\left(y\right)}{\partial PD}$$ $$= \frac{1}{B\left(k,n-k+1\right)} {{PD\left(y\right)}^{k-1}{\left(1-{PD\left(y\right)} \right)}^{n-k}} \frac{\partial}{\partial PD} N\left[\frac{N^{-1}\left[ PD \right]-\sqrt{2\rho} y}{\sqrt{1-\rho} } \right]$$ $$= \frac{1}{B\left(k,n-k+1\right)} {{PD\left(y\right)}^{k-1}{\left(1-{PD\left(y\right)} \right)}^{n-k}} \; n\left[\frac{N^{-1}\left[ PD \right]-\sqrt{2\rho} y}{\sqrt{1-\rho} } \right] \frac{1}{\sqrt{1-\rho} } \frac{\partial N^{-1}\left[ PD \right]}{\partial PD}$$ $$= \frac{1}{B\left(k,n-k+1\right)} {{PD\left(y\right)}^{k-1}{\left(1-{PD\left(y\right)} \right)}^{n-k}} \; n\left[\frac{N^{-1}\left[ PD \right]-\sqrt{2\rho} y}{\sqrt{1-\rho} } \right] \frac{1}{\sqrt{1-\rho} } \frac{1}{n\left[ N^{-1}\left[ PD \right] \right]}$$

Thus,

$$\frac{\partial V_{0}}{\partial PD} = e^{-r T}LGD \; \int_{-\infty}^{\infty} { \frac{\partial}{\partial PD} I_{PD\left(y\right)} \left( k,n-k+1 \right) \frac{e^{-y^2}}{\sqrt{\pi}} d y }$$ $$= e^{-r T}LGD \; \int_{-\infty}^{\infty} { \frac{1}{B\left(k,n-k+1\right)} {{PD\left(y\right)}^{k-1}{\left(1-{PD\left(y\right)} \right)}^{n-k}} \; n\left[\frac{N^{-1}\left[ PD \right]-\sqrt{2\rho} y}{\sqrt{1-\rho} } \right] \frac{1}{\sqrt{1-\rho} } \frac{1}{n\left[ N^{-1}\left[ PD \right] \right]} \frac{e^{-y^2}}{\sqrt{\pi}} d y }$$ $$= e^{-r T}LGD \; \frac{1}{B\left(k,n-k+1\right)} \frac{1}{ n\left[ N^{-1}\left[ PD \right] \right] \sqrt{1-\rho}} \int_{-\infty}^{\infty} { {{PD\left(y\right)}^{k-1}{\left(1-{PD\left(y\right)} \right)}^{n-k}} \; n\left[\frac{N^{-1}\left[ PD \right]-\sqrt{2\rho} y}{\sqrt{1-\rho} } \right] \frac{e^{-y^2}}{\sqrt{\pi}} d y }$$

### Derivative with respect to $$\rho$$

Now, differentiating both sides with respect to the second parameter $$\rho$$, we get:

$$\frac{\partial V_{0}}{\partial \rho} = e^{-r T}LGD \; \int_{-\infty}^{\infty} { \frac{\partial}{\partial \rho} I_{PD\left(y\right)} \left( k,n-k+1 \right) \frac{e^{-y^2}}{\sqrt{\pi}} d y }$$ $$\frac{\partial V_{0}}{\partial \rho} = e^{-r T}LGD \; \int_{-\infty}^{\infty} { \frac{\partial}{\partial PD\left( y \right)} I_{PD\left(y\right)} \left( k,n-k+1 \right) \frac{\partial PD\left(y\right)}{\partial \rho} \frac{e^{-y^2}}{\sqrt{\pi}} d y }$$ $$= e^{-r T}LGD \; \int_{-\infty}^{\infty} { \frac{1}{B\left(k,n-k+1\right)} {{PD\left(y\right)}^{k-1}{\left(1-{PD\left(y\right)} \right)}^{n-k}} \; n\left[\frac{N^{-1}\left[ PD \right]-\sqrt{2\rho} y}{\sqrt{1-\rho} } \right] \frac{\partial}{\partial \rho} \frac{N^{-1}\left[ PD\right]-\sqrt{2\rho} y}{\sqrt{1-\rho} } \frac{e^{-y^2}}{\sqrt{\pi}} d y }$$ $$= e^{-r T}LGD \; \int_{-\infty}^{\infty} { \frac{1}{B\left(k,n-k+1\right)} {{PD\left(y\right)}^{k-1}{\left(1-{PD\left(y\right)} \right)}^{n-k}} \; n\left[\frac{N^{-1}\left[ PD \right]-\sqrt{2\rho} y}{\sqrt{1-\rho} } \right] \frac{-\sqrt{2}y+\sqrt{\rho}N^{-1}\left[ PD\right]}{2 \sqrt{\rho} \sqrt{1-\rho} \left( 1-\rho \right)} \frac{e^{-y^2}}{\sqrt{\pi}} d y }$$

Where, in the last step, we substituted:

$$\frac{\partial}{\partial \rho} \frac{N^{-1}\left[ PD\right]-\sqrt{2\rho} y}{\sqrt{1-\rho} }$$ $$=\frac{\sqrt{1-\rho} \frac{\partial}{\partial \rho} \left({N^{-1}\left[ PD\right]-\sqrt{2\rho} y}\right)- \left({N^{-1}\left[ PD\right]-\sqrt{2\rho} y}\right) \frac{\partial}{\partial \rho}\sqrt{1-\rho} }{1-\rho}$$ $$=\frac{ - \frac{y \sqrt{1-\rho}}{\sqrt{2\rho}} + \frac{{N^{-1}\left[ PD\right]-\sqrt{2\rho} y}}{2\sqrt{1-\rho}}}{1-\rho}$$ $$=\frac{-\sqrt{2}y\left( 1-\rho \right)+\sqrt{\rho}N^{-1}\left[ PD\right]-\rho y \sqrt{2}}{2 \sqrt{\rho} \sqrt{1-\rho} \left( 1-\rho \right) }$$ $$=\frac{-\sqrt{2}y+\rho y \sqrt{2} +\sqrt{\rho}N^{-1}\left[ PD\right]-\rho y \sqrt{2}}{2 \sqrt{\rho} \sqrt{1-\rho} \left( 1-\rho \right)}$$ $$=\frac{-\sqrt{2}y+\sqrt{\rho}N^{-1}\left[ PD\right]}{2 \sqrt{\rho} \sqrt{1-\rho} \left( 1-\rho \right)}$$