Você está na página 1de 143

# Computational Finance (PGP)

Area: Finance Instructor: Michael Carter Term: 6 Objective: This hands-on course aims to develop tools and techniques to implement and analyze the core models of modern finance, as applied in asset pricing and risk management. Financial models will be implemented in Excel, supplemented where appropriate by Visual Basic for Applications (VBA). (It is important to appreciate that it is primarily a course in computation, not a course in programming. Excel and VBA are the vehicles, not the objective.) The course will both enhance understanding of the theory and provide relevant tools for practitioners. The aim is not to produce programmers, but to enable managers to become informed users of the numbers produced for them by others. Outline: Fixed income assets 1. Basic bond pricing 2. Interest rate swaps 3. Estimating the term structure of interest rates Derivatives: lattice methods 4. Binomial and trinomial trees 5. Implied trees 6. American options Derivatives: simulation 7. Random number generation 8. Variance reduction 9. American options 10. Low-discrepancy sequences 11. Non-Gaussian processes Derivatives: Exotic options 12. Asian options 13. Barrier options 14. Basket and spread options 15. Variance swaps Interest rate derivatives 16. Blacks model for bond options, caps and swaptions 17. The Black-Derman-Toy model

Pedagogy: Course meetings will combine lecture and practical work. Students must bring their laptop computer to each session. Sessions required: 25 Assessment: Assignments (2) Final exam Homework

## 50% 40% 10%

Prerequisites: Core courses only. Restriction on class size: 30 Relationship with other courses: There is potential overlap with (a) Futures, Options and Risk Management and (b) Fixed Income Securities. However, the computational focus of this course differentiates it from other courses. Bibliography: There is no specific text for the course. Course materials are provided online. Additional student expenses: Nil.

## Useful financial functions in Excel

PV NPV FV Present value of an annuity Net present value of periodic cash flows Future value of an annuity RATE IRR Rate of return of an annuity Internal rate of return of periodic c

## PRICE PRICEDISC TBILLPRICE

Price of a coupon bond Price of a discount bond Price of T-bill (special case of PRICEDISC)

## COUPDAYS COUPDAYBS COUPDAYSNC

Number of days in current coupon Number of days between previous settlement Number of days between settlemen coupon

DURATION

## Duration of a coupon bond

MDURATION

Modified duration

EFFECT

TBILLEQ

## Formula auditing toolbar

The Formula Auditing Toolbar enables you to trace graphically the relationships between cells. It also allows you to monitor cell contents by placing them in a Watch Window.

To display the formula auditing toolbar View > Toolbars > Formula auditing

To trace a cell's precedents 1. 2. 3. 4. Select a cell containing a formula Click on the Trace Precedents button Click on the Trace Precedents button again to display the previous level of precedents. Remove tracer arrows one level at a time by clicking Remove Precedent Arrows

To trace a cell's dependents 1. 2. 3. 4. Select a cell containing a formula Click on the Trace Dependents button Click on the Trace Dependents button again to display the previous level of dependents. Remove tracer arrows one level at a time by clicking Remove Dependent Arrows

To select the cell at the other end of an arrow Double click the arrow

To remove all tracer arrows Click the Remove All Arrows button.

To display all the relationships in a worksheet 1. In an empty cell, type = 2. Then click the Select All button and evaluate the cell with Ctrl-Enter 3. Click the Trace Precedents button twice.

## To display all formulae Click Ctrl-~

To add a cell to the watch window 1. Open the Watch Window by clicking on the Watch Window button in the Formula Auditing Toolbar. 2. Select the cells you want to monitor. 3. Click on the Add Watch button in the Watch Window.

## Basic bond pricing

In principal, pricing a risk-free bond is deceptively simple - the price or value of a bond is the present value of the future cash flows, discounted at the prevailing rate of interest, which is known as the yield.
T

1 C 1 r

1 R 1 r

P
t 1

where P is the price, C is the coupon, R is the redemption value (principal) and T is the term. Alternatively, the yield of a bond is the internal rate of return at which the discounted value is equal to market price. Bonds are known as fixed income assets, because the timing and magnitude of the future cash flows are fixed. Their value however varies inversely with the yield. Bonds of similar risk and term will attract similar yields. In practice, bond pricing is more complicated because coupons are paid more frequently than annually, typically every six months. a price is required between coupon periods necessitating discounting for fractional periods. interest rates (yields) may be expected to change during the term of the bond. The first complication is dealt with by treating the coupon period (e.g. 6 months) as the discounting period. If there are m coupons per year,
mT

C m 1

1
r m

1 R 1
r m

mT

P
t 1

Treatment of fractional periods is a matter of market convention. In particular, various markets employ different day count conventions for calculating the fraction of the coupon period which as elapsed on a given day. Similar conventions are employed for pricing zero coupon bonds. However, zero coupon bonds issued with a maturity less than one year (notes) are priced with yet another convention. Computation of bond prices and yields requires being familiar with the prevailing conventions. Changing interest rates (the yield curve) can be accommodated by discounting each cash flow at the appropriate spot rate. Credit risk can be incorporated in a simple way by discounting at a higher rate than the yield on risk-free bonds. This difference, known as the spread, depends upon the credit rating of the issuer. More sophisticated measures employ credit risk models to allow for the possibility of default and ratings changes during a given horizon. Sophisticated measures will also account directly for the options embedded in many bonds, as for example in a callable bond.

Daycountconventions
Coupons Daycount Basis Settlement +2 Actual/365 2 2 2 Actual/Actual 30/360 3 1 0 +7 +2

Corporatebonds
Germany India Japan UK US

## Day countsaremarket conventions,whicharesubjectto changeandexceptions. Theinformationcollectedherehasbeenassembledfroma varietyofsources.Itistentativeandprovidedfor educationalpurposesonly.Theinformationneedstobe verifiedbeforebeingusedforcommercialpurposes

Governmentbonds
Germany India Japan UK US USmunicipal 1 2 2 2 2 Actual/365 30/360 Actual/365 Actual/Actual Actual/Actual 30/360 3 0 3 1 1 0 +2 +1 +1 +1

BasisisanExcelparameter encodingthedatecount. Basis Daycount 0 US(NASD)30/360 1 Actual/actual 2 Actual/360 3 Actual/365 4 European30/360 FromRBI FAQs Bondmarket:Thedaycountconventionfollowedis30/360, whichmeansthatirrespectiveoftheactualnumberofdaysina month,thenumberofdaysinamonthistakenas30 andthe numberofdaysinayearistakenas360. Moneymarket:Thedaycountconventionfollowedisactual/365, whichmeansthattheactualnumberofdaysinamonthistaken fornumberofdays(numerator)whereasthenumberofdaysina yearistakenas365days.Hence,inthecaseofTreasurybills,which areessentiallymoneymarketinstruments,money market conventionisfollowed.

Governmentbills
Germany India US Actual/360 Actual/365 Actual/Actual 2 3 1 +2 +2 +1

Moneymarket(LIBOR)
Germany India Japan UK US Eurolibor Actual/360 Actual/365 Actual/360 Actual/365 Actual/360 30/360 2 3 2 3 2 0

## Duration and convexity

Duration and Sensitivity
Assuming annual coupons, the price of a coupon bond is the discounted value of cash flows
T

1 C 1 r

1 R 1 r

P
t 1

where P is the full or dirty price, C is the annual coupon, R is the redemption value and T is the term. This can be rewritten as
T t T

P
t 1

C 1

R 1

T

tC 1
t 1

t 1

TR 1

T 1

T

1 C 1 r

1 t R 1 r

(1)

t 1

## The (Macauley) duration of the bond is

T

Dur
t 1

1 t 1 r

R t

1 T 1 r

so that
T

1 C 1 r

1 t R 1 r

Dur
t 1

(2)

which is precisely the term inside the brackets in equation (1). Substituting equation (2) into equation (1) gives P r 1 1 r Dur P

Duration.nb

## With m coupons per year, this becomes (see below) P r 1 1

r m

Dur

To simplify, we call the product on the left modified duration. That is, defining 1 MDur 1 we have dP dr MDur P
r m

Dur

## For small changes in interest rate, we have P r or P P MDur r MDur P

A one percentage point increase in yield will lead to (approx.) MDur fall in price. Practitioners often express duration (that is, interest-rate sensitivity) in terms of the dollar value of a basis point (DV01) or more generally price value of a basis point (PV01). This is defined as PV01 MDur P 0.01 0.01

Note that, strictly speaking, it is the invoice or dirty price that should be used for P in this calculation.

Multiannual coupons
If there are m coupons per year, the price of a bond is
mT

C m 1 C m 1

1
r m

1 R 1
t r m

mT

P
t 1 mT

r m

r R 1 m

mT

t 1

mT

C t m 1
mT r m

r m

t 1

1 m 1
r m

r mT R 1
t

mT 1

1 m

t 1

m 1
mT r m

1 1

t C m m 1

TR 1

t 1

Duration.nb

1 1
r m

mT

t m

C m

1 1
r m

R T

1 1
r m

mT

t 1

1 1 mDur
r m

Dur

## A closed formula for duration

Inverting the previous equation, the duration of a bond is 1 Dur where
mT r m

P r

(3)

C m 1

1
r m

1 R 1
r m

mT

P
t 1

By summing the geometric series, the price of the bond can be written in closed form as

C P r 1 1

1
r mT m

1 1
r mT m

Differentiating this expression and substituting in (2), we obtain a closed formula for the duration of a bond

1 Dur r

r m

T
C R

C R

r
r mT m

1 1

r m

(4) r

r m

1 1

r mT m

## The limit of duration for long term bonds

As T goes to infinity, the second term in equation (3) goes to zero. Therefore, the duration of a long-term bond converges to

Duration.nb

1 lim Dur
T

r m

## For example, with a yield of 5%, the duration of a biannual converges to

1 5

5 2

20.5

Convexity
Duration is related to the first derivative of bond price with respect to yield. Convexity is a measure of the second derivative, normalised by bond price.
2

r2

Though it is possible to derive a formula for convexity, by differentiating the above formula for P r, we would need to incorporate the complications date count conventions for mid-coupon bonds. Alternatively, we can estimate convexity accurately by numerical differentiation Pr C r 2P r P r
2

Pr

where r is a small change in interest rate (e.g. 0.0001 for 1 basis point). Alternatively, we can compute convexity from the first derivative of duration (this is useful if we have a formula for duration, as in Excel). From above
2

PC But P r

P r

r2

PD

where D is modified duration. Substituting and using the product rule PC PD r P D P D2 so that D2 D r r P P D r D r

Duration.nb

## r can itself be calculated by numerical differentiation.

Numerical differentiation
The derivative of a function f HxL is f f ' HxL = lim x f x
x 0

## An obvious method to approximate the derivative is to compute f Hx + xL - f HxL x 2x

f Hx + xL - f HxL x

for small x. This is known as the forward difference. A better alternative (though more costly to compute) is f Hx + xL - f Hx - xL f ' Ix +
1 2

which is known as the central difference. Using central differences, the second derivative can be estimated by 2 f x
2

Numerical Recipes (Press et al., 2007: 229) discuss the numerical issues in computing numerical derivatives. In particular, choice of x can be crucial.

f Hx + xL - 2 f Hx L + f Hx - xL H xL2

xM - f ' Ix x

1 2

xM

f Hx+xL- f Hx L x

f HxL- f Hx -xL x

f Hx+xL- f Hx L x

f HxL- f Hx -xL x

## Interest rates swaps

The present value of the floating side of a swap (assuming a notional principal of one) is
n

PVfloating
i 1

i Ti ri

1,i

where i is the discount factor at the end of period i, Ti is the elapsed time adjusted for day count, ri

1,i

is

forward rate fixed at the end of period i-1 and payable at the end of period i, and n is the number of floating rate payments. The forward rate is ri
i 1 i 1,i

1 Ti
i 1 i

Substituting
n

1 Ti

PVfloating
i 1 n

i Ti i i
1

i
i 1 n

i
i 1

## since 0 = 1. That is PVfloating 1 n

(1)

Let N denote the number of fixed payments, j the discount factor applicable to the jth fixed payment, and T j the time over which the jth fixed payment is accrued. The present value of the fixed side (assuming a notional principal of one) and annual fixed payments
N

PVfixed
j 1

j T j sN

s N QN

(2)

where
N

QN
j 1

j Tj

QN

N TN

Note that SN T j is the dollar amount of the fixed payment at time T j . Consequently, the net present value of a swap is NPV s N QN 1 N Principal
(3)

## At fair value (NPV = 0) 1 N s N QN s N QN N TN

InterestRateSwaps.nb

s N QN

sN N TN N
1

N 1

## are determined, so is QN 1 , and we can solve for N

(4)

1 1

s N QN

sN TN

QN

1 j 1

j Tj

QN

TN

This provides a general bootstrapping procedure from inferring discount factors from swap rates. Generalising, consider a forward swap starting in period t floating side is
T

## 1 and ending in period T. The present value of the

PVfloating
i t 1 T

i Ti i i
1

i 1 i

1 Ti

i
i t 1 T

i
i t 1

The present value of the fixed side (assuming a notional principal of one) is
T T t

PVfixed
j t 1

j T j sN

sN
j 1

j Tj
j 1

j Tj

sN QT

Qt

where the sum is taken over all fixed payments between times t 1 and T. Equating fixed and floating sides, the forward swap rate (the fixed rate of a swap starting in t+1 and ending in period T) is given by sN t QT T
(5)

Qt

Bootstrapping
With annual compounding, the price of a unit par bond with n years remaining is given by c P1 c P2 c Pi
1

c Pt

where c is the coupon (yield) and Pi is the discount factor (price of a t-year zero-coupon bond). This can be solved successively to give the prices of zero-coupon bonds to match a given yield curve. 1 Pt c 1
t 1 i 1 Pi

c 2 t i c 2
1 2 1 2 2

c 2 P1

c P 2
t
1 2

c 1 2 Pt 1

Pi

## Estimating the term structure

The basic bond pricing equation is
n

C m 1 sti m
m ti

R 1 stn m
m tn

P
i 1

(1)

where P C R m n price full or dirty price annual coupon redemption payment principal frequency of coupons number of remaining coupons

## This can be written in terms of the discount factors C P where 1 1 sti m

m ti n

ti
i 1

tn R

ti

The spot rates or discount factors also determine the forward rates. Let rti denote the forward (short) rate

s 1 so that rti m m

m ti

s 1 m

m ti

rti m

1 1 ti
1

s m ti m s m ti m
1

ti ti ti ti

rti

ti

ti

If there is an active market in zero-coupon bonds, these can be used to give immediate market estimates of the discount rate at various terms. However, such instruments are traded only in the U.K. and U.S. treasury markets. Moreover, even in these markets, they are usually disregarded because of restricted maturities, limited liquidity and tax complications. In principle, discount factors ti can be inferred from the prices of coupon bonds inverting (1). In turn, these can be used to infer the spot rate (zti ) and forward rate rti curves. The inversion process is known as bootstrapping. In practice, estimation of the spot rate curve is complicated by two basic problems:

EstimatingTermStructure.nb

Bonds of the same maturity may be selling at different yields, due to market imperfections, limited liquidity, tax etc. There may be no data on bonds of other maturities. These problems are tackled (with varying degrees of success) by statistical estimation and interpolation. The basic approach is to assume a specific functional form for the forward rate or discount function, and then adjust the parameters until the best fit is obtained. Simple polynomial functions such as f t 0 1 t 2 t2 3 t 3 (2) .

have been found not to be very suitable, since they imply that rates go to plus or minus infinity as t Two basic generalizations are found - exponential functions and polynomial or exponential splines.

## Parsimonious functional forms

The most straightforward generalization of (2) is to substitute an exponential for each power of t, fitting a model of the form f t 0 1
k1 t

k2 t

k3 t

This is the exponential yield model adopted by J.P Morgan. The most popular model of this form is due to Nelson and Siegel (1987). They observe that the second order exponential model is the general solution to a second-order differential equation (assuming real unequal roots)
t t

f t

where 1 , 2 are the rates of decay. Finding that this is overparameterized, they adopt the general solution for the case of equal roots
t

f t

## (3) f t 0 . 1 can be interpreted as the weight

attached to the short term component, and 2 as the weight of the medium term. determines the rate of decay. The spot rate, the average of the forward rates, can be obtained by integrating this equation, giving
t

1 t f t t

st
0

t 1

(4)

Given values for the parameters 0 , 1 , 3 and , bonds can be valued using the continuous analogue of (1)
n st t i 1

C m

s tn tn

(5)

This is the model adopted by the National Stock Exchange of India for estimating its published spot rate series. Svennson (1994) extended this specification by adding an additional term for greater flexibility, specifically

EstimatingTermStructure.nb

Svennson (1994) extended this specification by adding an additional term for greater flexibility, specifically
t

f t

t 1

t 1

t 2

t 2

## The corresponding spot rate curve is st 0 1 2 1 t

t t

2 t

This is the model used by the Deutsche Bundesbank for estimating its published spot rate series.

8
Example: National Stock Exchange of India

Forward

Estimating the Nelson-Siegel model for bonds traded on 26 June 2004 yields the following parameter 6 estimates 0

5 4 3 2

Spot

0.0727, 1

0.0231, 2

0.0210,

2.8601

10

15

20

Example: Deutsche Bundesbank For the 15 September 2004, the Deutsche Bundesbank estimated the following parameters for the Svennson model: 0 5.4596, 1 3.53042, 2 0.37788, 3 0.98812, 1 2.70411, 2 2.53479

## These parameters imply the following spot rates.

EstimatingTermStructure.nb

1 2 3 4 5 6 7 8 9 10

2.30311 2.64336 2.94634 3.21246 3.44425 3.64514 3.81886 3.96905 4.09904 4.21179

The spot and forward curves are illustrated in the following graph.

6 5 4 3 2

10

15

20

Spline
A cubic spline comprises a sequence of cubic functions between chosen points called knots, the coefficients of the cubic functions chosen so that their first and second derivatives match at each of the knots. This makes the resulting spline smooth. Author McCullough Fisher Waggoner Instrument Estimation Knots Discount Forward Forward LS NLLS NLLS n n 3 n 3

Evaluation
A recent comprehensive review by Ioannides (2003) found that the parsimonious functional forms outperformed corresponding spline methods, with the Svennson specification preferred over that of Nelson and Siegel. However, we note that the Bank of England recently drew the opposite conclusion, switching from Svensson's method to a spline method (Anderson and Sleath, 1999).

'Implementation of Nelson-Siegel method for estimating forward rate curve ' Michael Carter, 2004 Function Getformula(ThisCell) Getformula = ThisCell.Formula End Function ' Discount function Function df(t As Double, b0 As Double, b1 As Double, b2 As Double, tau As Double) As Double df = Exp(-t * (b0 + (b1 + b2) * (1 - Exp(-t / tau)) * (tau / t) - b2 * Exp(-t / tau))) End Function 'Bond price function Function Pr(t As Double, C As Double, n As Integer, b0 As Double, b1 As Double, b2 As Double, tau As Double) As Double Dim i As Integer Dim P As Double P=0 For i = 1 To n P = P + df(t + (i - 1) / 2, b0, b1, b2, tau) * (100 * C / 2) Next i Pr = P + df(t + (n - 1) / 2, b0, b1, b2, tau) * 100 End Function

## Table 1 The term structure of interest rates - estimation details

Central bank Belgium Estimation method Svensson or Nelson-Siegel Minimised error Weighted prices Shortest maturity in estimation Treasury certificates: > few days Bonds: > one year Canada Merrill Lynch Exponential Spline Weighted prices Bills: 1 to 12 months Bonds: > 12 months Weighted prices Weighted prices 1 day Treasury bills: all Treasury Notes: : 1 month Bonds: : 1 year Germany Italy Svensson Nelson-Siegel Yields Weighted prices > 3 months Money market rates: O/N and Libor rates from 1 to 12 months Bonds: > 1 year Japan Smoothing splines Prices 1 day Effectively by price adjustments for bills No 1 to 10 years No No 1 to 10 years Up to 30 years Up to 10 years (before February 2002) Effectively by excluding bonds 3 months to 30 years Adjustments for tax distortions No Relevant maturity spectrum Couple of days to 16 years

Finland France

## Nelson-Siegel Svensson or Nelson-Siegel

No No

1 to 12 years Up to 10 years

Norway

Svensson

Yields

Up to 10 years

Spain

Yes No No

Sweden

Switzerland

Yields

No

1 to 30 years

BIS Papers No 25

xi

## Table 1 cont The term structure of interest rates - estimation details

Central bank United Kingdom1 Estimation method VRP (government nominal) VRP (government real/implied inflation) VRP (bank liability curve) United States Smoothing splines (two curves) Minimised error Yields Shortest maturity in estimation 1 week (GC repo yield) 1.4 years Adjustments for tax distortions No Relevant maturity spectrum Up to around 30 years Up to around 30 years

Yields

No

1 week 30 days

No No No

## Up to around 30 years Up to 1 year 1 to 10 years

The United Kingdom used the Svensson method between January 1982 and April 1998.

3.

## Zero-coupon yield curves available from the BIS

Table 2 provides an overview of the term structure information available from the BIS Data Bank. Most central banks estimate term structures at a daily frequency. With the exception of the United Kingdom, central banks which use Nelson and Siegel-related models report estimated parameters to the BIS Data Bank. Moreover, Germany and Switzerland provide both estimated parameters and spot rates from the estimated term structures. Canada, the United States and Japan, which use the smoothing splines approach, provide a selection of spot rates. With the exception of France, Italy and Spain, the central banks report their data in percentage notation. Specific information on the retrieval of term structure of interest rates data from the BIS Data Bank can be obtained from BIS Data Bank Services.

xii

BIS Papers No 25

## Treasury Yield Curve Methodology

This description was revised and updated on February 9, 2006. The Treasurys yield curve is derived using a quasi-cubic hermite spline function. Our inputs are the COB bid yields for the on-the-run securities. Because the on-the-run securities typically trade close to par, those securities are designated as the knot points in the quasi-cubic hermite spline algorithm and the resulting yield curve is considered a par curve. However, Treasury reserves the option to input additional bid yields if there is no on-the-run security available for a given maturity range that we deem necessary for deriving a good fit for the quasi-cubic hermite spline curve. In particular, we are currently using inputs that are not on-the-run securities. These are two composite rates in the 20-year range reflecting market yields available in that time tranche. Previously, a rolled-down 10-year note with a remaining maturity nearest to 7 years was also used as an additional input. That input was discontinued on May 26, 2005. More specifically, the current inputs are the most recently auctioned 4-, 13- and 26week bills, plus the most recently auctioned 2-, 3-, 5-, and 10-year notes and the most recently auctioned 30-year bond, plus the off-the-runs in the 20-year maturity range. The quotes for these securities are obtained at or near the 3:30 PM close each trading day. The long-term composite inputs are the arithmetic averages of the bid yields on bonds with 18 - 22 years remaining to maturity; and those with 20 years and over remaining to maturity, each inputted at their average maturity. The inputs for the three bills are their bond equivalent yields. To reduce volatility in the 1-year CMT rate, and due to the fact that there is no on-therun issue between 6-months and 2-years, Treasury uses an additional input to insure that the 1-year rate is consistent with on-the-run yields on either side of its maturity range. Thus, Treasury interpolates between the secondary bond equivalent yield on the most recently auctioned 26-week bill and the secondary market yield on the most recently auctioned 2-year note and inputs the resulting yield as an additional knot point for the derivation of the daily Treasury Yield Curve. The result of this step is that the 1year CMT is generally the same as the interpolated rate. Treasury has used this interpolated methodology since August 6, 2004. Treasury does not provide the computer formulation of our quasi-cubic hermite spline yield curve derivation program. However, we have found that most researchers have been able to reasonably match our results using alternative cubic spline formulas. Treasury reviews its yield curve derivation methodology on a regular basis and reserves the right to modify, adjust or improve the methodology at its option. If Treasury determines that the methodology needs to be changed or updated, Treasury will revise the above description to reflect such changes. Yield curve rates are normally available at Treasurys interest rate web sites as early as 5:00 PM and usually no later than 6:00 PM each trading day. Office of Debt Management Department of the Treasury
file:///C|/Documents%20and%20Settings/MC/Desktop/U_...ry%20-%20Treasury%20Yield%20Curve%20Methodology.htm (1 of 2)23/11/06 9:35:09 AM

Daily Treasury Yield Curve Rates Daily Treasury LongTerm Rates Daily Treasury Real Yield Curve Rates Daily Treasury Real Long-Term Rates Weekly Aa Corporate Bond Index

## The binomial model

Michael Carter
A derivative is an asset the value of which depends upon another underlying asset. Consider the simplest possible scenario, in which the underlying has two possible future states "up" and "down". The value of the derivative in these two states is Vu and Vd respectively.

Underlying

uS

Derivative

Vu

dS

Vd

The current value of the derivative is enforced by the possibility of arbitrage between the derivative and the underlying asset. Consider a portfolio comprising x shares and short one option.

Portfolio

x u S - Vu

xS-V

x d S - Vd
By choosing x appropriately, we can make the portfolio risk-free. That is, choosing x so that x u S - Vu = x d S - Vd

BinomialModel.nb

we have Vu - Vd x S = u -d Exercise Suppose S = 100, u = 1.05, d = 0.95, Vu = 5 and Vd = 0. Calculate the risk-free hedge. Show that it is risk-free by comparing the value of the portfolio in the two states. Substituting for x S, the value of the portfolio at time T in either state is Vu - Vd u x S - Vu = u J N - Vu u -d u Vu - u Vd - u Vu + d Vu = u-d d Vu - u Vd = u-d The value of the portfolio at time 0 is i d Vu - u Vd y x S - V = d Hu x S - Vu L = d j z z j u-d k {

where d is the discount factor. Let R = 1 d. Solving for V i d Vu - u Vd y z V = x S - d j z j u-d { k 1 i d Vu - u Vd y Vu - Vd z = - j z j R k u -d u-d { 1 i R Vu - R Vd - d Vu + u Vd y z z = j j R k u-d { 1 iR - d u- R y = j Vu + Vd z j z R k u-d u-d { R- d p = u-d

Letting

## we obtain the fundamental option valuation equation 1 V = H p Vu + H1 - pL Vd L R

The value of the option at time 0 is the discounted expected value of the payoff, where the expectation is taken with respect to the synthetic or risk-neutral probabilities (defined above) and discounted at the risk-free rate.

BinomialModel.nb

This value is enforced by arbitrage. To see this, suppose that option is selling at a premium above its true value. 1 V > H p Vu + H1 - pL Vd L R

An arbitrageur can sell n options and buy n x shares, borrowing the net cost n Hx S - V L. At time T, the portfolio is worth nHx u S - Vu L in the "up" state and (equally) nHx d S - Vd L in the "down" state. Repaying the loan plus interest of R n Hx S - V L, the arbitrageur makes a risk-free profit of profit = payoff loan = n Hx u S - Vu L - R n Hx S - V L Vu - Vd i d Vu - u Vd y = n j z - R n J - V N z j u-d u -d k { 1 = n R JV - H p Vu + H1 - pL Vd LN R

Conversely, if the option is selling at a discount, a risk-free profit can be made by reversing this transaction, buying options and selling shares. Exercise Suppose S = 100, u = 1.05, d = 0.95, Vu = 5, Vd = 0 and R = 1.01. Calculate the true value of the option. Suppose that the option is priced at 3.10. Find a profitable arbitrage. Remarks R is the risk-free total return for the period T. It is given either by R = 1 + r T or R = r T where r is the risk-free (spot) rate for the period T. It is common to use continuous compounding in option evaluation, although discrete compounding is convenient (and appropriate) for the binomial model. The risk-neutral probabilities p and 1 - p are those probabilities at which the expected growth rate of the underlying asset is equal to the risk-free rate, that is p u S + H1 - pL d S = R S

Solving for p,

## In the language of probability, p makes the discounted asset price a martingale.

p Hu - d L S + d S = R S p Hu - d L S = HR - dL S R- d p = u-d

BinomialModel.nb

Exercise What condition is required to ensure the existence of this equivalent martingale measure (probability)? The current asset price S will depend upon the real probabilities q. The expected rate of return q u S + H1 - qL d S - S m = = q u + H1 - qL d - 1 S

## must be sufficient to induce investors to hold the asset.

The hedge ratio x is equal to delta of the option, the sensitivity of the option price to changes in the price of the underlying DV Vu - Vd x = = Hu - dL S DS

For a vanilla call option at maturity with a strike price of K Vu = max Hu S - K, 0L and Vd = max Hd S - K, 0L

## For a vanilla put option at maturity with a strike price of K Vu = max HK - u S, 0L

For a vanilla European option prior to maturity, Vu and Vd are the discounted expected values of the option in the "up" and "down" states respectively. For a vanilla American option prior to maturity, Vu and Vd are the maximum of the intrinsic values and discounted expected values of the option in the "up" and "down" states respectively.

and Vd = max HK - d S, 0L

## The Black-Scholes formula for stock indices, currencies and futures

Michael Carter
The standard Black-Scholes formula is c = S0 NHd1 L - K -r T NHd2 L

where

## This can be rewritten as

lnHS0 KL + Hr + s2 2L T lnHF0 KL + s2 T 2 !!!! , d2 = d1 - s T d1 = = !!!! !!!! s T s T c = S0 NHd1 L - K -r T NHd2 L = -r T HS0 r T NHd1 L - K NHd2 LL = -r T HF0 N Hd1 L - K N Hd2 LL

where F0 = S0 r T is the expected forward price of S determined at time 0 under the risk-neutral distribution. A straightforward proof is given in the appendix.

Continuous dividend
If the underlying assets pays a continuous dividend yield at the rate q, its forward price is F0 = S0 Hr-qL T

and therefore the call option value is c = -r T HS0 -Hr-qL T NHd1 L - K NHd2 LL = S0 - q T NHd1 L - K -r T NHd2 L

with

Foreign currency

## The forward price of a foreign currency is given by F0 = S0 Hr-r f L T

GeneralizedBlackScholes.nb

which is known as covered interest parity. Therefore, the value of a foreign currency option is c = -r T HS0 Hr- f f L T NHd1 L - K NHd2 LL = S0 - r f T NHd1 L - K -r T NHd2 L

with

## lnHS0 KL + Hr - r f + s2 2L T lnHF0 KL + s2 T 2 !!!! d1 = = !!!! , d2 = d1 - s T !!!! s T s T

Future
The value of a call option on a future is given directly by c = -r T HF0 NHd1 L - K NHd2 LL

with

## lnHF0 KL + s2 T 2 !!!! d1 = , d2 = d1 - s T !!!! s T

All these cases can be subsumed in a generalized Black-Scholes formula c = S0 Hb-rL T NHd1 L - K -r T NHd2 L

where

where b is the cost-of-carry of holding the underlying security, with b= r non-dividend paying stock

## Put-call parity gives p + S0 Hb-rL T = c + K - r T

so that

GeneralizedBlackScholes.nb

Traditionally, the Black-Scholes model is implemented in dividend yield form c = S0 - q T NHd1 L - K -r T NHd2 L

p = H S0 Hb-rL T NHd1 L - K -r T NHd2 LL + K - r T - S0 Hb-rL T = K -r T KH1 - NHd2 LL - S0 Hb-rL T H1 - NHd1 L L = K -r T NH-d1 L - S0 Hb-rL T NH-d1 L p = K -r T NH-d2 L - S0 - q T NH-d1 L

with the specific cases being obtained with the following substitutions q = 0 q = q q = rf q = r non-dividend paying stock

lnHS0 KL + Hr - q + s2 2L T !!!! d1 = !!!! , d2 = d1 - s T s T stock with dividend yield q currency option futures options

Note that even if the dividend yield is not constant, the formulae still hold with q equal to the average annualized dividend yield during the life of the option.

Appendix
THEOREM. If S is lognormally distributed and the standard deviation of ln S is s then PrHS > KL = NHd2 L

and

where

Proof:

## E@maxHS - K, 0LD = EHSL NHd1 L - K NHd2 L

(1)

GeneralizedBlackScholes.nb

## For the second part, see Hull (2003: 262-263).

Recognising that (under Black-Scholes assumptions) EHST L = F0 = S0 r T and s = s formula for a call option is immediate.

## !!!! T , the Black-Scholes

Implementation of Black-Scholes option pricing Michael Carter, 2004 Option Explicit ' ************************************************************ ' Option values Function BSCall(S As Double, K As Double, r As Double, q As Double, sigma As Double, T As Double) As Double Dim d1 As Double Dim d2 As Double d1 = (Log(S / K) + (r - q + sigma * sigma / 2) * T) / (sigma * Sqr(T)) d2 = d1 - sigma * Sqr(T) BSCall = S * Exp(-q * T) * Application.NormSDist(d1) - K * Exp(-r * T) * Application.NormSDist(d2) End Function Function BSPut(S As Double, K As Double, r As Double, q As Double, sigma As Double, T As Double) As Double Dim d1 As Double Dim d2 As Double d1 = (Log(S / K) + (r - q + sigma * sigma / 2) * T) / (sigma * Sqr(T)) d2 = d1 - sigma * Sqr(T) BSPut = K * Exp(-r * T) * Application.NormSDist(-d2) - S * Exp(-q * T) * Application.NormSDist(-d1) End Function ' ************************************************************ ' The Greeks Function BSCallDelta(S As Double, K As Double, r As Double, q As Double, sigma As Double, T As Double) As Double Dim d1 As Double d1 = (Log(S / K) + (r - q + sigma * sigma / 2) * T) / (sigma * Sqr(T)) BSCallDelta = Exp(-q * T) * Application.NormSDist(d1) End Function Function BSPutDelta(S As Double, K As Double, r As Double, q As Double, sigma As Double, T As Double) As Double Dim d1 As Double d1 = (Log(S / K) + (r - q + sigma * sigma / 2) * T) / (sigma * Sqr(T)) BSPutDelta = Exp(-q * T) * (Application.NormSDist(d1) - 1) End Function

Function BSCallGamma(S As Double, K As Double, r As Double, q As Double, sigma As Double, T As Double) As Double Dim d1 As Double d1 = (Log(S / K) + (r - q + sigma * sigma / 2) * T) / (sigma * Sqr(T)) Debug.Print d1 BSCallGamma = Exp(-q * T) * Application.NormDist(d1, 0, 1, False) / (S * sigma * Sqr(T)) End Function Function BSPutGamma(S As Double, K As Double, r As Double, q As Double, sigma As Double, T As Double) As Double BSPutGamma = BSCallGamma(S, K, r, q, sigma, T) End Function

## Dealing with dividends

Michael Carter
European options
The Black-Scholes formula is readily adapted to continuous dividends yields (see The Black-Scholes formula for stock indices, currencies and futures). The price of a dividend paying stock typically falls when the stock goes ex-dividend. A common approach to dealing with discrete dividends is to subtract the present value of the dividends from the current stock price before applying the Black-Scholes formula (Hull 2003: 253). For example, if dividends d1 , d2 , , dn are anticipated at times t1 , t2 , , tn , the present value of the dividends is D = r ti di
n i=1

and the option is valued as cHS - D, K, r, s, tL or pHS - D, K, r, s, tL where c and p are the Black-Scholes formulae for call and put options respectively. This is problematic, not the least because historical volatility measures refer to the stock price including dividends (Fischling 2002). Bos and Vandemark (2002) propose a simple modification that closely matches numerical results. Instead of subtracting the full present value of future dividends from the current stock price, they propose apportioning each dividend between the current price and the strike price in proportion to the relative time. Specifically, if dividends d1 , d2 , , dn are anticipated at times t1 , t2 , , tn , they compute "near" and "far" components T - ti ti Dn = r ti di and D f = r ti di T T i=1 i=1
n n

## The option is valued as

cHS - Dn , K + D f , r, s, tL or pHS - Dn , K + D f , r, s, tL where c and p are the Black-Scholes formulae for call and put options respectively.

American options
Dealing with dividends for American options is more complicated, since dividends are closely interwined with the incentives for early exercise. This is discussed in the complementary note American options.

Dividends.nb

## The binomial model

In a risk-neutral world, the total return from the stock must be r. If dividends provide a continuous yield of q, the expected growth rate in the stock price must be r - q. The risk-neutral process for the stock price therefore is S = Hr - qL S t + s S z

The can be approximated in the simple binomial model by adjusting the risk-neutral probabilities, so that p u S0 + H1 - pL d S0 = S0 Hr-qL Dt Hr-qL Dt - d p = u-d

or

With this amendment, the binomial model can be used to value European and American options on indices, currencies and futures. Discrete proportional dividends are also straightforward to incorporate into the binomial model. Whenever the stock pays a proportional dividend, the stock price tree must be adjusted downwards when the stock goes ex-dividend (Hull 2003: 402). Discrete cash dividends are more difficult, since the adjusted tree becomes non-recombining for nodes after dividend date. This leads to an impractical increase in the number of nodes. We can finesse this problem in an analogous way to the treatment of cash dividends with the Black-Scholes formula. Assume that the stock price S has two components - a risky component S * with volatility s* and the dividend stream - r t D. Develop a binomial tree to represent the stochastic part S * with r Dt - d * * * S0 = S0 - - r t D, p = , u = s Dt , d = -s Dt u-d Then add back the present value of the dividends to each node (prior to the ex-dividend date) to obtain a binomial tree representation of S, which can then be used to value contingent claims in the usual way. This procedure could be enhanced by apportioning the dividends between current price and strike price according to the procedure of Bos and Vandemark discussed above.

Hedging strategies
Michael Carter
Preliminaries

Introduction
Consider a derivative (or portfolio of derivatives) on a single underlying asset. Its value depends upon the current asset price S and its volatility s, the risk-free interest rate r, and the time to maturity t. That is, V = f HS, r, s, tL. (It also depends upon constants like the strike price K.) Taking a Taylor series expansion, the change in value over a small time period can be approximated by f f f f 1 2 f dV dS + dr + ds + dt + dS2 S r s t 2 S 2 + other second order terms + higher order terms (1)

The partial derivatives in this expansion are known collectively as "the Greeks". They measure the sensitivity of a portfolio to changes in the underlying parameters. Specifically f D = Delta measures the sensitivity of the portfolio value to changes in the price of the underlying S f r = Rho measures the sensitivity of the portfolio value to changes in the interest rate r f v = Vega measures the sensitivity s of the portfolio value to changes in the volatility of the underlying f Q = Theta measures the sensitivity of the portfolio value to the passage of time t D 2 f G = = Gamma measures the sensitivity of delta to changes in the price of the underlying, S S 2 or the curvature of the S - V curve. Substituting in (1), the change in value of the portfolio can be approximated by 1 dV DdS + rdr + v ds + Qdt + GdS2 2 (2)

Because differentiation is a linear operator, the hedge parameters of a portfolio are equal to a weighted average of the hedge parameters of its components. In particular, the hedge parameters of a short position are the negative of the hedge parameters of a long position. Consequently, (2) applies equally to a portfolio as to an individual asset. The sensitivity of a portfolio to the risk factors (S, r, s) can be altered by changing the composition of the portfolio. It can be reduced by adding assets with offsetting parameters.

HedgingStrategies.nb The Greeks are not independent. Any derivative (or portfolio of derivatives) V = f HS, r, s, tL must satisfy the Black-Scholes differential equation 2 f f f 1 + r S + s2 S 2 = r V S 2 t S 2 Substituting P = Q t P = D S 2 P = G S 2

it follows that the Greeks must satisfy the following relationship 1 Q + r S D + s2 S 2 G = r V 2 (3)

## Computing the Greeks

The Greeks of vanilla European options have straightforward formulae, which can be derived from the Black-Scholes formula. The generalized Black-Scholes formulae for European options are c = S -q T NHd1 L - K -r T NHd2 L

where

## lnHS KL + Hr - q + s2 TL 2 d1 = !!!! , s T Delta Call NHd1 L

-q T

p = K -r T NH-d2 L - S -q T NH-d1 L

lnHS KL + Hr - q - s2 TL 2 d2 = !!!! = d1 - s s T
-q T

Gamma

Rho Vega

Theta

K T -r T NHd2 L

## -q T S s N ' Hd1 L - !!!! 2 T

- K T -r T NH-d2 L -q T S

## -q T N ' Hd1 L !!!! Ss T

Put HNHd1 L - 1L

- q -q T S NH-d1 L - r K -r T NH-d2 L

## !!!! T N ' Hd1 L

HedgingStrategies.nb

As an example of the derivation, for a call option D d1 1 G = = -q T N ' Hd1 L = -q T N ' Hd1 L !!!! S S Ss T

Calculating vega from the Black-Scholes formula is an approximation, since the formula is derived under the assumption that volatility is constant. Fortunately, it can be shown that it is a good approximation to the vega calculated from a stochastic volatility model (Hull 2003: 318). Some exotic options (e.g. barrier options) have analogous formulae. However, for most exotic options and vanilla options, the Greeks must be estimated by numerical techniques. Since these are the type of options for which institutions require such information, this motivates are interest in the accurate computation of option values and sensitivities. In principle, the Greeks can be estimated by numerical differentiation. For example, cHS1 L - cHS0 L D = S1 - S0 and DHS1 L - DHS0 L G = S1 - S0

However, this is not always the most appropriate method, as the small size of the denominator in the limit magnifies errors in the numerator.

Hedging
In the previous section, we showed the sensitivity of the value of a portfolio of derivatives of a single underlying to its risk factors can be approximated by 1 dV DdS + rdr + v ds + Qdt + GdS2 2 (4)

Hedging is the process of modifying the portfolio to reduce or eliminate the stochastic elements on the righthand side. Delta-hedging eliminates the first-term on the right-hand side by making the portfolio delta neutral (D = 0). This can be done by taking an offsetting position in the underlying asset, as represented by the tangent to the portfolio at the current asset price.

HedgingStrategies.nb

## 20 17.5 15 12.5 10 7.5 5 2.5 90 100 110 120

Delta-gamma hedging also eliminates the last term in (4) by making the portfolio gamma neutral (G = 0). Since the underlying is gamma neutral, delta-gamma hedging requires the addition of other derivatives to the portfolio. Curvature (Gamma) increases as an option approaches maturity, especially for at-the-money options.

Increasing curvature approaching maturity - 1, 3 ,6 months 20 17.5 15 12.5 10 7.5 5 2.5 90 100 110 120 Time

HedgingStrategies.nb

Call Gamma over time 0.07 0.06 0.05 0.04 0.03 0.02 0.01 In the money 1 2 3 4 5 6 Months to expiry Out of the money At the money

## 20 17.5 15 12.5 10 7.5 5 2.5 90

Recall the fundamental relationship (3) 1 Q + r S D + s2 S 2 G = r V 2 For a delta-gamma-neutral portfolio, this reduces to Q=rV The portfolio earns the risk-free rate. The closer that hedging option matches the target option, the more robust will be the hedge provided (i.e. the wider the range of parameter variation that will be neutralised). The hedge may be improved by combining two or more options. For example, combining two options, one with a shorter and one with a longer time to maturity

Hedge option

100

110

120

HedgingStrategies.nb

would a more accurate match to the gamma of the target option. There is a tradeoff between the robustness of the hedge (the frequency of hedge adjustments) and the number of options that must be purchased and managed. The actual performance of a hedge may not reach its theoretical potential (for example, because of model errors and transaction costs). Consequently, adding too many options to the hedge may give results that are better on paper than in reality. A hedge comprising at least two derivatives, in addition to the underlying, can be used to eliminate three terms in equation (3). A hedge comprising three derivatives, in addition to the underlying, can be used to neutralize all four stochastic terms in equation (3), eliminating all risk to a first-order approximation. In principle, a hedge can be found by solving a system of linear equations. Suppose there are m potential hedging instruments. Let x1 , x2 , , xm denote the amount of hedging instrument j, and let xS denote the amount invested in the underlying. Then, we seek a solution to the following system of equations. xS + x1 D1 + x2 D2 + + xm Dm = D x1 G1 + x2 G2 + + xm Gm = G x1 v1 + x2 v2 + + xm vm = v x1 r1 + x2 r2 + + xm rm = r Provided that the Greeks of the hedging instruments are linearly independent, there will be a unique solution if m = 3 and multiple solutions if m > 3. However, the solutions may not be economically sensible. Since T appears explicitly in the formula for vega, options of different maturities will be most effective in hedging against volatility risk. Although interest rate risk can be hedged by options, it may be cost-effective and certainly more straightforward to hedge interest rate risk by trading bond future contracts, since they are pure rho instruments, with no impact on delta, gamma or vega. Example

Rules of thumb
Consider a call option that is at-the-money forward, that is K = F0 = S0 r T Then the Black-Scholes formula (assuming no dividend yield) simplifies to c = S0 HNHd1 L - NHd2 LL

where

ln HS0 S0 L - r T + Hr + s2 2L T 1 !!!! ln HS0 F0 L + Hr + s2 2L T = !!!! = s T d1 = !!!! 2 s T s T d2 = d1 - s Therefore the call option value is 1 !!!! 1 !!!! c = S0 JNJ s T N - NJ- s T NN 2 2 !!!! Provided that s T is small, this can be approximated by c = S0 0.4 s !!!! T 1 !!!! !!!! T = - s T 2

Since the peak of the standard normal density function is 1 rectangle of height 0.4.

## The standard normal distribution 0.4 0.3 0.2 0.1

-3

-2

-1

This formula can be inverted to obtain a "rough and ready" estimate of the implied velocity from quoted option prices, using the average of the two nearest-the-money call options. 1 c s = 2.5 !!!! S0 T

## Greeks and the binomial method

Numerical differentiation
Delta measures the sensitivity of the option value to changes in the price of the underlying. It is defined as V S lim S
dS 0

V S

dS dS

V S

## An obvious method to evaluate V S dS dS V S

is to compute

for small dS. This is known as the forward difference. A better alternative (though more costly to compute) is V S dS V S 2 dS which is known as the central difference. The other first-order Greeks (rho, theta and vega) can be estimated similarly. Gamma is the derivative of delta, or the second derivative of v S . Using central differences, gamma can be estimated by S
1 2

dS

dS dS

1 2

dS

V S dS V S dS

V S

V S dS dS

V S dS V S dS

V S

V S dS dS

dS 2V S dS
2

dS

V S

dS

V S

dS

## Numerical differentiation and the binomial tree

Numerical differentiation is not the best method to be applied to the binomial tree. The problem is illustrated in the following diagram.

Greeks.nb

## Binomial 12 10 8 6 4 2 82.5 87.5 90 92.5 95 97.5

Implied trees
Michael Carter
Preliminaries

Implied trees are one practical method to deal with the volatility smile. The objective is to build a tree for the underlying that reproduces the market prices of traded derivatives. In other words, the resulting tree is calibrated to current market data. The calibrated tree can then be used to to compute hedge parameters for traded options to price non-standard derivatives (American options and exotics) on the same underlying. The starting point is current market prices and quotations for calls and puts of various strikes and maturities. Typically, these market data are converted into a table of implied volatilities. This table is then used to interpolate volatilities and market prices for arbitrary strikes and maturities.

Binomial tree
The one-step tree The value of a one-period call option struck at the initial price S is 1 Vc S R pu Su S (1) u S is the price of the asset following an up-tick and 1 R is the

## where pu is the risk-neutral probability of an up-tick, Su 1 Vp S where pd 1 R pd S Sd

one-period discount factor. Similarly, the value of a one-period put option struck at S is (2) d S is the resulting asset price.

## pu is the probability of a down-tick, and Sd

In the binomial model, the risk-neutral (arbitrage free) probability pu is that which makes the expected return on the asset equal to the risk-free rate of return, that is pu Su where R
r q t

pu Sd

RS

## Solving for pu R pu u d or d pu RS Su Sd Sd (3)

If we add an additional constraint such as u 1 d, then we can solve for the binomial tree consistent with market data. For example, if we have the market price Vc , we obtain from solving equations (1) and (3) the following formula for u, from which we can derive Su , Sd and pu .

ImpliedTrees.nb

S u RS

Vc Vc

Alternatively, we can use the market price V p of a put to obtain from (2) and (3) RS u S Vp Vp 1 if and only if the dividend yield equals zero.

Note that R

## Given u, we can derive S S Su or S RS Su S Vp , Vp Sd S S RS Vp , Vp pu RS Su Sd Sd RS Vc Vc S RS , Sd S Vc Vc RS , pu Su Sd Sd

We can also compute the state contingent prices (discounted probabilities) at the new nodes u pu and d 1 pu

These will be required in the next step. We have shown how we can infer a unique one-step binomial tree consistent with given a single market price. Note that the inferred tree will differ depending upon whether we start with a call or a put price, unless the prices are consistent. In practice, consistency is usually imposed by starting with an implied volatility for relevant term and strike, and imputing prices for the call or put using a binomial tree with the requisite volatility. This required implied volatility is obtained by interpolation from the implied volatilities of quoted options. Assuming that we are dealing with European options, the implied volatility of quoted options is obtained using the BlackScholes formula. Then, the recommended practice is to use these data to interpolate implied volatilities for the nodes of the tree. The implied prices for options struck at nodes of the tree are then obtained from a binomial model with the requisite volatility.

The two - step tree To complete the second step, we can arbitrarily set the asset price along the middle branch of the tree equal to the starting price. Given this base line, we can determine the top and bottom nodes of the tree. Suppose we know the value vu of a oneperiod call option struck at S From equation (1) we have 1 vu S with R pu u d d RS uS dS dS RS Sup Sd Sd R pu Sup S Su , the upper node in the previous step. Then we are in a position analogous to the first step.

## Solving for Sup gives

ImpliedTrees.nb

Solving for Sup gives S2 Sup S Sd S Sd S0 . S0 , we can determine the bottom node of the tree from the value vd of a one-period put option RS 1 pu S Sdown and pu Su Sdown Sdown vu vu (4)

## struck at the bottom node in the previous step, solving

Su S Su

vd vd

(5)

It remains to supply the supposed data - the values of the one-period options struck at the Su and Sd . We now show how this can be inferred from market data. Let Vc Su , 2) denote the value of a call option struck at Su and expiring after two periods. This value can be interpolated from market data. After one period, there are two possibilities. Either the price increased to Su or decreased to Sd . In the former case, the option is then worth vu . In the latter case it is worthless, as it is bound to expire out of the money. Consequently Vc Su , 2 pu vu 1 p 0 pu vu

## Similarly the value v p Sd , 2) of a two-period put option struck at Sd is V p Sd , 2 which implies vd V p Sd , 2 1 pu pu 0 1 p vd 1 pu vd

Throughout this note, we will adopt the convention that a capital V refers to a market value, while a small v refers to an imputed value.

The n-step tree In essence, building an n-step tree involves repeating the preceding two steps again and again. To facilitate this, we need to define some more precise notation.
Notation

Let Si, j denote the asset price at the jth node of the ith step. That is, i, j denotes the node reached after j upward and i state contingent price at the i, j option (struck at Si, j ).
th

downward steps. Si,0 is the minimum price attained after i steps while Si,i is the maximum price. Similarly, let i, j denote the node. Let pi, j denote the probability of an uptick at the i, j
th

node with 1

pi, j the

probability of a downtick. Finally, vi, j denotes the value of at node i of a one-period (maturing at time i

1) at-the-money

ImpliedTrees.nb

4,4 3,3 2,2 1,1 0,0 S0,0 v0,0 p0,0 1,0 S1,0 v1,0 p1,0 2,0 S2,0 v2,0 p2,0 3,0 S3,0 v3,0 p3,0 4,0 S4,0 v4,0 p4,0 S1,1 v1,1 p1,1 2,1 S2,1 v2,1 p2,1 3,1 S3,1 v3,1 p3,1 4,1 S4,1 v4,1 p4,1 S2,2 v2,2 p2,2 3,2 S3,2 v3,2 p3,2 4,2 S4,2 v4,2 p4,2 S3,3 v3,3 p3,3 4,3 S4,3 v4,3 p4,3 S4,4 v4,4 p4,4

## State contingent prices and probabilities

We have seen in a previous lecture how state prices can be calculated inductively from previous values i,0 i, j 1 1 pi
1,0

1,0 , 1, j

i,i pi

pi
1, j 1

1,i 1

i 1 ,i ,

pi

1, j

1, j 1

while the previous probabilities are computed from current asset prices pi R Si
1, j 1, j 1

Si, j Si, j pi
1,_

Si, j

## The sequence of calculation is Si,_

Forward option prices

i,_ . It remains to infer the asset prices from the market data.

Let Vc Si, j , i

1 denote the value of a call option struck at Si, j at time t0 and maturing at time i

## t , that is maturing after

i 1steps in the tree. We can infer this value by interpolation from market data. Note that there is no need to specify the current asset price of the multi-period options - it is always the initial asset price S0,0 . Now consider the possibilities for this option one period prior to maturity. Let vi,k Si, j denote the value of this option at time i t if the asset price reaches Si,k . Then
i

1
k 0

Out
j 1

At
i

k j 1

1
k 0

## i,k vi,k Si,k

i, j vi, j Si,k

(6)

pi,k max Si

1,k 1

Si, j , 0

pi,k max Si

1,k

Si, j , 0

(7)

where is the one-period discount factor and pi,k is the risk-neutral probability applicable at node i, k .

ImpliedTrees.nb

where is the one-period discount factor and pi,k is the risk-neutral probability applicable at node i, k . For all states k j, the option must necessarily expire out of the money. Therefore vi,k Si, j 0 for all k j, and the first term

in equation (6) is zero. For all k operator from (7) to give vi,k Si, j pi,k Si

## j we can eliminate the max

1,k 1

Si, j

pi,k Si

1,k

Si, j

pi,k Si

1,k 1

pi,k Si

1,k

Si, j

(8)

Furthermore, the risk-neutral probability pi,k satisfies the equation pi,k Si where R
1,k 1

pi,k Si

1,k

R Si,k

1 equals the one-period risk neutral return. Substituting in (8) gives vi,k Si, j R Si,k Si, j for k j

## Substituting this in (6) gives Out Vc Si, j , i where vi, j 1 0 At

i

In i,k R Si,k
k j 1

i, j vi, j Si,k

Si, j

vi, j Si, j is the only unknown. (For the at-the-money option vi, j , we can dispense with the argument Si, j , since

there is no ambiguity.) Solving for vi, j = vi, j Si, j , Vc Si, j , i vi, j Similarly, the value of an i 1
i k j 1 i,k

R Si,k

Si, j (9)

i j 1

At
i

V p Si, j , i

1
k 0

k 0

## i,k vi,k Si, j

i, j vi, j Si, j
k j 1

where vi,k Si, j is the value of the option at node i, k . For k vi,k Si, j pi,k Si, j Si, j Si, j Conversely, for k Si
1,k 1 1,k 1

1,k 1,k

1 1

## pi,k Si, j pi,k Si

pi,k Si R Si,k

j, the option will expire out of the money with vi,k Si, j =0. Consequently
j 1

V p Si, j , i and

1
k 0

i,k Si, j

R Si,k

i, j vi, j

v p Si, j , i vi, j

j 1 k 0 i,k

Si, j

R Si,k

(10)

i, j

To summarize, vi, j denotes the implied value at node i, j of an at-the-money call or put option struck at Si, j and expiring after one-period. The choice of call or put is arbitrary. It is conventional to use (9) to determine vi, j in the top half of the tree and use (10) determine vi, j in the bottom half of the tree. The choice of call or put along the horizontal is arbitrary. Note that, once we have determined the asset prices at stage i in the tree, we can then determine state prices and forward option prices at the same stage. The sequence of calculation is Si,_ pi 1,_ i,_ vi,_ .

ImpliedTrees.nb

Note that, once we have determined the asset prices at stage i in the tree, we can then determine state prices and forward option prices at the same stage. The sequence of calculation is Si,_ pi 1,_ i,_ vi,_ .
Asset prices

It remains to determine the asset prices in the next stage of the tree, which we compute from the forward asset prices in the previous stage. If the stage i is even, then we arbitrarily set asset price of the central node equal to the starting price. That is Si,i 2 S0,0 , i 2, 4, 6,

This is known as the centering condition. If the stage i is odd, we determine the values of the two central nodes in identical fashion to the one-stage tree above. Let m i 2 , the largest integer less than i 2. m points to the central node when i is even, and to the lower of the two central nodes when i is odd.

i, j Si, j vi, j

1 1

pi, j

i Si vi

1, j

1, j 1, j

pi

1, j

## i, j Si, j vi, j pi, j

Now consider a node above the central node. A one-period call option struck at the preceding (down) node has the value vi
1, j

pi

j, j

Si, j

Si

1, j

where pi

R Si
j, j

1, j 1

Si, j Si, j

Si, j

in which the only unknown is Si, j 1 . Starting at the central node, we can successively solve for all the nodes above the center Si, j R Si2 1, j
1

Si
1, j

1, j

Si, j

Si, j vi vi
1, j

1, j

R Si

Si, j

m m

1, m 2, m

2, , i , i even 3, , i , i odd

Similarly, we can successively compute the prices at all nodes below the central node using the values of one-period put options struck at the preceding (up) node. vi giving Si, j R Si2 1, j R Si Si
1, j 1, j 1, j

pi

j, j

Si

1, j

Si, j

where pi

R Si
j, j

1, j 1

Si, j Si, j

Si, j

Si, j

1 1

Si, j vi

1 vi 1, j

Si, j

, j
1, j

1, m

2, , 0

## The resulting tree

There is a unique binomial tree fitting a given set of market data (once the central trunk has been specified). The resulting tree is distorted, as the asset prices adapt to fit the volatility at different nodes in the tree.

ImpliedTrees.nb

## An implied binomial tree

The procedure can be adapted to apply to American style options and options with dividends (Chriss 1996). Nothing in the procedure guarantees that the transition probabilities are nonnegative. If and when "wrong" probabilities arise, the tree must be adjusted to eliminate them. The same problem arises with trinomial trees.

Trinomial trees
Trinomial trees give additional degrees of freedom. We can build an asset price tree with regularly spaced nodes, and then use market data to determine the transition probabilities. This additional flexibility is especially useful where the market data is noisy, or where it is desired to use the fitted tree to price certain exotic options like barrier options. Let S0,0 denote the root of the tree, with nodes at step i being labelled Si , i , Si, tree, the value of a call option struck at K and expiring at i T is (S
i i i 1,

Vc K, i
j i

## i, j Si, j K and Si, j i,i Si,i Si,i

K
j j 1 1

i, j Si, j K. In particular,

## where j is such that Si , j Vc Si,i 1 , i

from which we can deduce i,i Similarly Vc Si,i 2 , i so that i,i Vc Si,i 2 , i
1

## Vc Si,i 1 , i Si,i Si,i

1

i,i Si,i

Si,i

i,i

Si,i

Si,i

i,i Si,i
1

Si,i

Si,i

Si,i

Proceeding in this fashion, we can iteratively deduce the state contingent prices at each node of the tree from the value of options struck at adjacent nodes. Computationally, it is preferable to use call options to calibrate the top of half of the tree, and then switch to put options for the bottom half of the tree.

ImpliedTrees.nb

Proceeding in this fashion, we can iteratively deduce the state contingent prices at each node of the tree from the value of options struck at adjacent nodes. Computationally, it is preferable to use call options to calibrate the top of half of the tree, and then switch to put options for the bottom half of the tree. Given the state contingent prices, we can then deduce the transition probabilities at each nodes. At the root node, for example, 1,1 Similarly pd 0,0 Furthermore 2,2 pu 1,1 so that pu 1,1 1,1 1 2,2 1,1 1,
1

pu 0,0 so that

pu 0,0

1,1

and pm 0,0

pu 0,0

pd 0,0

Next we observe that the risk-neutral transition probabilities must satisfy the equations pu S2,2 1,1 pu 1,1 where R
r q t

pd S2,0 1,1 1

R S1,1

pm 1,1

## is the risk-neutral drift.

Given pu , we can solve these equations for pm and pd 1,1 1,1 1,1 pm 1,1 R S1,1 S2,0 S2,1 pu S2,2 1,1 S2,0 S2,0 , pd 1,1 1 pu 1,1 pu 1,1

Next, we can use pm to deduce the value of pu from the equation 1,1 1,0 2,1 which gives pu 1,0 2,1 pm 1,1 1,1 1,0 pm 1,1 1,1 pu 1,0 1,0

Iterating this procedure, we can generate all the transition probabilities in the tree, using the following recursive system of equations.

(12)

ImpliedTrees.nb

pu i,i

1,i 1

i,i i
1,k 1

pu i,k

pm i,k i,k

i,k

, pu Si i,k
1,k 1

k Si

i
1,k 1

pm i,k pd i,k

R Si,k

Si

1,k 1

Si 1 pu i,k pu i,k

1,k

Si

1,k 1

To avoid the accumulation of numerical errors, it is recommended to compute the top half of the tree using (12) and then compute the bottom half using analogous recursions working from the bottom up, namely pd i, i
i 1, i 1

i, i

pd i,

1, k 1

pm i, i,
k k

k 1

i,

k 1

, Si Si

k Si

i (13)

pm i,

Si
k

1, k 1

R Si, Si

pd i,

1, k 1 1, k

1 ,k 1

1, k 1

pu k i,

pu k i,

pu k i, i, i 1, , 0 for successive i 1, 2, 3, .

## Specifically, in (12) and (13), let k

We must e sure that the transition probabilities are all nonnegative. There are two ways in which negative probabilites can arise the state space is inappropriate the volatility skew is extreme at particular observations A robust way to avoid the first problem is to build a tree whose volatility is equal to the maximum implied volatility in the data. Once a market-consistent tree has been constructed, any contingent claim can be priced in the standard manner. For European-style derivatives, we can use the state-contingent prices at maturity; for American-style derivatives, we use backward induction.

(12)

## Binomial model - implementation

Michael Carter
The following is the pseudocode for an efficient implementation of the binomial method for American and European options. BinomialAmericanCall (S0 , K, r, q, s, t, nL /* initialize parameters */ Dt = t/n; !!!!! u = s Dt ; d = 1/u; d = -r Dt ; Hr-qL Dt p = d ; p = 1- p; u-d pu = d p; pd = d H1 - pL; /* allocate storage */ vectors s[-n,n], v[-n,n]; /* initialize the tree */ s[0] = S0 ; /* calculate potential asset prices */ for j = 1 to n s[j] = u * s[j-1]; s[-j] = d*s[-j+1]; end; /* calculate option exercise values */ for j = -n to n by 2 v[j] = max (s[j] - K,0); end; /* calculate option values by backward induction */ for i = n - 1 to 0 by - 1 for j = -i to i by 2 v[j] = max H pu * v[j+1] + pd * v[j-1], s[j] - K); end; end; /* return option value */ BinomialAmericanCall = v[0] The corresponding put option can be evaluated by taking the negative of S and K . BinomialEuropeanCall (S0 , K, r, q, s, t, nL /* initialize parameters */

## /* pu and pd are discounted probabilities */

BinomialProgramming.nb

Dt = t/n; !!!!!! u = s Dt ; d = 1/u; Hr-qL Dt - d p = ; u-d 1- p p = p ; /* calculate maximum asset price and probability*/ s = un S0 ; P = pn ; EV = P * maxHs - K, 0L; /* proceed down final asset prices calculating expected values */ for j = n - 1 to 0 by -1 j+1 P = j P p; ns = d 2 s; IV = maxHs - K, 0L; if (IV > 0) EV = EV + P * IV; else break; endif end; /* return option value */ BinomialEuropeanCall = -r t EV;
1 H L 10-316 . For example, the Excel VBA data type Double has a minimum value of 2 4.94065645841247 * 10-324 , so that n = 1000 is a practical maximum for this algorithm. However, the algorithm could be modified to exclude very low probability final prices and so increase the number of branches. 1050 1 NOTE: We have to be careful that P = pn does not cause an underflow error. As T , p and 2

Implementation of binomial model for option pricing Michael Carter, 2004 Option Explicit Option Base 0 Enum OptionType callOption = 1 putOption = -1 End Enum Enum OptionStyle American = 1 European = 2 End Enum Function RecursiveBinomialTree(S As Double, K As Double, u As Double, _ d As Double, p As Double, delta As Double, n As Integer) As Double ' A recursive version of the basic option valuation routine ' For illustrative purposes ' Only viable for a small number of stages (e.g. 15) Dim pu As Double, pd As Double pu = delta * p ' pu and pd are discounted prices pd = delta * (1 - p) If n > 15 Then RecursiveBinomialTree = "Too many steps for recursion" ElseIf n = 0 Then RecursiveBinomialTree = WorksheetFunction.Max(S - K, 0) Else RecursiveBinomialTree = (pu * RecursiveBinomialTree(u * S, K, u, d, p, delta, n - 1) +_ pd * RecursiveBinomialTree(d * S, K, u, d, p, delta, n - 1)) End If End Function Function RecursiveBinomialEurCall(S0 As Double, K As Double, r As Double, q As Double, _ sigma As Double, T As Double, n As Integer) As Double Dim dt As Double, u As Double, d As Double, p As Double, delta As Double dt = T / n u = Exp(sigma * Sqr(dt)) d=1/u delta = Exp(-r * dt) p = (Exp((r - q) * dt) - d) / (u - d) RecursiveBinomialEurCall = RecursiveBinomialTree(S0, K, u, d, p, delta, n) End Function

Function BinomialTree(S0 As Double, K As Double, u As Double, d As Double, _ p As Double, delta As Double, n As Integer) As Double ' Efficient implementation of binomial tree for American options ' Allocate storage Dim i As Integer, j As Integer Dim pu As Double, pd As Double Dim S() As Double, V() As Double ReDim S(2 * n) ReDim V(2 * n) ' Initialize parameters pu = delta * p ' pu and pd are discounted prices pd = delta * (1 - p) ' Initialize the tree S(n) = S0 ' Calculate potential asset prices For j = n + 1 To 2 * n S(j) = u * S(j - 1) Next j For j = n - 1 To 0 Step -1 S(j) = d * S(j + 1) Next j ' Calculate option values at maturity For j = 0 To 2 * n Step 2 V(j) = Application.Max(S(j) - K, 0) Next j ' Calculate option values by backward induction For i = n - 1 To 0 Step -1 For j = n - i To n + i Step 2 V(j) = Application.Max(pu * V(j + 1) + pd * V(j - 1), S(j) - K) Next j Next i ' Return option value BinomialTree = V(n) End Function

Function BinomialAmerCall(S0 As Double, K As Double, r As Double, q As Double, _ sigma As Double, T As Double, n As Integer) As Double Dim dt As Double, u As Double, d As Double, p As Double, delta As Double dt = T / n u = Exp(sigma * Sqr(dt)) d=1/u delta = Exp(-r * dt) p = (Exp((r - q) * dt) - d) / (u - d) BinomialAmerCall = BinomialTree(S0, K, u, d, p, delta, n) End Function Function BinomialAmerPut(S0 As Double, K As Double, r As Double, q As Double, _ sigma As Double, T As Double, n As Integer) As Double Dim dt As Double, u As Double, d As Double, p As Double, delta As Double dt = T / n u = Exp(sigma * Sqr(dt)) d=1/u delta = Exp(-r * dt) p = (Exp((r - q) * dt) - d) / (u - d) BinomialAmerPut = BinomialTree(-S0, -K, u, d, p, delta, n) End Function

Function BinomialEurCall(S0 As Double, K As Double, r As Double, q As Double, _ sigma As Double, T As Double, n As Integer) As Double Dim dt As Double, u As Double, d As Double, p As Double, fp As Double, _ pi As Double, S As Double, EV As Double, IV As Double, j As Integer dt = T / n u = Exp(sigma * Sqr(dt)) d=1/u p = (Exp((r - q) * dt) - d) / (u - d) pi = (1 - p) / p ' calculate maximum asset price and probability S = u ^ n * S0 fp = p ^ n EV = fp * WorksheetFunction.Max(S - K, 0)

' proceed down final asset prices calculating expected values For j = n - 1 To 0 Step -1 fp = (j + 1) / (n - j) * fp * pi S=d^2*S IV = WorksheetFunction.Max(S - K, 0) If IV > 0 Then EV = EV + fp * IV Else Exit For End If Next j BinomialEurCall = Exp(-r * T) * EV End Function Function BinomialEurPut(S0 As Double, K As Double, r As Double, q As Double, _ sigma As Double, T As Double, n As Integer) As Double Dim dt As Double, u As Double, d As Double, p As Double, fp As Double, _ pi As Double, S As Double, EV As Double, IV As Double, j As Integer dt = T / n u = Exp(sigma * Sqr(dt)) d=1/u p = (Exp((r - q) * dt) - d) / (u - d) pi = p / (1 - p) ' calculate minimum asset price and probability S = d ^ n * S0 fp = (1 - p) ^ n EV = fp * WorksheetFunction.Max(K - S, 0) ' proceed up final asset prices calculating expected values For j = 0 To n - 1 fp = (n - j) / (j + 1) * fp * pi S=u^2*S IV = WorksheetFunction.Max(K - S, 0) If IV > 0 Then EV = EV + fp * IV Else Exit For End If Next j BinomialEurPut = Exp(-r * T) * EV End Function

Function EBinomialTree(S0 As Double, K As Double, u As Double, d As Double, _ p As Double, delta As Double, n As Integer) As Variant 'Extended binomial tree for calculating Greeks n=n+2 ' extend tree ' Allocate storage Dim A As Variant Dim i As Integer, j As Integer Dim pu As Double, pd As Double Dim S() As Double, V() As Double ReDim S(2 * n) ReDim V(2 * n) ' Initialize parameters pu = delta * p ' pu and pd are discounted prices pd = delta * (1 - p) ' Initialize the tree S(n) = S0 ' Calculate potential asset prices For j = n + 1 To 2 * n S(j) = u * S(j - 1) Next j For j = n - 1 To 0 Step -1 S(j) = d * S(j + 1) Next j ' Calculate option values at maturity For j = 0 To 2 * n Step 2 V(j) = Application.Max(S(j) - K, 0) Next j ' Calculate option values by backward induction For i = n - 1 To 2 Step -1 For j = n - i To n + i Step 2 V(j) = Application.Max(pu * V(j + 1) + pd * V(j - 1), S(j) - K) Next j Next i ' Return option values EBinomialTree = Array(V(n - 2), V(n), V(n + 2)) End Function

Function BinomialAmerCallDelta(S0 As Double, K As Double, r As Double, q As Double, _ sigma As Double, T As Double, n As Integer) As Double Dim dt As Double, u As Double, d As Double, p As Double, delta As Double Dim V As Variant dt = T / n u = Exp(sigma * Sqr(dt)) d=1/u delta = Exp(-r * dt) p = (Exp((r - q) * dt) - d) / (u - d) V = EBinomialTree(S0, K, u, d, p, delta, n) BinomialAmerCallDelta = (V(2) - V(0)) / ((u ^ 2 - d ^ 2) * S0) End Function

Function BinomialAmerPutDelta(S0 As Double, K As Double, r As Double, q As Double, _ sigma As Double, T As Double, n As Integer) As Double Dim dt As Double, u As Double, d As Double, p As Double, delta As Double Dim V As Variant dt = T / n u = Exp(sigma * Sqr(dt)) d=1/u delta = Exp(-r * dt) p = (Exp((r - q) * dt) - d) / (u - d) V = EBinomialTree(-S0, -K, u, d, p, delta, n) BinomialAmerPutDelta = (V(2) - V(0)) / ((u ^ 2 - d ^ 2) * S0) End Function Function BinomialAmerCallGamma(S0 As Double, K As Double, r As Double, q As Double, _ sigma As Double, T As Double, n As Integer) As Double Dim dt As Double, u As Double, d As Double, p As Double, delta As Double Dim V As Variant dt = T / n u = Exp(sigma * Sqr(dt)) d=1/u delta = Exp(-r * dt) p = (Exp((r - q) * dt) - d) / (u - d) V = EBinomialTree(S0, K, u, d, p, delta, n) BinomialAmerCallGamma = ((V(2) - V(1)) / ((u ^ 2 - 1) * S0) - (V(1) - V(0)) / ((1 - d ^ 2) * S0)) / ((u ^ 2 - d ^ 2) * S0 / 2) End Function

## Improving the binomial method

Michael Carter
Introduction
As the number of steps are increased, the binomial method converges to the true value (by the Central Limit Theorem), but the convergence is slow and awkward. This is illustrated in the following graph for an American out-of-the-money put option (S 100, K 90, r 5 , 30 , T 1 2 ). The horizontal axis represents the true value as calculated with a 50,000 step tree.

Binomial convergence
3.38

3.37

3.36

3.33

3.32

## This pattern repeats indefinitely as the number of steps is increased.

ImprovingBinomial.nb

Binomial convergence
Binomial convergence
3.349

3.348

13.42 13.41

3.347

13.4
3.346

1000

150

3.344

1500

200

250 2000

300

2500

3.343

## The next graph illustrates the same option with K

110.

Clearly, there is a tradeoff between accuracy and efficiency (speed). Various methods are available for improving the performance of the binomial model. These can be classified into two groups depending on whether aimed at improving accuracy improving efficiency Typically, success on one front implies a sacrifice on the other.

ImprovingBinomial.nb

Improving accuracy
Successive averages
A popular technique in practice is to average the results of successive integers, n and n 1.

## Binomial convergence 3.37

successive averages

3.36

## 3.35 50 3.34 100 150 200 250 300

3.33 Parameterization
In class, we used the simple parameterization
r q t t t

, d

, p

where t = t/n. Some improvement in accuracy (at negligble computational cost) can be attained by modifying the parameterization. Two possibilities are:
r q t t t t t

u and

,d

, p

u where r

, d
1 2

2 t

2 t2 , p

1 2 1

t x

2 .

## Tian (1999) proposed a flexible binomial tree with

r q t 2 t t 2 t t

,d

, p

where is an arbitrarily chosen tilt parameter. can be chosen so as to make one node coincide with the strike price, thus smoothing convergence. Another proposal of Tian sounds promising. Convergence of the binomial tree price to the true price requires that the first and second moments (mean and variance) of the (discrete) binomial distribution of the nodes match or converge to those of the (continuous) process of the underlying asset, that is

ImprovingBinomial.nb

Another proposal of Tian sounds promising. Convergence of the binomial tree price to the true price requires that the first and second moments (mean and variance) of the (discrete) binomial distribution of the nodes match or converge to those of the (continuous) process of the underlying asset, that is pu p u2
2

1 1

p d p d2

r t 2 2 r t

where 2 r t is the second moment of asset returns when the log returns have variance 2 t. (See Chance 2007 for a thorough discussion.) Tian (1993) suggests matching in addition the third moment to allow for the skew in the underlying distribution, requiring p u3 1 p d3
3 2 r t

This gives three equations which can be solved for the three unknowns u, d and p. However, the outcome is disappointing.

Binomial convergence
3.38 3.37 3.36 3.35 50 3.34 3.33 3.32 100 150

## out of the money put

Tian

200

250

300

Magic numbers
The oscillations arises from the relationship between the strike price and the terminal nodes of the tree. The graphs reveal that there are particular choices of n that minimize the error in their neighbourhood. These magic numbers depend upon the precise parameters of the option. By tailoring the size of the tree to the particular option, we might obtain more accurate results with smaller trees. This becomes especially important in applying the binomial method to barrier options.

Binomial-Black-Scholes
Convergence can be significantly enhanced using the Black-Scholes formula to evaluate the penultimate nodes. This is known as the Binomial-Black-Scholes method.

ImprovingBinomial.nb

Binomial convergence 3.365 3.36 3.355 3.35 50 3.34 3.335 Richardson extrapolation 100

## Binomial Black Scholes

150

200

250

300

Richardson extrapolation is a method to improve an approximation that depends on a step size. Applied to the binomial model, extrapolation attempts to estimate and incorporate the improvement of higher n. For example, suppose we assume that errors decline inversely with n, so that C Pn1 Pn2 P P n1 C n2

where P is the (unknown) true value, Pn1 and Pn2 are estimates with step size n1 and n2 respectively, and C is an unknown constant. Solving for P, we have P n2 Pn2 n2 n1 Pn2 n1 2 n1
n 2 n 2

In particular, when n2 n Pn P

n, we have

Pn 2 2 Pn Pn 2

## which can be alternatively expressed as P 2 Pn Pn 2 Pn Pn Pn 2

It is not helpful when applied to the pure binomial model, but is very effective when applied after BlackScholes smoothing.

ImprovingBinomial.nb

3.36

## 3.35 50 3.34 100 150 200 250 300

3.33
Smoothing and extrapolation also makes a dramatic improvement to the Tian moment-matching tree.

Binomial convergence
3.38

3.37

3.36

Tian

## 3.35 50 3.34 100 150 200 250

3.33

3.32

In a recent contribution, Widdicks, Andricopoulos, Newton and Duck (2002) have applied extrapolation to the peaks of the errors, as illustrated in the following diagram from their paper.

ImprovingBinomial.nb

Control variable
A simple and effective technique is to use the binomial method to estimate the early exercise premium, as measured by the difference between the estimated prices of identical American and European options. This estimate is added to the Black-Scholes value, to give the estimated value of the American option. P p Ab Eb

where p is the Black-Scholes value, Ab is the binomial estimate of the American option, and Eb is the binomial estimate of a corresponding European option. This is known as the control variable technique. Rewriting the previous equation P Ab p Eb

we observe that the effectiveness of this approach depends upon the degree to which the binomial error in the American option matches that of the European option in sign and magnitude. Chung and Shackleton (2005) explore this issue, provide a methodology for determining the optimal control, and discuss other potential control variables.

ImprovingBinomial.nb

## Black Scholes control variable

50 3.34 3.335

100

150

200

250

300

Comparison Binomial convergence 3.36 3.355 3.35 out of the money put Binomial Black Scholes BBS with RE

50 3.34

100

150

200

250

300

## Black Scholes control variable 3.335

ImprovingBinomial.nb

Binomial convergence
3.38

3.37

3.36

## Binomial Black Scholes BBS with RE

3.35 50 3.34 Tian with smoothing and extrapolation 3.33 100 150 200 250

3.32

Improving efficiency
Truncation
Andricopoulos et al. (2004) proposed curtailing the range of nodes that are computed by backward induction, reporting a near doubling of speed with negligible loss of accuracy.

10

ImprovingBinomial.nb

## The diagonal algorithm

Curran (1995) proposed an innovative diagonal algorithm for evaluating binomial trees, which significantly reduced the number of nodes that needed to be evaluated. He reported a 10 to 15-fold increase in speed (with identical accuracy) over the corresponding standard tree. Note that this algorithm achieves a pure increase in efficiency, returning the same result as the standard method. It is equally applicable to extrapolation and control variable techniques.

## The diagonal algorithm

Michael Carter
Curran (1995) proposed an innovative diagonal algorithm for evaluating binomial trees, which significantly reduced the number of nodes that needed to be evaluated. He reported a 10 to 15-fold increase in speed (with identical accuracy) over the corresponding standard tree. Note that this algorithm achieves a pure increase in efficiency, returning the same result as the standard method.It is equally applicable to extrapolation and control variable techniques. The diagonal algorithm depends upon two propositions regarding the evolution of option values in a binary tree. They can be illustrated diagramatically as follows: Proposition 1 If it pays to exercise the option in the next period, it pays to exercise immediately. exercise exercise exercise Proposition 2 If it pays to hold the option at some time and asset price, then it pays to hold the option at the same asset price at every earlier price. ? hold hold ? Proposition 1 applies provided q r. The intuition is that, on average, the asset price will grow, and therefore the implicit value will decline. If it is worth exercising in the future, it is worth exercising now. Proposition 2 applies irrespective of the dividend yield (provided that u d = 1). These properties of a binary tree enable two forms of acceleration in the tree. By Proposition 2, once an entire diagonal of no exercise (or hold) nodes has been computed, we can jump immediately to the origin, since there are no further exercise nodes. We can evaluate the initial value of the option by computing the discounted expected value of the implicit values along the no-exercise diagonal in a manner similar to computing expected values of the terminal nodes of a European option. Provided that q r, we can start evaluation along the diagonal starting immediately below the strike price, since we know that all nodes below this diagonal will be exercise nodes (Proposition 1), and therefore their value will be equal to the implicit value.

DiagonalAlgorithm.nb

Proof of Proposition 1: Let S denote the current asset price. Assume that both subsequent nodes are exercise nodes. Then the expected future value is FV = H p HK - u SL + H1 - pL HK - d SLL = K - H p u + H1 - pL dL S p u + H1 - pL d = Hr-qL Dt

## Substituting, the expected future value at the subsequent node is FV = K - Hr-qL Dt S

Provided that q r, the expected future value is less than the current implicit value, that is A fortiori, the discounted future value is less than the current implicit value. That is, -r Dt HK - SL is more than you can expect by waiting. Consequently, the option should be exercised immediately. Note that this is not necessarily the case if q > r. In this case, expected capital gains are negative. So the option may become more valuable. Proposition 2 applies irrespective of the dividend yield. It depends upon the following lemma. Lemma. Ceteris paribus, the value of an American option increases with time to maturity (Lyuu, Lemma 8.2.1). Proof of lemma. Suppose otherwise. Sell the more expensive shorter option and buy the one with the longer maturity for a positive cash flow. Let t denote the time at which the shorter option is exercised or expires, and Pt the value of the longer option at this time (assuming a put for example). Case 1: Pt > max HK - St , 0L. Sell the longer option. FV = K - Hr-qL Dt S K - S

Case 2: Pt max HK - St , 0L. In this case, the short option will be exercised. Offset this by exercising the longer option. In either case, we have a positive cash flow at time zero, and a nonnegative cash flow at time t.

Proof of Proposition 2. Let Pu and Pd denote the possible values of the option given an asset price of S, and let +2 +2 Pu and Pd denote the possible values of the option two periods later. By assumption, the holding value at time +2 is greater than the exercise value. That is
+2 +2 -r Dt H p Pu + H1 - pL Pd L K - S +2 +2 Pu Pu and Pd Pd

By the lemma, the possible values are at least as great as they will be two periods later.

Therefore, the current holding is at least as great as the current exercise value.
+2 +2 -r Dt H p Pu + H1 - pL Pd L -r Dt H p Pu + H1 - pL Pd L K - S

## Timing VBA code execution

Michael Carter
Accurately timing execution speed on a multitasking computer is surprisingly difficult, since the CPU can be regularly interrupted by other processes. It is normal to record different times on repeated runs. So good practice would be to average (or minimum) over a number of runs. It is also sensible to close other applications when undertaking timing comparisons. VBA contains a function Timer() that gives the number of seconds since midnight. By calling Timer() at the beginning and end of a lengthy computation, it is possible to estimate the time taken by the function as follows:
Dim StartTime, EndTime, ComputationTime As Single StartTime = Timer Do lengthy computation EndTime = Timer ComputationTime = EndTime StartTime

More accurate timing can be achieved using the Windows operating system function GetTickCount(), which returns the time in milliseconds since the system was started. It is claimed to have a resolution of 10 milliseconds (approximately). To use this function, it must first be declared as follows:
Declare Function GetTickCount Lib " Kernel32 " HL As Long Dim StartTime, EndTime, ComputationTime As Long StartTime = GetTickCount Do lengthy computation EndTime = GetTickCount ComputationTime = EndTime StartTime

More information is available in the Microsoft tutorial note How To Use QueryPerformanceCounter to Time Code.

## Random number generation

Michael Carter
A pseudorandom number generator is a deterministic algorithm that generates a series of numbers in a manner that appears to be random. It can be described by a recursive function xi f xi
1

or more generally xi f xi 1 , xi 2 , , xi
k

f may be linear or nonlinear. The starting value x0 (or values) is called the seed. By default, the seed is often set from the system clock. The most common pseudorandom number generator is the linear congruential generator xi a xi
i

## Rescaling the sequence by dividing my m gives a sequence in the ui

By careful choice of a, c and m, a sequence of period m can be obtained. Then, the resulting sequence of real numbers will appear to be uniformly distributed on 0, 1 . However, not that inappropriate choice of a, c and m can give very poor results. Excel VBA's RND function is a linear congruential generator with a 1 140 671 485, c 12820163 and m 224 , with a period of 224 16, 777, 216. Starting with the default seed of 327680, the first values in the sequence are: 0.705548, 0.533424, 0.579519, 0.289562, and 0.301948. (It is not possible to replicate this generator in VBA or a spreadsheet because the internal representation of long integers is not accessible.)

Press, Teukolsky, Vetterling and Flannery (1992) is a valuable source of reliable random number generators that have been well-tested, including the so-called "minimal standard" generator of Park and Miller which uses a 75 16 807 c 0 m 231 1 2 147 483 647

The period of this generator is 231 2 2.1 109 . For general use, they recommend ran1 which combines the minimal standard generator with an additional shuffle to eliminate low-order serial correlations. Where a longer period is required, they describe ran2 which combines two linear congruential generators with different periods. They also describe some "quick and dirty alternatives" for less demanding applications. An increasingly popular algorithm is the Mersenne twister. It has a period of 219,937 1, is fast to compute and is guaranteed to have equidistribution properties in at least 633 dimensions. An implementation for Excel is freely available from NT Technologies. Excel 2003 implemented a new RAND function based on the Wichman and Hill (1982) algorithm, which combines three linear congruential generators. It is claimed to have a period of 1013 . This is retained in Excel 2007 (see Description of the RAND function in Excel 2007 and in Excel 2003).

RandomNumberGeneration.nb

## Normal random deviates

Pseudo-random values from a distribution other than uniform (e.g. normal) are known as random deviates, to distinguish them from uniform random numbers. Normal random deviates are almost always generated in a two-step procedure, first generating normal random numbers and then transforming them in some way to produce numbers that appear to come from a standard normal distribution. A variety of very clever methods have been proposed for doing this transformation, of which the most common are the Box-Muller method and normal inverse transformation. Box-Muller transformation Draw two random numbers u1 and u2 from U 0, 1 such that w Calculate c z1 c u1 and z2 2
log w w

u2 1

u2 2

## c u2 are normally distributed (N 0, 1 )

The Box-Muller transformation is very efficient. However, there are circumstances in which it is inappropriate It should not be used with quasi-random number sequences, as it will scramble the lowdiscrepancy property of the sequence. It should not be used in conjunction with a simple LCG generator (Bratley, Fox, Schrage 1982: 223) Inverse normal transformation Let U be uniformly distributed on (0,1). Let F x be the distribution function of a continuous distribution. Then F is strictly increasing on [0,1] and has an inverse F u F x if and only if x F
1 1

such that

u F
1

Therefore, we can compute a random deviate X with distribution F x simply by setting X Then PX x PF
1

U .

U u F x

PU u for 0 F x

F x u 1. Therefore

## But since U is uniform, P U PX x PY

So the problem of generating random deviates is essentially a numerial problem of inverting the distribution function.

RandomNumberGeneration.nb

The cumulative distribution function of the standard normal distribution is 1 x 2 This has no closed form, and so much be computed numerically. Hull (2003) outlines a polynomial approximation that gives six place decimal accuracy (p. 248). Similarly, the inverse CDF much be computed numerically. Moro (1995) proposed a rational polynomial approximation that gives eight place decimal accuracy. It has become very popular in finance applications. The NORMSINV function in Excel XP has been reported to still give slightly erroneous results (McCullough and Wilson, 2002).
x t2 2

## Multivariate normal distribution

Given two independent standard normal random variables z1 and z2 , the following transformation generates two correlated normal random variables with mean 0, standard deviation 1 and correlation coefficient . x1 x2 Exercise Do it! z1 z1 1 2 z2

RandomNumberGeneration.nb

## Furthermore, if we set x1 x2 then x1 , x2 2 1 1 2 1 z1 2 z1 1 1 2 z2 2 1 , 2 and covariance matrix

has a bivariate normal distribution with mean 1 2 2 2 , as can be confirmed by direct computation.

2 1 1 2

1 2 2 2

## can be factored into a product of triangular matrices

H H T . In this case,

2 2

with H H T

If Z is a vector of independent normal random variables, that is Z ~ N(0,I), then X HZ H H T . Conversely, if X ~ N(, ), then
1

## Description of the RAND function in Excel 2007 and in Excel 2003

http://support.microsoft.com/kb/828795/en-us

Article ID: 828795 - Last Review: January 16, 2007 - Revision: 5.3

## Description of the RAND function in Excel 2007 and in Excel 2003

SUMMARY

This article describes the modified algorithm that is used in the random number generator function, RAND, in Microsoft Office Excel 2007 and in Microsoft Office Excel 2003.

The RAND function in earlier versions of Excel used a pseudo-random number generation algorithm whose performance on standard tests of randomness was not sufficient. Although this is likely to affect only those users who have to make a large number of calls to RAND, such as a million or more, and not to be a concern for almost every user, the pseudo-random number generation algorithm that is described here was first implemented for Excel 2003. It passes the same battery of standard tests. The battery of tests is named Diehard (see note 1). The algorithm that is implemented in Excel 2003 was developed by B.A. Wichman and I.D. Hill (see note 2 and note 3). This random number generator is also used in the RAT-STATS software package that is provided by the Office of the Inspector General, U.S. Department of Health and Human Services. It has been shown by Rotz et al (see note 4) to pass the DIEHARD tests and additional tests developed by the National Institute of Standards and Technology (NIST, formerly National Bureau of Standards).

Notes
The tests were developed by Professor George Marsaglia, Department of Statistics, Florida State University and are available at the following Web site: http://i.cs.hku.hk/~diehard (http://i.cs.hku.hk/~diehard) Wichman, B.A. and I.D. Hill, Algorithm AS 183: An Efficient and Portable Pseudo-Random Number Generator, Applied Statistics, 31, 188-190, 1982. Wichman, B.A. and I.D. Hill, Building a Random-Number Generator, BYTE, pp. 127-128, March 1987. Rotz, W. and E. Falk, D. Wood, and J. Mulrow, A Comparison of Random Number Generators Used in Business, presented at Joint Statistical Meetings, Atlanta, GA, 2001. The basic idea is that if you take three random numbers on [0,1] and sum them, the fractional part of the sum is itself a random number on [0,1]. The critical statements in the Fortran code listing from the original Wichman and Hill article are: C IX, IY, IZ SHOULD BE SET TO INTEGER VALUES BETWEEN 1 AND 30000 BEFORE FIRST ENTRY IX = MOD(171 * IX, 30269) IY = MOD(172 * IY, 30307) IZ = MOD(170 * IZ, 30323) RANDOM = AMOD(FLOAT(IX) / 30269.0 + FLOAT(IY) / 30307.0 + FLOAT(IZ) / 30323.0, 1.0) Therefore IX, IY, IZ generate integers between 0 and 30268, 0 and 30306, and 0 and 30322 respectively. These are combined in the last statement to implement the simple principle that was expressed earlier: if you take three random numbers on [0,1] and sum them, the fractional part of the sum is itself a random number on [0,1]. Because RAND produces pseudo-random numbers, if a long sequence of them is produced, eventually the sequence will repeat itself. Combining random numbers as in the Wichman-Hill procedure guarantees that more than 10^13 numbers will be generated before the repetition begins. Several of the Diehard tests produced unsatisfactory results with earlier versions of RAND because the cycle before numbers started repeating was unacceptably short.

## Results in Earlier Versions of Excel

The RAND function in earlier versions of Excel was fine in practice for users who did not require a lengthy sequence of random numbers (such as a million). It failed several standard tests of randomness, making its performance an issue when a lengthy sequence of random numbers was needed.

## Results in Excel 2003

A simple and effective algorithm has been implemented. The new generator passes all standard tests of randomness.

Conclusions
Power users of RAND who require lengthy sequences of random numbers are better off with the new generator of Excel 2003. Other users should be undeterred from using RAND in earlier versions of Excel.

1 of 2

05/03/2009 10:52

## Description of the RAND function in Excel 2007 and in Excel 2003

http://support.microsoft.com/kb/828795/en-us

REFERENCES

For more information about an issue that was documented to occur in RAND, click the following article number to view the article in the Microsoft Knowledge Base: 834520 (http://support.microsoft.com
/kb/834520/ )

## The RAND function returns negative numbers in Excel 2003

APPLIES TO
Microsoft Office Excel 2007 Microsoft Office Excel 2003

## Get Help Now

Contact a support professional by E-mail, Online, or Phone

## Help and Support

2009 Microsoft

2 of 2

05/03/2009 10:52

1/24/2012

NumericalRecipes
Never useaLCGgenerator(alone) useageneratorwithaperiod<2 2 10 useabuiltingeneratorinCorC++ Avoid generatorsdesignedforcryptographicuse generatorswithperiod>10

NumericalRecipes

Normaltransformation
ExcelsNormSInv nowOK

Excel
Setseed? Y N Y Volatile? Quality N Weak Y Unknown Y& N Good

## Rnd() Rand() PRand

PRand
EverydayRNGfromNumericalRecipes Combines64bitXorShift withLCG Period2 2 10
Uniform Volatile Nonvolatile URand() Normal NRand() Seed SetSeed

Comparativeefficiency
Timerequiredfor1millionsimulations(minutes)
NormSInv Rand URand NRand vbaNRand 4.7 3.4 4.2 4.2 NormMInv 3.6 3.6 3.6

## URandNonV() NRandNonV() SetSeedNonV()

NormMInv () MoroinversenormalCDF
2.1GHzPentium

f f f i * o N r E c A R t o

s l M U t A T t o N

(:

MoNITE THEFULL
quosi'rondom numbers useful into Tronsforming MonteCorlo voriobles be o bit of o gomble. con simulotion Boris Moro how fo do it quickly ond occurotely exploins
I I onte Carlo simulation is often used for f V I pricing European-slylederivative securities n'ith complicated pavoffs, especiailv t h o s ed e p e n d e n t u p o n s e v e r a l B r o r t ' n i a n motions. It involves simulating the path of the underlf ing security price a number of times and calculatingthe expectedoption value as an averageover all prices obtained at maturiry. The path depends on the drift and volatility, n'hich measures the size of normalh' distributed random fl uctuations. In practice,one first has to calculatepseudorandom numbers in the interval (0,1) - or a (0,1)s,for an s-factormodel unit h1'percube, and then transform them into a set of Gaussian deviatesusing the Box-Muller algorithm (see Flannery, Pressand Teukolsky (1992), page 2 8 9 ) .U n f o r t u n a t e l y , i f t h e M o n t e C a r l o method is basedon standardpseudo-random numbers, it is very slow becausethe pricing error decreases only with 1/{N where N is the number of simulation runs. Recently,Jov, Bo1'leand Tan (1994)have shown that the efficienry of the method can be greatly increasedif quasi-random rather than pseudo-randomnumbers are used (Fox Davis (1973)also gives the result correct to (1986)).These are deterministic sequences machineprecision but is not much fasterthan defined on a unit hvpercube n'hich have a Nen'ton's ntethod. Rational approximations Ion'discrepanc\/,thails, they fill the domain for x(Y) n'ere deriyed by Odeh and Evans nearl;' uniformll'. Unlike a pseudo-random and by Beasteyand Springer (1977). LT.974) sequence finite length, there can be no clus_ T h e l a t t e r of program (ppND) iJ fast but ters of points, so u'hen the function is calcu- becomesinaccurate in the tails of the distrib_ lated by averaging over such a set, the esti- ution. mate is more accurate. We obtained an approximation to the In a Monte Carlo simulation, such num- inverse of the cumulative normal distribution bers must be transformedinto Gaussiandevi- function n'hich has a high acoracy for all y in atesso that tl'relow discrepancyof the origi- the inten'al [10-r:, !-Lo-L2]and ii faster than nal sequenceis preserved.The Box-Muller standard implementations of the Box-Muller method and its variants scramble the quasi- method. random sequence and thereforeshould not be We shall use symmetry of the inverse of used for that purpose. the cumulative normal distribution and con_ Instead, one has to compute the inverse, sider onlv the interval (0.5, 1). For small x(Y),of the cumulative normal distribution deviations (Y < 0.92) we use the function function derived by Beasleyand Springer:

'dt Y ( x= - = ) te ^l2n -*

t'

## Relotive errorsin the foil of distribution

1.0 I O-r t0 -:
I0-l l0*
l0-5 l0-6 l0t l0-8 l0-e l0-,0 l0-" l0-,r

(1) u'hich can be done using Newton,s iteration. in practice,howevet this is too slow to be use_ ful. The approximation'derived by Hill and w h e r e Y : Y - 0 . 5 . For Y > 0.92 \^/eapproximate x(y) by a polynomial:
n=8

## H 2 ^ La"y x(y)=v-s*. _ 1+ Ibny2"

x ( Y ) =I . n . n
n=0

l0-,,
I0-,0

2.6.104

I .9.10-8

where: . krin(-ln(1- y)) + k, ; an,bnand cn are suitabh' chosen coefficients and the con_ stants k, and lg are such that z = _! when Y = 0.92 andz : lwheny = 1 - !O-r2. The rational approximation (1) has the largest absolute error of 3x10-s in the interval [0.5, 0.92]. In the tails of the distribution, our algorithm retains this accuracy for up to seven standard deviations. High_order poly_ nomial approximations which have 14_digit accuracy in the interval [10-rs, t-tg-rs; cin e a s i l y b e c o n s t r u c t e db u t t h e y r u n m u c h slower. The table shoH'sthe time needed for generating 107 double precision normally dis_ tributed numbers on a Sun Sparc 10-30 using three programs: GASDEV (Box-Muller algol as implemented by Flannery et ily, 11B 1 . 0 . 1 0 - r r PIND (Beasley and Springer) and CNDEV u'hich is based on our algorithm. In the first set of runs, uniformly distributed pseudo_

## RISK VOL8/NO 2/FEBRUARY

.la

M O N T E

C A R L O

S I M U L A T I O N

randonl numbersfrom the inten'al (O,1)n'ere generatedby the function DRAND48. In the secondset of runs (PPND and CNDEV) normal deviates\^'ereproduced from uniformly drarvn numbers from the interval (0,1), ie, rr'ithout function DRAND48. I for BorisMorois o researcher TMG Finonciol He Products Greenwich, in Connecticut. thonks for PhelinBoyle comments ond Professor
suggesfions

## PROGRAM THE CNDEV.C

#include <moth.h>

## Are you taking enoughcare?

RISkcare
The DerivativeDevelopment& ConsultancySpecialists
independent Experienced adviceon hedgingstrategies, individual & portfoliopricing andongoingrisk analysis. investment opportunities, provides Riskcare For users, marketmakersand softwaredevelopers derivativeproducts, of the mathematics, technology, to trainingandbusiness awareness suit your requirements.

needcare. Complexstructures (0) l7t 251 4748or Fax: 251 2663 Telephone: 44
Complete confidentiality guaranteed.

RISK

## Simulating asset prices

Michael Carter
As a computation method, simulation has two major advantages it can easily deal with multiple random factors, for example random interest rates or volatility, or options on multiple assets it can easily incorporate more alternative asset processes, such as jumps or non-normal stochastic processes The major disadvantage is that it is computationally very intensive. Our starting point is the observation that periodic returns are approximately normally distributed around a trend

CNX Nifty 1990-2006 Prices 3000 2500 2000 1500 1000 500 0.1 0.05 0 -0.05 -0.1 Returns

## CNX Nifty distribution v. normal 0.25 0.2 0.15 0.1 0.05 -4

That is, we assume St !!!!! lnJ N ~ NIn Dt, s Dt M St-1 ln St = ln St-1 + n Dt + s

-2

with mean and variance are proportional to Dt. This implies that the distribution of asset prices is lognormal. This process can be simulated by computing !!!!! Dt zt

SimulatingPrices.nb

This equation distinguishes two components of the periodic return - the steady drift n Dt together with the !!!!! stochastic variation s Dt zt . The previous equation can be rewritten as St = n Dt + s where zt is a standard normal random variable. Since the exponential function is nonlinear where m = n + s2 2 is the expected return of the asset. dS = m S dt + s S dz or dS = m dt + s dz S This implies that the logarithm of the stock price follow d ln S = n dt + s dz
1 2 !!!!! Dt z
2

St-1

More formally, the fundamental assumption underlying Black-Scholes and most other financial models is that asset prices follow a particular stochastic process called geometric Brownian motion (GBM) (1)

E@ St D = Hn + s 2L t S0 = m t S0

(2)

The derivation of (2) from (1) is an application of Ito's lemma (Hull: 2003:232-233, where n = m Luenberger 1998:313). There are two methods of simulating stock prices, depending upon whether we take a discrete version of (1) or (2). A discrete version of (1) is dS = St - St-1 = m St-1 Dt + s St-1 et St = I1 + m Dt + s et !!!!! Dt M St-1 !!!!! Dt

s2 .

## where et is a standard normal random variable, so that (3)

This is the approach taken by a Hull (2003: 224). A discrete version of (2) is d ln S = lnHSt L - lnHSt-1 L = n Dt + s et lnHSt L = lnHSt-1 L + n Dt + s et St = n Dt + s et
!!!!!! Dt

## where et is a standard normal random variable and n = m - s2 2, so that or !!!!! Dt

!!!!! Dt

St-1

(4)

In practice, the second approach is preferred because it is more accurate (although it is computationally slower). Whereas (3) is only true in the limit as Dt 0, equation (4) is true for all Dt.

## Monte Carlo simulation

Statistical foundations
The value of a derivative instrument is discounted expected value of the payoff V0 E
rT

V St , 0

where the expectation is taken with respect to the risk-neutral distribution. Monte Carlo simulation can be used to estimate this expected value by averaging over repeated samples from the assumed distribution of the underlying. V0
th rT

EV

rT

V1

V2 n

Vn

where Vi is the value of the of the i realization under the risk-neutral distribution. The statistical foundations of Monte Carlo simulation rest on the two fundamental theorems of probability. Assume that X1 , X2 , ..., Xn are independent and identically distributed random variables with mean and variance 2 .
First fundamental theorem (Law of large numbers)

## The sample average converges to the mean, that is X X1 X2 n

Variance of independent random variables

...

Xn

Since the variables are independent, their variance is additive, that is 1 Var X Var n 1 n2 1 Var X n so that X n. n Var X1 2 X1 Var n 1 n2 Var X2 ... 1 X2 ... Var n 1 n2 Var Xn 1 Xn

## Second fundamental theorem (Central limit theorem)

Whatever the distribution of X , the sample mean X converges to a normal distribution. That is, for large samples, X N ,
2 n

MonteCarloSimulation.nb

Variance reduction
The principal methods of variance reduction are:
Antithetic variables

A sufficient condition for variance reduction with uniform or normal random variables is that the outcome function is monotonic.
Control variables

## With selected optimally, that is the standard estimator is

Cov Y , CV Var CV , the ratio of the variances of the control variable estimator to

Var Y

CV Var Y

E CV 1

2 Y,CV

The effectiveness of the control variable method depends solely upon the degree of correlation between target variable and the control variable (the sign is absorbed into ). In practice, the population moments are unknown and is estimated from the sample. This introduces some bias in finite samples. This bias can be eliminated by estimating on a different random sample. Typically, the bias is so small that this is not worthwhile.
Importance sampling

## Other methods include:

Moment matching Stratified sampling Latin hypercube sampling

Comments: Moment matching can also be achieved by using the moments as control variables. Boyle, Broadie and Glasserman, BS show that including using moments as control variables is asymptotically better than moment matching. Low-discrepancy (quasi-random) sequences automatically achieve first-moment matching, stratified and Latin hypercube sampling.

## Simulating the Greeks

The delta of a derivative is dV d S0 With simulation, this can be estimated by the average of the finite-differences over a sample n of replications.

MonteCarloSimulation.nb

1 n

V S0

V S0

If we use different random samples for estimating V S0 and V S0 small. A better estimate of variance of is Var Var V S0 Var V S0 2

, the variance of

## becomes very large as becomes

is generally obtained by using the same random numbers in estimating both V S0 and V S0

. The

2 Cov V S0 , V S0

## Provided that V S0 and V S0 lower variance.

Pathwise derivative

are positively correlated, the estimate obtained from common random numbers will have a

The pathwise derivative decomposes the total derivative into two components. dV d S0 d V d ST d ST d S0

r q
2 2

S0

r q

2 2

T Z

T Z

ST S0
rT

## The discounted payoff of a vanilla European call option is dV d ST

rT

max ST K K

K, 0

d d S0 max ST K, 0

rT

0,

, ST ST

The function is not differentiable at ST K, but this is a zero-probability event. Combining the two factors, the pathwise estimator of delta for a vanilla European call option is dV d S0 d V d ST d ST d S0
rT

ST S0

I ST

where I S T K equals one if S T K and zero otherwise. This estimator can easily be computed by simulation. A minor modification of this procedure can be used to estimate vega, but it is generally inapplicable to estimating gamma.

Michael Carter
Preliminaries

## Multivariate normal distribution

Given two independent standard normal random variables Z1 and Z2 , the following transformation generates two correlated normal random variables with mean 0, standard deviation 1 and correlation coefficient . X1 Z1 , X2 Z1 1 2 Z2

Furthermore, if we set X1 1 1 Z1 , X2 2 2 Z1 1 2 Z2
2 1

then X1 , X2 has a bivariate normal distribution with mean 1 , 2 and covariance matrix can be confirmed by direct computation.

1 2
2 2

1 2

, as

Generalizing, if Z is a n-vector of independent normal random variables (Z ~ N(0,I)) and an L is an n n square matrix, then X is N , LZ L LT . Therefore, in order to produce a random sample from a multivariate normal distribution, we . Then E L Z Z T LT L E Z Z T LT L I LT L LT X E LZ LZ
T

where

T

## The Cholesky decomposition

Any square, symmetric, positive-definite matrix A can be factored into the product of two triangular matrices A L LT 2 1 is 1 2

2
1 2

0
3 2

since 2
1 2

0
3 2

2 0

1 2 3 2

2 1 1 2

Cholesky.nb

l1,1 LL
T

0 0

2 l1,1

l1,1 l2,1
2 l2,1 2 l2,2

2 l3,1

2 l3,3

l2,1 l2,2

l1,1 l2,1

l2,2 l3,2

## l1,1 l3,1 l2,1 l3,1

l2,2 l3,2

2 l3,2

Equating the resulting matrices element by element, we can solve the system row by row
2 l1,1

a1,1 a2,1 a3,1 a2,1 a2,2 l2,2 l3,2 a3,1 l2,2 l3,2
2 l3,3

2 l2,1 2 l2,2

2 l3,1 2 l3,2

## a3,2 a3,2 a3,3

to give l1,1 l2,1 a1,1 , a2,1 l1,1 a3,1 l1,1 , l2,2 a2,2 a3,2 l2,1 l2,1 l3,1 l2,2

l3,1

, l3,2

, l3,3

a3,3

2 l3,1

2 l3,2

i 1

li,i

ai,i
j 1

2 li, j

## 1 l j,i li,i ai, j

i 1

li,k l j,k ,
k 1

1, , n

Implementation

Asian options
Introduction
Asian options are popular in currency and commodity markets because they offer a cheaper method of hedging exposure to regular periodic cash flows they are less susceptible to manipulation of the spot market. There are two classes of Asian options average price options average strike options (payoff max S (payoff max ST K, 0 or max K S, 0 or max S S, 0 ) ST , 0 )

Average strike options are sometimes called floating strike options. Vanmaele et al. (2006) provide transformations between average price and average strike options. In addition, there are two ways of calculating the average S - arithmetic and geometric. A m 1 1
1

S0

S2

Sm

S0 S1 Sn

m 1

Note that by convention, the average includes the price on the first day of averaging. Jensen's inequality states that the arithmetic mean is larger than the geometric mean, with equality if and only if the observations are equal. Unfortunately, most Asian options in practice are based on arithmetic averaging, while precise results are readily available only for geometric averages. In practice, we use the price of an equivalent geometric average option as a lever to price its arithmetic counterpart. Upper and lower bounds Jensen's inequality implies that the value of an arithmetic Asian option is bounded below by its geometric counterpart. cG T cA T

We can also develop useful upper bounds. The value of the arithmetic Asian option is cA T
rT

E ST

where expectation is taken with respect to the risk neutral distribution. This implies cA T
rT

E ST E m

K 1 1 E
i 0 m rT m

rT

S ti
i 0 m

1 m 1 m 1 m 1 1 1

rT

S ti

E
i 0

S ti

m rT i 0

E S ti

Asian.nb

1 m 1

c ti
i 0

The value of an Asian option is less than the value of a portfolio of intermediate options with the same strike price. Furthermore, absent dividends, c ti c T and therefore cG T cA T 1 m 1
m

c ti
i 0

cT

Put-call parity Put-call parity applies to European average price options, whether arithmetic or geometric. To see this, observe that the difference between the terminal values of a put and call option is c0 p0 S K K S S K

## Taking risk-neutral expectations cT pT

rT

ES

The expectation E S can be calculated exactly for both arithmetic and geometric averages. Consequently, it suffices to compute call values and derive the values of puts from (1).

## Geometric average options

Suppose that St is lognormal with mean t and variance 2 t. Then the geometric average
1

Gm

S0 S1

Sm

m 1

## is lognormal with mean E Gm S0

2 m 1 2 m 1 6 T 2

(1)

(2)

## See Appendix. Under the risk neutral distribution E Gm S0

rt r q
m 2 2 m 1 6 T 2

By the fundamental theorem (Hull 2003: 262), the value of a European call option on Gm is cG where N ln d1 E max Gm K, 0
rt

E Gm N d1

K N d2

E Gm K V2 2

T , d2

ln

E Gm K

V2 2

r q
2 6 T 2

V and

Asian.nb

## the expected value is EG S0

r q
2 6 T 2

S0

q T

which is the same as the expected value of ST assuming the dividend yield q . Consequently, the value of European geometric Asian option with continuous averaging is given by BlackScholes formula with the substitutions (Hull 2003, p. 444) dividend yield 1 2 This also provides a useful approximation for large n. Moments of the geometric mean under the risk neutral distribution Discrete EG V log G S0
r q 2m 1 m 1
m 2 2 m 1 6 T 2

2 r q 6 volatility

Continuous S0
r q 2 3
2 6 T 2

2 6

## Arithmetic average options

The arithmetic average of lognormal random variables is not lognormal, and its precise distribution has proved intractable. There are three practical approaches to accurate valuation of arithmetic Asian options: analytical approximation simulation using the geometric average option as a control variate a modified binomial method

Analytical approximation
Although the distribution of the arithmetic average is A is intractable, its moments E Ak can be readily calculated. This has spurred a variety of approximation methods. Moments of A Observe that S1 S2 Sm
m

S0 R1 S1 R2 S0 R1 R2

S0 R1 R2 Rn Si S0 1 R1 R1 R2 R1 R2 Rm E [Ri ] . Then a
m

i 0

where the gross returns Ri are independent and identically distributed. Let a
m

E
i 0

Si

S0 E 1

R1

R1 R2

R1 R2 Rn

S0 1

S0

1 1

am a

## Under the risk neutral distribution, a

E Ri =

r q T m

. Therefore

Asian.nb

E Am

1 m 1

E
i 0

Si

S0 m 1

1 1

r q T m 1 m r q T m

## For continuous averaging, we have (Hull 2003: 444)

r q T m 1 m r q T

EA

lim E An

lim
m

S0 m 1

1 1

1 S0

r q T m

q T

An upper bound We have previous observed that G difference in payoffs is 0, A K G K A A G K, G G, K A (Jensen's inequality). This implies that CG A K G K A A G A , but also that the

## Taking risk-neutral expectations CA T CG T

rT

EA

EG

and therefore CG T CA T CG T
rT

EA

EG

Example. For S0 50, r 10 , q 0, 40 , T 1 and n 250, the expected values of the arithmetic and geometric means are 52.59 and 51.86 respectively. The value of geometric average call option is 5.13. Therefore, we can deduce that the value of an arithmetic average option C A is bounded as follows 5.13 CA 5.13
0.1

52.37

51.87

5.79

Simple modified geometric The simplest analytical approximation assumes that arithmetic average is lognormally distributed with mean E An , but assuming the standard deviation of ln An is g = / 3 . By the fundamental theorem (Hull 2003: 262) CA where d1 ln E An K G T 2 T 2 G , d2 d1 G T
rT

E max S

K, 0

rT

E An N d1

K N d2

Other analytical approximations Extensions of the previous idea include: Levy: Assume An is lognormally distributed with true mean and variance (Hull 2003: 444) Turnbull and Wakeman: Approximate the actual distribution of An using Edgeworth expansions. There is evidence that Levy approximation is not generally more accurate (and may be less accurate) than the simple modified geometic method, and that the Turnbull and Wakeman method is no more accurate unless higher (third and fourth) moments are used (James 2003: 215-216). Bounds Earlier, we developed upper and lower bounds for an arithmetic average option

Asian.nb

CG T

CA T

CG T

rT

EA

EG

In a recent contribution, Nielsen and Sandmann (2003) develop tighter upper and lower bounds that are easily calculated. In a numerical analysis of 32 options, they find that the Levy approximation satisfies the bounds in only eight cases while the Turnbull and Wakeman method satisfies the bounds in only seven cases. They conclude "more information is gained from the easily calculated bounds than from the pricing approximations" in their sample. They also show how the bounds can be used to calculate hedge parameters.

## Hull (2003) Options, Futures, and Other Derivatives

Barrier options
Michael Carter
Preliminaries

Introduction
A barrier option is similar to a vanilla call or put, but the final payoff depends on whether or not the underlying price achieves a particular level (the barrier) during the life of the option. The vanilla option may either knock-in or knock-out when the barrier is crossed. Sometimes, a rebate is paid if the vanilla option lapses because the barrier condition is not met. Barrier options are one of the most commonly traded exotic options, since they are less expensive than vanilla calls and puts.

## European barrier options

Following Bjrk (1998), we consider the class of derivatives on a single underlying asset where the payoff FHST L depends on ST (and not St , t < T). Throughout, we consider continuous monitoring. Since a portfolio comprising a knock-in and a knock-out option with the same barrier and strike will always pay the same as a vanilla option (e.g. HS - KL+ ), we can use the in-out parity condition Knock - in option + Knock - out option = Vanilla option

to deduce the price of one type from the other. A knock-out option can be either down-and-out or up-andout, depending upon the relationship between the current asset price S and the barrier H.

14 12 10 8 6 4 2

European barrier call options Barrier Vanilla Down-out Strike Down-in 85 90 95 100 105

Theorem 1 (Down-and-out) Suppose that V HS, F L denotes the value of a European derivative contract F HST L on S maturing at time T. The value of a down-and-out version of the derivative is
s H 2 i H 2 y j z Vdo HS0 , FL = V HS0 , FH L - J N V j , FH z S S k { 2n

2 where H < S0 is the barrier, n = r - q - s 2 2 and FH is F truncated below H. Proof: Bjrk 1998: 185-186 Proof FH HSL = 9 FHSL, for S > H 0, for S H

Barrier.nb

## = FHSL . IHS > LL

Corollary 1 (Down-and-in) Suppose that V HSL denotes the value of a European derivative contract on S maturing at time T. The value of a down-and-in version of the same option is where H < S0 is the barrier, n = r - q - s 2 2 and Note that Vdi depends upon both FH and FH . Proof Risk neutral valuation implies that the value functional V is linear in F. Since F = FH + FH V HS0 , FL = V HS0 , FH L + V HS0 , FH L FH HSL = 9 FHSL, for S < H 0, for S H
s H 2 i H 2 y z j Vdi HS0 , FL = V HS0 , F L + J N V j , FH z S0 { k S0 2n

By in-out parity

## Vdi HS0 , FL = V HS0 , FL - Vdo HS0 , FL

2n

Example: Vanilla European call with H K The payout for a vanilla European call is FHSL = max HS - K, 0L

s H 2 i H 2 y j z = V HS0 , F L + J N V j , FH z S S k {

## i s H 2 i H 2 yy j z j zz j = V HS0 , FH L + V HS0 , FH L - j V HS0 FH L - J N V j , FH z z j z j S k S {z k {

2n

The truncated payouts FH and FH depend upon whether H K or H > K. For H K FH HSL = FHSL = max HS - K, 0L and FH HSL = 0

Barrier.nb

FH

FH

H
and therefore

## V HS0 , FH L = V HS0 , FL and V HS0 , FH L = 0

2n

where cHS0 , KL is the Black-Scholes formula for a vanilla European call. Note that we can directly use the Black-Scholes formula for valuing these options. How would you obtain the hedge parameters? Exercise Show that this is the same as the formula given in Hull (2003:439) for the value of a vanilla down-and-in call, namely H 2l H 2 l-2 !!!! NIy - s T M cdi = S0 - q T J N NHyL - K -r T J N S0 S0

## s s H 2 i H 2 y H 2 j z Vdo HS0 , FL = V HS0 , FL - J N V j , Fz = cHS0 , KL - J N S0 S0 k S0 { 2n

i H2 y z cj , K z j k S0 {

i H2 y z cj , K z j k S0 {

where

## lnHH 2 HS0 KLL lnHH 2 HS0 KLL + Hr - q + s2 2L r - q + s2 2 !!!! l = 2 , y = !!!! = + l s T !!!! s s T s T

2n

s H 2 cdi HS0 , K, HL = J N S0

= S0

s H 2 i H 2 !!!! y j z = J N j -q T N HyL - K -r T N Iy - s T Mz S0 k S0 { 2n 2n 2n

i H2 y z cj , K z j k S0 {

-q T

s s H 2 +2 H 2 !!!! J N N HyL - K -r T J N N Iy - s T M S0 S0

Barrier.nb

where
H lnI M + Hr - q + s2 2L T s2 S0 K and n = r - q - y = !!!! 2 s T
2

Define

so that

r - q - s2 2 + s2 n r - q + s2 2 l = 2 = = + 1 s2 s2 s 2n 2 l = + 2 s2

Substituting, we derive the formula in Hull. H 2l H 2 l-2 !!!! cdi HS0 , K, HL = S0 -q T J N NHyL - K -r T J N N Iy - s T M S0 S0 r - q + s2 2 l = 2 s
2 2 2

Alternatively, we can start with the formula in Hull. Factoring out the power, this can be written as H 2 l-2 i H 2 j S - q T J N NHy L - K -r T NIy - s !!!! My z j 0 cdi = J N T z z j 1 1 S0 S0 { k H 2 l-2 ii H 2 y - q T !!!! y jj z jj z z = J N NHy1 L - K -r T NIy1 - s T Mz S0 kk S0 { { H 2 Hl-1L i H 2 y j z = J N cj , K z S0 S0 k {

## H H H lnI M + s2 l T lnI M lnI M + Hr - q + s2 2L T S0 K S0 K S0 K !!!! y = !!!! = = + s l T !!!! !!!! s T s T s T

H where cI 0 , KM is the value of a vanilla call with underlying price H 2 S0 and strike K S
2

r - q + s2 2 l = 2 s
2

Furthermore

## where n = r - q - s2 2.Therefore, the value of a down-and-in call with barrier H K is with

s H 2 cdi = J N S0 2n

r - q + s2 2 r - q + s2 2 + s2 r - q - s2 2 n l - 1 = 2 - 1 = = 2 = 2 s s2 s s i H2 y j z cj , K z S0 k {

Barrier.nb

## H H H lnI M + Hr - q + s2 2L T lnI M + s2 l T lnI M S0 K !!!! S0 K S0 K y = + s l T = = !!!! !!!! !!!! s T s T s T

2 2 2

Example: Vanilla European call H > K The payout for a vanilla European call is FHSL = max HS - K, 0L

FH

FH

K
For H > K

The down-truncated payout is a portfolio of a standard call and HH - KL cash-or-nothing binary options both with strike H, and therefore where bHS, HL is the value of an option that pays 1 if ST > H and zero otherwise. Substituting in Theorem 1
s H 2 i H 2 y j z cdo HS0 , K, HL = V HS0 , FH L - J N V j , FH z S0 k S0 { = 2n

Similarly

## FH HSL = FHSL - FH HSL = max HS - K, 0L - maxHS - H, 0L - HH - KL . IHS > HL

H c HS0 , HL + HH - KL b HS0 , HL - J N S0

2n 2 s

i i jc j , H y + HH - KL b i , H yy z j zz j j z j zz k k S0 { k S0 {{ H2 H2

(1)

Barrier.nb

The up-truncated payoff is a portfolio comprising a bull spread together with a short position in H - K binary options. V HS, FH L = cHS, KL - cHS, HL - HH - KL bHS, HL cdi HS0 , K, HL =
s H 2 cHS0 , KL - cHS0 , HL - HH - KL bHS0 , HL + J N S0 2n

Substituting in Corollary 1

Note that

Exercise

## cdi HS0 , K, HL + cdo HS0 , K, HL = cHS0 , KL bHS, HL = -r T NHd2 L

2 (2) i i H2 jH jcj , H y + HH - KL bi , H yy z zz j j j z zz k S0 k k S0 { {{

## Show that the value of a single binary option is

where N is the cumulative distribution function of the standard normal distribution and lnHS0 HL + nT d2 = , n = r - q - s2 2 !!!! s T

Note that this is analogous to the second term of the Black-Scholes formula with H in place of K. Exercise Show that equations (1) and (2) are equivalent to the formulae given in Hull (2003: 439), namely H 2l H 2 l-2 cdo = S0 -q T NHx1 L - K -r T NHx2 L - S0 -q T J N NHy1 L + J N K -r T NHy2 L S0 S0 cdi = c - cdi lnHS0 HL lnHS0 HL + Hr - q + s2 2L T !!!! !!!! x1 = !!!! = + l s T , x2 = x1 - s T !!!! s T s T

where

## lnHH S0 L lnHH S0 L + Hr - q + s2 2L T !!!! !!!! y1 = !!!! = + l s T , y2 = y1 - s T !!!! s T s T

Barrier.nb

s H 2 cdo HS0 , K, HL = cHS0 , HL + HH - KL bHS0 , HL - J N S0 2n

= S0 -q T NHx1 L - H -r T = S0
s H 2 J N S0 2n

-q T

where

NHx1 L - K

## i H 2 -q T y j j z NHy1 L - H -r T NHy2 L + HH - KL -r T NHy2 Lz S0 k {

-r T
s H 2 NHx2 L - J N S0 2n

## 2 i i H2 jcj , H y + HH - KL bi , H yy z jH zz j j z j zz k k S0 { k S0 {{ NHx2 L + HH - KL -r T NHx2 L -

i H 2 -q T y j j z NHy1 L - K -r T NHy2 Lz k S0 {

## Substituting and simplifying

where

H 2l H 2 l-2 cdo HS0 , K, HL = S0 -q T NHx1 L - K -r T NHx2 L - S0 -q T J N NHy1 L + J N K -r T NHy2 L S0 S0 lnHS0 HL lnHS0 HL + Hr - q + s2 2L T !!!! !!!! x1 = !!!! = + l s T , x2 = x1 - s T !!!! s T s T

Theorem 2 (Up-and-out) Suppose that V HS, F L denotes the value of a European derivative contract F HST L on S maturing at time T. The value of an up-and-out version of the derivative is where H > S0 is the barrier, n = r - q - s 2 2 and FH HSL = 9 FHSL, for S < H 0, for S H
s H 2 i H 2 y z j Vuo HS0 , FL = V HS0 , FH L - J N V j , FH z S { k S 2n

## = FHSL . IHS < HL

Barrier.nb Corollary 2 (Up-and-in) Suppose that V HSL denotes the value of a European derivative contract on S maturing at time T. The value of an up-and-in version of the same option is where H > S0 is the barrier, n = r - q - s 2 2, Example Vanilla European call FH HSL = FHSL . IHS > HL and
s H 2 i H 2 y j z Vui HS0 , FL = V HS0 , FH L + J N V j , FH z S0 k S0 { 2n

When H K, an up-and-in call is equivalent to a vanilla whereas the value of an up-and-out call is always zero. Therefore, we need only consider explicitly the case H > K. Recall that the up-truncated payoff of a vanilla European call when H > K is a portfolio comprising a bull spread together with a short position in H - K binary options. V HS, FH L = cHS, KL - cHS, HL - HH - KL bHS, HL
2n

## Substituting the payoff in Theorem 2

The down-truncated payoff of a vanilla European call when H > K is a portfolio comprising a standard call and HH - KL cash-or-nothing binary option both with strike H. Substituting the payoff in Corollary 2 V HS, FH L = cHS, HL + HH - KL bHS, HL
2n s H 2 i H 2 y j z cui HS0 , K, HL = V HS0 , FH L + J N V j , FH z S k S { = c HS0 , HL + HH - KL b HS0 , HL +

## s H 2 i H 2 y j z cuo HS0 , K, HL = V HS0 , F L - J N V j , FH z S k S { = cHS0 , KL - cHS0 , HL - HH - KL bHS0 , HL -

H J N S0

2n 2 s

i i j cj , K y - ci , H y - HH - KL bi , H yy z j z j zz j j z j z j zz k k S0 { k S0 { k S0 {{ H2 H2 H2

(3)

Exercise

H J N S0

2n 2 s

Show that equations (3) and (4) are equivalent to the formula on p. 440 of Hull (2003).

i j j j j c i , K y - c i , H y - HH - KL b i , H yy z z zz j j j j z z zz k S0 k S0 k k S0 { { {{ H2 H2 H2

(4)

Barrier.nb

Discrete monitoring The above formulae assume continuous monitoring of the asset price. Many real-world contracts assume monitoring at discrete intervals, e.g. daily at a specific time. Broadie, Glasserman and Kou (1997) suggest an adjustment to the barrier to account for discrete monitoring. Specifically, the barrier H is adjusted as follows

## where b = 0.5826 and m is the monitoring frequency. Summary

H +b s H

!!!!!!!!! -b s Tm ,

!!!!!!!!! Tm ,

H < S0 HdownL

H > S0

HupL

The following table summarizes the valuation formulae for European style barrier call options. cdi
H I 0 M S

H K
2n 2 s

H cI 0 , KM S

H H cdo cHS0 , KL - I 0 M s cI 0 , KM S S
2n 2 2

## cHS0 , KL - cHS0 , HL - HH - KL bHS0 , HL + cHS0 , HL + HH - KL bHS0 , HL +

2n 2 2 2 2n 2 2 2

H > K

cui

cHS0 , KL

cuo

## cHS0 , KL - cHS0 , HL - HH - KL bHS0 , HL -

H H H H I 0 M s I cI 0 , KM - cI 0 , HM - HH - KL bI 0 , HMM S S S S
2

cHS0 , HL + HH - KL bHS0 , HL 2n 2 2

H H H I 0 M s IcI 0 , HM + HH - KL bI 0 , HMM S S S
2n 2 2 2 2

H H H I 0 M s IcI 0 , HM + HH - KL bI 0 , HMM S S S

Rebate

H H H H I 0 M s I cI 0 , KM - cI 0 , HM - HH - KL bI 0 , HMM S S S S
2

For knock-out options, it is customary for the rebate to be paid immediately that the barrier is hit. This complicates the valuation, since the rebate is paid at a random time. The discounted expected value of the rebate R is i H a+b H a-b !!!! y z j Vrebate = R jJ N NHh zL + J N NIh z - 2 h b s T M z z j z j S S0 { k 0

where

Proof

and h = 1 if the barrier is approached from above HS0 > HL and h = -1 if the barrier is approached from below HS0 < HL.

10

Barrier.nb

## Standard American barrier options

We showed above that, for H K, the value of a down-and-in vanilla European option is related to the value of the underlying non-barrier option by the formula
s H 2 cdi HS0 , K, HL = J N S0 2n

Fortunately, the same relationship applies to knock-in American options (Haug 2001, Dai and Kwok 2004). That is, where H K,
s H 2 i H 2 y j z Cdi HS0 , K, HL = J N Cj , K z S0 k S0 { 2n

i H2 y j z cj , K z S0 k {

(5)

where Cdi is the value of a knock-in option entitling the holder to a standard American option of strike K if and when the asset price S falls below the barrier H, and C is the value of the underlying American option. More generally
s H 2 i i H 2 y i H2 yy j j z j zz Cdi HS0 , K, HL = J N jCj , K z - cj , K zz + cdi HS, K, HL S0 k k S0 { k S0 {{ 2n

(6)

provided that

When H K, cdi HS, K, HL matches the second term inside the brackets.

Analogous (though different formulae) can be given when (7) is not satisfied (Dai and Kwok 2004). This means that we can easily value a knock-in American option by applying our best numerical techniques to corresponding standard options. Unfortunately (for computation), in-out parity does not hold for American barrier options. Consequently, we cannot use (6) to compute the value of a knock-out option. Indeed, Cdi HS, K, HL + Cdo HS, K, HL > CHS, KL

r y i H max j z jK, K z q { k

(7)

To see this, consider a portfolio comprising a down-and-in plus a down-and-out with the same strike, barrier and maturity. We show that this portfolio dominates a corresponding nonbarrier call. Suppose that the portfolio holder adopts an exercise policy for the down-and-out identical to that for the nonbarrier option (though this is suboptimal for the down-and-out). The exercise payoff of the portfolio is always higher than that of the nonbarrier call because the portfolio has an additional option. Both the portfolio and the option have the same payoff at maturity because one of the options will be knocked-out. In all scenarios, the portfolio is worth at least as much as the option and possibly more.

Barrier.nb

11

Numerical methods
The preceding analysis provides exact formulae for standard European barrier options, plus an efficient approach for dealing with American knock-in options. However, this does not exhaust the variety of barriers options traded in over-the-counter markets. In particular, where the barrier is non-constant (and non-exponential) early exercise is allowed (American knock-out options) it is desired to allow for non-lognormality (volatility skew) it is necessary to resort to numerical methods. Barrier options pose a special problem for numerical methods, which is illustrated by the binomial method.

Binomial trees
We have previously examined the convergence of the basic binomial method. The following diagram depicts the errors for a one-year vanilla European call option (S = 95, K = 100, r = 10 %, q = 0, s = 25 %).

0.04 0.02

50 -0.02 -0.04

100

150

200

250

300

Performance deteriorates dramatically when applied to Barrier options. For a down-and-out version of the previous option with the barrier at 90, we find

12

Barrier.nb

Binomial error in down-and-out call 2 1.75 1.5 1.25 1 0.75 0.5 0.25 100 200 300 400

The reason is that, when the barrier lies between the nodes of the tree, the effective barrier is different to the true barrier. Performance can be significantly improved if we ensure that the barrier lies on or just above a row of nodes. This requires a judicious choice of the number of steps n. Recall that in the basic binomial model u = s
!!!!!!!!! Tn !!!!!!!!! Tn

, d = -s

Barrier H will be precisely aligned with a row of nodes in a tree of size n when S0 k s
!!!!!!!!! Tn

= H

for some k = 1, 2, , n.
2 y i ks n = j z T , k = 1, 2, z j k lnHS0 HL {

T S0 ln = k s \$%%%%%%% H n

Barrier H will lie on or just above a row of nodes when n is the largest integer which is smaller than the right-hand side. For the option depicted above, these magic numbers are 21, 85, 192, 342 and 534.

At these magic numbers, the binomial method delivers similar accuracy to that obtained for vanilla options.

Barrier.nb

13

## 0.25 0.2 0.15 0.1 0.05

100

200

300

400

Derman, Kani, Ergener and Bardhan (1995) propose an enhancd binomial method to allow for nonconstant barriers.

Trinomial trees
We have just seen how the accuracy of binomial method can be preserved by careful selection of the tree size n to align the barrier with the nodes in the tree. Since the trinomial tree has an additional degree of freedom, this alignment can achieved for any n through judicious choice of the "stretch" parameter l. The standard parameterization of the trinomial tree is u = l s 1 d = u
!!!!!! Dt

## 1 n = r - q - s2 2 !!!!! 1 Dt pu = + n 2 2l 2ls !!!!! 1 Dt pd = - n 2 2l 2ls

1 pm = 1 - pu - pd = 1 - 2 l

14

Barrier.nb

Consider an up-and-out barrier option. To find the appropriate value of l, start with l = 1. Let m denote the maximum number of consecutive up moves allowed before breaching the barrier. That is S0 um < H Given l = 1, we have S0 m s Define
!!!!!! Dt

but

< H

## and then choose l > 1 such that l m = m* which implies that S0 l m s

!!!!!! Dt

logHH S0 L m* = !!!!! s Dt = H

With this choice of l, the tree is precisely aligned with the barrier after m upward steps. For example, suppose S0 = 95, H = 125, with s = 25 % and T = 1. For a 5-step tree, Dt = 1 5, m* = 2.45464 and m = 2, so that l = m* m = 1.22732. For this choice of l, the tree coincides with the barrier after precisely 2 steps. The following graph depicts the convergence of a trinomial tree in valuing a 6-month European up-and-out call option (S = 100, K = 90, H = 125, r = 5 %, q = 2 %, and s = 30 %L. The red path shows the error !!!!!!!!! of a trinomial tree with l = 3 2 against n, while the blue line depicts the error a trinomial tree in which l is chosen optimally for each n so as to align a row of nodes with the barrier.

## Trinomial error in up-and-out call

0.4

0.2

100 -0.2
The following graph displays the percentage error.

200

300

400

Barrier.nb

15

20

10

100 -10

200

300

400

## Hull (2003) Options, Futures, and Other Derivatives

Preliminaries

Examples
Commodity markets The soybean crush spread traded on the CBOT is CS 48 2000
M

SM

11 100

SO

SB

where S is the price is the futures price of soy meal in dollars per ton, S O is the futures price of soy oil in dollars per 100 pounds, and St is the futures price of soybean in dollars per bushel. The payoff of a call option on the soybean crush is CSC CS K

Energy markets The payoff of the 1:1:0 gasoline crack spread call is CSGC 42 UG CO K

where UG is the price of unleaded gasoline (\$ / gallon) and CO is the price of crude oil (\$ / barrel). The payoff of the 3:2:1 crack spread call is CSHC 42 2 3 UG 1 3 HO CO K

where HO is the price of heating oil. Crack spread options are traded on NYMEX. A spark spread is a proxy for cost of converting a specific fuel (usually natural gas) into electricity. SS E Heff NG

where E and NG are the futures prices of electricity and natural gas, and Heff is the heat rate. Interest rate markets The TED spread measures the difference between 3-month Tbills and 3-month LIBOR. The MOB spread measures the difference in yield between municipal and treasury bonds.

Exchange options
A spread option with a zero strike is known as an option to exchange payoff S1 S2

for which we have an exact formula (known as the Magrabe formula). c where d1 Ln S1 S2 q2 T q1 2 2 T
q1 T

S1 N d1

q2 T

S2 N d2

d2

d1

2 1

2 1 1

2 2

Note that the value is independent of the risk-free rate. Alternatively, in terms of futures prices, we have c where d1 d2 Ln F1 F2 d1 T T 2 T 2
rT

F1 N d1

F2 N d2

2 1

2 1 1

2 2

Approximations
The Kirk approximation The payoff of a spread option is payoff S1 S2 K K, treating
F2 F2 K

The popular Kirk approximation values the spread option as an exchange between F1 and F2 F2 c where Fi
r qi T

## K as lognormal with volatilty

rT

2 .

F1 N d1

F2

K N d2

Si , i

1, 2 b 2 2 , b 2 F2 F2 K

2 1 Ln

2 b 1 1
1 2

d1 d2 d1

F1 F2 K

2 T

Clearly, the Kirk approximation reduces to the Margrabe formula when K K S2 . Bjerksund and Stensland The payoff of the spread can be written as CT S1 S2 K S1 S2 K I S1 T S2 T K

## 0, and will be most useful when

where I is the indicator function, taking the value one when its argument is true, and zero otherwise. Bjerksund and Stensland consider the related derivative with the payoff cT where a S1 F2 S2 K K, b S1 S2 K I S1 T a S2 T E S2 T
b b

F2 F2

S2

r q2 T

## . This has two implications:

They can compute the exact value of the related derivative, which they propose as a superior alternative to the Kirk approximation. The related derivative can be used as a control variable in simulating the value of a spread option. The exact value is given by the following formula. c where Fi d1 1 d2 d1 12 d3 d1 Ln d3
F1 a r qi T rT

F1 N d1

F2 N d2

K N d3

Si , i

1, 2 b 2 2 2 b 1 2 T 1 2 1 2 1 1 2 b 22 T 1 2 b2 2 2 b 2 T 2
1 2

2 1 Ln
F1 a

2 b 1 1
1 2

2 1

b2 2 T 2

d2

Ln T 12

F1 a

b 1 2

b 1 2
1 2

T
1 2

2 1 T

b2 2 T 2

Greeks
For the BjS c
rT

F1 N d1 1

F2 N d2

K N d3

First note di F1 c F1
rT

F1
rT

T N d1 F1 d1 F1 d1 F2 d2 F2 1 d2 F1 T K d3 K d3 di F1

N d1

and therefore c S1 c F1 F1 S1
qT

N d1

F1 d1

F2 1 d2 F1 T

K d3

Computing the derivative with respect to F2 is a a little more difficult, since the adjusted volatility depends upon b, which is a function of F2 . b F2 b2 K
2 F2

d0 F2 d1 F2 d2 F2 2 d1 F2 2

1 T 3 1 T 3

2 1

b 2

K b2 F22 K b2 F22

Log

F1 F2 K F1 F2 T K

T 2

2 2 F2 K

2 1 b2 K 1 F22

b 2

2 Log

T 2

2 2 F2 K

b 1

2 12 22 3

## Volatility and Variance swaps

Introduction
A volatility swap is a forward contract on realized volatility. Its payoff is payoff R Kvol N

where R is realised volatility (annualized), Kvol is the specified delivery price, and N is the notional amount of the swap in "dollars" per annualized volatility point. A variance swap is a forward contract on realized variance, with payoff payoff 2 R Kvar N

where N is expressed in "dollars" per annualized volatility point squared. For example, a 3-month volatility swap on the S&P 500 struck at 20% with a notional \$100,000 would pay (25 - 20) 100000 = \$500000 if the realised volatility was 25%. A volatility or variance swap is a position on realized volatility. It is related to, but distinct from, options on implied volatility (VIX) which are traded on the CBOE. Questions how to hedge volatility. how to replicate (hence price and hedge) a variance swap? how is the VIX computed.

Hedging volatility
In the Black-Scholes framework, vega of a vanilla call or put is Vega where Ln S K d1 T For this purpose, it is convenient to measure variance vega, which (by the chain rule) is a multiple of vega. VarVega V r q 2 T 2 V
qT

S N ' d1

2 1 2

Vega

The following graph shows vega on traded options on the Nifty on 5 January 2010, allowing for the volatility smile. We observe that: (Var)vega is sharply peaked around the strike of an option. We also observe that (var)vega increases with the strike.

VarSwaps.nb

## Vega of a one month options on the Nifty at selected strikes

1500

1000

500

4000

5000

6000

7000

This suggests that vega can be hedged by a weighted portfolio of traded options. This is illustrated in the following diagram, where the red line is the (var)vega of a portfolio of options weighted inversely to strike squared.

1500

1000
Out[6]=

500

4000

5000

6000

7000

In fact, a portfolio of options at all strikes, weighted inversely proportional to strike, will give an exposure to variance which is independent of asset price. This is precisely what is needed to trade pure variance. It is easy to show that the terminal payoff of such a portfolio comprising puts K K and calls K K is
K

payoff

K2 ST K K

ST log ST K

K
K

1 K2

ST

K
(1)

## Valuing a variance swap

For an asset following geometric Brownian motion, it can be shown that expected (realized) variance over period 0, T is E Var 2 T r q T E log ST
(2)

S0

Inverting equation (1) shows that a log contract is equivalent to a forward together with a portfolio of vanilla calls and puts.

VarSwaps.nb

log

ST K

ST K

K 1 K2 1
sK

forward K ST ST K K K S0 K F F K
K 0

K 0

r q T

K2

E ST

q T

log

log

F K K K

K
0 rT 0 K

1 K
2

rT

PK

K
K rT K

1 K2 1 K
2

rT

CK

K
(3)

1 K
2

PK

CK
2

1 K2

rT

PK

K
K

1 K2

rT

CK

1 F T K

## where we have used the fact that log F K F K K

To value a variance swap, we need to approximate this with traded options. First method: numerical integration Approximate (3) by E Var 2 T
K K

K K2

rT

PK
K K

K K2

rT

CK

1 F T K

(4)

This is the basis of the method employed to calculate the VIX. Second method: replicating the log contract Rewriting (2) E Var 2 T 2 T 2 T where f ST 2 T ST K K log ST K r q T S0 r q T E ST K
r q T

q T

E log

## ST S0 K E ST K K log K S0 K E log K S0 E f ST log ST K

f ST is a payoff function which can be approximated by a portfolio traded vanilla calls and puts, as shown in the workbook VarSwaps.xlsm.

VarSwaps.nb

0.20

0.15

0.10

0.05

4500

5000

5500

6000

6500

## To approximate this, consider first the segment around K .

A segment of the payoff function f ST
0.005

0.004

Out[25]=

0.003

0.002

0.001

5400

5500

5600

5700

## Computing the VIX

The CBOE VIX is an estimate of the 30-day expected volatility of the S&P 500 index, computed as a weighted average estimated volatility for near- and next-term options. Specifically VIX 100 T2 T2 T30 T1 T1 2 1 T30 T2 T1 T1 T2 2 2

where 2 and 2 are the estimated variance of near- and next-term options respectively, T1 and T2 are their 1 2 respective times to maturity and T30 30 365. Each variance computed by evaluating (4) using all quoted options with active bid price. In the evaluation times to maturity are computed in minutes (although expressed on an annual basis). the forward price F is computed by put-call parity applyed to the nearest-to-the-money strike F KNTM
rT

CK

PK

where KNTM is the strike at which the absolute difference between call and put prices is mininized. the boundary K is selected as the strike immediately below the forward price F. In computing India-VIX, the NSE uses the same methodology, with the following modifications. the risk-free rate is MIBOR 30 or 90 days. (It appears that the rate is not interpolated to match time to maturity.)

VarSwaps.nb

the forward price F is set at the appropriate futures closing price. cubic splines are used to compute mid-price where the bid-ask spread is greater than 30%.

## Interest rate derivatives

Michael Carter
Interest rate derivatives are financial assets whose payoff depends in some way on the level of interest rates. Examples include Bond options Bond futures options Callable and putable bonds Mortgages Mortgate-backed securities Interest rate caps and floors Swaps Swapoptions Interest rate derivatives are more difficult to value than stock or foreign exchange derivatives, because The behavior of interest rates is more complicated. It is necessary to develop of model describing the behavior of the entire zero-coupon yield curve. The volatilities at different point of the yield curve are different. Interest rates are used for discounting as well as defining the payoff of the derivative.

## Modeling the term structure - discrete time

We can represent the term structure of interest rates in three equivalent ways: discount function (prices of zero coupon bonds) spot rates (yield to maturity of zero coupon bonds) forward rates Let R1 , R2 , , RT denote the spot rates of interest appropriate to 1, 2, , T years (we assume annual compounding for simplicity). Then the current prices of zero coupon bonds are 1 PH0, 1L = , 1 + R1 Conversely
1

T 1 RT = J N - 1 PH0, TL

1 PH0, 2L = 2 , , H1 + R2 L

1 PH0, TL = T H1 + RT L

(1)

(2)

InterestRateDerivatives.nb

Forward rates are rates agreed now for a loan in the future. For example, f3,5 denotes the rate agreed now for a 2-year loan beginning in 3 years. Absence of arbitrage requires that H1 + R2 L2 = H1 + R1 L H1 + f1,2 L

## Substituting from (1), we have

H1 + RT LT = H1 + Rt Lt H1 + ft,T LT-t 1 1 = H1 + f1,2 L PH0, 2L PH0, 1L PH0, 1L f1,2 = - 1 PH0, 2L and and

so that

## Note also that H1 + R3 L3 = H1 + R2 L2 H1 + f2,3 L = H1 + R1 L H1 + f1,2 L H1 + f2,3 L H1 + RT LT = H1 + R1 L H1 + f1,2 L H1 + f2,3 L H1 + fT-1,T L

so that

In a discrete model, the short rate r is the one period forward rate. That is PH0, 0L 1 = f0,1 = - 1 = - 1 = R1 , r1 = f1,2 , PH0, 1L PH0, 1L r2 = f2,3 , , rT-1 = fT-1,T

r0

## Modeling the term structure - continuous time

As in the Black-Scholes model, theoretical work is almost always exposited in continuous time. As with discrete compounding, we can represent the term structure of interest rates in three equivalent ways: discount function (prices of zero coupon bonds) spot rates (yield to maturity of zero coupon bonds) forward rates Each of these familiar interest rate concepts has a continuous time counterpart.

InterestRateDerivatives.nb

## T-t RHt, TL = PHt, TL - 1

To derive the expressions for the forward rate, note that one period forward rates f Ht, t, t + 1L must satisfy where f Ht, t, t + 1L = RHt, t + 1L. In particular, this implies that
i=1

H1 + RHt, TLLT-t = H1 + RHt, t + 1LLH1 + f Ht, t + 1, t + 2LL H1 + f Ht, T - 1, TLL = H1 + f Ht, t + i - 1, t + iLL
T-t

## PHt, T + 1L f Ht, T, T + 1L = - 1 PHt, TL

1 PHt, TL = J N 1 + RHt, TL
1

Discrete

Continuous

T-t

(4)

which yields

(5)

## For small time periods, (5) requires

or

ln PHt, T + DTL = - f Ht, T, T + D TL DT ln PHt, TL Letting D T 0, the instantaneous forward rate is ln PHt, T + D TL - ln PHt, TL f Ht, TL = lim - = - ln PHt, TL DT 0 DT T
T-t

(6)

From (1)

## With continuous discounting, this becomes

T-t i T-t y j z j z PHt, TL = - f Ht,t+i-1,t+iL1 = expj - f Ht, t + i - 1, t + iL1z j z j z i=1 k i=1 {

## In continuous time, this becomes PHt, TL = -t

T

f Ht,tL t

InterestRateDerivatives.nb

This can be derived more formally by integrating (3) ln PHt, tL t = ln PHt, TL - ln PHt, tL = -
T t T

## But since PHt, tL = 1

The price of the discount bond is the final cashflow discounted by instantaneous forward rates. It follows that the spot rate is the continuous average of forward rates
T 1 RHt, TL = f Ht, tL t T -t t

ln PHt, TL = -

f Ht, tL t PHt, TL = -t

f Ht,tL t

f Ht, tL t

Further

The short rate r is the rate on instantaneous borrowing or lending, i.e. RHt, tL = f Ht, tL . A sum of \$1 invested at the short rate at time zero and continuously rolled over is called a money market account. Its value at time t is pt = 0 rs ds
t

## Interest rate derivatives as portfolios of bond options

Several popular interest rate derivatives can be valued as portfolios of European options on discount bonds. Therefore, it suffices to develop formulae or algorithms for discount bonds. This is especially useful in calibrating interest-rate models to market data.

Coupon bonds
Assuming that there is only one factor of uncertainty, so that all rates are positively related to r0 , we can value options on coupon bonds by treating them as a portfolio of options on zero-coupon bonds. Consider a call option maturing at time T on a coupon bond maturing at time tn > T, where n is the number of coupon payments remaining at time T. The price of the bond at time T will be B = ci PrT HT, ti L
n i=1

and the payoff of a call option maturing at time T will be i n y j z j z max j ci PrT HT, ti L - K, 0z j z k i=1 {

InterestRateDerivatives.nb

where rT is the short rate at time T. Note that cn includes the principal repayment. Note that B depends upon the short rate at time T. Let rK denote the short-rate at time T at which the price of the coupon bond is equal to the strike price. That is ci PrK HT, ti L = K
n i=1

The option will be exercised provided rT < rK and not exercised if rT rK . Let Ki denote the value at time T of a zero-coupon bond paying \$1 at time ti given rT = rK Ki = PrK HT, ti L
n n i=1 i=1

so that

## Therefore the payoff of the coupon bond option can be written as

n i n y y i n j z z j j z z j max j ci PrT HT, ti L - K, 0z = max j ci PrT HT, ti L - ci Ki , 0z j z z j k i=1 { { k i=1 i=1

ci Ki = ci PrK HT, ti L = K

n i=1

## Consequently, the option can be valued as a portfolio of options on discount bonds.

Swaptions
A swaption is an option on an interest rate swap, and can therefore be regarded as an option to exchange a coupon bond for a floating rate bond. At the start of the swap, the value of the floating rate bond equals the principal amount of the swap. A European swaption can therefore be regarded as an exchange a coupon bond for the principal amount of the swap. If the swaption gives the holder the right to pay fixed and receive floating (a payer swaption), it is a put option on a fixed rate bond with strike price equal to the notional principal. If the swaption gives the holder the right to pay floating and receive fixed (a receiver swaption), it is a call option on the fixed rate bond.

## Interest rate caps and floors

An interest rate cap is a portfolio of interest rate options. Each component option on a forward rate is known as a caplet. We show that an interest rate cap can be valued as a portfolio of European put options on discount bonds. Assuming annual tenor, the payoff from each caplet discounted to the beginning of the period is P max Hr - cap, 0L payoff = 1+r

where is P is the principal and cap is the cap rate. This is equivalent to

InterestRateDerivatives.nb

The second term in the brackets, PH1 + capL H1 + rL, is the value at the beginning of the period of a discount bond that pays P(1+cap) at the end of the period. Therefore, the payoff of the t-period caplet is equal to the payoff of a put option on a discount bond with a face value of PH1 + capL and a maturity of t + 1. The option has a strike price of P and maturity of t. Consequently, the cap can be regarded as a portfolio of European put options on zero-coupon bonds. Analogously, an interest rate floor can be valued as a portfolio of European call options on discount bonds. A collar is a combination of a long position in a cap and a short poisiton in a floor. There is a put-call parity relationship between the prices of caps and floors with the same strike place RK , namely cap price + floor price = value of swap where the swap is an agreement to receive floating and pay fixed RK , with no exchange of payments on the first reset date.

r - cap payoff = P max J , 0N 1+r 1 + r - H1 + capL = P max J , 0N 1+r PH1 + capL = max JP - , 0N 1+r

## Interest rate derivatives: Standard market models

Michael Carter
The three most popular over-the-counter interest rate derivatives are bond options, interest rate caps and floors and swap options. Many traders use a Black-Scholes type formula known as Black's model for valuing these derivatives. It is based on the following key result. THEOREM. If S is lognormally distributed and the standard deviation of ln S is s then PrHS > KL = NHd2 L

and

where

Consequently

lnHEHSL KL + s2 2 d1 = , s

## Proof: Hull (2003: 262-263)

Recognising that (under Black-Scholes assumptions) EHST L = S0 r T and s = s for a call option is immediate.

## Consider a European call option on a variable S. Let

c = -r T E@maxHS - K, 0LD = -r T HS0 r T NHd1 L - K NHd2 LL = S0 NHd1 L - K -r T NHd2 L T = time to maturity of the option F = forward price of S with maturity T F0 = value of F at time 0 K = strike price of option P H0, TL = price at time 0 of a discount bond paying \$1 at time T.

Assume

EHST L = F0

## S is lognormally distributed with the standard deviation of ln S equal to s

!!!! T

Black'sModel.nb

Then the expected payoff of the option at time T is E@maxHST - K, 0LD = F0 NHd1 L - K NHd2 L

where

## Similarly the value of a corresponding put option is

lnHF0 KL + s2 T 2 d1 = , !!!! s T

c = PH0, TL E@maxHST - K, 0LD = PH0, TL HF0 NHd1 L - K NHd2 LL p = PH0, TL HK NH-d2 L - F0 NH-d1 LL

(2)

## lnHF0 KL - s2 T 2 !!!! d2 = = d1 - s T !!!! s T (3)

This is usually referred to as Black's model since the formulas are similar to those in the model suggested by Fisher Black for commodity futures. Note that it is not necessary to make any assumption about the stochastic process followed by V of F, only that VT is lognormal at time T. Although the volatility parameter s is usually referred to as the volatility of F or the forward volatility of V , its only role is determine the standard deviation of ln S at time T.

Bond options
In addition to trading in the OTC market, bond options are frequently embedded in standard bonds in order to make them more attractive to the issuer or potential purchasers. Examples include callable bonds, puttable fonds and conventional mortages with early payment privileges. Most OTC bond options and some embedded bond options are European. In using Black's model to value European bond options, it is assumed that the bond price ST at the maturity of !!!! the option is lognormal with the standard deviation of ln ST = s T . The forward price of the bond is S0 - C F0 = PH0, TL where S0 is the current price and C is the present value of the coupons that will be paid during the life of the option. The value of a call option is given by (2) and the value of a put option by (3). The spot and forward prices in this formula are cash ("dirty") prices, and so the strike price should also be the cash price. In practice, the strike price is often the quoted ("clean") price applicable when the option is exercised, in which case K should be set equal to the strike price plus accrued interest at the expiration date of the option. The volatility parameter s is the volatility of the forward price F. Volatilities are usually quoted in terms of yield volatilities. Practitioners typically use bond duration to convert yield volatilities s y to price volatilities by s = D y0 s y . where D is modified duration and y0 is the forward yield.

Black'sModel.nb

The Black model assumes that volatility (variance) of the underlying increases linearly with time to maturity. However, the price of a bond as it approaches maturity must be equal to the principal plus coupon ("pull to par effect"). Therefore, the volatility of a bond over its life first increases then decreases to zero. Pricing of European bond options using the Black model should therefore be limited to options of short maturity compared to the maturity of the bond. A rule of thumb used by some traders is that the time to maturity of the option should be no more than one-fifth of the maturity of the underlying bond.

## Interest rate cap

Recall that an interest rate cap is a portfolio of interest rate options. The caplet corresponding to the rate rk observed at time tk provides a payoff at time tk+1 of L Dt maxHrk - cap, 0L where is L is the notional principal. This is effectively a call option on rk with the payoff made at time tk+1 . In using Black's model to value caps and floors, it is assumed that the interest rate rk is lognormal with volatility sk . Applying equation (1), the expected payoff at time tk+1 is E@L Dt maxHrk - cap, 0LD = L Dt @ fk NHd1 L - cap NHd2 LD

where fk is the forward rate between time tk and tk+1 , and lnH fk capL + s2 tk 2 !!!! d1 = k , d2 = d1 - s tk !!!! sk tk

## The present value of the caplet is

The value of an interest rate cap is the sum of the values of its constituent caplets, each valued according the previous equation. Similarly, the value of an interest rate floor is the sum of its constituent floorlets, each of which is analagous to a put option vfloorlet = PH0, t + 1L L Dt @ floor NH-d2 L - fk NH-d1 L D

## vcaplet = PH0, t + 1L L Dt @ fk NHd1 L - cap NHd2 LD

Where the same volatility is used to price each caplet, these are known as flat volatilities. In contrast, spot volatilities are specific to each caplet. While many traders like to use spot volatilities, cap prices are usually quoted in the market in terms of flat implied volatilities.

Swaption
The payoff from a payer swaption in each period is L Dt maxHrT - rS , 0L where L is the notional principal of the swap, rT is the actual swap rate at the maturity of the option, and rS is the fixed rate payable under the option. To apply Black's model to value the swaption, it is assumed that rT is lognormal with volatility (of log rT ) equal to s. The expected value of the cash flow received at time Ti is

Black'sModel.nb

## The total value of the swaption is

mn

where m = 1 Dt is the compounding frequency, n is the length of option (in years), and Ti = T + i m. Define The value of a payer swaption is vpayer = A L @r0 NHd1 L - rS NHd2 LD L Dt maxHrS - rT , 0L 1 A = PH0, Ti L m i=1
mn

i=1

## Similarly, the payoff of a receiver swaption in each period is

which is analogous to a put option on rT . The value of the receiver swaption vreceiver = A L @rS NH-d2 L - r0 NH-d1 L D

## Brokers provide tables of implied volatilities for European swap options.

Conclusion
Practitioners typically use an adaptation of Black's model for valuing the most popular interest rate derivatives bond options, interest rate caps and swaptions. Each model is based on the assumption that a key variable is lognormal. These assumptions are inconsistent with one another. For example, if future bond prices are lognormal, future zero rates and swap rates are not. Similarly, if future zero rates are lognormal, future bond prices and swap rates are not. However, the great popularity of this model for pricing both caps and swaptions indicates that this inconsistency is not significant economically.

## Determining price volatility from yield volatility

First consider an option maturing at t on a discount bond which matures at T. The initial price of the bond is S0
rT T

## At maturity of the option, the price of the bond is St

rt 1

S0
t

rT

T t

where rT

is a random variable.

Differentiating St rT
t

rT

T t

t St

t

rT

rT
t

t t

rT

t

Vol

rT rT
t

t

Vol

rT rT
t

## The Black-Derman-Toy model

The single factor model of Black-Derman-Toy stands out as a very attractive tool for pricing interest rate options in India. This model is lattice based, incorporates mean reversion, assumes level independent volatility and is calibrated through an exogenously specified yield curve. Jayant Varma, 1996

Michael Carter
The fundamental assumption underlying Black-Scholes and most other financial models is that asset prices follow a particular stochastic process called geometric Brownian motion (GBM) dS = m S dt + s S dz or dS = m dt + s dz S This implies that the logarithm of the stock price follows d ln S = n dt + s dz
1 2

(1)

(2)

The derivation of (2) from (1) is an application of Ito's lemma (Hull: 2003:232-233, where n = m Luenberger 1998:313). This implies that the asset price is lognormal, that is lnHSt L = lnHSt-1 L + n Dt + s et
!!!!!! Dt

s2 .

or

!!!!! Dt

St = n Dt + s et

St-1

## The basic binomial model sets n = 0, so that St = u St-1 or St = d St-1 with u = s

!!!!!! Dt !!!!!! Dt

and d = - s

The Black-Derman-Toy model assumes that short rates follow the stochastic process d ln r = nHtL dt + sHtL dz which implies that the short rate is lognormal lnHrt L = lnHrt-1 L + nHtL Dt + sHtL et rt = nHtL Dt + sHtL et
!!!!! Dt

or

!!!!! Dt

rt-1

## This can be approximated by a binomial model

BlackDermanToy.nb

## rt = u rt-1 or rt = d rt-1 with u = nt Dt + st

!!!!!! Dt !!!!! Dt

and d = nt Dt - st

where nt and st are chosen to match the actual term structure of interest rates and volatilities. The single asset and interest rate models are compared in the following table. Lognormal or Binomial lnHSt L = lnHSt-1 L + n Dt + s et or
!!!!!!

## St = n Dt + s et Dt St-1 St = u St-1 or St = d St-1 with u = s

!!!!! Dt

!!!!! Dt

lnHrt L = lnHrt-1 L + nHtL Dt + sHtL et or rt = nHtL Dt + sHtL et Dt rt-1 rt = u rt-1 or rt = d rt-1 with
!!!!!! Dt !!!!!!

!!!!! Dt

d = - s

!!!!! Dt

u = nt Dt + st

d = nt Dt - st

!!!!! Dt

## Kolmogorov-Smirnov One-Sided Test

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 > 40

0.1 0.9000 0.6838 0.5648 0.4927 0.4470 0.4104 0.3815 0.3583 0.3391 0.3226 0.3083 0.2958 0.2847 0.2748 0.2659 0.2578 0.2504 0.2436 0.2373 0.2316 0.2262 0.2212 0.2165 0.2120 0.2079 0.2040 0.2003 0.1968 0.1935 0.1903 0.1873 0.1844 0.1817 0.1791 0.1766 0.1742 0.1719 0.1697 0.1675 0.1655 1:07= n

0.05 0.9500 0.7764 0.6360 0.5652 0.5094 0.4680 0.4361 0.4096 0.3875 0.3687 0.3524 0.3382 0.3255 0.3142 0.3040 0.2947 0.2863 0.2785 0.2714 0.2647 0.2586 0.2528 0.2475 0.2424 0.2377 0.2332 0.2290 0.2250 0.2212 0.2176 0.2141 0.2108 0.2077 0.2047 0.2018 0.1991 0.1965 0.1939 0.1915 0.1891 1:22= n

0.025 0.9750 0.8419 0.7076 0.6239 0.5633 0.5193 0.4834 0.4543 0.4300 0.4092 0.3912 0.3754 0.3614 0.3489 0.3376 0.3273 0.3180 0.3094 0.3014 0.2941 0.2872 0.2809 0.2749 0.2693 0.2640 0.2591 0.2544 0.2499 0.2457 0.2417 0.2379 0.2342 0.2308 0.2274 0.2242 0.2212 0.2183 0.2154 0.2127 0.2101 1:36= n

0.01 0.9900 0.9000 0.7846 0.6889 0.6272 0.5774 0.5384 0.5065 0.4796 0.4566 0.4367 0.4192 0.4036 0.3897 0.3771 0.3657 0.3553 0.3457 0.3369 0.3287 0.3210 0.3139 0.3073 0.3010 0.2952 0.2896 0.2844 0.2794 0.2747 0.2702 0.2660 0.2619 0.2580 0.2543 0.2507 0.2473 0.2440 0.2409 0.2379 0.2349 1:52= n

0.005 0.9950 0.9293 0.8290 0.7342 0.6685 0.6166 0.5758 0.5418 0.5133 0.4889 0.4677 0.4490 0.4325 0.4176 0.4042 0.3920 0.3809 0.3706 0.3612 0.3524 0.3443 0.3367 0.3295 0.3229 0.3166 0.3106 0.3050 0.2997 0.2947 0.2899 0.2853 0.2809 0.2768 0.2728 0.2690 0.2653 0.2618 0.2584 0.2552 0.2521 1:63= n