270 likes | 518 Views
Hedge with an Edge An Introduction to the Mathematics of Finance . Monte Carlo Methods. Riaz Ahmed & Adnan Khan Lahore Uviersity of Management Sciences . Topics. Simulating Bernoulli Random Variable Generating Random Variables Inverse Transform Method Box Muller Method
E N D
Hedge with an EdgeAn Introduction to the Mathematics of Finance Monte Carlo Methods Riaz Ahmed & Adnan Khan Lahore Uviersity of Management Sciences
Topics • Simulating Bernoulli Random Variable • Generating Random Variables • Inverse Transform Method • Box Muller Method • Rejection Method • Simulate a 1-D random Walk • Calculate the mean • Calculate the Variance • Simulating Brownian Motion • Geometric Brownian Motion • Arithmetic Brownian Motion • Variance Reduction Techniques
Simulating a Binomially Distributed Random Variable • Note sum of Bernoulli trials is a binomial • Let Xi be a Bernoulli trial with probability ‘p’ of success • is binomial ‘n’, ‘p’
Some Properties • Distribution of successes in trials • Expected Value • Variance
Simulation of Binomial • Generating Bernoulli • Binomial as the sum of Bernoulli • Monte Carlo Simulation • Numerical vs. Exact Mean and Variance
Continuous Random Variables • Inverse Transform Method • Suppose a random variable has cdf ‘F(x)’ • Then Y=F-1(U) also had the same cdf • Generating the exponential • Generate the exponential, compare with exact cdf • Generate a r.v. with cdf
Simulating Normal using Inverse Transform • Cannot get a closed form in terms of elementary functions • Excel has built in command normsinv() • Use normsinv(rand())
Rejection Method • Simulate & • To Simulate look @ • If accept, else reject • To Simulate N(0,1) let • If set
Box Muller Method • Recall the cdf for the standard normal is • We saw one way was to invert this • Another technique is to generate • Then and where
Weiner Process • W(t) CT-CS process is a Weiner Process if W(t) depends continuously on t and the following hold a) • are independent
Simulating Brownian Motion • Initialize at 0 as W(0)=0 • Simulate Weiner Increments according to • The Weiner Process then follows
Stock Price Model • Modeled by Geometric Brownian Motion • Note • To simulate use the ‘Euler Scheme’
Mean Reverting Process • Arithmetic Brownian Motion is mean reverting • Interest rate models • The numerical scheme is
Option Pricing using Monte Carlo • Generate several risk-neutral random walks for the asset starting at the asset price today and going on till expiry. • For each path generated calculate the payoff. • Calculate average the average of all the payoffs • Take the present value of this average to get the option value today.
Challenge Problem Simulate using Monte Carlo techniques the price of a European call option where the underlying with volatility 0.5 interest rate 3% exercise price 100 and currently underlying at 90