school of mathematicspjohnson/resources/math60082/lecture... · review improved finite difference...
Post on 20-May-2018
227 Views
Preview:
TRANSCRIPT
ReviewImproved Finite Difference Methods
Exotic optionsSummary
FINITE DIFFERENCE - CRANK NICOLSON
Dr P. V. Johnson
School of Mathematics
2013
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
OUTLINE
1 REVIEWLast time...Today’s lecture
2 IMPROVED FINITE DIFFERENCE METHODSThe Crank-Nicolson MethodSOR method
3 EXOTIC OPTIONSAmerican optionsConvergence and accuracy
4 SUMMARYOverview
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
OUTLINE
1 REVIEWLast time...Today’s lecture
2 IMPROVED FINITE DIFFERENCE METHODSThe Crank-Nicolson MethodSOR method
3 EXOTIC OPTIONSAmerican optionsConvergence and accuracy
4 SUMMARYOverview
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
OUTLINE
1 REVIEWLast time...Today’s lecture
2 IMPROVED FINITE DIFFERENCE METHODSThe Crank-Nicolson MethodSOR method
3 EXOTIC OPTIONSAmerican optionsConvergence and accuracy
4 SUMMARYOverview
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
OUTLINE
1 REVIEWLast time...Today’s lecture
2 IMPROVED FINITE DIFFERENCE METHODSThe Crank-Nicolson MethodSOR method
3 EXOTIC OPTIONSAmerican optionsConvergence and accuracy
4 SUMMARYOverview
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
Last time...Today’s lecture
Introduced the finite-difference method to solve PDEsDiscetise the original PDE to obtain a linear system ofequations to solve.This scheme was explained for the Black Scholes PDE andin particular we derived the explicit finite differencescheme to solve the European call and put optionproblems.
The convergence of the method is similar to the binomialtree and, in fact, the method can be considered a trinomialtree.Explicit method can be unstable - constraints on our gridsize.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
Last time...Today’s lecture
Introduced the finite-difference method to solve PDEsDiscetise the original PDE to obtain a linear system ofequations to solve.This scheme was explained for the Black Scholes PDE andin particular we derived the explicit finite differencescheme to solve the European call and put optionproblems.The convergence of the method is similar to the binomialtree and, in fact, the method can be considered a trinomialtree.Explicit method can be unstable - constraints on our gridsize.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
Last time...Today’s lecture
Here we will introduce the Crank-Nicolson methodThe method has two advantages over the explicit method:
stability;improved convergence.
Here we will need to solve a matrix equation.
In addition we will discuss how to price American optionsand how to remove nonlinearity error in a variety of cases.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
Last time...Today’s lecture
Here we will introduce the Crank-Nicolson methodThe method has two advantages over the explicit method:
stability;improved convergence.
Here we will need to solve a matrix equation.In addition we will discuss how to price American optionsand how to remove nonlinearity error in a variety of cases.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
CRANK NICOLSON METHOD
The Crank-Nicolson scheme works by evaluating thederivatives at V(S, t + ∆t/2).The main advantages of this are:
error in the time now (∆t)2
no stability constraints
Crank-Nicolson method is implicit, we will need to usethree option values in the future (t + ∆t)to calculate three option values at (t).
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
Crank-Nicolson grid
0 T∆t 2∆t (i+1)∆t... ...
0
∆S
2∆S
.
.
j∆S
.
.
SU
Vji
upper boundary
lower boundary
pde holds in this region
Vj-1i
Vj+1i
Vji+1
Vj-1i+1
Vj+1i+1
i∆t
Focus attention on i, j-th value Vji, and a little
piece of the grid around that point
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
APPROXIMATING AT THE HALF STEP
Now take approximations to the derivatives at the halfstep t + 1/2∆tThey are in terms of Vi
j , as follows:
∂V∂t≈
Vi+1j −Vi
j
∆t
∂V∂S≈ 1
4∆S(Vi
j+1 −Vij−1 + Vi+1
j+1 −Vi+1j−1)
∂2V∂S2 ≈
12∆S2 (V
ij+1 − 2Vi
j + Vij−1 + Vi+1
j+1 − 2Vi+1j + Vi+1
j−1)
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
DERIVING THE EQUATION
Here the Vi values are all unknown, so...rearrange our equations to have the known values on onesidethe unknown values on the other.
14 (σ
2j2 − rj)Vij−1 + (−σ2j2
2− r
2− 1
∆t)Vi
j +14 (σ
2j2 + rj)Vij+1 =
− 14 (σ
2j2 − rj)Vi+1j−1 − (−σ2j2
2− r
2+
1∆t
)Vi+1j − 1
4(σ2j2 + rj)Vi+1
j+1
There is one of these equations for each point in the grid
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
MATRIX EQUATIONS
•We can rewrite the valuation problem in terms of a matrix asfollows:
b0 c0 0 0 . . . . 0a1 b1 c1 0 . . . . .0 a2 b2 c2 0 . . . .. 0 a3 b3 c3 0 . . .. . . . . . . . .. . . 0 aj bj cj 0 .. . . . . . . . .0 . . . . . 0 ajmax bjmax
Vi0
Vi1
Vi2
Vi3..
Vijmax−1Vi
jmax
=
di
0di
1di
2di
3..
dijmax−1di
jmax
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
MATRIX EQUATIONS
where:
aj = 14 (σ
2j2 − rj)
bj = −σ2j2
2− r
2− 1
∆tcj = 1
4 (σ2j2 + rj)
dj = − 14 (σ
2j2 − rj)Vi+1j−1 − (−σ2j2
2− r
2+
1∆t
)Vi+1j
− 14 (σ
2j2 + rj)Vi+1j+1
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
WHAT TO DO ON THE BOUNDARIES?
Boundary conditions are an important part of solving anyPDEFor most PDEs we know the boundary conditions for largeand small SFor call options ajmax = 0, bjmax = 1,djmax = Sue−δ(T−i∆t) −Xe−r(T−i∆t), b0 = 1, c0 = 0, d0 = 0
For put options b0 = 1, c0 = 0, d0 = Xe−r(T−i∆t), ajmax = 0,bjmax = 1, djmax = 0In general we can always determine the values of b0, c0, d0,ajmax, bjmax and djmax from our boundary conditions.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
THE CRANK-NICOLSON METHOD
At each point in time we need to solve the matrix equationin order to calculate the Vi
j values.
There are two approaches to doing this,solve the matrix equation directly (LU decomposition),solve the matrix equation via an iterative method (SOR).
If possible, the LU approach is the preferred approach as itgives you an exact value for Vi
j and is much faster.
However, not possible to use LU approach with Americanoptions.The SOR (Successive Over Relaxation) can be easilyadapted to value American options
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
MATRIX EQUATIONS
The SOR method is a simpler approach but can take a littlelonger as it relies upon iteration.If we consider each of the individual equations fromAV = d we have that
a1Vi0 + b1Vi
1 + c1Vi2 = di
1
a2Vi1 + b2Vi
2 + c2Vi3 = di
1
............ = ...ajVi
j−1 + bjVij + cjVi
j+1 = dij
............ = ...ajmax−1Vi
jmax−2 + bjmax−1Vijmax−1 + cjmax−1Vi
jmax = dijmax−1
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
JACOBI ITERATION
Rearrange these equations to get:
Vij =
1bj(di
j − ajVij−1 − cjVi
j+1)
The Jacobi method is an iterative one that relies upon theprevious equation.
Taking an initial guess for Vij , denoted as Vi,0
jiterate using the formula below for the (k + 1)th iteration:
Vi,k+1j =
1bj(di
j − ajVi,kj−1 − cjV
i,kj+1)
carry on until the difference between Vi,kj and Vi,k+1
j issufficiently small for all j.
For Gauss-Seidel use the most up-to-date guess wherepossible:
Vi,k+1j =
1bj(di
j − ajVi,k+1j−1 − cjV
i,kj+1)
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
JACOBI ITERATION
Rearrange these equations to get:
Vij =
1bj(di
j − ajVij−1 − cjVi
j+1)
The Jacobi method is an iterative one that relies upon theprevious equation.
Taking an initial guess for Vij , denoted as Vi,0
jiterate using the formula below for the (k + 1)th iteration:
Vi,k+1j =
1bj(di
j − ajVi,kj−1 − cjV
i,kj+1)
carry on until the difference between Vi,kj and Vi,k+1
j issufficiently small for all j.
For Gauss-Seidel use the most up-to-date guess wherepossible:
Vi,k+1j =
1bj(di
j − ajVi,k+1j−1 − cjV
i,kj+1)
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
SOR
The SOR method is another slight adjustment. It startsfrom the trivial observation that
Vi,k+1j = Vi,k
j + (Vi,k+1j −Vi,k
j )
and so (Vi,k+1j −Vi,k
j ) is a correction term.Now try to over correct value, should work faster.This is true if Vi,k
j → Vij monotonically in k.
So the SOR algorithm says that
yi,k+1j =
1bj(di
j − ajVi,k+1j−1 − cjV
i,kj+1)
Vi,k+1j = Vi,k
j + ω(yi,k+1j −Vi,k
j )
where 1 < ω < 2 is called the over-relaxation parameter.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
The Crank-Nicolson MethodSOR method
SOR
The SOR method is another slight adjustment. It startsfrom the trivial observation that
Vi,k+1j = Vi,k
j + (Vi,k+1j −Vi,k
j )
and so (Vi,k+1j −Vi,k
j ) is a correction term.Now try to over correct value, should work faster.This is true if Vi,k
j → Vij monotonically in k.
So the SOR algorithm says that
yi,k+1j =
1bj(di
j − ajVi,k+1j−1 − cjV
i,kj+1)
Vi,k+1j = Vi,k
j + ω(yi,k+1j −Vi,k
j )
where 1 < ω < 2 is called the over-relaxation parameter.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
AMERICAN OPTIONS: EXPLICIT
American option pricing problem requires an optimalearly exercise strategy.To generate one, compare the continuation value with theearly exercise value - take the larger.With the explicit finite difference method is prettystraightforward
calculate the continuation value CoVij
CoVij =
11 + r∆t
(AVi+1j+1 + BVi+1
j + CVi+1j−1)
then compare this to the early exercise payoff.
Thus for a put:
Vij = max[X− j∆S,
11 + r∆t
(AVi+1j+1 + BVi+1
j + CVi+1j−1)]
This is similar to using the binomial tree
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
AMERICAN OPTIONS: EXPLICIT
American option pricing problem requires an optimalearly exercise strategy.To generate one, compare the continuation value with theearly exercise value - take the larger.With the explicit finite difference method is prettystraightforward
calculate the continuation value CoVij
CoVij =
11 + r∆t
(AVi+1j+1 + BVi+1
j + CVi+1j−1)
then compare this to the early exercise payoff.Thus for a put:
Vij = max[X− j∆S,
11 + r∆t
(AVi+1j+1 + BVi+1
j + CVi+1j−1)]
This is similar to using the binomial treeDr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
American put option: Explicit
...0
∆S
2∆S
.
.
j∆S
.
.
SUImpose upper boundary at SU
Impose lower boundary at 0
terminalboundary
0 T∆t 2∆t (i+1)∆t ...i∆t
Move through “interior” ofmesh/grid using this rule
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
AMERICAN PUT OPTION: C-N
The American option pricing problem is slightly morecomplex for the Crank-Nicolson method.Consider the process of calculating Vi
j ...
The value of the option Vij , for all values of j, depends also
upon the value of Vij−1 and Vi
j+1.
Optimally deciding when to early exercise requires that wealready know these values.If we early exercise at some point this could change Vi
j forall j.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
AMERICAN PUT OPTION: C-N
The American option pricing problem is slightly morecomplex for the Crank-Nicolson method.Consider the process of calculating Vi
j ...
The value of the option Vij , for all values of j, depends also
upon the value of Vij−1 and Vi
j+1.
Optimally deciding when to early exercise requires that wealready know these values.If we early exercise at some point this could change Vi
j forall j.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
PSOR
A simple solution to this problem is to project our SORmethod (Projected SOR)In order to project, check whether or not it would beoptimal to exercise at each iteration.
This changes
yi,k+1j =
1bj(di
j − ajVi,k+1j−1 − cjV
i,kj+1)
Vi,k+1j = Vi,k
j + ω(yi,k+1j −Vi,k
j )
to (in the case of the American put option)
yi,k+1j =
1bj(di
j − ajVi,k+1j−1 − cjV
i,kj+1)
Vi,k+1j = max(Vi,k
j + ω(yi,k+1j −Vi,k
j ), X− j∆S)
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
PSOR
A simple solution to this problem is to project our SORmethod (Projected SOR)In order to project, check whether or not it would beoptimal to exercise at each iteration.This changes
yi,k+1j =
1bj(di
j − ajVi,k+1j−1 − cjV
i,kj+1)
Vi,k+1j = Vi,k
j + ω(yi,k+1j −Vi,k
j )
to (in the case of the American put option)
yi,k+1j =
1bj(di
j − ajVi,k+1j−1 − cjV
i,kj+1)
Vi,k+1j = max(Vi,k
j + ω(yi,k+1j −Vi,k
j ), X− j∆S)
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
CONVERGENCE
If the option price and the derivatives are well behavedthen the errors of the
Explicit method are O(∆t, (∆S)2)Crank-Nicolson method are O((∆t)2, (∆S)2).
These can be considered similar to the distribution errorfor the binomial tree.If convergence is smooth we can use extrapolation.
Finite-difference methods can suffer from non-linearityerror if the grid is not correctly aligned with respect to anydiscontinuities
in the option value,or in the derivatives of the option value.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
CONVERGENCE
If the option price and the derivatives are well behavedthen the errors of the
Explicit method are O(∆t, (∆S)2)Crank-Nicolson method are O((∆t)2, (∆S)2).
These can be considered similar to the distribution errorfor the binomial tree.If convergence is smooth we can use extrapolation.Finite-difference methods can suffer from non-linearityerror if the grid is not correctly aligned with respect to anydiscontinuities
in the option value,or in the derivatives of the option value.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
NON-LINEARITY ERROR
Now have the freedom to construct the grid as desired.Makes it is simple to construct the grid so that you have agrid point upon any discontinuities.For example, if we consider an European call or put optionthen the only source of non-linearity error is at S = X atexpiry.
Always choose ∆S so that X = j∆S for some integer valueof j.So if in this case S0 = 100 and X = 95, you need a suitablylarge SU and a ∆S which is a divisor of 95.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
NON-LINEARITY ERROR
Now have the freedom to construct the grid as desired.Makes it is simple to construct the grid so that you have agrid point upon any discontinuities.For example, if we consider an European call or put optionthen the only source of non-linearity error is at S = X atexpiry.Always choose ∆S so that X = j∆S for some integer valueof j.So if in this case S0 = 100 and X = 95, you need a suitablylarge SU and a ∆S which is a divisor of 95.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
BARRIER OPTIONS
When pricing barrier options, there is a large amount ofnon-linearity error that comes from not having the nodesin the tree aligned with the position of the barrier.Thus with barrier options we have two sources ofnon-linearity error
the error from the barrierthe error from the discontinuous payoff.
Simply match the grid to the barrier and the payoff.For a down and out barrier option choose SL (the lowervalue of S) to be on the barrier and then, as in the previousexample, choose ∆S so that the exercise price is also on anode.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
American optionsConvergence and accuracy
BARRIER OPTIONS
When pricing barrier options, there is a large amount ofnon-linearity error that comes from not having the nodesin the tree aligned with the position of the barrier.Thus with barrier options we have two sources ofnon-linearity error
the error from the barrierthe error from the discontinuous payoff.
Simply match the grid to the barrier and the payoff.For a down and out barrier option choose SL (the lowervalue of S) to be on the barrier and then, as in the previousexample, choose ∆S so that the exercise price is also on anode.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
Overview
OVERVIEW
We have introduced the Crank-Nicolson finite differencemethod.It is:
slightly harder to program;has faster convergence;better stability properties.
Applying the method to American options requires the useof PSORmore complex than the method for valuing Americanoptions using the explicit method.Can choose the dimensions of the grid so as to remove thenonlinearity error.
Dr P. V. Johnson MATH60082
ReviewImproved Finite Difference Methods
Exotic optionsSummary
Overview
OVERVIEW
We have introduced the Crank-Nicolson finite differencemethod.It is:
slightly harder to program;has faster convergence;better stability properties.
Applying the method to American options requires the useof PSORmore complex than the method for valuing Americanoptions using the explicit method.Can choose the dimensions of the grid so as to remove thenonlinearity error.
Dr P. V. Johnson MATH60082
top related