Monte Carlo Simulation

Similar documents
Barrier Option Valuation with Binomial Model

MÄLARDALENS HÖGSKOLA

Bose Vandermark (Lehman) Method

Pricing Barrier Options Using Monte Carlo Simulation Pricing Options with Python

Asset-or-nothing digitals

Computer Exercise 2 Simulation

Computer Exercise 2 Simulation

Computational Finance Improving Monte Carlo

23 Stochastic Ordinary Differential Equations with Examples from Finance

Analytical Finance 1 Seminar Monte-Carlo application for Value-at-Risk on a portfolio of Options, Futures and Equities

Computational Finance Least Squares Monte Carlo

Equity Basket Option Pricing Guide

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

Approximation of functions and American options

Financial Engineering with FRONT ARENA

Curran model for pricing Asian options

An Analysis of a Dynamic Application of Black-Scholes in Option Trading

STRATEGIES WITH OPTIONS

MFIN 7003 Module 2. Mathematical Techniques in Finance. Sessions B&C: Oct 12, 2015 Nov 28, 2015

Key Features Asset allocation, cash flow analysis, object-oriented portfolio optimization, and risk analysis

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

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

FINITE DIFFERENCE METHODS

ActuarialBrew.com. Exam MFE / 3F. Actuarial Models Financial Economics Segment. Solutions 2014, 2nd edition

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

About Black-Sholes formula, volatility, implied volatility and math. statistics.

An Analysis of a Dynamic Application of Black-Scholes in Option Trading

MONTE CARLO EXTENSIONS

Computational Finance. Computational Finance p. 1

1. In this exercise, we can easily employ the equations (13.66) (13.70), (13.79) (13.80) and

source experience distilled PUBLISHING BIRMINGHAM - MUMBAI

Assignment - Exotic options

Svensson (1994) model and the Nelson & Siegel (1987) model

Optimizing Modular Expansions in an Industrial Setting Using Real Options

Black-Scholes-Merton Model

UNIVERSITY OF AGDER EXAM. Faculty of Economicsand Social Sciences. Exam code: Exam name: Date: Time: Number of pages: Number of problems: Enclosure:

1.1 Interest rates Time value of money

Monte Carlo Simulation (General Simulation Models)

ActuarialBrew.com. Exam MFE / 3F. Actuarial Models Financial Economics Segment. Solutions 2014, 1 st edition

MSc Financial Mathematics

Computational Finance Finite Difference Methods

Corporate Finance Theory FRL CRN: P. Sarmas Summer Quarter 2012 Building 24B Room 1417 Tuesday & Thursday: 4:00 5:50 p.m.

A Study on Numerical Solution of Black-Scholes Model

The following content is provided under a Creative Commons license. Your support

Master s in Financial Engineering Foundations of Buy-Side Finance: Quantitative Risk and Portfolio Management. > Teaching > Courses

Modelling the Sharpe ratio for investment strategies

Financial Times Series. Lecture 6

Numerical schemes for SDEs

Hedging with Options

EFFICIENT MONTE CARLO ALGORITHM FOR PRICING BARRIER OPTIONS

BIRLA INSTITUTE OF TECHNOLOGY AND SCIENCE, Pilani Pilani Campus Instruction Division

Market Volatility and Risk Proxies

As we saw in Chapter 12, one of the many uses of Monte Carlo simulation by

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

ANALYTICAL FINANCE II Floating Rate Notes, fixed coupon bonds and swaps

Web Appendix. Are the effects of monetary policy shocks big or small? Olivier Coibion

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

The Black-Scholes Model

Option Pricing Using Bayesian Neural Networks

Volatility Surface. Course Name: Analytical Finance I. Report date: Oct.18,2012. Supervisor:Jan R.M Röman. Authors: Wenqing Huang.

Options Pricing Using Combinatoric Methods Postnikov Final Paper

Final Projects Introduction to Numerical Analysis atzberg/fall2006/index.html Professor: Paul J.

CHAPTER 8 Estimating with Confidence

Monte Carlo Simulation in Financial Valuation

BOOTSTRAPPING A ZERO-SWAP CURVE FOR TENOR 3M USING PYTHON

The Black-Scholes Model

Adjusting the Black-Scholes Framework in the Presence of a Volatility Skew

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

arxiv: v1 [q-fin.rm] 1 Jan 2017

NATIONAL UNIVERSITY OF SINGAPORE Department of Finance

Chapter -7 CONCLUSION

Derivative Securities Section 9 Fall 2004 Notes by Robert V. Kohn, Courant Institute of Mathematical Sciences.

Using R for teaching financial mathematics and statistics

Monte Carlo and Empirical Methods for Stochastic Inference (MASM11/FMS091)

Lecture on Interest Rates

Pricing Asian Options

Using Fractals to Improve Currency Risk Management Strategies

MODELLING VOLATILITY SURFACES WITH GARCH

Valuation of Asian Option. Qi An Jingjing Guo

Bounds on some contingent claims with non-convex payoff based on multiple assets

Arbitrage-Free Pricing of XVA for American Options in Discrete Time

Investment Planning Group (IPG) Progress Report #2

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

Any asset that derives its value from another underlying asset is called a derivative asset. The underlying asset could be any asset - for example, a

Math Option pricing using Quasi Monte Carlo simulation

ESG Yield Curve Calibration. User Guide

-divergences and Monte Carlo methods

Final Projects Introduction to Numerical Analysis Professor: Paul J. Atzberger

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

Executive Summary: A CVaR Scenario-based Framework For Minimizing Downside Risk In Multi-Asset Class Portfolios

******************************* The multi-period binomial model generalizes the single-period binomial model we considered in Section 2.

Valuing Early Stage Investments with Market Related Timing Risk

King s College London

NtInsight for ALM. Feature List

NATIONAL UNIVERSITY OF SINGAPORE Department of Finance FIN3130: Financial Modeling Semester 1, 2018/2019

Theory Of Stochastic Processes Cox Miller

Microsoft Morgan Stanley Finance Contest Final Report

Stochastic Modelling in Finance

Certified Quantitative Financial Modeling Professional VS-1243

Pricing of options in emerging financial markets using Martingale simulation: an example from Turkey

Transcription:

MMA707 Analytical FinanceⅠ Jan R. M. Röman Monte Carlo Simulation GROUP Wej Wang Maierdan Halifu Yankai Shao Arvid Kjellberg 2008 10 09 Department of Mathematics and Physics Mälardalen University SE 721 23 Västerås, Sweden

Abstract This report is designed to describe methods of Monte Carlo simulation to students and teachers of the course: Analytical Finance and other scholars who are interested in Monte Carlo simulation. The report introduces some background and general ideas about Monte Carlo simulation and how it can solve unpredictable stock price movements and endeavors.

Content 1. Aim and Mathematical Approach...4 1.1 Aim 4 1.2 Mathematical Approach 4 2. Numerical Example 6 3. The MATLAB GUI User Interface 7 4. Codes in the MATLAB program 8 4.1 Strike price 8 4.2 Spot price..8 4.3 Interest Rate..8 4.4 Volatility...8 4.5 Start date & End date...9 4.6 Iteration.9 4.7 Core part of the program...9 5. Reference..11 6. Appendix..12

1. Aim and Mathematical Approach 1.1 Aim We aim to create a simulation program to price European call option and put option. The options are pricing with the method of Monte Carlo Simulation algorithm with MATLAB. 1.2 Mathematical approach for European options First we use Black-Scholes formula to find a series of prices for both European call options and European put options. Then we use Time and Volatility from Black-Scholes formula into our Monte Carlo Simulation to simulate the underlying asset price changes. The Black-Scholes Formula we use: Where: And here Φ is the standard normal cumulative distribution function: And we can use Put-call Parity to get the price of put options: Where: After we get the values, we turn to use Monte Carlo simulation immediately. As we know, the stock price of a share at time T is: Where S(0) and S(T) are the prices of the share at moment 0 and T respectively, r is a

risk-free interest rate, is volatility, Z~N(0,1). Then we define prices both for call option and put option: To find the theoretical option value we calculate the mean value of the discounted pay-off:

2. Numerical Examples: To get the price of European options use the Monte Carlo simulation program, we take one European call option with the following parameters: Strike Price K = 95 Spot Price S = 100 Interest Rate r = 0.0425 (the latest interest rate in Sweden) Volatility = 0.3 Start Date: 01/01/08 End Date: 02/04/09 Iterations = 100

3. The MATLAB GUI User Interface: We made a program with MATLAB GUI, where the data are needed to be entered in the corresponding edit boxes. After pressing the Calculate pushbutton, the option price as well as its mean return from simulation and distribution histogram will be displayed.

4. Codes in the MATLAB program: We only include part of MATLAB code where have been programmed. 4.1 Strike price: function edit1strikeprice_callback(hobject, eventdata, handles) user_entry = str2double(get(hobject,'string')) New1=get(hObject,'String'); New2=str2double(New1); handles.edit1strikeprice=new2; guidata(hobject,handles); function edit1strikeprice_createfcn(hobject, eventdata, handles) if ispc && isequal(get(hobject,'backgroundcolor'), get(0,'defaultuicontrolbackgroundcolor')) set(hobject,'backgroundcolor','white'); end 4.2 Spot price function edit2spotprice_callback(hobject, eventdata, handles) user_entry = str2double(get(hobject,'string')); New1=get(hObject,'String'); New2=str2double(New1); handles.edit2spotprice=new2; guidata(hobject,handles); 4.3 Interest Rate: function edit3interestrate_callback(hobject, eventdata, handles) user_entry = str2double(get(hobject,'string')); %#ok<nasgu> New1=get(hObject,'String'); New2=str2double(New1); handles.edit3interestrate=new2; guidata(hobject,handles); 4.4 Volatility function edit4volatility_callback(hobject, eventdata, handles)

user_entry = str2double(get(hobject,'string')); New1=get(hObject,'String'); New2=str2double(New1); handles.edit4volatility=new2; guidata(hobject,handles); 4.5 Start date & End date: The length between start and end date is calculated by MATLAB function yearfrac, which is programmed within Pushbutton1 Callback instead. 4.6 Iterations: function edit7iterations_callback(hobject, eventdata, handles) user_entry = str2double(get(hobject,'string')); New1=get(hObject,'String'); New2=str2double(New1); handles.edit7iterations=new2; guidata(hobject,handles); 4.7 This is the most important part in our program which generates the Monte Carlo simulation: function pushbutton1_callback(hobject, eventdata, handles) K = handles.edit1strikeprice; S = handles.edit2spotprice; r = handles.edit3interestrate; SIG = handles.edit4volatility; iter = handles.edit7iterations startdate = get(handles.edit5startdate, 'String'); enddate = get(handles.edit6enddate, 'String'); try T = yearfrac(startdate, enddate); catch error('optionpricegui:invaliddates',... 'Dates must be in a valid format') end [call,put] = blsprice(s,k,r,t,sig);

if handles.bcall == true set(handles.optionprice,'string',call); else set(handles.optionprice,'string',put); end guidata(hobject,handles); %now run the Monte Carlo simulation numdays = daysact(startdate, enddate); TT = sqrt(t/numdays) * ones(numdays, iter); rnum = randn(numdays, iter); BT = TT.*rNum; TT = [zeros(1, iter); TT]; BT = [zeros(1, iter); BT]; ST = S* exp(cumsum((r - 0.5 * SIG^2) * TT + SIG * BT)); % Plot the Monte Carlo simulation set(handles.axeshist,'yaxislocation','right','xaxislocation','top',... 'xtick',[],'xlimmode','auto') if size(st,2)>1000 ind = randperm(size(st,2))'; STplot = ST(:,ind(1:1000)); else STplot = ST; end % Plot the monte-carlo underlying price paths handles.pricepaths = plot(handles.axesmonte, (0:numDays), STplot,... 'color', [.7,.7,.7]); %plot the mean underlying Monte carlo price path STmean = mean(st,2); handles.meanline = line('xdata', (0:numDays), 'YData', STmean,... 'Parent', handles.axesmonte, 'Marker', '.','MarkerSize', 10, 'Color', 'r'); %Monte Carlo Plots xlabel(handles.axesmonte, 'Time (Days)','fontweight','bold') ylabel(handles.axesmonte, 'Underlying ($)','fontweight','bold') axis(handles.axesmonte, 'tight') grid(handles.axesmonte, 'on') legend(handles.axesmonte,... {'$$S_{t+dt} = S_te^{(r-\frac{{\sigma^2}}{2})dt+\sigma\epsilon\sqrt{dt}}$$'},... 'fontsize',14,'interpreter','latex', 'Location', 'NorthWest'); x = handles.meanline; y = [zeros(1, iter); BT]; hist(y,x)

5. References: 1. Analytical Finance 1 Lecture Note, Jan R. M. Röman, 2007 2. http://en.wikipedia.org/wiki/black-scholes, latest visit Oct 08, 2008 3. http://en.wikipedia.org/wiki/monte_carlo_simulation, latest visit Oct 08, 2008 4. www.mathworks.com, latest visit Oct 08, 2008

6. Appendix We use the same interface to find the price one European put option using the data from the previous section.