Steven R. Dunbar
Department of Mathematics
203 Avery Hall
University of Nebraska-Lincoln
Lincoln, NE 68588-0130
http://www.math.unl.edu
Voice: 402-472-3731
Fax: 402-472-8466

Stochastic Processes and
Advanced Mathematical Finance

__________________________________________________________________________

Properties of Geometric Brownian Motion

_______________________________________________________________________

Note: These pages are prepared with MathJax. MathJax is an open source JavaScript display engine for mathematics that works in all browsers. See http://mathjax.org for details on supported browsers, accessibility, copy-and-paste, and other features.

_______________________________________________________________________________________________

Rating

Rating

Mathematically Mature: may contain mathematics beyond calculus with proofs.

_______________________________________________________________________________________________

Section Starter Question

Section Starter Question

What is the relative rate of change of a function?

For the function defined by the ordinary differential equation

dx dt = rxx(0) = x0

what is the relative rate of growth? What is the function?

_______________________________________________________________________________________________

Key Concepts

Key Concepts

  1. Geometric Brownian Motion is the continuous time stochastic process z0 exp(μt + σW(t)) where W(t) is standard Brownian Motion.
  2. The mean of Geometric Brownian Motion is
    z0 exp(μt + (12)σ2t).

  3. The variance of Geometric Brownian Motion is
    z02 exp(2μt + σ2t)(exp(σ2t) 1).

__________________________________________________________________________

Vocabulary

Vocabulary

  1. Geometric Brownian Motion is the continuous time stochastic process z0 exp(μt + σW(t)) where W(t) is standard Brownian Motion.
  2. A random variable X is said to have the lognormal distribution (with parameters μ and σ) if log(X) is normally distributed (log(X) N(μ,σ2)). The p.d.f. for X is
    fX(x) = 1 2πσx exp((12)[(ln(x) μ)σ]2).

__________________________________________________________________________

Mathematical Ideas

Mathematical Ideas

Geometric Brownian Motion

Geometric Brownian Motion is the continuous time stochastic process X(t) = z0 exp(μt + σW(t)) where W(t) is standard Brownian Motion. Most economists prefer Geometric Brownian Motion as a simple model for market prices because it is everywhere positive (with probability 1), in contrast to Brownian Motion, even Brownian Motion with drift. Furthermore, as we have seen from the stochastic differential equation for Geometric Brownian Motion, the relative change is a combination of a deterministic proportional growth term similar to inflation or interest rate growth plus a normally distributed random change

dX X = rdt + σdW.

(See Itô’s Formula and Stochastic Calculus..) On a short time scale this is a sensible economic model.

A random variable X is said to have the lognormal distribution (with parameters μ and σ) if log(X) is normally distributed (log(X) N(μ,σ2)). The p.d.f. for X is

fX(x) = 1 2πσx exp((12)[(ln(x) μ)σ]2).

Theorem 1. At fixed time t, Geometric Brownian Motion z0 exp(μt + σW(t)) has a lognormal distribution with parameters (ln(z0) + μt) and σt.

Proof.

FX(x) = X x = z0 exp(μt + σW(t)) x = μt + σW(t) ln(xz0) = W(t) (ln(xz0) μt)σ = W(t)t (ln(xz0) μt)(σt) =(ln(xz0)μt)(σt) 1 2π exp(y22)dy

Now differentiating with respect to x, we obtain that

fX(x) = 1 2πσxt exp((12)[(ln(x) ln(z0) μt)(σt)]2).


geometricbrownian-1.png

Figure 1: The p.d.f. and c.d.f. for a lognormal random variable with m = 1, s = 1.5.

Calculation of the Mean

We can calculate the mean of Geometric Brownian Motion by using the m.g.f. for the normal distribution.

Theorem 2. 𝔼 z0 exp(μt + σW(t)) = z0 exp(μt + (12)σ2t)

Proof.

𝔼 X(t) = 𝔼 z0 exp(μt + σW(t)) = z0 exp(μt)𝔼 exp(σW(t)) = z0 exp(μt)𝔼 exp(σW(t)u) |u=1 = z0 exp(μt) exp(σ2tu22)| u=1 = z0 exp(μt + (12)σ2t)

since σW(t) N(0,σ2t) and 𝔼 exp(Y u) = exp(σ2tu22) when Y N(0,σ2t). See Moment Generating Functions, Theorem 4.. □

Calculation of the Variance

We can calculate the variance of Geometric Brownian Motion by using the m.g.f. for the normal distribution, together with the common formula

Var X = 𝔼 (X 𝔼 X)2 = 𝔼 X2 (𝔼 X)2

and the previously obtained formula for 𝔼 X.

Theorem 3. Var z0 exp(μt + σW(t)) = z02 exp(2μt + σ2t)[exp(σ2t) 1]

Proof. First compute:

𝔼 X(t)2 = 𝔼 z 02 exp(μt + σW(t))2 = z02𝔼 exp(2μt + 2σW(t)) = z02 exp(2μt)𝔼 exp(2σW(t)) = z02 exp(2μt)𝔼 exp(2σW(t)u) | u=1 = z02 exp(2μt) exp(4σ2tu22)| u=1 = z02 exp(2μt + 2σ2t)

Therefore,

Var z0 exp(μt + σW(t)) = z02 exp(2μt + 2σ2t) z 02 exp(2μt + σ2t) = z02 exp(2μt + σ2t)[exp(σ2t) 1].

Note that this has the consequence that the variance starts at 0 and then grows exponentially. The variation of Geometric Brownian Motion starts small, and then increases, so that the motion generally makes larger and larger swings as time increases.

Stochastic Differential Equation and Parameter Summary

If a Geometric Brownian Motion is defined by the stochastic differential equation

dX = rXdt + σXdWX(0) = z0

then the Geometric Brownian Motion is

X(t) = z0 exp((r (12)σ2)t + σW(t)).

At each time the Geometric Brownian Motion has lognormal distribution with parameters (ln(z0) + rt (12)σ2t) and σt. The mean of the Geometric Brownian Motion is 𝔼 X(t) = z0 exp(rt). The variance of the Geometric Brownian Motion is

Var X(t) = z02 exp(2rt)[exp(σ2t) 1]

If the primary object is the Geometric Brownian Motion

X(t) = z0 exp(μt + σW(t)).

then by Itô’s formula the SDE satisfied by this stochastic process is

dX = (μ + (12)σ2)X(t)dt + σX(t)dWX(0) = z 0.

At each time the Geometric Brownian Motion has lognormal distribution with parameters (ln(z0) + μt) and σt. The mean of the Geometric Brownian Motion is 𝔼 X(t) = z0 exp(μt + (12)σ2t). The variance of the Geometric Brownian Motion is

z02 exp(2μt + σ2t)[exp(σ2t) 1].

Ruin and Victory Probabilities for Geometric Brownian Motion

Because of the exponential-logarithmic connection between Geometric Brownian Motion and Brownian Motion, many results for Brownian Motion can be immediately translated into results for Geometric Brownian Motion. Here is a result on the probability of victory, now interpreted as the condition of reaching a certain multiple of the initial value. For A < 1 < B define the “duration to ruin or victory”, or the “hitting time” as

TA,B = min{t 0 : z0 exp(μt + σW(t)) z0 = A, z0 exp(μt + σW(t)) z0 = B}

Theorem 4. For a Geometric Brownian Motion with parameters μ and σ, and A < 1 < B,

z0 exp(μTA,B + σW(TA,B)) z0 = B = 1 A1(2μσ2)σ2 B1(2μσ2)σ2 A1(2μσ2)σ2

Quadratic Variation of Geometric Brownian Motion

The quadratic variation of Geometric Brownian Motion may be deduced from Itô’s formula:

dX = (μ σ22)Xdt + σXdW

so that

(dX)2 = (μ σ22)2X2dt2 + (μ σ22)σX2dtdW + σ2X2(dW)2.

Guided by the heuristic principle that terms of order (dt)2 and dt dW dt32 are small and may be ignored, and that (dW)2 = dt, we obtain:

(dX)2 = σ2X2dt.

Continuing heuristically, the expected quadratic variation is

𝔼 0T (dX)2 = 𝔼 0T σ2X2dt = σ20T 𝔼 X2 dt = σ2 0T z 02 exp(2μt + 2σ2t)dt = σ2z 02 2μ + 2σ2 exp((2μ + 2σ2)T) 1 .

Note the assumption that the order of the integration and the expectation can be interchanged.

Sources

This section is adapted from: A First Course in Stochastic Processes, Second Edition, by S. Karlin and H. Taylor, Academic Press, 1975, page 357; An Introduction to Stochastic Modeling 3rd Edition, by H. Taylor, and S. Karlin, Academic Press, 1998, pages 514–516; and Introduction to Probability Models 9th Edition, S. Ross, Academic Press, 2006.

_______________________________________________________________________________________________

Algorithms, Scripts, Simulations

Algorithms, Scripts, Simulations

Algorithm

Given values for μ, σ and an interval [0,T], the script creates  trials  sample paths of Geometric Brownian Motion, sampled at N equally-spaced values on [0,T]. The scripts do this by creating  trials  Brownian Motion sample paths sampled at N equally-spaced values on [0,T] using the definition of Brownian Motion having normally distributed increments. Adding the drift term and then exponentiating the sample paths creates  trials  Geometric Brownian Motion sample paths sampled at N equally-spaced values on [0,T]. Then the scripts use semi-logarithmic least-squares statistical fitting to calculate the relative growth rate of the mean of the sample paths. The scripts also compute the predicted relative growth rate to compare it to the calculated relative growth rate. The problems at the end of the section explore plotting the sample paths, comparing the sample paths to the predicted mean with standard deviation bounds, and comparing the mean quadratic variation of the sample paths to the theoretical quadratic variation of Geometric Brownian Motion.

Scripts

Geogebra

GeoGebra applet for Geometric Brownian Motion.

R

R script for Geomtric Brownian Motion..

1mu <- 1 
2sigma <- 0.5 
3T <- 1 
4# length of the interval [0, T] in time units 
5 
6trials <- 200 
7N <- 200 
8# number of end-points of the grid including T 
9Delta <- T/N 
10# time increment 
11 
12t <- t( seq(0,T, length=N+1) * t(matrix(1, trials, N+1)) ) 
13# Note use of the R matrix recycling rules, by columns, so transposes 
14W <- cbind(0, t( apply(sqrt(Delta) * matrix(rnorm(trials * N), trials, N), 1, cumsum))) 
15# Wiener process, Note the transpose after the apply, (side effect of 
16# apply is the result matches the length of individual calls to FUN, 
17# then the MARGIN dimension/s come next. So its not so much 
18# "transposed" as that being a consequence of apply in 2D.)  Note 
19# use of recycling with cbind to start at 0 
20 
21GBM <- exp( mu*t + sigma*W) 
22 
23meanGBM <- colMeans(GBM) 
24 
25meanGBM_rate <- lm(log(meanGBM) ~ seq(0,T, length=N+1)) 
26predicted_mean_rate = mu + (1/2)*sigma^2 
27 
28cat(sprintf("Observed meanGBM relative rate: %f \n", coefficients(meanGBM_rate)[2] )) 
29cat(sprintf("Predicted mean relative rate: %f \n", predicted_mean_rate)) 
30  
Octave

Octave script for Geometric Brownian Motion.

1mu = 1; 
2sigma = 0.5; 
3T = 1; 
4# length of the interval [0, T] in time units 
5 
6trials = 200; 
7N = 100; 
8# number of end-points of the grid including T 
9Delta = T/N; 
10# time increment 
11 
12W = zeros(trials, N+1); 
13# initialization of the vector W approximating 
14# Wiener process 
15t = ones(trials, N+1) .* linspace(0, T, N+1); 
16# Note the use of broadcasting (Octave name for R recylcing) 
17W(:, 2:N+1) =  cumsum( sqrt(Delta) * stdnormal_rnd(trials,N), 2); 
18 
19GBM = exp(mu*t + sigma*W); 
20 
21meanGBM = mean(GBM); 
22 
23A = [transpose((0:Delta:T)) ones(N+1, 1)]; 
24meanGBM_rate = A\transpose( log(meanGBM) ) 
25predicted_mean_rate = mu + (1/2)*sigma^2 
26  
Perl

Perl PDL script for Geometric Brownian Motion.

1$mu = 1; 
2$sigma = 0.5; 
3$T = 1.; 
4# length of the interval [0, T] in time units 
5 
6$trials = 200; 
7$N = 100; 
8# number of end-points of the grid including T 
9$Delta = $T / $N; 
10# time increment 
11 
12$W = zeros( $N + 1, $trials ); 
13# initialization of the vector W approximating 
14# Wiener process 
15$t = ones( $N+1, $trials ) * zeros( $N + 1 )->xlinvals( 0, $T ); 
16# Note the use of PDL dim 1 threading rule (PDL name for R recycling) 
17$W ( 1 : $N, : ) .= cumusumover( sqrt($Delta) * grandom($N, $trials) ); 
18 
19$GBM = exp( $mu * $t + $sigma * $W ); 
20 
21$meanGBM = sumover($GBM->xchg(0,1))/$trials; 
22 
23use PDL::Fit::Linfit; 
24 
25$fitFuncs = cat ones($N + 1), zeros( $N + 1 )->xlinvals( 0, $T ); 
26( $linfitfunc, $coeffs ) = linfit1d log($meanGBM), $fitFuncs; 
27print "Observed Mean GBM Rate: ", $coeffs(1), "\n"; 
28print "Predicted Mean GBM Rate: ", $mu + (1./2.)*$sigma**2, "\n"; 
29  
SciPy

Scientific Python script for Geometric Brownian Motion.

1import scipy 
2 
3mu = 1.; 
4sigma = 0.5; 
5T = 1. 
6# length of the interval [0, T] in time units 
7 
8trials = 200 
9N = 100 
10# number of end-points of the grid including T 
11Delta = T/N; 
12# time increment 
13 
14W = scipy.zeros((trials, N+1), dtype = float) 
15# initialization of the vector W approximating 
16# Wiener process 
17t = scipy.ones( (trials,N+1), dtype = float) * scipy.linspace(0, T, N+1) 
18# Note the use of recycling 
19W[:, 1:N+1] = scipy.cumsum(scipy.sqrt(Delta)*scipy.random.standard_normal( (trials, N)), axis = 1,) 
20 
21GBM = scipy.exp( mu*t + sigma*W) 
22meanGBM = scipy.mean(GBM, axis=0) 
23predicted_mean_GBM_rate = mu + (1./2.)*sigma**2 
24 
25meanGBM_rate = scipy.polyfit( scipy.linspace(0, T, N+1), scipy.log(meanGBM), 1) 
26 
27print "Observed Mean GBM Relative Rate:", meanGBM_rate[0]; 
28print "Predicted Mean GBM Relative Rate:", predicted_mean_GBM_rate;

__________________________________________________________________________

Problems to Work

Problems to Work for Understanding

  1. Differentiate
    (ln(xz0)μt)(σt) 1 2π exp(y22)dy

    to obtain the p.d.f. of Geometric Brownian Motion.

  2. What is the probability that Geometric Brownian Motion with parameters μ = σ22 and σ (so that the mean is constant) ever rises to more than twice its original value? In economic terms, if you buy a stock or index fund whose fluctuations are described by this Geometric Brownian Motion, what are your chances to double your money?
  3. What is the probability that Geometric Brownian Motion with parameters μ = 0 and σ ever rises to more than twice its original value? In economic terms, if you buy a stock or index fund whose fluctuations are described by this Geometric Brownian Motion, what are your chances to double your money?
  4. Derive the probability of ruin (the probability of Geometric Brownian Motion hitting A < 1 before hitting B > 1).
  5. Modify the scripts to plot several sample paths of Geometric Brownian Motion all on the same set of axes.
  6. Modify the scripts to plot several sample paths of Geometric Brownian Motion and the mean function of Geometric Brownian Motion and the mean function plus and minus one standard deviation function, all on the same set of axes.
  7. Modify the scripts to measure the quadratic variation of each of many sample paths of Geometric Brownian Motion, find the mean quadratic variation and compare to the theoretical quadratic variation of Geometric Brownian Motion.

__________________________________________________________________________

Books

Reading Suggestion:

References

[1]   S. Karlin and H. Taylor. A Second Course in Stochastic Processes. Academic Press, 1981.

[2]   Sheldon M. Ross. Introduction to Probability Models. Academic Press, 9th edition, 2006.

[3]   H. M. Taylor and Samuel Karlin. An Introduction to Stochastic Modeling. Academic Press, third edition, 1998.

__________________________________________________________________________

Links

Outside Readings and Links:

  1. Graphical Representations of Brownian Motion and Geometric Brownian Motion.
  2. Wikipedia Geometric Brownian Motion.

__________________________________________________________________________

I check all the information on each page for correctness and typographical errors. Nevertheless, some errors may occur and I would be grateful if you would alert me to such errors. I make every reasonable effort to present current and accurate information for public use, however I do not guarantee the accuracy or timeliness of information on this website. Your use of the information from this website is strictly voluntary and at your risk.

I have checked the links to external sites for usefulness. Links to external websites are provided as a convenience. I do not endorse, control, monitor, or guarantee the information contained in any external website. I don’t guarantee that the links are active at all times. Use the links here with the same caution as you would all information on the Internet. This website reflects the thoughts, interests and opinions of its author. They do not explicitly represent official positions or policies of my employer.

Information on this website is subject to change without notice.

Steve Dunbar’s Home Page, http://www.math.unl.edu/~sdunbar1

Email to Steve Dunbar, sdunbar1 at unl dot edu

Last modified: Processed from LATEX source on August 4, 2016