Elementary s to Chas Tic Calculus

download Elementary s to Chas Tic Calculus

of 44

Transcript of Elementary s to Chas Tic Calculus

  • 7/30/2019 Elementary s to Chas Tic Calculus

    1/44

    1

    Elementary Stochastic Calculus1 In this lecture. . .

    G all the stochastic calculus you need to know, and no moreG

    the meaning of Markov and martingale

    GBrownian motion

    G

    stochastic integrationG

    stochastic differential equations

    GIts lemma in one and more dimensions

  • 7/30/2019 Elementary s to Chas Tic Calculus

    2/44

  • 7/30/2019 Elementary s to Chas Tic Calculus

    3/44

    3

    3 A motivating example

    Toss a coin. Every time you throw a head you receive $1, every

    time you throw a tail you pay out $1. In the experiment below the

    sequence was THHTHT, and you finished even.

    -2

    -1

    0

    1

    2

    0 1 2 3 4 5 6 7

    1.The outcome of a coin tossing experiment.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    4/44

    4

    G 5

    L

    denotes the random amount, either $1 or -$1, you make on the

    L th toss:

    ( > 5

    L

    @ ( > 5

    L

    @ and ( > 5L

    5

    M

    @

    In this example it doesnt matter whether or not these expectations

    are conditional on the past. In other words, if you threw five headsin a row it does not affect the outcome of the sixth toss.

    GIntroduce

    6

    L

    to mean the total amount of money you have won up

    to and including theL

    th toss so that

    6

    L

    L

    ;

    M

    5

    M

    Later on it will be useful if we have 6

    , i.e., you start with nomoney.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    5/44

    5

    If we now calculate expectations of 6L

    it does matter what infor-

    mation we have. If we calculate expectations of future events beforethe experiment has even begun then

    ( > 6

    L

    @ and ( > 6 L

    @ ( > 5

    5

    5

    ? ? ? @ L

    On the other hand, suppose there have been five tosses already, canwe use this information and what can we say about expectations for

    the sixth toss?

    GThis is the conditional expectation.

    The expectation of 6

    conditional upon the previous five tosses

    gives

    ( > 6

    M 5

    5

    ( 6

  • 7/30/2019 Elementary s to Chas Tic Calculus

    6/44

    6

    4 The Markov property

    GThe expected value of the random variable

    6

    L

    conditional upon all

    of the past events only depends on the previous value $L >

    . This

    is the Markov property.

    We say that the random walk has no memory beyond where it is

    now. Note that it doesnt have to be the case that the expected value

    of the random variable$

    L

    is the same as the previous value.

    This can be generalized to say that given information about$

    M

    for

    some values of T M L then the only information that is of use to

    us in estimating 6L

    is the value of 6M

    for the largest M for which we

    have information.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    7/44

    7

    5 The martingale property

    The coin tossing experiment possesses another property that can be

    important in finance. You know how much money you have won af-

    ter the fifth toss. Your expected winnings after the sixth toss, and in-

    deed after any number of tosses if we keep playing, is just the amountyou already hold.

    G The conditional expectation of your winnings at any time in the

    future is just the amount you already hold:

    ( > $

    L

    M $

    M

    M L @ $

    M

    This is called the martingale property.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    8/44

    8

    6 Quadratic variation

    The quadratic variation of the random walk is defined by

    L

    ;

    M

    $

    M

    > $

    M >

    Because you either win or lose an amount $1 after each toss,M $

    M

    b

    $

    M >

    M . Thus the quadratic variation is always L :

    L

    ;

    M

    $

    M

    > $

    M >

    L

    We are going to use the coin-tossing experiment for one more demon-

    stration. And that will lead us to a continuous-time random walk.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    9/44

    9

    7 Brownian motion

    Change the rules of the coin-tossing experiment slightly. First of all

    restrict the time allowed for the six tosses to a periodW

    , so each toss

    will take a timeW . Second, the size of the bet will not be $1 but

    5

    9 .This new experiment clearly still possesses both the Markov and

    martingale properties, and its quadratic variation measured over the

    whole experiment is

    ;

    M

    $

    M

    > $

    M >

    @

    U

    7

    9

    9

  • 7/30/2019 Elementary s to Chas Tic Calculus

    10/44

    10

    Change the rules again, to speed up the game.

    GWe will have

    Qtosses in the allowed time

    W, with an amount

    5

    9 3

    riding on each throw.

    Again, the Markov and martingale properties are retained and the

    quadratic variation is stillQ

    ;

    M

    $

    M

    > $

    M >

    3 @

    U

    7

    9

    3

    9

    Now make Q larger and larger. This speeds up the game, decreasingthe time between tosses, with a smaller amount for each bet. But

    the new scalings have been chosen very carefully, the timestep is

    decreasing likeQ

    > but the bet size only decreases byQ

    > .

  • 7/30/2019 Elementary s to Chas Tic Calculus

    11/44

    11

    -1

    -0.5

    0

    0.5

    1

    1.5

    2

    0 0.2 0.4 0.6 0.8 1

    2.A series of coin tossing experiments.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    12/44

    12

    As we go to the limit3 , the resulting random walk stays

    finite. It has an expectation, conditional on a starting value of zero,of

    > $ 9 @

    and a variance

    > $ 9

    @ 9

    We use6 W

    to denote the amount you have won or the value of the

    random variable after a time W .

    G The limiting process for this random walk as the timesteps go tozero is called Brownian motion, and we will denote it by ; W .

  • 7/30/2019 Elementary s to Chas Tic Calculus

    13/44

    13

    The important properties of Brownian motion are as follows.

    G Finiteness : Any other scaling of the bet size or increments with

    timestep would have resulted in either a random walk going to

    infinity in a finite time, or a limit in which there was no motion

    at all. It is important that the increment scales with the square root

    of the timestep.

    G Continuity : The paths are continuous, there are no discontinuities.

    Brownian motion is the continuous-time limit of our discrete time

    random walk.G Markov : The conditional distribution of ; W given information

    up until W depends only on ; .

    G Martingale : Given information up until W the conditional

    expectation of; W is ; .

  • 7/30/2019 Elementary s to Chas Tic Calculus

    14/44

    14

    G Quadratic variation : If we divide up the time to W in a partition

    with Q partition points W L L W Q thenQ

    ;

    M

    ; W

    M

    > ; W

    M >

    9 (Technically almost surely.)

    G Normality : Over finite time increments W L > to 9 L , ; W L > ; W L >

    is Normally distributed with mean zero and variance9

    L

    > 9

    L >

    .

  • 7/30/2019 Elementary s to Chas Tic Calculus

    15/44

    15

    Having built up the idea and properties of Brownian motion from

    a series of experiments, we can discard the experiments, to leave theBrownian motion that is defined by its properties. These properties

    will be very important for our financial models.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    16/44

    16

    8 Stochastic integration

    Define a stochastic integral by

    : W

    =

    9

    1 G ; O L P

    3

    3

    ;

    M

    1 9

    M >

    ; W

    M

    > ; W

    M >

    with

    9

    M

    M W

    Q

    G Note that the function I W is evaluated in the summation at theleft-hand point W

    M >

    .

    It will be crucially important that each function evaluation does not

    know about the random increment that multiplies it, i.e. the integra-

    tion is non-anticipatory.In financial terms, we will see that we take some action such as

    choosing a portfolio and only then does the stock price move. This

    choice of integration is natural in finance, ensuring that we use no

    information about the future in our current actions.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    17/44

    17

    9 Stochastic differential equations

    Stochastic integrals are important for any theory of stochastic cal-

    culus since they can be meaningfully defined. However, it is very

    common to use a shorthand notation for expressions such as

    : W

    =

    9

    1 G ; (1)

    That shorthand comes from differentiating (1) and is

    G : I W G ;

    GThink of G ; as being an increment in ; , i.e. a Normal random

    variable with mean zero and standard deviation G W .

  • 7/30/2019 Elementary s to Chas Tic Calculus

    18/44

    18

    Pursuing this idea further, imagine what might be meant by

    G : J W G W I W G ; (2)

    This is simply shorthand for

    : W

    =

    9

    J G

    =

    9

    1 G ;

    GEquations like (2) are called stochastic differential equations.

    Their precise meaning comes, however, from the technically more

    accurate equivalent stochastic integral.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    19/44

    19

    10 The mean square limit

    This is useful in the precise definition of stochastic integration.

    Examine the quantity

    (

    3

    ;

    M

    ; W

    M

    > ; W

    M >

    > 9

    where

    9

    M

    M W

    Q

  • 7/30/2019 Elementary s to Chas Tic Calculus

    20/44

    20

    This can be expanded as

    (

    3

    ;

    M

    ; W

    M

    > ; W

    M >

    3

    ;

    L

    ;

    M L

    ; W

    L

    > ; W

    L >

    ; W

    M

    > ; W

    M >

    > 9

    3

    ;

    M

    ; W

    M

    > ; W

    M >

    9

    Since ; WM

    > ; W

    M >

    is Normally distributed with mean zero and

    variance 9 3 we have

    A

    ; W

    M

    > ; W

    M >

    B

    9

    Q

    and

    (

    A

    ; W

    M

    > ; W

    M >

    B

    9

    3

  • 7/30/2019 Elementary s to Chas Tic Calculus

    21/44

    21

    Thus the required expectation becomes

    Q

    W

    Q

    Q Q >

    W

    Q

    > 9 3

    9

    3

    9

    M

    3

    N

    AsQ this tends to zero. We therefore say that

    3

    ;

    M

    ; W

    M

    > ; W

    M >

    9

    in the mean square limit. This is often written, for obvious reasons,

    as=

    9

    G ;

    W

    Whenever we talk about equality in the following proof we

    mean equality in the mean square sense.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    22/44

    22

    11 Functions of stochastic variables and

    Its lemma

    Now well see the idea of a function of a stochastic variable. Below

    is shown a realization of a Brownian motion ; W and the function

    ) ; ;

    .

    -0.4

    -0.3

    -0.2

    -0.1

    0

    0.1

    0.2

    0.3

    0.4

    0 0.1 0.2 0.3 0.4 0.5

    Brownian motion

    Square of Brownian motion

    3.A realization of a random walk and its square.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    23/44

    23

    If) ; is it true that G ) ; G ; ? No.

    GThe ordinary rules of calculus do not generally hold in a stochastic

    environment.

    Then what are the rules of calculus?

    We now derive the most important rule of stochastic calculus,Its lemma.

  • 7/30/2019 Elementary s to Chas Tic Calculus

    24/44

    24

    In this derivation we will need various timescales. The first timescale

    is very, very small. Denote it bys W

    Q

    K

    This timescale is so small that the function ) ; W K can be ap-

    proximated by a Taylor series:

    ) ; W K > ) ; W ; W K > ; W

    G )

    G ;

    ; W

    ; W K > ; W

    G

    )

    G ;

    ; W ? ? ?

  • 7/30/2019 Elementary s to Chas Tic Calculus

    25/44

    25

    From this it follows that

    ) ; W K > ) ; W ) ; W K > ) ; W K ? ? ?

    ) ; W Q K > ) ; W Q > K

    3

    ;

    M

    ; W M K > ; W M > K

    G )

    G ;

    ; W M > K

    G

    )

    G ;

    ; W

    3

    ;

    M

    ; W M K > ; W M > K

    ? ? ?

    This has used the approximation

    G

    )

    G ;

    ; W M > K

    G

    )

    G ;

    ; 9

    This is consistent with the order of accuracy we require.

    26

  • 7/30/2019 Elementary s to Chas Tic Calculus

    26/44

    26

    The first line in this becomes simply

    ) ; W Q K > ) ; W ) ; W s W > ) ; W

    The second is just the definition of=

    9 I 9

    9

    G )

    G ;

    G ;

    and the last is

    G

    )

    G ;

    ; W s W

    in the mean square sense. Thus we have

    ) ; W s W > ) ; W

    =

    9 I 9

    9

    G )

    G ;

    ; G ;

    =

    9 I 9

    9

    G

    )

    G ;

    ; G

    27

  • 7/30/2019 Elementary s to Chas Tic Calculus

    27/44

    27

    We can now extend this result over longer timescales, from zero up

    to W , over which ) does vary substantially to get

    ) ; W ) ;

    =

    9

    G )

    G ;

    ; G ;

    =

    9

    /

    / ;

    ; G

    This is the integral version ofIts lemma, which is usually written

    as

    G )

    G )

    G ;

    G ;

    G

    )

    G ;

    G W

    28

  • 7/30/2019 Elementary s to Chas Tic Calculus

    28/44

    28

    We can now answer the question, If ) ; what stochastic dif-

    ferential equation does ) satisfy? In this example

    G )

    G ;

    ; andG

    )

    G ;

    Therefore Its lemma tells us that

    G ) ; G ; G W

    This is not what we would get if; were a deterministic variable. In

    integrated form

    ;

    ) ; )

    =

    9

    ; G ;

    =

    9

    / Q

    =

    9

    ; G ; W

    Therefore=

    9

    ; G ;

    ;

    >

    9

    29

  • 7/30/2019 Elementary s to Chas Tic Calculus

    29/44

    29

    12 It and Taylor

    If we were to do a naive Taylor series expansion of ) , completely

    disregarding the nature of ; , and treating G ; as a small increment

    in;

    , we would get

    ) ; G ; ) ;

    G )

    G ;

    G ;

    G

    )

    G ;

    G ;

    ignoring higher-order terms. We could argue that ) ; G ; >

    ) ; was just the change in ) and so

    G )

    G )

    G ;

    G ;

    G

    )

    G ;

    G ;

    This is very similar to the proper It result with the only difference

    being that there is a G ; instead of a G W . However, since in a sense#

    9

    G ;

    W we could perhaps write G ;

    G W

    30

  • 7/30/2019 Elementary s to Chas Tic Calculus

    30/44

    30

    This lacks any rigor but it does give the correct result.

    GYou can, with little risk of error, use Taylor series with the rule of

    thumb

    G ;

    G W

    and in practice you will get the right result.

    31

  • 7/30/2019 Elementary s to Chas Tic Calculus

    31/44

    31

    Suppose our stochastic differential equation is

    G 6 D 6 G W E 6 G ; (3)

    say, for some functions D 6 and E 6 . Here G ; is the usual Brown-

    ian increment. Now if we have a function of6 , 9 6 , what stochas-

    tic differential equation does it satisfy? The answer is

    G 9

    G 9

    G 6

    G 6

    E

    G

    9

    G 6

    G W

    We could derive this properly or just cheat by using Taylor series

    with G ;

    G W . We could, if we wanted, substitute for G 6 from (3)to get an equation for

    G 9in terms of the pure Brownian motion

    ;:

    G 9

    M

    , $

    / '

    / $

    - $

    /

    '

    / $

    N

    G W E 6 G ;

    32

  • 7/30/2019 Elementary s to Chas Tic Calculus

    32/44

    32

    13 It in higher dimensions

    In financial problems we often have functions of one stochastic vari-

    able 6 and a determinisic variable W , time: 9 6 W . If

    G 6 D 6 W G W E 6 W G ;

    then the increment G 9 is given by

    G 9

    # 9

    # W

    G W

    # 9

    # 6

    G 6

    E

    #

    9

    # 6

    G W

    Again, this is shorthand notation for the correct integrated form.

    33

  • 7/30/2019 Elementary s to Chas Tic Calculus

    33/44

    33

    Occasionally, we have a function of two, or more, random vari-

    ables, and time as well: 9 6 6 W . Lets write the behaviour of6 and 6

    in the general form

    G 6

    D

    6

    6

    W G W E

    6

    6

    W G ;

    and

    G 6

    D

    6

    6

    W G W E

    6

    6

    W G ;

    Note that we have two Brownian increments G ;

    and G ;

    . We can

    think of these as being Normally distributed with variance G W , but

    they are correlated. The correlation between these two random vari-ables we will call . This can also be a function of6

    , 6

    and W but

    must satisfy

    > T T

    34

  • 7/30/2019 Elementary s to Chas Tic Calculus

    34/44

    34

    G The rules of thumb can readily be imagined:

    G ;

    G W G ;

    G W and G ;

    G ;

    G W

    Its lemma becomes

    G 9

    # 9

    # W

    G W

    # 9

    # 6

    G 6

    # 9

    # 6

    G 6

    E

    #

    9

    # 6

    G W E

    E

    #

    9

    # 6

    # 6

    G W

    E

    #

    9

    # 6

    G W

    35

  • 7/30/2019 Elementary s to Chas Tic Calculus

    35/44

    14 Some pertinent examples

    The first example is like the simple Brownian motion but with a drift:

    G 6 { G W G ;

    -0.05

    0

    0.05

    0.1

    0.15

    0.2

    0.25

    0.3

    0.35

    0.4

    0 0.2 0.4 0.6 0.8 1

    4.A realization ofG 6 { G W G ; .

    In this realization 6 has gone negative.

    36

  • 7/30/2019 Elementary s to Chas Tic Calculus

    36/44

    This stochastic differential equation G 6 { G W G ; can be

    integrated exactly to give6 W 6 { W ; W > ;

    37

  • 7/30/2019 Elementary s to Chas Tic Calculus

    37/44

    Our second example is similar to the above but the drift and ran-

    domness scale with 6 :G 6 { 6 G W 6 G ;

    0

    0.5

    1

    1.5

    2

    2.5

    3

    3.5

    4

    4.5

    5

    0 0.2 0.4 0.6 0.8 1

    5.A realization of G 6 { 6 G W 6 G ; .

    If 6 starts out positive it can never go negative; the closer that 6

    gets to zero the smaller the increments G 6 .

    38

  • 7/30/2019 Elementary s to Chas Tic Calculus

    38/44

    This property of this random walk is clearly seen if we examine

    the function ) 6 O R J 6 using Its lemma. From It we have

    G )

    G )

    G 6

    G 6

    6

    G

    )

    G 6

    G W

    6

    { 6 G W 6 G ; >

    P

    / 9

    ?

    { >

    P

    @

    / 9 G ;

    This shows us that O R J 6 can range between minus and plus infinity

    but cannot reach these limits in a finite time, therefore 6 cannot reach

    zero or infinity in a finite time.

    39

  • 7/30/2019 Elementary s to Chas Tic Calculus

    39/44

    The integral form of this stochastic differential equation follows

    simply from the stochastic differential equation for O R J 6 :

    6 W 6 H

    { >

    W ; W > ;

    The stochastic differential equationG 6 { 6 G W 6 G ; will be

    particularly important in the modeling of many asset classes. If wehave some function 9 6 W then from It it follows that

    G 9

    # 9

    # W

    G W

    # 9

    # 6

    G 6

    6

    #

    )

    # 6

    G W

    40

  • 7/30/2019 Elementary s to Chas Tic Calculus

    40/44

    The third example is

    G 6 | > { 6 G W G ;

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    0 0.2 0.4 0.6 0.8 1

    6.A realization ofG 6 | > { 6 G W G ;

    .

    41

  • 7/30/2019 Elementary s to Chas Tic Calculus

    41/44

    The random walk

    G 6 | > { 6 G W G ;

    is an example of a mean-reverting random walk. If 6 is large, the

    negative coefficient in front of G W means that 6 will move down on

    average, if 6 is small it rises on average. There is still no incentive

    for 6 to stay positive in this random walk. With U instead of 6 this

    random walk is the Vasicek model for the short-term interest rate.

    42

  • 7/30/2019 Elementary s to Chas Tic Calculus

    42/44

    The final example is similar to the third but we are going to adjust

    the random term slightly:G 6 | > { 6 G W 6

    G ;

    Now if6 ever gets close to zero the randomness decreases, perhaps

    this will stop 6 from going negative? Lets play around with this

    example for a while. And well see It in practice.

    Write ) 6 . What stochastic differential equation does )

    satisfy? Since

    G )

    G 6

    6

    >

    and/

    / $

    >

    $

    >

    we have

    /

    M

    | >

    )

    >

    { )

    N

    / 9

    G ;

    43

  • 7/30/2019 Elementary s to Chas Tic Calculus

    43/44

    We have just turned the original stochastic differential equation

    with a variable coefficient in front of the random term into a sto-chastic differential equation with a constant random term. In so do-

    ing we have made the drift term nastier. In particular, the drift is now

    singular at ) 6 .

    Continuing with this example, instead of choosing ) 6

    , canwe find a function ) 6 such that its stochastic differential equation

    has a zero drift term? For this we will need

    | > { 6

    G )

    G 6

    6

    G

    )

    G 6

    44

  • 7/30/2019 Elementary s to Chas Tic Calculus

    44/44

    This can be integrated once to give

    G )

    G 6

    $ 6

    >

    |

    H

    { 6

    (4)

    for any constant $ .

    If |

    M

    we cannot integrate (4) at$ . This makes the origin non-

    attainable. In other words, if the parameter|

    is sufficiently large

    it forces the random walk to stay away from zero.This particular stochastic differential equation for

    6will be impor-

    tant later on, it is the Cox, Ingersoll & Ross model for the short-term

    interest rate.