Computer Exercise 2 Simulation

Similar documents
Computer Exercise 2 Simulation

Numerical schemes for SDEs

Parameter estimation in SDE:s

MASM006 UNIVERSITY OF EXETER SCHOOL OF ENGINEERING, COMPUTER SCIENCE AND MATHEMATICS MATHEMATICAL SCIENCES FINANCIAL MATHEMATICS.

2.1 Mathematical Basis: Risk-Neutral Pricing

Monte Carlo Simulations

Monte Carlo Methods for Uncertainty Quantification

Valuation of performance-dependent options in a Black- Scholes framework

Asian Option Pricing: Monte Carlo Control Variate. A discrete arithmetic Asian call option has the payoff. S T i N N + 1

King s College London

Optimal Search for Parameters in Monte Carlo Simulation for Derivative Pricing

IEOR E4703: Monte-Carlo Simulation

"Vibrato" Monte Carlo evaluation of Greeks

The Use of Importance Sampling to Speed Up Stochastic Volatility Simulations

2 f. f t S 2. Delta measures the sensitivityof the portfolio value to changes in the price of the underlying

AMH4 - ADVANCED OPTION PRICING. Contents

MSc in Financial Engineering

STOCHASTIC VOLATILITY AND OPTION PRICING

The stochastic calculus

Advanced Topics in Derivative Pricing Models. Topic 4 - Variance products and volatility derivatives

Computational Finance. Computational Finance p. 1

The Heston Model. B.Sc. Thesis. - Stochastic Volatility and Approximation - Author Patrik Karlsson,

Monte Carlo Methods in Option Pricing. UiO-STK4510 Autumn 2015

EFFICIENT MONTE CARLO ALGORITHM FOR PRICING BARRIER OPTIONS

Pricing Variance Swaps under Stochastic Volatility Model with Regime Switching - Discrete Observations Case

Lecture 8: The Black-Scholes theory

Application of Moment Expansion Method to Option Square Root Model

King s College London

Simulating Stochastic Differential Equations

Accelerated Option Pricing Multiple Scenarios

Financial Engineering MRM 8610 Spring 2015 (CRN 12477) Instructor Information. Class Information. Catalog Description. Textbooks

TEST OF BOUNDED LOG-NORMAL PROCESS FOR OPTIONS PRICING

Definition Pricing Risk management Second generation barrier options. Barrier Options. Arfima Financial Solutions

Multilevel Monte Carlo for Basket Options

CONTINUOUS TIME PRICING AND TRADING: A REVIEW, WITH SOME EXTRA PIECES

Math Computational Finance Option pricing using Brownian bridge and Stratified samlping

NEWCASTLE UNIVERSITY SCHOOL OF MATHEMATICS, STATISTICS & PHYSICS SEMESTER 1 SPECIMEN 2 MAS3904. Stochastic Financial Modelling. Time allowed: 2 hours

The University of Chicago, Booth School of Business Business 41202, Spring Quarter 2011, Mr. Ruey S. Tsay. Solutions to Final Exam.

Stochastic Processes and Stochastic Calculus - 9 Complete and Incomplete Market Models

3.1 Itô s Lemma for Continuous Stochastic Variables

JDEP 384H: Numerical Methods in Business

Valuation of Asian Option. Qi An Jingjing Guo

MATH4143: Scientific Computations for Finance Applications Final exam Time: 9:00 am - 12:00 noon, April 18, Student Name (print):

Computational Methods for Option Pricing. A Directed Research Project. Submitted to the Faculty of the WORCESTER POLYTECHNIC INSTITUTE

Computational Finance

Option Pricing for Discrete Hedging and Non-Gaussian Processes

Cash Accumulation Strategy based on Optimal Replication of Random Claims with Ordinary Integrals

Multi-Asset Options. A Numerical Study VILHELM NIKLASSON FRIDA TIVEDAL. Master s thesis in Engineering Mathematics and Computational Science

Pricing theory of financial derivatives

STOCHASTIC VOLATILITY MODELS: CALIBRATION, PRICING AND HEDGING. Warrick Poklewski-Koziell

Write legibly. Unreadable answers are worthless.

HEDGING RAINBOW OPTIONS IN DISCRETE TIME

1 Introduction. 2 Old Methodology BOARD OF GOVERNORS OF THE FEDERAL RESERVE SYSTEM DIVISION OF RESEARCH AND STATISTICS

Math 416/516: Stochastic Simulation

Basic Concepts in Mathematical Finance

Barrier Option. 2 of 33 3/13/2014

MATH3075/3975 FINANCIAL MATHEMATICS TUTORIAL PROBLEMS

Time-changed Brownian motion and option pricing

Monte Carlo Methods for Uncertainty Quantification

Market interest-rate models

Monte Carlo Methods for Uncertainty Quantification

Lecture 17. The model is parametrized by the time period, δt, and three fixed constant parameters, v, σ and the riskless rate r.

AMSTERDAM BOSTON HEIDELBERG LONDON NEW YORK OXFORD PARIS SAN DIEGO SAN FRANCISCO SINGAPORE SYDNEY TOKYO Academic Press is an Imprint of Elsevier

"Pricing Exotic Options using Strong Convergence Properties

Risk Neutral Valuation, the Black-

Queens College, CUNY, Department of Computer Science Computational Finance CSCI 365 / 765 Fall 2017 Instructor: Dr. Sateesh Mane.

Handbook of Financial Risk Management

MATH6911: Numerical Methods in Finance. Final exam Time: 2:00pm - 5:00pm, April 11, Student Name (print): Student Signature: Student ID:

Economic Scenario Generator: Applications in Enterprise Risk Management. Ping Sun Executive Director, Financial Engineering Numerix LLC

Gamma. The finite-difference formula for gamma is

FINANCIAL OPTION ANALYSIS HANDOUTS

Multilevel Monte Carlo Simulation

Machine Learning for Quantitative Finance

Computational Finance Improving Monte Carlo

Calibration Lecture 4: LSV and Model Uncertainty

Value at Risk Ch.12. PAK Study Manual

Optimized Least-squares Monte Carlo (OLSM) for Measuring Counterparty Credit Exposure of American-style Options

The Black-Scholes Model

A Moment Matching Approach To The Valuation Of A Volume Weighted Average Price Option

Monte Carlo Methods in Financial Engineering

European option pricing under parameter uncertainty

Slides for DN2281, KTH 1

2 Control variates. λe λti λe e λt i where R(t) = t Y 1 Y N(t) is the time from the last event to t. L t = e λr(t) e e λt(t) Exercises

Lecture IV Portfolio management: Efficient portfolios. Introduction to Finance Mathematics Fall Financial mathematics

Valuation of derivative assets Lecture 8

SADDLEPOINT APPROXIMATIONS TO OPTION PRICES 1. By L. C. G. Rogers and O. Zane University of Bath and First Chicago NBD

Calibrating to Market Data Getting the Model into Shape

Financial Models with Levy Processes and Volatility Clustering

AD in Monte Carlo for finance

The Black-Scholes Model

MÄLARDALENS HÖGSKOLA

Module 2: Monte Carlo Methods

Math Computational Finance Double barrier option pricing using Quasi Monte Carlo and Brownian Bridge methods

Pricing of European and Asian options with Monte Carlo simulations

Binomial model: numerical algorithm

Hedging with Life and General Insurance Products

Math Option pricing using Quasi Monte Carlo simulation

Strategies for Improving the Efficiency of Monte-Carlo Methods

Counterparty Credit Risk Simulation

Monte Carlo Methods in Structuring and Derivatives Pricing

Transcription:

Lund University with Lund Institute of Technology Valuation of Derivative Assets Centre for Mathematical Sciences, Mathematical Statistics Fall 2017 Computer Exercise 2 Simulation This lab deals with pricing derivatives using simulation of continuous time models. Continuous time models are flexible and powerful but our analytical tools are sometimes too limited for all kind of different processes and contracts. In this computer exercise, we use Monte Carlo simulation to calculate prices. Furthermore, errors and convergence is studied. It is preferred if you use Matlab but other languages or program packages are also permitted (and even encouraged). However, if some other program or language is used, careful documentation of the code is essential. Assignments labeled Extra are voluntary but is highly recommended. 1 Preparations before the lab Read chapter 7 in Björk (2009), section 7.6.10, 7.6.12 and chapter 11 in Åberg (2017), chapter 11 in Madsen et al (2004) and this guide for the lab. You should also solve the exercise B 7.3. Before the lab starts, the questions below (or a subset of them) will be posed. All of the posed questions must be answered correctly in order for the lab to be approved. Note: that there will be a lecture on simulation L11, on Thursday the fifth reading week. 2 Catalogue of Questions You should be able to answer these questions before the computer exercise. 1. Describe the main ideas of how the Black & Scholes formula is obtained. σ2 (r 2. We know the the value of a stock following a GBM at time T is S(T ) = S(0)e 2 )T +σw (T ). Calculate explicitely the variance reduction for estimating the mean of S t using antithetic variables (hint use the results from Exercises Å 12.8 and Å 5.7(3.)). 3. How do you simulate a multivariate Gaussian distribution for a given expectation vector and covariance matrix? 4. Explain the Milstein approximation and how you would use it when discretizing the stochastic volatility process in section 4.3. Also review the alternative simulation algorithm presented in lecture 11. 5. Write down the expression for calculating the standard deviation of an estimated price using the crude Monte Carlo method, antithetic variables and control variables. 1

3 Basic simulation theory We know from economic theory that the price of an option is given by Π(t) = e r(t t) E Q [Φ(S(T )) F t ]. The focus in this lab is therefore the calculation of expected values given some martingale measure, Q. By using the law of large numbers, we know that 1 N N f(x i ) E[f(X)] i=1 in probability as N. Thus, prices can be approximated by simulating many random variables with the correct distribution and calculating the mean of these. The variance of the estimate of E Q [f(x)] can often be reduced considerably by applying a variance reduction technique, see e.g. Åberg (2017); Fishman (1996); Glasserman (2004). 4 Lab tasks The lab consists of two assignments. The first assignment is pricing of an European call option, followed by pricing an European call option and a Barrier option where the volatility of the stock is modelled as a stochastic process (i.e. a stochastic volatility model). The lab is also an introduction to variance reduction techniques. 4.1 European call option Consider a European call option, written on a stock, with a strike price 80. The option matures in one year. Assume that the continuously compounded risk free interest rate is 1%, the current price of the stock is 90 and it s volatility σ = 0.6. Assignment: Calculate the price of the option using simulation. Solve the problem using: Crude Monte Carlo. Antithetic variables. Control variables (Use e.g. S T ). Compare your result to the price given by the Black & Scholes formula. Calculate the price and the standard deviation of the estimated price. Extra (not mandatory): Options Out-of-the-Money is more difficult to price than option inthe-money. Try using importance sampling and compare your results to applying the crude method (or any other method). Assume the continuously compounded risk free interest rate is 5%, the current price of the stock is 50, the strike prize is 150 and it s volatility σ = 0.4. Use the results in the slides from lecture 11. 2

4.2 Basket call option Assignment: Compute with Monte Carlo methods the arbitrage free price at t = 0 of the Arithmetic Basket call option arithmetic Basket call has a pay-off defined as: (( ) + 1 n S i (T ) K), n i=1 on the stock S 1,, S n with strike price K = 80, 100, 120, time to maturity is four years. Assume that that n = 12, the continuously compounded risk free interest rate is 0.25%, the current prices of the stocks are all assumed to 90 and their volatilities all (σ 1, σ n ) all are 0.2 and the pair wise correlations ρ ij, i j are all 0.3. This gives that the log stock prices at time t are Gaussian with expectation µ = (ln(s 1 (0)) + (r σ 2 i /2)t,, ln(s n (0)) + (r σ 2 n/2)t) and covariance matrix Σ = diag(σ 1,, σ n ) [ {ρ ij } n,n i=1, j=1] diag(σ1,, σ n )t. As example for n = 2 we get [ σ1 0 Σ = 0 σ 2 ] [ 1 ρ12 ρ 12 1 ] [ σ1 0 0 σ 2 ] t. Use N = 1000, 10000, 100000 where N is the number of replications used in the Monte Carlo calculation. 4.3 Stochastic volatility One of the drawbacks of the Black & Scholes formula is that the variance is assumed to be constant. By using simulation, we can remove this requirement in the pricing. One alternative model of the stock price (under the risk-neutral measure) is ds t = rs t dt + V t S t ( 1 ρ 2 dw (1) t + ρdw (2) t ) dv t = κ(θ V t )dt + σ V t dw (2) t, where W (1) t and W (2) t are two independent standard Brownian motions. This model is a stochastic volatility model, more precisely it is the Heston model. The solution to these equations is not available in closed form, so we have to discretize this model, see chapter 11 in Madsen et al (2004). We need to use the Milstein-Scheme for the second equation to keep the numerical solution positive, we moreover need to take quite small time steps. 3

Even though there is no closed form solution of the price of an European call option in the Heston model, there are still fast and accurate pricing techniques that can be used. The Matlab function opt_price calculates the price of an European call option using a Fourier inversion technique. The matlab routine opt_price can be downloaded from the course homepage: http://www.maths.lth.se/matstat/kurser/fmsn25masm24/ Assignment: Use the crude Monte Carlo method to calculate the price of an European call option when κ = 10, θ = 0.16, σ = 0.1, ρ = 0.8 and V 0 = 0.16. Use the same values for the initial stock price, strike level, interest rate and time to maturity as in 4.1. Compare your result from the Monte Carlo simulation with the price generated by opt_price. Assignment: Calculate the price of an up-out contract Z UO defined by: { max (S(T ) K, 0), if S(t) < B for all t [0, T ], Z UO = 0, if S(t) B for some t [0, T ]. with K = 40, B = 100 and S 0 = 50, using the crude Monte Carlo method. Extra: Calculate the price of the up-out contract using antithetic variables and control variables. 5 Feedback Comments on the lab (from all kinds of point of view) are welcome. Please send them to Magnus Wiktorsson, magnusw@maths.lth.se or phone 046 222 86 25. 4

6 MATLAB routines The function opt_price calculates the price of an European put or call option using a Fourier inversion technique. Syntax P=opt_price(model,par,call,power,K,S,r,Tau) calculates the optionprice using inverse fouriertransform by the Gauss-Laguerre quadrature method, using the optimal straight integration path going through the saddlepoint of the integrand. ------------------------- input--------------------------------- model : Modelname for the model used to price options use the syntax: [P]=opt_price( Heston,par,C,p,K,S,r,Tau) to use the Heston model and so on Available models are: BS,Heston,Merton,Bates,NIG,NIGCIR,VG,CGMY NOTE TO GET INFO on a model and its parameters just use opt_price( modelname ) e.g. opt_price( Heston ) for info about the Heston model par : model parameters corresponding to the chosen model see the help text for the corresponding model with e.g. opt_price( Heston ) for Heston call : row vector containing 1 if call 0 if put option power : vector containing the p for power options payoff=max(s_tau-k,0)^p for call i.e. p=1 for an ordinary call option, p=0 for a binary option K : row vector containg strike prices S : row vector containg intial/current stock price r : row vector of interest rate yields Tau : row vector containing time to maturity Note that C,p,K,S,Tau and r should be vectors with matching dimensions ------------------------output---------------------------- P : calculated price (C) 2006,2010 Magnus Wiktorsson 5

Other useful commands: help Display help for MATLAB functions in Command Window mean Mean value of arrays std Standard deviation of arrays var Variance of arrays max Maximum elements of array normcdf Normal cumulative distribution function References Björk, T. (2009), Arbitrage Theory in Continuous Time, Oxford University Press, New York. Fishman, George S. (1996) Monte Carlo Concepts Algorithms, and Applications, Springer- Verlag, New York Glasserman, Paul (2003) Monte Carlo Methods in Financial Engineering, Springer-Verlag, New York Åberg, Sebastian (2017) Derivative pricing, KF Sigma. H. Madsen, J.N. Nielsen, Erik Lindström, M. Baadsgaard & Jan Holst (2004) Statistics in Finance Lund University, Lund Institute of Technology - Centre for Mathematical Sciences. Centrum Scientiarum Mathematicarum 6