previous up next ','..','$myPermit') ?> SYLLABUS  Previous: 5.3.1 The Vasicek model  Up: 5.3 Methods for bonds  Next: 5.4 Computer quiz


5.3.2 Extensions for derivatives $ \spadesuit $


The material in this section is intended for students at a more advanced level than your profile"; else echo " [ SLIDE swap - cap-/floorlet - option || VIDEO modem - LAN - DSL] "; ?>


Looking at a swap as being a bond paying a coupon $ (r-X) dt$ over an infinitesimally short time interval, the differential change in the value of a bond (3.5#eq.6) can simply be supplemented with the corresponding increment. This immediately leads to the partial differential equation for a swap

$\displaystyle \frac{\partial P}{\partial t} +\frac{1}{2}\sigma_s^2 \frac{\parti...
...partial r^2} +(\mu_s -\lambda\sigma_s)\frac{\partial P}{\partial r} = rP -(r-X)$ (5.3.2#eq.1)

";?>
and can again be solved using the finite element method. The new term does not involve any unknown and therefore appears on the right hand side of the linear problem (5.3.1#eq.4) with a contribution that can be integrated analytically

$\displaystyle \int_{r_-}^{r_+} dr e_i(r) \Delta t (r-X) = \Delta t h(ih-X)$ (5.3.2#eq.2)

";?>
It has been coded into FEMSolution.java with an increment of the right hand side vector
                                                       // Construct the problem
      c=b.dot(f);                                      //  A*fp=B*f=c as before
      for (int i=1; i<n; i++)                          // Add swap source term
        c[i]+= timeStep*h*(i*h-X);
      c0=(f[0]+(x[0]-X)*timeStep)*Math.exp(timeStep*X);// Bounday conditions
      a.setL(0, 0.);a.setD(0, 1.);a.setR(0, 0.);c[0]=c0;//left: Dirichlet
      dPdyn=(f[n]-f[n-1])/h; cn=c[n-1]-2*dx[0]*a.getL(n-1)*dPdyn;
      a.setL(n,a1n);a.setD(n,ann);a.setR(n, 0.);c[n]=cn;//right:Neuman
The Dirichlet boundary condition has been modified to account for the compounded interest from the fixed swap rate $ -X$ , but the rest remains the same as for the pricing of a bond.
Similar considerations are valid for caplets and floorlets: viewed as a bond paying a coupon $ \max(r-X,0)dt$ for the caplet and $ \max(X-r,0)dt$ for the floorlet, this yields the modified Vasicek equation for a caplet

$\displaystyle \frac{\partial P}{\partial t} +\frac{1}{2}\sigma_s^2 \frac{\parti...
...l r^2} +(\mu_s -\lambda\sigma_s)\frac{\partial P}{\partial r} = rP -\max(r-X,0)$ (5.3.2#eq.3)

";?>
and, by replacing $ \max(r-X,0)$ with $ \max(X-r,0)$ , the counterpart for the floorlet. Both have been implemented into FEMSolution.java and the scheme for the caplet reads
                                                       // Construct the problem
      c=b.dot(f);                                      //  A*fp=B*f=c as before
      for (int i=1; i<n; i++)
        if (i*h<X) c[i]+=0;
        else       c[i]+=timeStep*h*(i*h-X); 
      a.setL(0, 0.);a.setD(0, 1.);a.setR(0, 0.);c[0]=0.;//left: Dirichlet
      dPdyn=0; cn=c[n-1]-2*dx[0]*a.getL(n-1)*dPdyn;
      a.setL(n,a1n);a.setD(n,ann);a.setR(n, 0.);c[n]=cn;//right:Neuman
Having calculated the fair price for a bond, a swap, cap or floor, it is relatively easy to calculate the value of derivatives such as bond options, swaptions, captions and floortions: their value depends on the same random variable and therefore satisfies the same equation as the underlying. For example, after calculating the value of the bond by solving the Vasicek equation (3.5#eq.6) backwards in time $ T_B\rightarrow T$ , the terminal bond option payoff (2.2.4#eq.1) can be used to integrate backwards further $ T\rightarrow t$ until the present value of the bond option is found.

SYLLABUS  Previous: 5.3.1 The Vasicek model  Up: 5.3 Methods for bonds  Next: 5.4 Computer quiz