Simulation Efficiency and an Introduction to Variance Reduction Methods

Similar documents
IEOR E4703: Monte-Carlo Simulation

1 Estimating sensitivities

5. Best Unbiased Estimators

14.30 Introduction to Statistical Methods in Economics Spring 2009

Combining imperfect data, and an introduction to data assimilation Ross Bannister, NCEO, September 2010

Estimating Proportions with Confidence

x satisfying all regularity conditions. Then

Statistics for Economics & Business

Parametric Density Estimation: Maximum Likelihood Estimation

point estimator a random variable (like P or X) whose values are used to estimate a population parameter

5 Statistical Inference

Sampling Distributions and Estimation

FINM6900 Finance Theory How Is Asymmetric Information Reflected in Asset Prices?

. (The calculated sample mean is symbolized by x.)

0.1 Valuation Formula:

Monetary Economics: Problem Set #5 Solutions

A random variable is a variable whose value is a numerical outcome of a random phenomenon.

Chapter 8. Confidence Interval Estimation. Copyright 2015, 2012, 2009 Pearson Education, Inc. Chapter 8, Slide 1

1 Random Variables and Key Statistics

Lecture 4: Parameter Estimation and Confidence Intervals. GENOME 560 Doug Fowler, GS

Online appendices from The xva Challenge by Jon Gregory. APPENDIX 10A: Exposure and swaption analogy.

Introduction to Probability and Statistics Chapter 7

The material in this chapter is motivated by Experiment 9.

Unbiased estimators Estimators

Binomial Model. Stock Price Dynamics. The Key Idea Riskless Hedge

Appendix 1 to Chapter 5

STRAND: FINANCE. Unit 3 Loans and Mortgages TEXT. Contents. Section. 3.1 Annual Percentage Rate (APR) 3.2 APR for Repayment of Loans

Exam 1 Spring 2015 Statistics for Applications 3/5/2015

1. Suppose X is a variable that follows the normal distribution with known standard deviation σ = 0.3 but unknown mean µ.

of Asset Pricing R e = expected return

Today: Finish Chapter 9 (Sections 9.6 to 9.8 and 9.9 Lesson 3)

Topic-7. Large Sample Estimation

r i = a i + b i f b i = Cov[r i, f] The only parameters to be estimated for this model are a i 's, b i 's, σe 2 i

ECON 5350 Class Notes Maximum Likelihood Estimation

CHAPTER 8 Estimating with Confidence

of Asset Pricing APPENDIX 1 TO CHAPTER EXPECTED RETURN APPLICATION Expected Return

Models of Asset Pricing

Models of Asset Pricing

Models of Asset Pricing

A point estimate is the value of a statistic that estimates the value of a parameter.

AY Term 2 Mock Examination

Basic formula for confidence intervals. Formulas for estimating population variance Normal Uniform Proportion

Sampling Distributions & Estimators

ii. Interval estimation:

ST 305: Exam 2 Fall 2014

Notes on Expected Revenue from Auctions

Chapter 8: Estimation of Mean & Proportion. Introduction

NOTES ON ESTIMATION AND CONFIDENCE INTERVALS. 1. Estimation

A Bayesian perspective on estimating mean, variance, and standard-deviation from data

Lecture 5 Point Es/mator and Sampling Distribu/on

Lecture 9: The law of large numbers and central limit theorem

Chapter 10 - Lecture 2 The independent two sample t-test and. confidence interval

We learned: $100 cash today is preferred over $100 a year from now

Problem Set 1a - Oligopoly

Maximum Empirical Likelihood Estimation (MELE)

FOUNDATION ACTED COURSE (FAC)

Math 124: Lecture for Week 10 of 17

Lecture 4: Probability (continued)

18.S096 Problem Set 5 Fall 2013 Volatility Modeling Due Date: 10/29/2013

Standard Deviations for Normal Sampling Distributions are: For proportions For means _

Exam 2. Instructor: Cynthia Rudin TA: Dimitrios Bisias. October 25, 2011

Confidence Intervals. CI for a population mean (σ is known and n > 30 or the variable is normally distributed in the.

Online appendices from Counterparty Risk and Credit Value Adjustment a continuing challenge for global financial markets by Jon Gregory

Confidence Intervals Introduction

A New Constructive Proof of Graham's Theorem and More New Classes of Functionally Complete Functions

Summary. Recap. Last Lecture. .1 If you know MLE of θ, can you also know MLE of τ(θ) for any function τ?

Sequences and Series

Rafa l Kulik and Marc Raimondo. University of Ottawa and University of Sydney. Supplementary material

CAPITAL PROJECT SCREENING AND SELECTION

Solutions to Problem Sheet 1

Research Article The Probability That a Measurement Falls within a Range of n Standard Deviations from an Estimate of the Mean

Quantitative Analysis

Inferential Statistics and Probability a Holistic Approach. Inference Process. Inference Process. Chapter 8 Slides. Maurice Geraghty,

STAT 135 Solutions to Homework 3: 30 points

1 The Black-Scholes model

BASIC STATISTICS ECOE 1323

Institute of Actuaries of India Subject CT5 General Insurance, Life and Health Contingencies

INTERVAL GAMES. and player 2 selects 1, then player 2 would give player 1 a payoff of, 1) = 0.

Calculation of the Annual Equivalent Rate (AER)

SCHOOL OF ACCOUNTING AND BUSINESS BSc. (APPLIED ACCOUNTING) GENERAL / SPECIAL DEGREE PROGRAMME

Chapter 8 Interval Estimation. Estimation Concepts. General Form of a Confidence Interval

Topic 14: Maximum Likelihood Estimation

The Valuation of the Catastrophe Equity Puts with Jump Risks

Subject CT5 Contingencies Core Technical. Syllabus. for the 2011 Examinations. The Faculty of Actuaries and Institute of Actuaries.

First determine the payments under the payment system

Annual compounding, revisited

Non-Inferiority Logrank Tests

Introduction to Econometrics (3 rd Updated Edition) Solutions to Odd- Numbered End- of- Chapter Exercises: Chapter 2

BIOSTATS 540 Fall Estimation Page 1 of 72. Unit 6. Estimation. Use at least twelve observations in constructing a confidence interval

Subject CT1 Financial Mathematics Core Technical Syllabus

4.5 Generalized likelihood ratio test

CHAPTER 2 PRICING OF BONDS

CAPITAL ASSET PRICING MODEL

1 The Power of Compounding

Control Charts for Mean under Shrinkage Technique

Kernel Density Estimation. Let X be a random variable with continuous distribution F (x) and density f(x) = d

Overlapping Generations

An Empirical Study of the Behaviour of the Sample Kurtosis in Samples from Symmetric Stable Distributions


The Time Value of Money in Financial Management

Transcription:

Mote Carlo Simulatio: IEOR E4703 Columbia Uiversity c 2017 by Marti Haugh Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods I these otes we discuss the efficiecy of a Mote-Carlo estimator. This aturally leads to the search for more efficiet estimators ad towards this ed we describe some simple variace reductio techiques. I particular, we describe cotrol variates, atithetic variates ad coditioal Mote-Carlo, all of which are desiged to reduce the variace of our Mote-Carlo estimators. We will defer a discussio of other variace reductio techiques such as commo radom umbers, stratified samplig ad importace samplig util later. 1 Simulatio Efficiecy Suppose as usual that we wish to estimate θ := E[h(X)]. The the stadard simulatio algorithm is: 1. Geerate X 1,..., X 2. Estimate θ with θ = j=1 Y j/ where Y j := h(x j ). 3. Approximate 100(1 α)% cofidece itervals are the give by [ ] σ θ z 1 α/2, θ σ + z 1 α/2 where σ is the usual estimate of Var(Y ) based o Y 1,..., Y. Oe way to measure the quality of the estimator, θ, is by the half-width, HW, of the cofidece iterval. For a fixed α, we have Var(Y ) HW = z 1 α/2. We would like HW to be small, but sometimes this is difficult to achieve. This may be because Var(Y ) is too large, or too much computatioal effort is required to simulate each Y j so that is ecessarily small, or some combiatio of the two. As a result, it is ofte imperative to address the issue of simulatio efficiecy. There are a umber of thigs we ca do: 1. Develop a good simulatio algorithm. 2. Program carefully to miimize storage requiremets. For example we do ot eed to store all the Y j s: we oly eed to keep track of Y j ad Yj 2 to compute θ ad approximate CI s. 3. Program carefully to miimize executio time. 4. Decrease the variability of the simulatio output that we use to estimate θ. The techiques used to do this are usually called variace reductio techiques. We will ow study some of the simplest variace reductio techiques, ad assume that we are doig items (1) to (3) as well as possible. Before proceedig to study these techiques, however, we should first describe a measure of simulatio efficiecy.

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 2 1.1 Measurig Simulatio Efficiecy Suppose there are two radom variables, W ad Y, such that E[W ] = E[Y ] = θ. The we could choose to either simulate W 1,..., W or Y 1,..., Y i order to estimate θ. Let M w deote the method of estimatig θ by simulatig the W i s. M y is similarly defied. Which method is more efficiet, M w or M y? To aswer this, let w ad y be the umber of samples of W ad Y, respectively, that are eeded to achieve a half-width, HW. The we kow that ( z1 α/2 ) 2 w = Var(W ) HW ( z1 α/2 ) 2 y = Var(Y ). HW Let E w ad E y deote the amout of computatioal effort required to produce oe sample of W ad Y, respectively. The the total effort expeded by M w ad M y, respectively, to achieve a half width HW are T E w = T E y = ( z1 α/2 HW ( z1 α/2 HW ) 2 Var(W ) Ew ) 2 Var(Y ) Ey. We the say that M w is more efficiet tha M y if T E w < T E y. Note that T E w < T E y if ad oly if Var(W )E w < Var(Y )E y. (1) We will use the quatity Var(W )E w as a measure of the efficiecy of the simulator, M w. Note that (1) implies we caot coclude that oe simulatio algorithm, M w, is better tha aother, M y, simply because Var(W ) < Var(Y ); we also eed to take E w ad E y ito cosideratio. However, it is ofte the case that we have two simulators available to us, M w ad M y, where E w E y ad Var(W ) << Var(Y ). I such cases it is clear that usig M w provides a substatial improvemet over usig M y. 2 Cotrol Variates Suppose you wish to determie the mea midday temperature, θ, i Grasslad ad that your data cosists of {(T i, R i ) : i = 1,... } where T i ad R i are the midday temperature ad daily raifall, respectively, o some radom day, D i. The θ = E[T ] is the mea midday temperature.if the D i s are draw uiformly from {1,..., 365}, the a obvious estimator for θ is θ = i=1 T i ad we the kow that E[ θ ] = θ. Suppose, however, that we also kow: 1. E[R], the mea daily raifall i Grasslad 2. R i ad T i are depedet; i particular, it teds to rai more i the cold seaso Is there ay way we ca exploit this iformatio to obtai a better estimate of θ? The aswer of course, is yes. Let R := i=1 R i/ ad ow suppose R > E[R]. The this implies that the D i s over-represet the raiy seaso i compariso to the dry seaso. But sice the raiy seaso teds to coicide with the cold seaso, it also meas that the D i s over-represet the cold seaso i compariso to the warm seaso. As a result, we expect θ < θ. Therefore, to improve our estimate, we should icrease θ. Similarly, if R < E[R], we should decrease θ. I this example, raifall is the cotrol variate sice it eables us to better cotrol our estimate of θ. The priciple idea behid may variace reductio techiques (icludig cotrol variates) is to use what you kow

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 3 about the system. I this example, the system is Grasslad s climate, ad what we kow is E[R], the average daily raifall. We will ow study cotrol variates more formally, ad i particular, we will determie by how much we should icrease or decrease θ. 2.1 The Cotrol Variate Method Suppose agai that we wish to estimate θ := E[Y ] where Y = h(x) is the output of a simulatio experimet. Suppose that Z is also a output of the simulatio or that we ca easily output it if we wish. Fially, we assume that we kow E[Z]. The we ca costruct may ubiased estimators of θ: 1. θ = Y, our usual estimator 2. θ c := Y + c(z E[Z]) for ay c R. The variace of θ c satisfies Var( θ c ) = Var(Y ) + c 2 Var(Z) + 2c Cov(Y, Z). (2) ad we ca choose c to miimize this quatity. Simple calculus the implies the optimal value of c is give by ad that the miimized variace satisfies c Cov(Y, Z) = Var(Z) Var( θ c ) = Var(Y ) = Var( θ) Cov(Y, Z)2 Var(Z) Cov(Y, Z)2. Var(Z) I order to achieve a variace reductio it is therefore oly ecessary that Cov(Y, Z) 0. The ew resultig Mote Carlo algorithm proceeds by geeratig samples of Y ad Z ad the settig i=1 θ c = (Y i + c (Z i E[Z])). There is a problem with this, however, as we usually do ot kow Cov(Y, Z). We overcome this problem by doig p pilot simulatios ad settig p j=1 Ĉov(Y, Z) = (Y j Y p )(Z j E[Z]). p 1 If it is also the case that Var(Z) is ukow, the we also estimate it with p j=1 Var(Z) = (Z j E[Z]) 2 p 1 ad fially set ĉ = Ĉov(Y, Z) Var(Z). Assumig we ca fid a cotrol variate, our cotrol variate simulatio algorithm is as follows. Note that the V i s are IID, so we ca compute approximate cofidece itervals as before.

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 4 Cotrol Variate Simulatio Algorithm for Estimatig E[Y ] / Do pilot simulatio first / for i = 1 to p geerate (Y i, Z i ) compute ĉ / Now do mai simulatio / for i = 1 to geerate (Y i, Z i ) set V i = Y i + ĉ (Z i E[Z]) set θĉ = V = i=1 V i/ set σ,v 2 = (V i θĉ ) 2 /( 1) σ set 100(1 α) % CI = [ θĉ z,v 1 α/2 ], θĉ σ + z,v 1 α/2 Example 1 Suppose we wish to estimate θ = E[e (U+W )2 ] where U, W U(0, 1) ad IID. I our otatio we the have Y := e (U+W )2. The usual approach is: 1. Geerate U 1,..., U ad W 1,..., W, all IID U(0, 1) 2. Compute Y 1 = e (U1+W1)2,..., Y = e (U+W)2 3. Costruct the estimator θ,y = j=1 Y j/ 4. Build cofidece itervals θ,y ± z 1 α/2 σ,y / where σ 2,y is the usual estimate of Var(Y ). Now cosider usig the cotrol variate techique. First we have to choose a appropriate cotrol variate, Z. There are may possibilities icludig Z 1 := U + W Z 2 := (U + W ) 2 Z 3 := e U+W Note that we ca easily compute E[Z i ] for i = 1, 2, 3 ad that it s also clear that Cov(Y, Z i ) 0. I a simple experimet we used Z 3, estimatig ĉ o the basis of a pilot simulatio with 100 samples. We reduced the variace by approximately a factor of 4. I geeral, a good rule of thumb is that we should ot be satisfied uless we have a variace reductio o the order of a factor of 5 to 10, though ofte we will achieve much more. Example 2 (Pricig a Asia Call Optio) Recall that the payoff of a Asia call optio is give by ( m i=1 h(x) := max 0, S it/m m ) K where X := {S it/m : i = 1,..., m}, K is the strike price ad T is the expiratio date. The price of the optio is the give by C a = E Q 0 [e rt h(x)]

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 5 where r is the risk-free iterest rate ad Q is the risk-eutral probability measure. We will assume as usual that S t GBM(r, σ) uder Q. The usual simulatio method for estimatig C a is to geerate idepedet samples of the payoff, Y i := e rt h(x i ), for i = 1,...,, ad to set i=1 Ĉ a = Y i. But we could also estimate C a usig cotrol variates ad there are may possible choices that we could use: 1. Z 1 = S T 2. Z 2 = e rt max(0, S T K) 3. Z 3 = m j=1 S it/m/m I each of the three cases, it is easy to compute E[Z]. Ideed, E[Z 2 ] is the well-studied Black-Scholes optio price. We would also expect Z 1, Z 2 ad Z 3 to have a positive covariace with Y, so that each oe would be a suitable cadidate for use as a cotrol variate. Which oe would lead to the greatest variace reductio? Exercise 1 Referrig to Example 2, explai why you could also use the value of the optio with payoff ( m ) 1/m g(x) := max 0, S it/m K as a cotrol variate. Do you thik it would result i a substatial variace reductio? i=1 Example 3 (The Barbershop) May applicatio of variace reductio techiques ca be foud i the study of queuig, commuicatios or ivetory systems. As a simple example of a queuig system, cosider the case of a barbershop where the barber opes for busiess every day at 9am ad closes at 6pm. He is the oly barber i the shop ad he s cosiderig hirig aother barber to share the workload. First, however, he would like to estimate the mea total time that customers sped waitig each day. Assume customers arrive at the barbershop accordig to a o-homogeeous Poisso process, N(t), with itesity λ(t), ad let W i deote the waitig time of the i th customer. The, otig that the barber closes the shop after T = 9 hours (but still serves ay customers who have arrived before the) the quatity that he wats to estimate is θ := E[Y ] where Y := N(T ) j=1 Assume also that the service times of customers are IID with CDF, F (.), ad that they are also idepedet of the arrival process, N(t). The usual simulatio method for estimatig θ would be to simulate days of operatio i the barbershop, thereby obtaiig samples, Y 1,..., Y, ad the settig j=1 θ = Y j. However, a better estimate could be obtaied by usig a cotrol variate. I particular, let Z deote the total time customers o a give day sped i service so that Z := where S j is the service time of the j th customer. The, sice services times are IID ad idepedet of the arrival process, it is easy to see that E[Z] = E[S]E[N(T )] which should be easily computable. Ituitio suggests that Z should be positively correlated with Y ad therefore it would also be a good cadidate to use as a cotrol variate. N(T ) j=1 W j. S j

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 6 2.2 Multiple Cotrol Variates Util ow we have oly cosidered the possibility of usig oe cotrol variate but there is o reaso why we should ot use more tha oe. Towards this ed, suppose agai that we wish to estimate θ := E[Y ] where Y is the output of a simulatio experimet. We also suppose that for i = 1,..., m, Z i is a output or that we ca easily output it if we wish, ad that E[Z i ] is kow for each i. We ca the costruct ubiased estimators of θ by defiig where c i R. The variace of θ c satisfies θ c := Y + c 1 (Z 1 E[Z 1 ]) +... + c m (Z m E[Z m ]) m m m Var( θ c ) = Var(Y ) + 2 c i Cov(Y, Z i ) + c i c j Cov(Z i, Z j ) (3) i=1 i=1 i=1 ad we could easily miimize this quatity w.r.t the c i s. As before, however, the optimal solutios c i will ivolve ukow covariaces (ad possibly variaces of the Z i s) that will eed to be estimated usig a pilot simulatio. A coveiet way of doig this is to observe that ĉ i = b i where the b i s are the (least squares) solutio to the followig liear regressio: Y = a + b 1 Z 1 +... + b m Z m + ɛ (4) where ɛ is a error term. Note that you must iclude the itercept, a, i (4). The simulatio algorithm with multiple cotrol variates is exactly aalogous to the simulatio algorithm with just a sigle cotrol variate. Multiple Cotrol Variate Simulatio Algorithm for Estimatig E[Y ] / Do pilot simulatio first / for i = 1 to p geerate (Y i, Z 1,i,..., Z m,i ) compute ĉ j, j = 1,..., m / Now do mai simulatio / for i = 1 to geerate (Y i, Z 1,i,..., Z m,i ) set V i = Y i + m j=1 ĉ j (Z j,i E[Z j ]) set θ c = V = i=1 V i/ set σ,v 2 = (V i θ c ) 2 /( 1) σ set 100(1 α) % CI = [ θc z,v 1 α/2, θ ] σ c + z,v 1 α/2

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 7 3 Atithetic Variates As usual we would like to estimate θ = E[h(X)] = E[Y ], ad suppose we have geerated two samples, Y 1 ad Y 2. The a ubiased estimate of θ is give by θ = (Y 1 + Y 2 )/2 with Var( θ) = Var(Y 1) + Var(Y 2 ) + 2Cov(Y 1, Y 2 ). 4 If Y 1 ad Y 2 are IID, the Var( θ) = Var(Y )/2. However, we could reduce Var( θ) if we could arrage it so that Cov(Y 1, Y 2 ) < 0. We ow describe the method of atithetic variates for doig this. We will begi with the case where Y is a fuctio of IID U(0, 1) radom variables so that θ = E[h(U)] where U = (U 1,..., U m ) ad the U i s are IID U(0, 1). The usual Mote Carlo algorithm, assumig we use 2 samples, is show below. Usual Simulatio Algorithm for Estimatig θ for i = 1 to 2 geerate U i set Y i = h(u i ) set θ 2 = Y 2 = 2 i=1 Y i/2 set σ 2 2 = 2 i=1 (Y i Y 2 ) 2 /(2 1) set approx. 100(1 α) % CI = θ 2 ± z 1 α/2 σ 2 I the above algorithm, however, we could also have used the 1 U i s to geerate sample Y values, sice if U i U(0, 1), the so too is 1 U i. We ca use this fact to costruct aother estimator of θ as follows. As before, we set Y i = h(u i ), where U i = (U (i) 1,..., U m (i) ). We ow also set Ỹi = h(1 U i ), where we use 1 U i to deote (1 U (i) 1,..., 1 U m (i) ). Note that E[Y i ] = E[Ỹi] = θ so that i particular, if Z i := Y i + Ỹi, 2 the E[Z i ] = θ so that Z i is a also ubiased estimator of θ. If the U i s are IID, the so too are the Z i s ad we ca use them as usual to compute approximate cofidece itervals for θ. We say that U i ad 1 U i are atithetic variates ad we the have the followig atithetic variate simulatio algorithm. Atithetic Variate Simulatio Algorithm for Estimatig θ for i = 1 to geerate U i set Y i = h(u i ) ad Ỹi = h(1 U i ) set Z i = (Y i + Ỹi)/2 set θ,a = Z = i=1 Z i/ set σ 2,a = i=1 (Z i Z ) 2 /( 1) set approx. 100(1 α) % CI = θ σ a, ± z,a 1 α/2

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 8 As usual, θ a, is a ubiased estimator of θ ad the Strog Law of Large Numbers implies θ,a θ almost surely as. Each of the two algorithms we have described above uses 2 samples so the questio aturally arises as to which algorithm is better. Note that both algorithms require approximately the same amout of effort so that comparig the two algorithms amouts to computig which estimator has a smaller variace. 3.1 Comparig Estimator Variaces It is easy to see that Var( θ 2 ) = Var ( 2 ) i=1 Y i = Var(Y ) 2 2 ad ( i=1 Var( θ,a ) = Var Z ) i = Var(Z) = Var(Y + Ỹ ) 4 = Var(Y ) 2 = Var( θ 2 ) + Cov(Y, Ỹ ). 2 + Cov(Y, Ỹ ) 2 Therefore Var( θ,a ) < Var( θ 2 ) if ad oly Cov(Y, Ỹ ) < 0. Recallig that Y = h(u) ad Ỹ = h(1 U), this meas that Var( θ,a ) < Var( θ 2 ) Cov (h(u), h(1 U)) < 0. We will soo discuss coditios that are sufficiet to guaratee that Cov(h(U), h(1 U)) < 0, but first let s cosider a example. Example 4 (Mote Carlo Itegratio) Cosider the problem of estimatig θ = 1 e x2 0 As usual, we may the write θ = E[e U 2 ] where U U(0, 1). We ca compare the usual raw simulatio algorithm with the simulatio algorithm that uses atithetic variates. Usig atithetic variates i this case results i a variace reductio of approximately 75%. We ow discuss the circumstaces uder which a variace reductio ca be guarateed. Cosider first the case where U is a uiform radom variable so that m = 1, U = U ad θ = E[h(U)]. Suppose ow that h(.) is a o-decreasig fuctio of u over [0, 1]. The if U is large, h(u) will also ted to be large while 1 U ad h(1 U) will ted to be small. That is, Cov(h(U), h(1 U)) < 0. We ca similarly coclude that if h(.) is a o-icreasig fuctio of u the oce agai, Cov(h(U), h(1 U)) < 0. So for the case where m = 1, a sufficiet coditio to guaratee a variace reductio is for h(.) to be a mootoic fuctio of u o [0, 1]. Let us ow cosider the more geeral case where m > 1, U = (U 1,..., U m ) ad θ = E[h(U)]. We say h(u 1,..., u m ) is a mootoic fuctio of each of its m argumets if, i each of its argumets, it is o-icreasig or o-decreasig. We have the followig theorem which geeralizes the m = 1 case above. Theorem 1 If h(u 1,..., u m ) is a mootoic fuctio of each of its argumets o [0, 1] m, the for a set U := (U 1,..., U m ) of IID U(0, 1) radom variables dx. Cov(h(U), h(1 U)) < 0 where Cov(h(U), h(1 U)) := Cov(h(U 1,..., U m ), h(1 U 1,..., 1 U m )).

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 9 Proof See Sheldo M. Ross s Simulatio. Note that the theorem specifies sufficiet coditios for a variace reductio, but ot ecessary coditios. This meas that it is still possible to obtai a variace reductio eve if the coditios of the theorem are ot satisfied. For example, if h(.) is mostly mootoic, the a variace reductio might be still be obtaied. 3.2 No-Uiform Atithetic Variates So far we have oly cosidered problems where θ = E[h(U)], for U a vector of IID U(0, 1) radom variables. Of course i practice, it is ofte the case that θ = E[Y ] where Y = h(x 1,..., X m ), ad where (X 1,..., X m ) is a vector of idepedet radom variables. We ca still use the atithetic variable method for such problems if we ca use the iverse trasform method to geerate the X i s. To see this, suppose F i (.) is the CDF of X i. If U i U(0, 1) the F 1 i (U i ) has the same distributio as X i. This implies that we ca geerate a sample of Y by geeratig U 1,..., U m IID U(0, 1) ad settig Z = h ( F 1 1 (U 1 ),..., F 1 m (U m ) ). Sice the CDF of ay radom variable is o-decreasig, it follows that the iverse CDFs, F 1 i (.), are also o-decreasig. This meas that if h(x 1,..., x m ) is a mootoic fuctio of each of its argumets, the h(f1 1 (U 1 ),..., Fm 1 (U m )) is also a mootoic fuctio of the U i s. Theorem 1 therefore applies. Atithetic variables are ofte very useful whe studyig queueig systems ad we briefly describe why by revisitig Example 3. Example 5 (The Barbershop Revisited) Cosider agai our barbershop example ad suppose that the barber ow wats to estimate the average total waitig time, θ, of the first 100 customers. The θ = E[Y ] where 100 Y = j=1 ad where W j is the waitig time of the j th customer. Now for each customer, j, there is a iter-arrival time, I j, which is the time betwee the (j 1) th ad j th arrivals. There is also a service time, S j, which is the amout of time the barber speds cuttig the j th customer s hair. It is therefore the case that Y may be writte as W j Y = h(i 1,..., I 100, S 1,..., S 100 ) for some fuctio, h(.). Now for may queueig systems, h(.) will be a mootoic fuctio of its argumets sice we would typically expect Y to icrease as service times icrease, ad decrease as iter-arrival times icrease. As a result, it might be advatageous to use atithetic variates to estimate θ. (We are implicitly assumig here that the I j s ad S j s ca be geerated usig the iverse trasform method.) 3.3 Normal Atithetic Variates We ca also geerate atithetic ormal radom variates without usig the iverse trasform techique. For if X N(µ, σ 2 ) the X N(µ, σ 2 ) also, where X := 2µ X. Clearly X ad X are egatively correlated. So if θ = E[h(X 1,..., X m )] where the X i s are IID N(µ, σ 2 ) ad h(.) is mootoic i its argumets, the we ca agai achieve a variace reductio by usig atithetic variates. Example 6 (Normal Atithetic Variates) Suppose we wat to estimate θ = E[X 2 ] where X N(2, 1). The it is easy to see that θ = 5, but we ca also estimate it usig atithetic variates. We have the followig questios: 1. Is a variace reductio guarateed? Why or why ot? 2. What would you expect if Z N(10, 1)?

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 10 3. What would you expect if Z N(0.5, 1)? Example 7 (Estimatig the Price of a Kock-I Optio) Suppose we wish to price a kock-i optio where the payoff is give by h(s T ) = max(0, S T K)I {ST >B} where B is some fixed costat. We assume that r is the risk-free iterest rate, S t GBM(r, σ 2 ) uder the risk-eutral measure, Q, ad that S 0 is the iitial stock price. The the optio price may be writte as C 0 = E Q 0 [e rt max(0, S T K)I {ST >B}] so we ca estimate it usig simulatio. Sice we ca write S T = S 0 e (r σ2 /2)T +σ T X where X N(0, 1) we ca use atithetic variates to estimate C 0. Are we sure to get a variace reductio? Example 8 We ca also use atithetic variates to price Asia optios. I this case, however, we eed to be a little careful geeratig the stock prices if we are to achieve a variace reductio. You might wat to thik about this yourself. It s worth emphasizig at this poit that i geeral, the variace reductio that ca be achieved through the use of atithetic variates is rarely (if ever!) dramatic. Other methods are capable of much greater variace reductio i practice. 4 Coditioal Mote Carlo We ow cosider the coditioal Mote Carlo variace reductio techique. The idea here is very simple. As was the case with cotrol variates, we use our kowledge about the system beig studied to reduce the variace of our estimator. As usual, we wish to estimate θ = E[h(X)] where X = (X 1,..., X m ). If we could compute θ aalytically, the this would be equivalet to solvig a m-dimesioal itegral. However, maybe it is possible to evaluate part of the itegral aalytically. If so, the we might be able to use simulatio to estimate the other part ad thereby obtai a variace reductio. I order to explore these ideas we must first review coditioal expectatios ad variaces. Coditioal Expectatios ad Variaces Let X ad Z be radom vectors, ad let Y = h(x) be a radom variable. Suppose we set V = E[Y Z]. The V is itself a radom variable that depeds o Z, so we may write V = g(z) for some fuctio, g( ). We also kow that E[V ] = E[E[Y Z]] = E[Y ] so if we are tryig to estimate θ = E[Y ], oe possibility would be to simulate V istead of simulatig Y. I order to decide which would be a better estimator of θ, it is ecessary to compare the variaces of Y ad V = E[Y Z]. To do this, recall the coditioal variace formula: Var(Y ) = E[Var(Y Z)] + Var(E[Y Z]). (5) Now Var(Y Z) is also a radom variable that depeds o Z, ad sice a variace is always o-egative, it must follow that E[Var(Y Z)] 0. But the (5) implies Var(Y ) Var(E[Y Z]) = Var(V )

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 11 so we ca coclude that V is a better 1 estimator of θ tha Y. To see this from aother perspective, suppose that to estimate θ we first have to simulate Z ad the simulate Y give Z. If we ca compute E[Y Z] exactly, the we ca elimiate the additioal oise that comes from simulatig Y give Z, thereby obtaiig a variace reductio. Fially, we poit out that i order for the coditioal expectatio method to be worthwhile, it must be the case that Y ad Z are depedet. Exercise 2 Why must Y ad Z be depedet for the coditioal Mote Carlo method to be worthwhile? 4.1 The Coditioal Mote Carlo Simulatio Algorithm Summarizig the previous discussio, we wat to estimate θ := E[h(X)] = E[Y ] usig coditioal Mote Carlo. To do so, we must have aother variable or vector, Z, that satisfies the followig requiremets: 1. Z ca be easily simulated 2. V := g(z) := E[Y Z] ca be computed exactly. This meas that we ca simulate a value of V by first simulatig a value of Z ad the settig 2 V = g(z) = E[Y Z]. We therefore have the followig algorithm for estimatig θ. Coditioal Mote Carlo Algorithm for Estimatig θ for i = 1 to geerate Z i compute g(z i ) = E[Y Z i ] set V i = g(z i ) set θ,cm = V = i=1 V i/ set σ 2,cm = i=1 (V i V ) 2 /( 1) set approx. 100(1 α) % CI = θ σ,cm ± z,cm 1 α/2 It is also possible that other variace reductio methods could be used i cojuctio with coditioig. For example, it might be possible to use cotrol variates, or if g(.) is a mootoic fuctio of its argumets, the atithetic variates might be useful. Example 9 Suppose we wish to estimate θ := P(U + Z > 4) where U Exp(1) ad Z Exp(1/2). If we set Y := I {U+Z>4} the we see that θ = E[Y ]. The the usual simulatio method is: 1. Geerate U 1,..., U, Z 1,..., Z all idepedet 2. Set Y i = I {Ui+Z i>4} for i = 1,..., 3. Set θ = i=1 Y i/ 4. Compute approximate CI s as usual. 1 This assumes that the work required to geerate V is ot too much greater tha the work required to geerate Y. See the discussio i Sectio 1. 2 It may also be possible to idetify the distributio of V = g(z), so that we could the simulate V directly.

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 12 However, we ca also use the coditioig method, which works as follows. Set V = E[Y Z]. The E[Y Z = z] = P(U + Z > 4 Z = z) = P(U > 4 z) = 1 F u (4 z) where F u (.) is the CDF of U which we kow is Exp(1). Therefore { e (4 z) if 0 z 4, 1 F u (4 z) = 1 if z > 4. which implies V = E[Y Z] = { e (4 Z) if 0 Z 4, 1 if Z > 4. Now the coditioal Mote Carlo algorithm for estimatig θ = E[V ] is: 1. Geerate Z 1,..., Z all idepedet 2. Set V i = E[Y Z i ] for i = 1,..., 3. Set θ,cm = i=1 V i/ 4. Compute approximate CI s as usual usig the V i s. Note that we might also wat to use other variace reductio methods i cojuctio with coditioig whe we are fidig θ,cm. Before proceed with aother example, we first recall the Black-Scholes formula for the price of a Europea call optio o a o-divided payig stock with time t price, S t. Let r be the risk-free iterest rate ad suppose S t GBM(r, σ 2 ) uder the risk-eutral measure, Q. The the price, C 0, of a call optio with strike K ad expiratio T is give by C 0 = E Q 0 [e rt max(0, S T K)] = S 0 Φ(d 1 ) Ke rt Φ(d 2 ) where Φ(.) is the CDF of a stadard ormal radom variable ad d 1 = log(s 0/K) + (r + σ 2 /2)T σ T d 2 = log(s 0/K) + (r σ 2 /2)T σ T = d 1 σ T. We will also eed the followig defiitio for Example 10 below. Defiitio 1 Let c(x, t, K, r, σ) be the Black-Scholes price of a Europea call optio whe the curret stock price is x, the time to maturity is t, the strike is K, the risk-free iterest rate is r ad the volatility is σ. Example 10 (Pricig a Barrier Optio) Suppose we wat to fid the price of a Europea optio that has payoff at expiratio give by { max(0, ST K h(x) = 1 ) if S T/2 L, max(0, S T K 2 ) otherwise. where X = (S T/2, S T ). We ca write the price of the optio as C 0 = E Q 0 [ ( )] e rt max(0, S T K 1 )I {ST /2 L} + max(0, S T K 2 )I {ST /2 >L}

Simulatio Efficiecy ad a Itroductio to Variace Reductio Methods 13 where as usual, we assume that S t GBM(r, σ 2 ). Questio 1: How would you estimate the price of this optio usig simulatio ad oly oe ormal radom variable per sample payoff? Questio 2: reductio? Could you use atithetic variates as well? Would they be guarateed to produce a variace Exercise 3 (Estimatig Credit Risk; from Asmusse ad Gly s Stochastic Simulatio) A bak has a portfolio of N = 100 loas to N compaies ad wats to evaluate its credit risk. Give that compay defaults, the loss for the bak is a N(µ, σ 2 ) radom variable X where µ = 3, σ 2 = 1. Defaults are depedet ad described by idicators D 1,..., D N ad a backgroud radom variable P (measurig, say, geeral ecoomic coditios), such that D 1,..., D N are IID Berouilli(p) give P = p, ad P has a Beta(1, 19) distributio, that is, desity (1 p) 18 /19, 0 < p < 1. Estimate P (L > x), where L = N =1 D X is the loss, usig both crude Mote Carlo ad coditioal Mote Carlo, where the coditioig is o N =1 D. For x, take x = 3 E[L] = 3N E[P ] E[X] = 3 100 0.05 3 = 45.