Professional Documents
Culture Documents
Rajarshi Sarkar
University of Nice and Sophia Antipolis and INRIA - Team Tosca
August 2012
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
1 / 71
We know very little about the first-passage behaviour except in some simple
cases like standard Wiener process,Wiener process with drift.
Here we look into three kinds of approaches
1. Euler scheme with the Brownian bridge idea
2.The probabilistic dichotomic Fast Algorithm for Gauss-Markov processes
given by Taillefumier and Magnasco
3. Exact Simulation of a diffusion process
Also, we look into the problem of pricing a barrier option, a financial
instrument dependent on the approximation of the first-passage time for the
price of the underlying asset.
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
2 / 71
Outline
1
Introduction
Euler Scheme
Fast Algorithm
Application - Finance
Conclusion
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
3 / 71
Introduction
dXt = (Xt , t)dt + (Xt , t)dWt
with
X0 = x0
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
4 / 71
Notations
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
5 / 71
Outline
1
Introduction
Euler Scheme
Fast Algorithm
Application - Finance
Conclusion
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
6 / 71
Reflection Principle
With a constant boundary L = a, we get ,
d = B(t) if
B(t)
t < a
t a
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
7 / 71
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
8 / 71
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
9 / 71
Brownian Bridge
Now, we look into the law of the first-passage time in the case of a Brownian
bridge.
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
10 / 71
Proof:
We know that Bt is a Gaussian random variable N (0, t). We first introduce the
maximum of the process between time tx and tz . as;
Mtx ,tz = suptx ttz Bt
P(tx < tz |Btx = x , Btz = z) = P(Mtx ,tz > L|Btx = x , Btz = z)
Now,we know that
P(Mtx ,tz > L, Btz = z|Btx = x )
. Now, from the
P(Btz = z|Btx = x )
strong Markov property for a Brownian motion and from the reflection property
we get,
P(Mtx ,tz > L, Btz < z|Btx = x ) = P(Mtx ,tz > L, Btz > 2L z|Btx = x )
= P(Btz > 2L z|Btx = x )
since, z < L. Thus,
1
P(Btz > 2Lz|Btx = x ) = p
2(tz tx )
Rajarshi Sarkar
(UNSA - INRIA)
exp
2Lz
((y x0 ) (x x0 ))2
2(tz tx )
August 2012
dy
11 / 71
Proof: continued...
By differentiation respect to z and L, we get,
2(2l (x + z))
P(Btz dz, Mtx ,tz dl|Btx = x ) = p
exp
2(tz tx )
(2l (x + z))2
2(tz tx )
dzdl
1
2(tz tx )
exp
(z x )2
2(tz tx )
Thus, we get,
P(Mtx ,tz dl|Btx = x , Btz = z) =
2(2l (x + z))
exp
tz tx
2(l x )(l z)
tz tx
dl
(UNSA - INRIA)
August 2012
12 / 71
Outline
1
Introduction
Euler Scheme
Fast Algorithm
Application - Finance
Conclusion
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
13 / 71
Definition
Given some probability space (,F,P); let X be a continuous stochastic process
with natural filtration Ft .Then X is a Gauss-Markov process if ;
X is a Gaussian process if for any integers n and positive reals
t1 < t2 < < tn , the random vector (Xt1 ,Xt2 ,. . . ,Xtn ) has a joint Gaussian
distribution. Thus, for any reals a1 ,a2 ,. . . ,an , random variable
n
X
ai Xti
i=1
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
14 / 71
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
15 / 71
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
16 / 71
Proof: continued....
Now we consider Xt = Yt Zt for some Zt . Applying Itos formula, we get
Z t
exp(
(u) du)dZt = (t)dWt with Z0 = x0
0
Thus,
Z
Zt = x0 +
Z
exp(
Rs
Rt
Rt
Thus we get, Xt = exp( 0 (u) du)(x0 + 0 exp( 0 (u) du)(s) dWs ).
Thus defining the functions g, h and f as,
Z t
(u) du)
g(t) = exp(
0
Z t
Z s
h(t) =
exp(2
(u) du)(s)2 ds
0
0
Z t
f (t) = exp(
(u) du)(t)
0
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
17 / 71
Final Result
Thus, we can write the stochastic process like;
Z t
Xt = g(t)(x0 +
f (s) dWs )
0
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
18 / 71
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
19 / 71
First one being Doobs integral representation which gives an expression for
the probability P(Xt = x |Xt0 = x0 ) of a general Gauss-Markov process.
2
x0
x
g(t)
g(t0 )
1
p
exp
P(Xt [x , x +dx ]|Xt0 = x0 ) =
2(h(t) h(t0 )
g(t) 2(h(t) h(t0 ))
iff h(t) 6= h(t0 ).
Second result being the fact that we can actually evaluate
P(Xty [y , y + dy ]|Xtx = x , Xtz = z)
This is because X is a Markov process, thus a sample path which starts from
x and terminates at z passing through y can be thought of as two
independent paths; one starting at x and finishing at y and another one
starting at y and ending at z.
Applying these two properties, we are able to finally construct the probability
density for the random variable Xty with mean (ty ) and variance (ty ).
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
20 / 71
Rajarshi Sarkar
Rt
tx
f 2 (u) du
(UNSA - INRIA)
August 2012
21 / 71
(UNSA - INRIA)
August 2012
22 / 71
with
X0 = x0
(UNSA - INRIA)
August 2012
23 / 71
Proof:
First we remember Doobs integral representation for the Gauss-Markov process in
question:
Z t
Xt = g(t)(x0 +
f (u) dWu )
0
Rt
Rt
where, g(t) = exp( 0 (u) du) and f (t) = exp( 0 (u) du)(t) and
Rs
Rt
h(t) = 0 exp(2 0 (u) du)(s)2 ds.
Xt
Xt
Thus, we see that g(t)
is a time changed Wiener process, as d g(t)
= f (t)dWt .
Thus, we can apply both the previous results very nicely to this proof.
we also have, (tx ) = Lx and (tz ) = Lz .
Lx
Lz
Let, Kx = g(t
, Kz = g(t
, x 0 = g(tx x ) , z 0 = g(tz z )
x)
z)
Now, lets define the affine boundary which we are going to consider in the first
step which joins (h(tx ), Kx ) and (h(tz ), Kz ) for tx < t < tz as,
L(t) =
Rajarshi Sarkar
(UNSA - INRIA)
h(tz ) h(t)
h(t) h(tx )
Kx +
Kz
h(tz ) h(tx )
h(tz ) h(tx )
August 2012
24 / 71
Proof: continued....
Now, we consider the first-passage time of the form
0
0
h(t
= inf{h(t) > h(tx )|Wh(t)
> L(t)}, where Wt0 is the time changed Wiener
x)
process defined by the SDE , dWt0 = f (t)dWt .
0
0
Then, conditioning to Wh(t
= x 0 and Wh(t
= z 0 , we get,
x)
z)
2(Kx x 0 )(Kz z 0 )
0
0
0
0
0
=
z
)
=
exp
=
x
,
W
<
h(t
)|W
P(h(t
z
h(tz )
h(tx )
x)
h(tz ) h(tx )
Now, we look into the event whose probability we just calculated.
0
0
0
{h(t
< h(tz )|Wh(t
= x 0 , Wh(t
= z 0}
x)
x)
z)
0
0
0
= {h(t) (h(tx ), h(tz )), Wh(t)
> L(t)|Wh(t
= x 0 , Wh(t
= z 0}
x)
z)
0
0
0
= {t (tx , tz ), Wh(t)
> L(t)|Wh(t
= x 0 , Wh(t
= z 0}
x)
z)
0
0
0
= {t (tx , tz ), g(t)Wh(t)
> g(t)L(t)|g(tx )Wh(t
= x , g(tz )(Wh(t
= z}
x)
z)
0
Now, since we can very easily see that Xt and g(t)Wh(t)
have the same law, thus
for tx t tz , we can deduce that,
0
0
P(h(tz ) < h(tz )|Wh(t
= x 0 , Wh(t
= z 0 ) = P(tx < tz |Xtx = x , Xtz = z)
x)
z)
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
25 / 71
Final Result
Thus, finally we get the result for the first-passage time for a conditioned
Gauss-Markov process as;
2(Lx x )(Lz z)
P(tx < tz |Xtx = x , Xtz = z) = exp
g(tz )g(tx )(h(tz ) h(tx ))
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
26 / 71
Outline
1
Introduction
Euler Scheme
Fast Algorithm
Application - Finance
Conclusion
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
27 / 71
Euler Scheme
We look into the Euler Scheme for the approximation of the first-passage time for
a Gauss-Markov process X .
dXt = (t)Xt dt + (t)dWt
0tT
with
X 0 = x0
b(k+1) = X
bk + (k)X
bk + (k) G k+1
X
with
k {0, 1, .....N 1}
(UNSA - INRIA)
August 2012
28 / 71
with
for
0tT
X0 = x0
where is a non-positive real constant, is a positive constant and x0 is a real
constant. T > 0 The Euler scheme, with = TN where N N is,
b(k+1) = X
bk + X
bk + G k+1 for k {0, 1, ....N 1}
X
with X0 = x0 .
Now, what if none of the discrete simulations crosses the boundary?
Conditioning on the values of (Xti ) and (Xti+1 ), we look at the probability for the
crossing to happen in-between these two values, if and only if none of the values
cross the boundary. Also we know that (Xt )ti tti+1 has the law of some form of
Brownian bridge.
2(Lti x )(Lti+1 z)
bt = x , X
bt = z) = exp
P( (ti , ti+1 )|X
i
i+1
g(ti )g(ti+1 )(h(ti+1 ) h(ti ))
where we have
the fact that > ti . where g(t) = exp(t) and
acknowledged
2 1exp(2t)
h(t) = ()
. Then we compare this probability of crossing, with an
2
uniform random variable U(0, 1).
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
29 / 71
1.5
"simulate_path.dat"
1
0.5
0
-0.5
-1
-1.5
-2
0
10
Time
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
30 / 71
(UNSA - INRIA)
August 2012
31 / 71
"firstpassagekernel.dat"
0.9
0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0
10
x
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
32 / 71
N
X
1X i x
N
i=1
where X denotes the sample data set for the first-passage time and N in our
above expression is the Monte-Carlo number, or the number of simulated values
we have in our data set.
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
33 / 71
"cumulative_density.dat"
0.9
P(First-passage Time < X)
0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0
10
X
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
34 / 71
Outline
1
Introduction
Euler Scheme
Fast Algorithm
Application - Finance
Conclusion
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
35 / 71
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
36 / 71
Regularity assumptions
Certain assumptions are taken into account.
Co-efficient Regularity Assumption : The Gauss-Markov processes are
solution of a linear stochastic equation with time-dependent
non-positive,bounded function and with time-dependent positive,
homogeneously Holder continuous function .
Barrier Regularity Assumption : The barrier is assumed to be homogeneously
Holder continuous and non-negative.
These determine the regularity of a continuous density function for the
first-passage time and prescribes the speed of convergence of the first-passage
time computation.
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
37 / 71
The Algorithm
We generate first the final position of the process using the formula.
p
XT = g(T )x0 + g(T ) h(T )
where, is a Gaussian random variable N (0, 1).
Then we simulate XT /2 using the result of the discrete construction of
Gauss-Markov process using the values of X0 and XT .
In this way, we keep on dividing and subdividing the domain to find the
values of out process at specific time.
When Xt L; by continuity of the sample path we know that the crossing
has occurred before or at t thus, we disregard continuing the simulation of
the sample path for time s following t.
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
38 / 71
In the case, when the newly simulated value does not cross the boundary and
neither does any of its adjacent values, we check if the probability for a
crossing to happen is larger than some prescribed small positive real .
We define a certain depth of search initially, i.e.
T
.
2N
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
39 / 71
with
X0 = x0
0tT
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
40 / 71
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
41 / 71
h
i
(k+1)T
After, simulating all the values in the interval kT
,
for some k, we
N
N
2
2
look for the time when the value crosses the boundary.
If such a time exists, then we say it is the first-passage time for the simulated
path.
If not, then we consider the probability of exit in that interval which has the
highest probability of exit compared to others.
Now,if the probability of crossing is greater than equal to the uniform variable
, we consider the mid-point of that time interval as our first-passage time.
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
42 / 71
1.5
"Initial_Simulation.dat"
1
0.5
0
-0.5
-1
-1.5
-2
0
10
Time
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
43 / 71
After the initial simulation, we check for the first time the process value has
touched or exceeded the value of the boundary L.
We find such a time in this case, and we go on checking the probability of
exit in each interval with an , where = 0.001.
Wherever the probability is greater than the , we simulate more values of the
process in that interval using the same idea as before.
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
44 / 71
0.52
"second_round_of_simulation.dat"
0.51
0.5
0.49
0.48
0.47
0.46
0.45
6.4721
6.4722
6.4723
6.4724
6.4725
6.4726
6.4727
6.4728
Time
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
45 / 71
"density_kernel.dat"
0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0
10
x
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
46 / 71
"cumulative_distribution.dat"
0.9
P(First-passage Time < X)
0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0
10
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
47 / 71
Outline
1
Introduction
Euler Scheme
Fast Algorithm
Application - Finance
Conclusion
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
48 / 71
Parameters
We look into the following the SDE,
dXt = Xt dt + dWt
with
X0 = x0
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
49 / 71
Euler Scheme
We first look into the results obtained from the Euler scheme for the above SDE.
We tabulate the Monte-Carlo number, the delta or the time-step, the expected
value E ( 1 <T ), the statistical error and the running time for the algorithm.
Table : Euler Scheme Results
MCN
Delta
Expected value
Statistical Error
1000
11000
170000
2700000
0.039
0.0097
0.00244
0.0006
8
10
12
14
1.1566
1.1946
1.2056
1.2162
0.09301
0.0286
0.00727
0.00189
Rajarshi Sarkar
(UNSA - INRIA)
Running Time(in se
0.11
1.476
117.465
1786.091
August 2012
50 / 71
Fast Algorithm
It is given that for a chosen parameter , with which we compare our probability
of crossing at each interval, and for a given depth 2N , we get,
P( N > + 2N ) = (N, )
The choice of is done in this fashion.
ln ln (N 1)ln2 lnT
with such a choice of , we get .
We choose = exp(18) and hence the probability of the algorithm returning an
erroneous result is 103
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
51 / 71
Fast Algorithm
MCN
Delta
Expected value
Statistical Error
1000
11000
170000
2700000
0.039
0.00976
0.00244
0.00015
8
10
12
14
1.564
1.348
1.246
1.2198
0.1235
0.0335
0.0084
0.00202
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
52 / 71
Rajarshi Sarkar
(UNSA - INRIA)
1
sinh(x )
32
exp(x ) x
exp
+
2sinh(x )
2
August 2012
53 / 71
The graph of the density function for the case when L = 0.5 and X0 = 0 is,
1.4
"firstpassagekernel.dat"
1.2
the pdf
1
0.8
0.6
0.4
0.2
0
0
10
Comparing it with the density functions estimated with the Euler scheme and the
Fast algorithm.
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
54 / 71
Euler Scheme
1
"firstpassagekernel.dat"
0.9
0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0
10
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
55 / 71
Fast Algorithm
0.9
"density_kernel.dat"
0.8
0.7
0.6
0.5
0.4
0.3
0.2
0.1
0
0
10
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
56 / 71
Outline
1
Introduction
Euler Scheme
Fast Algorithm
Application - Finance
Conclusion
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
57 / 71
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
58 / 71
Introduction
0 t T,
X0 = x0 R
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
59 / 71
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
60 / 71
Algorithm
Generate a random variable hT , using the Rejection Sampling and set
(0) = 0
Generate a Brownian Bridge {(t)}0tT , such that (T ) =
We will be accepting this sample path with
! probability
Z
1 T
0 ((t)) + 2 ((t)) dt
exp
2 0
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
61 / 71
Algorithm
Thus, the idea for checking the probability of acceptance we take help of the
Point Poisson Process (PPP)
Generate a Point Poisson Process(PPP)
on the domain [0,T] x [0,K], where
K = sup0tT 21 0 ((t)) + 2 ((t)) , with unit intensity Thus,
ts+1 ts E(K ) and xs+1 xs U(0, K )
If, 12 0 ((ti )) + 2 ((ti )) < xi , holds for all i 0 s then we accept the path
Else, we go back to simulating the random variable hT and continue
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
62 / 71
Numerical Simulation
The
restriction
of this algorithm is its boundedness criteria of
main
0
1
2
2 (.) + (.)
In a later paper,
to the case
0 it was showed
how the idea can be extended
0
when
1
1
2
2
limsupx 2 (x ) + (x ) < or limsupx 2 (x ) + (x ) < .
Thus, we choose to work with an SDE of the form,
dXt = sin(Xt )dt + dWt
X0 = x0
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
63 / 71
"samplepath.dat"
10
9.5
8.5
8
0
10
15
20
25
30
Time
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
64 / 71
t2 t1
t2 t1
t2 t1
1
t2 t
Lx
t2 t1
and =
Ly .
t2 t1
xt2 + t1
for 0 x
x +1
We, know the distribution of the random variable , from the very famous
"Bachelier - Levy formula",
g(x ) =
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
65 / 71
Outline
1
Introduction
Euler Scheme
Fast Algorithm
Application - Finance
Conclusion
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
66 / 71
with
St0 = s0
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
67 / 71
Monte-Carlo Number
Price
Statistical Error
10000
100000
1000000
8
9
10
0.000319
0.001
0.0038
0.00028
0.00012
0.000082
Rajarshi Sarkar
(UNSA - INRIA)
8
9
10
0.000298
0.000989
0.00372
0.00032
0.00023
0.000076
August 2012
68 / 71
Outline
1
Introduction
Euler Scheme
Fast Algorithm
Application - Finance
Conclusion
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
69 / 71
Conclusion
It is true that we know how the probability density function for the case of an
Ornstein-Uhlenbeck process looks like, however the expression is quite
cumbersome and long.
Thus, we need to look for ways to numerically simulate such a random event
We see that the probabilistic dichotomic fast algorithm, indeed does provide
much faster results as compared to Euler scheme.
We see, that when applicable the Exact simulation algorithm returns very
nice results for the first-passage time.
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
70 / 71
THANK YOU
Rajarshi Sarkar
(UNSA - INRIA)
August 2012
71 / 71