Lectures on Coupling (Exercises)
EPSRC/RSS GTP course, September 2005
Wilfrid Kendall w.s.kendall@warwick.ac.uk
Department of Statistics, University of Warwick
12th–16th September 2005
Exercises
“You are old,” said the youth, “and your programs don’t run,
And there isn’t one language you like;
Yet of useful suggestions for help you have none –
Have you thought about taking a hike?”
“Since I never write programs,” his father replied,
“Every language looks equally bad;
Yet the people keep paying to read all my books
And don’t realize that they’ve been had.”
“You are old,” said the youth, “and your programs don’t run,
And there isn’t one language you like;
Yet of useful suggestions for help you have none –
Have you thought about taking a hike?”
“Since I never write programs,” his father replied,
“Every language looks equally bad;
Yet the people keep paying to read all my books
And don’t realize that they’ve been had.”
I do hate sums. There is no greater mistake than to call arithmetic an exact science. There are permutations and aberrations discernible to minds entirely noble like mine; subtle variations which ordinary accountants fail to discover; hidden laws of number which it requires a mind like mine to perceive.
For instance, if you add a sum from the bottom up, and then again from the top down, the result is always different.
— Mrs. La Touche (19th cent.)
“ . . . I told my doctor I got all the exercise I needed being a pallbearer for all my friends who run and do exercises!”
— Winston Churchill
Summary
This is the online version of exercises for the
GTP Lectures on Coupling .
These exercises are meant to be suggestive rather than exhaustive: try to play around with the basic ideas given here!
Any errors are entirely intentional: their correction is part of the exercise.
Many exercises suggest calculations to be carried out in R ; with appropriate modifications one could use any one of Splus ,
APL or J , Mathematica , or Python . . . .
Introduction
“You are old,” said the youth, “as I mentioned before,
And make errors few people could bear;
You complain about everyone’s English but yours –
Do you really think this is quite fair?”
Exercise on Riffle Card Shuffle
Exercise on Doeblin coupling (I)
Exercise on Doeblin coupling (II)
Exercise on Doeblin coupling (III)
“I make lots of mistakes,” Father William declared,
“But my stature these days is so great
That no critic can hurt me – I’ve got them all scared,
And to stop me it’s now far too late.”
Introduction
“You are old,” said the youth, “as I mentioned before,
And make errors few people could bear;
You complain about everyone’s English but yours –
Do you really think this is quite fair?”
“I make lots of mistakes,” Father William declared,
“But my stature these days is so great
That no critic can hurt me – I’ve got them all scared,
And to stop me it’s now far too late.”
Exercise on Riffle Card Shuffle
Exercise on Doeblin coupling (I)
Exercise on Doeblin coupling (II)
Exercise on Doeblin coupling (III)
Exercise 1.1 on Top Card shuffle: I
Show that mean time to equilibrium for the Top Card Shuffle is order of n log ( n ) .
LECTURE
Exercise 1.2 on Riffle Card Shuffle: I
Use coupling to argue that the “probability of not yet being in equilibrium” after k riffle shuffles is greater than
1
1 − 1 × 1 −
2 k
× 1 −
2
2 k
× . . .
× 1 − n − 1
2 k
.
Compare log coupling probability to R log ( 1 − 2
− k x ) d x to deduce one needs about 2 log
2
n riffle shuffles . . .
Use R to find the median number of riffle shuffles required for a pack of 52 cards. (Outer products are useful here!)
LECTURE
Exercise 1.3 on Doeblin coupling (I): I
An example of Doeblin’s coupling for Markov chains: consider the utterly simple chain with transition matrix and equilibrium distribution
P =
0 .
9 0 .
1
0 .
1 0 .
9
; π =
1
2
1
2
.
Use R to compare convergence to equilibrium against coupling time distribution.
LECTURE
Exercise 1.4 on Doeblin coupling (II): I
Repeat the previous exercise but with a more interesting
Markov chain! Try for example the chain given by symmetric simple random walk on { 1 , 2 , 3 , 4 , 5 } and (because of periodicity!) compare walks begun at 1 and 5. Take account of the barriers at 1, 5 by replacing all transitions 1 → 0 by 1 → 1, and 5 → 6 by 5 → 5 (these are reflecting boundary conditions preserving reversibility!).
Since the coupling time distribution is less easy to calculate explicitly, approximate it by the time taken for the random walk to move from 1 to 5 (the Doeblin coupling certainly must have occurred by the time that happens!).
LECTURE
Exercise 1.5 on Doeblin coupling (III): I
Obtain better bounds by analyzing the derived Markov chain which represents the Doeblin coupling as a new Markov chain
X , e random walk. You will need to write an R function which takes the transition matrix of the original chain and returns the transition matrix of the Doeblin coupling chain. Then use this new transition matrix to compute the probability that the Doeblin coupling chain has hit (and therefore stays in!) the region
X = e
LECTURE
“I don’t think so,” said Rene Descartes. Just then, he vanished.
Coupling and Monotonicity
There has been an alarming increase in the number of things we know nothing about.
Exercise on Binomial monotonicity
Exercise on Epidemic comparison
Exercise 2.1 on Binomial monotonicity: I
(Elementary!) Consider the following R script, which generates a Binomial(100,p) random variable X as a function of p, using
100 independent Uniform ( 0 , 1 ) random variables stored in randomness . Use R to check
(a) monotonic dependence on p;
(b) correct distribution of X for fixed p.
LECTURE
Exercise 2.2 on Percolation: I
Suppose a rectangular array of nodes ( i , j ) defines a rectangular network through which fluid may flow freely, except that each node n ij independently is blocked (n ij probability 1 − p (otherwise n ij
=
= 0) with
1). Consider the percolation
probability of fluid being able to flow from the left-hand side to the right-hand side of the network.
(a) Show that this probability is an increasing function of p,
(b) and write a R script to simulate the extent of percolation, as a preliminary to estimation of the dependence of the percolation probability on the value of p.
LECTURE
Exercise 2.3 on Epidemic comparison: I
Verify that censoring reduces number of eventual removals in the coupling proof of Whittle’s Theorem.
(The coupling approach can be used to extend Whittle’s theorem, for example to case where duration of infectious interval is not exponentially distributed . . . )
LECTURE
Exercise 2.4 on FKG inequality: I
Use coupled Markov chains Y , e by
I observing that the joint distribution of Y
1
, Y
2
, . . . , Y n is the equilibrium distribution of a reversible Markov chain
“switching” values of the Y i independently,
I and exploiting the way in which conditioning the equilibrium distribution on a certain set B corresponds to restricting the
Markov chain to lie in B only.
If you examine the proof, you should be able to formulate an extension to case where the Y i
“interact attractively”.
LECTURE
Exercise 2.5 on FK representation: I
Recall the FK random cluster representation of the Ising model.
Consider the conditional distribution of sign S i of site i, given bond and sign configuration everywhere except at i and v bonds connecting i to the rest of the graph. Show
P
[ S i
= + 1 | . . .
] ∝ ( 1 − p ) v − x
( 1 − ( 1 − p ) x
) + ( 1 − p ) v
×
1
2
× 2 , where x is the number of neighbours of i with spin + 1, and deduce that the construction of the FK-representation at least has the correct one-point conditional probabilities.
Probability models (on a finite set of “sites”), whose one-point conditional probabilities agree and are positive, must be equal.
Proof: Gibbs’ sampler for regular Markov chains!
LECTURE
With every passing hour our solar system comes forty-three thousand miles closer to the globular cluster M13 in the constellation Hercules, and still there are some misfits who continue to insist that there is no such thing as progress.
— Ransom K. Ferm
Representation
Somewhere, something incredible is waiting to be known.
– Carl Sagan
Exercise on Lindley equation (I)
Exercise on Lindley equation (II)
Exercise on Strassen’s theorem (I)
Exercise on Strassen’s theorem (II)
Exercise on Strassen’s theorem (III)
Exercise 3.1 on Lindley equation (I): I
In the notation of Lindley’s equation, suppose Var [ η i
] < ∞ .
Show W
∞ will be finite only if
E
[ η i
] < 0 or η i
≡ 0.
We don’t need Var [ η i
] < ∞ for the above to be true . . .
LECTURE
Exercise 3.2 on Lindley equation (II): I
Use R to check out Lindley’s equation for the case where the η i are differences
η n
= S n
− X n + 1
= Uniform ( 0 , 1 ) − Uniform ( 0 , compare the long-run distribution of the chain
1 .
5 ) : you need to
W n + 1
= max max { 0 , η
1
, η
1
{ 0
+
,
η
W
2 n
+ η
, . . . , η n
1
} with the distribution of the supremum
+ η
2
+ . . .
+ η m
, . . .
} .
LECTURE
Exercise 3.3 on Loynes’s coupling: I
Use R to carry out Loynes’ construction for a queue with independent Exponential(3) service times and independent
Uniform ( 0 , 1 ) inter-arrival times. (Simplify matters by considering only the times at which services finish; this allows you to use the waiting time representation employed in the previous exercise!) Adjust the service and inter-arrival time parameters to get a good picture.
1
Repeat the simulation several times to get a feel for the construction — and its limitations! Notice that you can never be
sure that you have started far enough back for all subsequent runs to deliver the same result by time zero!
LECTURE
1 But keep the queue sub-critical:
mean service time should be less than mean inter-arrival time!
Exercise 3.4 on Strassen’s theorem (I): I
Consider two planar probability distributions
(a) P placing probability mass 1 / 4 on each of ( 1 , 1 ) , ( 1 , − 1 ) ,
( − 1 , 1 ) , ( − 1 , − 1 ) ;
(b) Q placing probability mass 1 / 5 on each of ( 1 .
1 , 1 ) ,
( 1 , − 1 .
1 ) , ( − 1 .
1 , 1 ) , ( − 1 , − 1 .
1 ) and ( 100 , 100 ) .
Suppose you want to construct a close-coupling of P and Q: random variables X with distribution P, Y with distribution Q, to minimize the probability
P
[ | X − Y | > 0 .
11 ] . Show how to use
Strassen’s theorem to find out what is the smallest such probability.
LECTURE
Exercise 3.5 on Strassen’s theorem (II): I
Repeat the above exercise but reversing the r ˆoles of P and Q.
LECTURE
Exercise 3.6 on Strassen’s theorem (III): I
Show that the condition of Strassen’s theorem is symmetric in
P and Q when ε
0
= ε , by applying the theorem itself!
LECTURE
Exercise 3.7 on Small sets: I
Work out the details of the procedure at the head of the section on split chains (compute α , compute the three densities used for random draws) when P is Uniform ( x − 1 , x + 1 ) and Q is
Uniform ( − 1 , + 1 ) .
LECTURE
Remember to never split an infinitive.
Approximation using coupling
In Riemann, Hilbert or in Banach space
Let superscripts and subscripts go their ways.
Our asymptotes no longer out of phase,
We shall encounter, counting, face to face.
– Stanislaw Lem, ”Cyberiad”
Exercise on Central Limit Theorem
Exercise 4.1 on Skorokhod (I): I
Employ the method indicated in the section on the Skorokhod representation to convert the following sequence of distributions into an almost surely convergent sequence and so identify the limit: the n th distribution is a scaled Geometric distribution with probability mass function
P
[ X n
= k / n ] = e
− ( k − 1 ) / n
1 − e
− 1 / n for k = 1, 2, . . . .
LECTURE
Exercise 4.2 on Skorokhod (II): I
Using the representation of the previous exercise, show that the limit distribution of G n is Gamma ( 1 , r ) , where G n is a scaled hypergeometric distribution with probability mass function
P
[ Y n
= k / n ] = k r e
− ( k − r ) / n
1 − e
− 1 / n r for k = r , r + 1, . . . .
LECTURE
Exercise 4.3 on Central Limit Theorem: I
In this exercise we see how to represent a zero-mean random variable X of finite variance as X = B ( T ) .
1.
Begin with the case when X has a two-point distribution, supported on {− a , b } where − a < 0 < b. Deduce the probabilities
P
[ X = − a ] ,
P
[ X = b ] from
E
[ X ] = 0. Use the fact that B is a martingale (so that
E
[ B
T
] = 0 whenever T is a stopping time such that B |
[ 0 , T ]
B
T is bounded) to deduce has the distribution of X if T is the time at which B first hits {− a , b } .
2.
Hence find a randomized stopping time T such that B
T is distributed as X when this distribution is symmetric about zero.
Exercise 4.3 on Central Limit Theorem: II
3.
(Harder: taken from
§ 13.3 Problem 2)
Suppose for simplicity X has probability density f .
Compute the joint density of x , y if x is drawn from distribution of X and y is then drawn from size-biased distribution of X conditioned to have opposite sign from x : density proportional to | y | f ( y ) if xy < 0.
4.
Hence show that B
T has the distribution of X if T is the randomized stopping time at which B first hits { x , y } , where x , y are constructed as above.
LECTURE
Exercise 4.4 on Stein-Chen (I): I
Here are a sequence of exercises to check the details of
Stein-Chen approximation.
Check the formula for g ( n + 1 ) solves the relevant equation.
LECTURE
Exercise 4.5 on Stein-Chen (II): I
Show that g ( n + 1 ) ×
P h f
= n + 1 i
=
P h f
∈ A , f
< n + 1 i
P h f
≥ n + 1 i
−
P n + 1 h f
∈ A , f
≥ n + 1 i
P h f
< n + 1 i n + 1
LECTURE
Exercise 4.6 on Stein-Chen (III): I
Use the Stein Estimating Equation to establish
| g ( n + 1 ) − g ( n ) | ≤
1 − e
− λ
λ for all n
In an obvious notation, g ( n + 1 ) = P j ∈ A g j
( n + 1 ) .
1.
First of all use the results of an earlier exercise to deduce g j
( n + 1 ) is negative when j ≥ n + 1, otherwise positive.
2.
Now show if j < n + 1 then g j
( n + 1 ) is decreasing in n.
3.
Hence (apply a previous exercise twice) show g j
( n + 1 ) − g j
( n ) ≤ g j
( j + 1 ) − g j
( j ) ≤ min {
1
, j
1 − e
− λ
} .
λ
LECTURE
Exercise 4.7 on Stein-Chen (IV): I
Use Stein-Chen to approximate W = P i
I i binary I i with
P
[ I i
= 1 ] = p i
.
for independent
LECTURE
Exercise 4.8 on Stein-Chen (V): I
Try out the result of the previous exercise in R using 100 independent binary random variables, half of which have mean
0 .
01, half of which have mean 0 .
02. Use simulation to estimate the difference between (a) the sum of these 100 random variables being even, and (b) a comparable Poisson random variable being even.
LECTURE
Mixing of Markov chains
Your analyst has you mixed up with another patient.
Don’t believe a thing he tells you.
Exercise on Coupling Inequality
Exercise on Strong stationary times (I)
Exercise on Strong stationary times (I)
Exercise 5.1 on Coupling Inequality: I
Prove the Coupling Inequality, dist tv
( L ( X n
) , π ) ≤ max y
{
P
T x , y
> n } , where dist tv
( L ( X n
) , π ) =
1
X
2 j
P
[ X n
= j ] − π j
, and π is the equilibrium distribution of the chain X , and T x , y is the random time under some coupling at which coupling occurs for the chains started at x and y .
LECTURE
Exercise 5.2 on Mixing (I): I
Deduce from coupling inequality that mixing in the mixing example occurs before time n log ( n ) / 2 for large n.
LECTURE
Exercise 5.3 on Slice (I): I
Implement a slice sampler in R for the standard normal density.
LECTURE
Exercise 5.4 on Strong stationary times (I): I
Verify the inductive claim, given number of checked cards, positions in pack of checked cards, list of values of cards; the map of checked card to value is uniformly random.
LECTURE
Exercise 5.5 on Strong stationary times (I): I
Verify
E
[ T ] ≈ 2n log n as suggested in the section.
LECTURE
The Coupling Zoo
Did you hear that two rabbits escaped from the zoo and so far they have only recaptured 116 of them?
Exercise 6.1 on The zoo (I): I
Define synchronized and reflection couplings ( X , Y ) for reflecting symmetric random walk on { 1 , 2 , 3 , 4 , 5 } . (Suppose X and Y start from extreme ends of the state-space.) Conduct simulations in R to compare coupling times.
LECTURE
Exercise 6.2 on The zoo (II): I
The Ornstein coupling can be used to build a non-adapted coupling for Markov chains, by coupling times of excursions from a fixed state. Suppose X is an aperiodic Markov chain on a finite state space which always returns with probability 1 to a reference state x . Suppose you know how to simulate a random excursion as follows:
I draw the time-length N of the excursion;
I conditional on N
. . . , X n − 1
= x n − 1
= n, draw the excursion X
0
, X n
= x where none of the x
= x , X
1 i
= equal x .
x
1
,
Show how to use Ornstein coupling to couple X begun at x and
Y begun at y = x .
LECTURE
Exercise 6.3 on The zoo (III): I
By definition a function f ( X t
, t ) is space-time harmonic if f ( X t
, t ) =
E
[ f ( X t + 1
, t + 1 ) | X t
, X t − 1
, . . .
] .
Suppose f ( X t
, t ) is bounded space-time harmonic; by scaling and adding constants we can assume 0 ≤ f ( X t
, t ) ≤ 1. By considering the expectation of f ( X t
, t ) − f ( Y t
, t ) , show that all couplings X , Y succeed only if all bounded space-time harmonic functions are constant.
(This is half of the relationship between space-time harmonic functions and successful couplings. The other half is harder . . . )
LECTURE
“Why be a man when you can be a success?”
— Bertold Brecht
Perfection (CFTP I)
People often find it easier to be a result of the past than a cause of the future.
Exercise 7.1 on CFTP (I): I
The following exercises examine the consequences of failing to follow the details of the CFTP algorithm.
Use R to demonstrate that CFTP applied to the simple reflecting random walk on { 1 , 2 , 3 , 4 } (reflection as specified in the previous exercise
) delivers the correct uniform
distribution on { 1 , 2 , 3 , 4 } .
LECTURE
Exercise 7.2 on CFTP (II): I
Use R to check that the forwards version of CFTP (continue forwards in time by adding more blocks of innovations, stop when you get coalescence!) does not return the equilibrium distribution for the reflecting random walk of the previous exercise.
LECTURE
Exercise 7.3 on CFTP (III): I
Use R to check that the failure to re-use randomness where applicable will mean CFTP does not return a draw from the equilibrium distribution. (Use the reflecting random walk of the previous exercises).
LECTURE
Exercise 7.4 on CFTP (IV): I
Modify your R implementation to give true CFTP (extending innovation run backwards in time if coalescence fails).
LECTURE
Exercise 7.5 on CFTP (V): I
Modify your R implementation to deal with a general aperiodic irreducible finite state-space Markov chain. The chain should be specified by a random map. You will have to check coalescence the hard way, by looking at outputs arising from all inputs! (So this implementation will be practicable only for small state space . . . )
LECTURE
Exercise 7.6 on Falling Leaves: I
Consider the falling leaves example of “occlusion-CFTP”. Work out a (coupling) argument to show that the “forward-time” algorithm exhibits bias in general.
HINT: suppose that the leaves are of variable size, and the largest possible leaf (“super-leaf”) can cover the window completely.
LECTURE
There’s no future in time travel
“I have seen the future and it is just like the present, only longer.”
— Kehlog Albran, “The Profit”
Exercise 8.1 on Small set CFTP: I
Suppose we carry out Small-set CFTP using the triangular kernel p ( x , y ) described in the relevant section. Show that the equilibrium density can be written in the form
π ( x ) =
∞
X
2
− n + 1
Z
1
0 n = 0 r
( n )
( u , x ) p (
1
2
, u ) d u where r ( n )
( u , x ) is the n-fold convolution integral r
( n )
( u , x ) =
Z
1
0 r ( u , a
1
) . . .
Z
1
0 r ( a n
, y ) d a n
. . .
d a
1 of the “residual kernel” r ( x , y ) = 2p ( x , y ) − p ( 1 / 2 , y ) .
HINT: show the time till coalescence has a Geometric distribution!
LECTURE
Perfection (FMMR)
The Modelski Chain Rule:
1.
Look intently at the problem for several minutes.
Scratch your head at 20-30 second intervals. Try solving the problem on your Hewlett-Packard.
2.
Failing this, look around at the class. Select a particularly bright-looking individual.
3.
Procure a large chain.
4.
Walk over to the selected student and threaten to beat him severely with the chain unless he gives you the answer to the problem. Generally, he will. It may also be a good idea to give him a sound thrashing anyway, just to show you mean business.
Exercise 9.1 on Siegmund (I): I
Prove the construction of the Siegmund dual Y really does require Y to be absorbed at 0.
LECTURE
Exercise 9.2 on Siegmund (II): I
Carry out the exercise from lectures: show that the Siegmund dual of simple symmetric random walk X on the non-negative integers, reflected at 0, is simple symmetric random walk Y on the non-negative integers, absorbed at 0.
What happens if the simple random walk X is not symmetric?
LECTURE
Sundry further topics in CFTP
A conclusion is simply the place where someone got tired of thinking.
Exercise on Realizable monotonicity
Exercise 10.1 on Realizable monotonicity: I
When designing multishift couplings, be aware that difficulties can arise which are related to issues of realizable monotonicity
( Fill and Machida 2001 ). For example (based on Kendall and
§ 5.4), suppose a gambler agrees to a complicated bet: There will be presented some non-empty subset of n horses, and the gambler must bet on one. However the choice must be made ahead of time (so for each possible subset
{ i
1
, . . . , i k
} the gambler must commit to a choice i r k
). Moreover the choices must be coupled: if i r k is chosen in { i
1
, . . . , i it must be chosen in any sub-subset which contains i r k
.
k
} then
It is not possible to do this so that all choices are distributed uniformly over their respective subsets. Show this to be true for the case n = 3.
LECTURE
Answers to exercises in Introduction
Answers to exercises in Introduction
Answer to Exercise on Top Card Shuffle
Answer to Exercise on Riffle Card Shuffle
Answer to Exercise on Doeblin coupling (I)
Answer to Exercise on Doeblin coupling (II)
Answer to Exercise on Doeblin coupling (III)
Answer to Exercise
on Top Card Shuffle: I
LECTURE
Look at successive times T
1
, T
2
, . . . when a card is placed below the original bottom card. Time T k
− T k − 1 is Geometric with success probability k / n, hence
E
[ T k
− T k − 1
] = n / k . Now use n
X
1
≈ log ( n ) .
k
1
So for n = 52 we expect to need about 205 shuffles.
LECTURE
Answer to Exercise
on Riffle Card Shuffle: I
LECTURE
By the coupling argument of the HINT, the effect of k riffle shuffles is to assign a random binary sequence of length k to each card. The chance that each card receives a different binary is the chance of placing n objects in different locations, if each object is placed independently at random in one of 2 k locations. This gives the result. For
P
[ “being in equilibrium” ]
≤
P h
n objects in 2 k different locations i
≤
P
[ choose first arbitrarily, second different from first, . . .
]
=
2 k
2 k
× 1 −
1
2 k
× 1 −
2
2 k
× . . .
× 1 − n − 1
2 k
.
Notice k > log
2
n for a positive lower bound!
Answer to Exercise
on Riffle Card Shuffle: II
Log coupling probability is approximately
Z n
0 x log 1 −
2 k d x =
= 2 k
" n
1 −
2 k
∼
2 k
Z
1
1 − n2
− k log ( u ) d u
#
1 log
1 − n
2 k
− n 2
− k
. . .
= − n
2
2
− k getting close to 1 as k increases past 2 log
2
n. This is a cut-off phenomenon. See
§ 4D) for (a lot) more on this.
(Sample R code on next page.)
LECTURE
R code for Exercise
The R calculation can be carried out as below.
n <- 52 t <- 20 cc <- array((1:n) - 1) k <- array(1:t) plot(1-apply(1-(cc %o% (1/(2ˆk))),2,prod))
Answer to Exercise
on Doeblin coupling (I): I
LECTURE
Convergence to equilibrium is obtained using matrix algebra as in the following R example. The coupling time distribution is easy to calculate in this symmetric case: there is a chance 1 / 2 of immediate coupling, and a chance
1 / 2 × ( 0 .
9
2
+ 0 .
1
2
) k − 1
× ( 2 × 0 .
9 × 0 .
1 ) of coupling at time k > 0. Notice that the coupling time distribution doesn’t match the convergence rate exactly (most easily seen by taking logs as in the R example).
(Sample R code on next page.)
LECTURE
R code for Exercise
n <- 20 p <- matrix(c(0.9,0.1, 0.1,0.9),2,2) pp <- matrix(c(1,0, 0,1),2,2) r <- numeric(n) for (i in 1:n) pp <- pp%*%p r[i] <- pp[1,1] plot(r-0.5,type="b") s <- 0.5*((0.9ˆ2+0.1ˆ2)ˆ(0:(n-1)))*(2*0.9*0.1) s <- 1-cumsum(append(0.5,s)) points(s,pch=19) plot(-log(r-0.5),type="b") points(-log(s),pch=19)
Answer to Exercise
on Doeblin coupling (II): I
LECTURE
Convergence to equilibrium is obtained using matrix algebra; note that the equilibrium distribution is reversibility.
π i
= 0 .
2 for all i, by
(Sample R code on next pages.)
LECTURE
R code for Exercise
n <- 40 p <- matrix(c(0.5,0.5,0,0,0,
0.5,0 ,0.5,0,0,
0, 0.5,0 ,0.5,0,
0, 0, 0.5,0, 0.5,
0, 0, 0, 0.5,0.5),5,5) pp <- matrix(c(1,0,0,0,0, 0,1,0,0,0, 0,0,1,0,0,
0,0,0,1,0, 0,0,0,0,1),5,5) r <- numeric(n) for (i in 1:n) pp <- pp%*%p r[i] <- pp[1,1] plot(r-0.2,type="b")
R code for Exercise
ctd.
Calculate approximation to coupling time distribution by modifying the transition matrix to stop the chain once it reaches state 5 p <- matrix(c(0.5,0.5,0,0,0,
0.5,0, 0.5,0, 0,
0, 0.5,0, 0.5,0,
0, 0, 0.5,0, 0.0,
0, 0, 0, 0.5,1.0),5,5) pp <- matrix(c(1,0,0,0,0, 0,1,0,0,0, 0,0,1,0,0,
0,0,0,1,0, 0,0,0,0,1),5,5) r <- numeric(n+1) r[1] <- 0 for (i in 1:n) pp <- pp%*%p r[i+1] <- pp[1,5] points(1-r,pch=19)
Answer to Exercise
on Doeblin coupling (III): I
LECTURE
Exercise in manipulating matrices in R !
LECTURE
Answers to exercises in Coupling and Monotonicity
Answers to exercises in Coupling and Monotonicity
Answer to Exercise on Binomial monotonicity
Answer to Exercise on Percolation
Answer to Exercise on Epidemic comparison
Answer to Exercise on FKG inequality
Answer to Exercise on FK representation
Answer to Exercise
on Binomial monotonicity: I
LECTURE
(a) Try plot(sapply(seq(0,1,by=0.05),bin)) .
(b) Simple approach: try a QQ-plot (but bear in mind the implicit normal approximation).
(c) More sophisticated: use a chi-square test.
(Sample R code on next page.)
LECTURE
R code for Exercise
randomness <- runif(100) bin <- function(p) sum(ceiling(randomness-(1-p))) p <- 0.4
y <- bin(p) for (i in 2:1000) randomness <- runif(100) y[i] <- bin(p) qqnorm(y) qqline(y) range=min(y):(max(y)-1) d=table(y) pmf <- dbinom(range,100,p)/sum(dbinom(range,100,p)) chisq.test(d,p=pmf,simulate.p.value=TRUE,B=2000)
Answer to Exercise
on Percolation: I
LECTURE
(a) Follows from coupling in the Exercise on Binomial monotonicity: replace total number of unblocked nodes by network function f ( { n ij
} ) , indicating whether fluid can flow from left to right. If [ n ij
= 1 ] = [ Z ij
≤ p ] then f (so
E
[ f ] ) is increasing function of n ij
, thus of p.
(b) The following computes t , the extent of fluid flow. Use this in a function replacing bin in the Exercise on Binomial monotonicity above, for (slow) estimation of the required percolation probability . . .
(Sample R code on next page.)
LECTURE
R code for Exercise
free <- matrix(ceiling(randomness-(1-p)),10,10) t0 <- matrix(0,10,10) tn <- cbind(1,matrix(0,10,9)) while(!identical(t0,tn)) t0 <- tn tr <- cbind(1,t0[1:10,1:9])*free tl <- cbind(t0[1:10,1:9],0)*free tu <- rbind(0,t0[1:9,1:10])*free td <- rbind(t0[1:9,1:10],0)*free tn <- pmax(t0,tl,tr,tu,td)
Answer to Exercise
on Epidemic comparison: I
LECTURE
Look at times at which individuals get infected:
H i epi
H i bd
=
= time of infection of i in epidemic , time of infection of i in birth-death process.
Result follows if H i epi
≥ H i bd for all i; true for i = 1, . . . , i
Induction: suppose true for i = 1, . . . , j − 1. Set
0
.
M epi j − 1
( t ) = number directly infected by 1 , . . . , j − 1 in epidemic by t
(include original infectives) ,
M bd j − 1
( t ) = number directly infected by 1 , . . . , j − 1 in birth-death process by t
(include original infectives) .
Answer to Exercise
on Epidemic comparison: II
Then M epi j − 1
( t ) ≤ M bd j − 1
( t ) for all t, since by induction H i epi
≥ for all i < j and future birth-death infections by such i must
H i bd include future epidemic infections for i. Thus at any t the first j − 1 individuals infect more in birth-death process than in epidemic. So:
H j epi
= inf { t : M epi j − 1
( t ) = j } , H j bd
= inf { t : M bd j − 1
( t ) = j } .
Hence H j epi
≥ H j bd
.
LECTURE
Answer to Exercise
on FKG inequality: I
LECTURE
The Markov chain Y acts independently on each of the y i
: switching
( Y i
( Y i
= 1 ) → ( Y
= 0 ) → ( Y i i
= 1 ) at rate p i
/ ( 1 − p i
) , and
= 0 ) at rate 1. Use detailed balance to check:
π [ Y i
= 0 ] × p i
1 − p i
= π [ Y i
= 1 ] × 1 .
In notation of the FKG inequality Theorem, consider a second
Markov chain e increasing event B:
I initially choose e
( 0 ) to lie in B but to dominate Y ( 0 ) componentwise (eg: set all coordinates of e
( 0 ) equal to 1).
I Y evolves by using the same jumps as Y at coordinates y i where they are equal, so long as the jump does not lead to a violation of the constraint e
∈ B;
Answer to Exercise
on FKG inequality: II
I at coordinates y i transition ( e i where
= 1 ) → ( e i e
= 0 )
Y to a at rate 1 so long as the jump does not lead to a violation of the constraint e
∈ B;
I if B is an increasing event then the above rules never lead to domination of e
Then e equilibrium (NB: regularity of Markov chain e being increasing!) we deduce
P
[ A | B ] = lim t →∞
P h e
∈ A i
≥ lim t →∞
P
[ Y ∈ A ] =
P
[ A ] .
LECTURE
Answer to Exercise
on FK representation: I
LECTURE
We condition on the random graph obtained from the random cluster model by deleting i and connecting bonds. Then
P
[ S i
= + 1 | . . .
] =
P
[ connects to some + 1 nbr , doesn’t connect to any − 1 nbr | . . .
] +
+
P
[ doesn’t connect to any nbr at all , assigned + 1 | . . .
]
∝ ( 1 − p ) v − x
( 1 − ( 1 − p ) x
) + ( 1 − p ) v
×
∝ ( 1 − p ) v − x
∝
1
2
× 2
1
( 1 − p ) x
.
Answer to Exercise
on FK representation: II
Notice (a) not connecting to neighbours will increase component count by 1, leading to factor 2 which cancels with probability 1 / 2 of assigning + 1; (b) the factor ( 1 − p ) v is a constant depending on i, so can be absorbed into constant of proportionality.
Answer to Exercise
on FK representation: III
Now compare similar calculation for Ising model:
P
[ S i
= + 1 | . . .
] ∝ exp
1
β
2
X
j nbr i
S j
= exp β #( nbrs assigned spin +) −
1
2
β v .
Hence agreement if 1 − p = e
− β .
LECTURE
Answers to exercises in Representation
Answers to exercises in Representation
Answer to Exercise on Lindley equation (I)
Answer to Exercise on Lindley equation (II)
Answer to Exercise on Loynes’s coupling
Answer to Exercise on Strassen’s theorem (I)
Answer to Exercise on Strassen’s theorem (II)
Answer to Exercise on Strassen’s theorem (III)
Answer to Exercise on Small sets
Answer to Exercise
on Lindley equation (I): I
LECTURE
Clearly W
∞
≡ 0 if η i
≡
(SLLN) states, if
E
[ | η i
0. The strong law of large numbers
| ] < ∞ then
η
1
+ . . .
+ η n n
→
E
[ η i
] almost surely.
So if
E
[ η i
] < 0 then η
1
+ . . .
+ η n
< 0 for all large enough n, so
W
∞ is finite. On the other hand if
E
[ η i
] > 0 then
η
1
+ . . .
+ η n
→ ∞ and so W
∞ is infinite.
Answer to Exercise
on Lindley equation (I): II
In the critical case
E
[ η i
] = 0 we can apply the Central Limit
Theorem (CLT): make adroit use of
P h
η m
+ . . .
+ η m + n
> n
1 / 2 i
> ( 1 − ε )
1
√
2 πσ 2
Z
∞
1 u
2 exp −
2 σ 2
(for all large enough n) to show η
1 large positive values for large n.
+ . . .
+ η n takes on arbitrarily d u
LECTURE
Answer to Exercise
on Lindley equation (II): I
LECTURE
First consider empirical distribution of N replicates of max { 0 , η
1
, η
1
+ η
2
, . . . , η
1
+ η
2
+ . . .
+ η n
} for adequately large n.
Now compare to evolution of W n + 1
= max { 0 , W n
+ η n
} .
(Some experimentation required with values of n, m to get good enough accuracy to see the fit!)
(Sample R code on next page.)
LECTURE
R code for Exercise
N <- 10000 n <- 300 z <- numeric(N+1) for (i in 1:N) z[i+1] <- max(0, cumsum(runif(n,0,1)-runif(n,0,1.5))) plot(density(z)) y <- numeric(N+1) eta <- runif(N,0,1)-runif(N,0,1.5) for (i in 1:N) y[i+1] <- max(0,y[i]+eta[i]) lines(density(y),col=2) ks.test(z,y)
Answer to Exercise
on Loynes’s coupling: I
LECTURE
Construct a long run of innovations
(waiting time − interarrival time), and simulate a queue run from empty at times − T for T = 2, 4, 8, . . . .
(Sample R code on next page.)
LECTURE
R code for Exercise
lnN <- 6
N <- 2ˆlnN eta <- rexp(N,3)-runif(N,0,1) plot((-1:0), xlim=N*(-1:0), ylim=6*(0:1)) for (c in 1:lnN)
Time <- 2ˆc y=rep(0,Time+1) for (t in (2:Time+1)) y[t] <- max(0,y[t-1]+eta[N-Time+t-1]) lines(cbind((-Time:0),y),col=c)
Answer to Exercise
on Strassen’s theorem (I): I
LECTURE
Strassen’s theorem tells us to compute sup
B
( P ( B ) − Q [ x : dist ( x , B ) < 0 .
11 ]) = 4 ×
1
4
−
1
5
(Use B = { ( 1 , 1 ) , ( 1 , − 1 ) , ( − 1 , 1 ) , ( − 1 , − 1 ) } .)
=
1
5
.
LECTURE
Answer to Exercise
on Strassen’s theorem (II): I
LECTURE
Now calculate sup
B
( Q ( B ) − P [ x : dist ( x , B ) < 0 .
11 ]) =
1
5
.
(Use B = { ( 100 , 100 ) } .)
LECTURE
Answer to Exercise
on Strassen’s theorem (III): I
LECTURE
Suppose for all B
P [ B ] ≤ Q [ x : dist ( x , B ) < ε ] + ε .
Then by Strassen’s theorem we know there are X -valued random variables X , Y with distributions P, Q and such that
P
[ dist ( X , Y ) > ε ] ≤ ε .
But this clearly is symmetric in X and Y , so apply Strassen’s theorem again but exchanging r ˆoles of P and Q to deduce for all B
Q [ B ] ≤ P [ x : dist ( x , B ) < ε ] + ε .
LECTURE
Answer to Exercise
on Small sets: I
LECTURE
By direct computation,
α =
(
1 − | x | / 2 when | x | ≤ 2 ,
0 otherwise.
The f ∧ g density is undefined if | x | > 2, and is
Uniform ( x − 1 , 1 ) if x > 0, otherwise Uniform ( 1 , 1 + x ) . The other two densities are
I Uniform ( x − 1 , x + 1 ) , Uniform ( − 1 , + 1 ) if | x | > 2,
I or Uniform ( − 1 , x − 1 ) , Uniform (+ 1 , + 1 + x ) if 2 > x ≥ 0,
I or Uniform ( x − 1 , − 1 ) , Uniform (+ 1 + x , + 1 ) if − 2 < x < 0.
LECTURE
Answers to exercises in Approximation using coupling
Answers to exercises in Approximation using coupling
Answer to Exercise on Skorokhod (I)
Answer to Exercise on Skorokhod (II)
Answer to Exercise on Central Limit Theorem
Answer to Exercise on Stein-Chen (I)
Answer to Exercise on Stein-Chen (II)
Answer to Exercise on Stein-Chen (III)
Answer to Exercise on Stein-Chen (IV)
Answer to Exercise on Stein-Chen (V)
Answer to Exercise
on Skorokhod (I): I
LECTURE
The n th distribution function is
F n
( k / n ) =
P
[ X ≤ k / n ] = 1 − e
− k / n for k = 0, 1, 2, . . . , with appropriate interpolation.
Thus the Skorokhod representation F
− 1 n
( U ) can be viewed as follows: discretize 1 − U to values 0, 1 / n , 2 / n, . . . , 1 − 1 / n.
Then take the negative logarithm.
It follows, X n
= F
− 1 n
( U ) → − log ( 1 − U ) almost surely (in fact
surely!) and so the limit is the Exponential distribution of rate 1.
LECTURE
Answer to Exercise
on Skorokhod (II): I
LECTURE
Easiest approach is to identify G n as the sum of r independent random variables each of distribution F n
. Hence we may represent Y n
X n , j
= F
− 1 n
( U j
= X n , 1
+ X n , 2
+ . . .
) → − log ( 1 − U j
)
+ X n , r
, where
. Hence Y n converges to the sum of r independent Exponential random variables of rate 1, hence the result.
LECTURE
Answer to Exercise
on Central Limit Theorem: I
P
[ B
T
= | X | ] =
P
[ B
T
= −| X | ] =
LECTURE
1.
Note that
E
[ X ] = − a
P
[ X = − a ] + b
P
[ X = b ] = 0 and also
P
[ X = − a ] +
P
[ X = b ] = 1. Solve and deduce
P
[ X = − a ] = b a + b
;
P
[ X = b ] = a a + b
.
Exactly the same calculations can be carried out for B
T
:
E
[ B
T
] = − a
P
[ B
T
= − a ] + b
P
[ B
T
= b ] = 0 and also
P
[ B
T
= − a ] +
P
[ B
T
= b ] = 1. The result follows.
2.
Define T as follows: draw x from the distribution of | X | and let T be the time at which B first hits {− x , x } . Arguing from above or directly,
1
2
, and the result follows.
Answer to Exercise
on Central Limit Theorem: II
3.
Joint density is proportional to f ( x ) | y | f ( y ) over xy < 0.
Computing the normalizing constant by integration, using
Z
0
−∞
| y | f ( y ) d y =
Z
∞
0
| y | f ( y ) d y
(consequence of
E
[ Y ] = 0), we see joint density is
0 f ( x ) | y | f ( y )
R
∞
| u | f ( u ) d u
.
Answer to Exercise
on Central Limit Theorem: III
4.
Setting c
− 1
= R
∞
0
| u | f ( u ) d u, and taking x > 0 for convenience,
P
[ B
T
∈ ( a , a + d a )] = c
Z y < 0
| y |
| y | + a
| y | f ( y ) d y × f ( a ) d a +
+ c
Z x < 0
| x |
| x | + a f ( x ) d x × | a | f ( a ) d a
= c
Z y < 0
| y | 2
+ | y | a
| y | f ( y ) d y f ( a ) d a
| y | + a
= f ( a ) d a as required!
LECTURE
Answer to Exercise
on Stein-Chen (I): I
LECTURE
We can prove this by induction. Verify directly that it holds for g ( 1 ) . Substitute for g ( n ) :
λ g ( n + 1 )
P h f
= n i
=
P h f
∈ A , f
< n i
−
P h f
∈ A i
P h f
< n i
+
I
[ n ∈ A ] −
P h f
∈ A i
P h f
= n i
=
P h f
∈ A , W < n i
+
I
[ n ∈ A ]
P h f
= n i
−
P h f
∈ A i
P h f
< n i
−
P h f
∈ A i
P h f
= n i
=
P h f
∈ A , f
< n + 1 i
−
P h f
∈ A i
P h f
< n + 1 i
Answer to Exercise
on Stein-Chen (I): II which leads to the formula as required, if we use
λ n + 1
P h f
= n i
(Poisson probabilities!)
=
P h f
= n + 1 i
LECTURE
Answer to Exercise
on Stein-Chen (II): I
LECTURE
Simply use
P h f
∈ A , f
< n + 1 i
=
P h f
∈ A , f
< n + 1 i
P h f
≥ n + 1 i
+
P h f
∈ A , f
< n + 1 i
P h f
< n + 1 i
.
LECTURE
Answer to Exercise
on Stein-Chen (III): I
LECTURE
1.
If j ≥ n + 1 we have
P h f
= j , f
< n + 1 i
= 0 so the positive part vanishes, conversely if j < n + 1 then the negative part vanishes.
2.
We have
P h f
≥ n + 1 i g j
( n + 1 ) =
P h f
= j i
( n + 1 )
P h f
= n + 1 i
=
P h f
= j i
1 n + 1
λ
1 + n + 2
λ
2
+
( n + 2 )( n + 3 )
+ . . .
.
But this decreases as n increases (compare term-by-term!).
Answer to Exercise
on Stein-Chen (III): II
3.
First note g j
( n + 1 ) − g j
( n ) is positive only if n = j. Then expand: g j
( j + 1 ) − g j
(
= j ) =
1
∞
X
λ r = j + 1
λ r e
− λ r !
+
1 j j − 1
X
λ r e
− λ r = 0 r !
e
− λ
λ
∞
X
λ r
r = j + 1 r !
+
1 j j
X r λ r
r !
r = 1
≤ min
1
, j
1 − e
− λ
λ
.
Answer to Exercise
on Stein-Chen (III): III
Case 1: introduce factor r / j ≥ 1 to terms of first summand, use P
∞ r = 0 r ( λ r
Case 2: remove factor r / j ≤ 1 from terms of second summand, use e
− λ
/
P
∞ r !) = r = 0
λ r e
λ ;
− λ
/ r ! = 1.
LECTURE
Answer to Exercise
on Stein-Chen (IV): I
LECTURE
Using the notation of of the subsection, set U i
= P j
I j and
V j
+ 1 = (
Var [ W ] =
P
P j = i i p i
I j
) + 1. Notice
( 1 − p i
) .
λ =
Clearly U j
≥ V j
, so the sum P p i
P i
E
[ | U i p i
, while
− V i
| ] collapses giving a bound
P
[ W ∈ A ] −
P h f
∈ A i
≤
X
( p i i
− p i
( 1 − p i
)) =
X i p i
2
.
(Sample R code on next page.)
LECTURE
Answer to Exercise
on Stein-Chen (V) I n <- 10000 mean((rbinom(n,50,0.01)+rbinom(n,50,0.02))%%2) lambda <- 50*0.01+50*0.02
mean(rpois(n,lambda)%%2)
(1-exp(-lambda)/lambda)*(50*0.01ˆ2+50*0.02ˆ2)
LECTURE
LECTURE
Answers to exercises in Mixing of Markov chains
Answers to exercises in Mixing of Markov chains
Answer to Exercise on Coupling Inequality
Answer to Exercise on Coupling Inequality
Answer to Exercise on Coupling Inequality
Answer to Exercise on Coupling Inequality
Answer to Exercise on Coupling Inequality
Answer to Exercise on Coupling Inequality
Answer to Exercise on Coupling Inequality
Answer to Exercise on Mixing (I)
Answer to Exercise on Slice (I)
Answer to Exercise on Strong stationary times
Answer to Exercise on Strong stationary times
Answer to Exercise
on Coupling Inequality:
LECTURE
Let X
∗ be the process started in equilibrium.
dist tv
( L ( X n
) , π ) =
1
X
2
P
[ X n
= j ] − π j j
=
LECTURE
= sup {
P
[ X n
∈ A ] − π ( A ) } = sup
A A
{
P
[ X n
∈ A ] −
P
[ X
∗ n
= sup {
P
[ X n
∈ A , X
∗ n
A
= X n
] −
P
[ X n
= X
∗ n
, X
∗ n
∈ A ] }
∈ A ] }
≤
P
[ X
∗ n
= X n
] ≤
X
π y P
T x , y
> n y
≤ max y
{
P
T x , y
> n } .
(Use P j
P
[ X n
= j ] = P i
π j
= 1 and A = { j :
P
[ X n
= j ] > π j
} !)
Answer to Exercise
on Coupling Inequality:
LECTURE
Let X
∗ be the process started in equilibrium.
dist tv
( L ( X n
) , π ) =
1
X
2
P
[ X n
= j ] − π j j
= sup {
P
[ X n
∈ A ] − π ( A ) }
A
=
(Use P j
P
[ X n
= j ] = P i
π j
= 1 and A = { j :
P
[ X n
= j ] > π j
} !)
LECTURE
= sup {
P
[ X n
∈ A , X
∗ n
A
= sup {
P
[ X n
∈ A ] −
P
[ X
∗ n
A
= X n
] −
P
[ X n
= X
∗ n
, X
∗ n
∈ A ] }
∈ A ] }
≤
P
[ X
∗ n
= X n
] ≤
X
π y P
T x , y
> n y
≤ max y
{
P
T x , y
> n } .
Answer to Exercise
on Coupling Inequality:
LECTURE
Let X
∗ be the process started in equilibrium.
1
X dist tv
( L ( X n
) , π ) =
P
[ X n
= j ] − π j
=
2 j
= sup {
P
[ X n
∈ A ] − π ( A ) } = sup
A A
{
P
[ X n
∈ A ] −
P
[ X
∗ n
∈ A ] }
(Use P j
P
[ X n
= j ] = P i
π j
= 1 and A = { j :
P
[ X n
= j ] > π j
} !)
LECTURE
= sup {
P
[ X n
∈ A , X
∗ n
A
= X n
] −
P
[ X n
= X
∗ n
, X
∗ n
∈ A ] }
≤
P
[ X
∗ n
= X n
] ≤
X
π y P
T x , y
> n y
≤ max y
{
P
T x , y
> n } .
Answer to Exercise
on Coupling Inequality:
LECTURE
Let X
∗ be the process started in equilibrium.
1
X dist tv
( L ( X n
) , π ) =
P
[ X n
= j ] − π j
=
2 j
= sup {
P
[ X n
∈ A ] − π ( A ) } = sup
A A
{
P
[ X n
∈ A ] −
P
[ X
∗ n
= sup {
P
[ X n
∈ A , X
∗ n
A
= X n
] −
P
[ X n
= X
∗ n
, X
∗ n
∈ A ] }
∈ A ] }
(Use P j
P
[ X n
= j ] = P i
π j
= 1 and A = { j :
P
[ X n
= j ] > π j
} !)
LECTURE
≤
P
[ X n
∗
= X n
] ≤
X
π y P
T x , y
> n y
≤ max y
{
P
T x , y
> n } .
Answer to Exercise
on Coupling Inequality:
LECTURE
Let X
∗ be the process started in equilibrium.
1
X dist tv
( L ( X n
) , π ) =
P
[ X n
= j ] − π j
=
2 j
= sup {
P
[ X n
∈ A ] − π ( A ) } = sup
A A
{
P
[ X n
∈ A ] −
P
[ X
∗ n
= sup {
P
[ X n
∈ A , X
∗ n
A
= X n
] −
P
[ X n
= X
∗ n
, X
∗ n
∈ A ] }
∈ A ] }
≤
P
[ X n
∗
= X n
]
(Use P j
P
[ X n
= j ] = P i
π j
= 1 and A = { j :
P
[ X n
= j ] > π j
} !)
LECTURE
≤
X
π y P
T x , y
> n y
≤ max y
{
P
T x , y
> n } .
Answer to Exercise
on Coupling Inequality:
LECTURE
Let X
∗ be the process started in equilibrium.
1
X dist tv
( L ( X n
) , π ) =
P
[ X n
= j ] − π j
=
2 j
= sup {
P
[ X n
∈ A ] − π ( A ) } = sup
A A
{
P
[ X n
∈ A ] −
P
[ X
∗ n
= sup {
P
[ X n
∈ A , X
∗ n
A
= X n
] −
P
[ X n
= X
∗ n
, X
∗ n
∈ A ] }
∈ A ] }
≤
P
[ X n
∗
= X n
] ≤
X
π y P
T x , y
> n y
(Use P j
P
[ X n
= j ] = P i
π j
= 1 and A = { j :
P
[ X n
= j ] > π j
} !)
LECTURE
≤ max y
{
P
T x , y
> n } .
Answer to Exercise
on Coupling Inequality:
LECTURE
Let X
∗ be the process started in equilibrium.
1
X dist tv
( L ( X n
) , π ) =
P
[ X n
= j ] − π j
=
2 j
= sup {
P
[ X n
∈ A ] − π ( A ) } = sup
A A
{
P
[ X n
∈ A ] −
P
[ X
∗ n
= sup {
P
[ X n
∈ A , X
∗ n
A
= X n
] −
P
[ X n
= X
∗ n
, X
∗ n
∈ A ] }
∈ A ] }
≤
P
[ X n
∗
= X n
] ≤
X
π y P
T x , y
> n y
≤ max y
{
P
T x , y
> n } .
(Use P j
P
[ X n
= j ] = P i
π j
= 1 and A = { j :
P
[ X n
= j ] > π j
} !)
LECTURE
Answer to Exercise
on Mixing (I): I
LECTURE
Coupling occurs at a random time which is the maximum of n independent Exponential ( 2 / n ) random variable. By the coupling inequality it suffices to consider
P
[ max { T
1
, . . . , T n
} ≤ t ] = (
P
[ T
1
≤ t ]) n
= 1 − e
− 2t / n n
.
Answer to Exercise
on Mixing (I): II
Setting t = n log ( α n ) / 2 we see
P
[ max { T
1
, . . . , T n
} ≤ n log ( α n ) / 2 ] =
1
1 −
α n n
→ exp ( − 1 /α ) .
So the coupling has to occur around time n log ( n ) / 2, and mixing must happen before this.
LECTURE
Answer to Exercise on Slice (I) I
Refer to pseudo-code: def mcmc_slice_move(x): y = uniform(0, x) return uniform(g0(y), g1(y))
LECTURE
LECTURE
Answer to Exercise
on Strong stationary times: I
LECTURE
You are referred to ( Diaconis 1988 ,
§ 10.B, Example 4) — though even here you are expected to do most of the work yourself!
LECTURE
Answer to Exercise
on Strong stationary times: I
LECTURE
We know T m + 1
− T m is Geometrically distributed with success probability ( n − m )( m + 1 ) / n
2
. So mean of T is
E
" n − 1
X
( T m
− T m − 1
)
#
= m = 0 n − 1
X n
2 m = 0 n + 1
1 n − m
1
+ m + 1
≈ 2n log n .
LECTURE
Answers to exercises in The Coupling Zoo
Answers to exercises in The Coupling Zoo
Answer to Exercise on The zoo (I)
Answer to Exercise on The zoo (II)
Answer to Exercise on The zoo (III)
Answer to Exercise
on The zoo (I): I
LECTURE
Suppose initially X = 1, Y = 5. We need only specify the jump probabilities till X = Y .
The synchronized coupling ( X , Y ) is obtained by setting
( X , Y ) → ( X + 1 , ( Y + 1 ) ∧ 5 ) with probability 1 / 2,
( X , Y ) → (( X − 1 ) ∨ 1 , Y − 1 ) with probability 1 / 2. Coupling occurs when Y hits 1 or X hits 5.
Answer to Exercise
on The zoo (I): II
The reflection coupling is obtained by setting
( X , Y ) → ( X + 1 , Y − 1 ) with probability 1 / 2,
( X , Y ) → (( X − 1 ) ∨ 1 , ( Y + 1 ) ∧ 5 ) with probability 1 / 2. Coupling occurs when X = Y = 3. (Notice that this coupling is susceptible to periodicity problems: consider what happens if { 1 , 2 , 3 , 4 , 5 } is replaced by
{ 1 , 2 , 3 , 4 } !)
It should be apparent that reflection coupling is faster here!
Check this out by simulation . . . .
LECTURE
Answer to Exercise
on The zoo (II): I
LECTURE
First note time ∆ when Y first hits x . Now simultaneously sample successive excursion times N
1
, N
2
, . . . for X and M
1
,
M
2
, . . . for Y as follows: fix constant k > 0 then
I Draw M i
;
I If M i
> k then set N i
= M i
;
I or use rejection sampling to draw N i conditional on N i
≤ k .
Study cumulative difference ∆ + P i
( N i
− M i
) . The N i
− M i are symmetric bounded random variables so random walk theory shows eventually ∆ + P N i equals P M i
. At this time
X = Y = x . Eliminate periodicity issues by noting: when k is large enough there is a positive probability of N i
− M i
= ± 1, say.
LECTURE
Answer to Exercise
on The zoo (III): I
LECTURE
If 0 ≤ f ( X t
, t ) ≤ 1 is a non-constant bounded space-time harmonic function then consider a coupling X , Y such that f ( X
0
, 0 ) > f ( Y
0
, 0 ) . Taking iterated conditional expectations,
E
[ f ( X t + 1
, t + 1 ) | X t
, X t − 1
, . . .
] −
E
[ f ( Y t + 1
, t + 1 ) | Y t
, Y t − 1
, . . .
]
= f ( X t
, t ) − f ( Y t
, t ) and so
E
[ f ( X t + 1
, t + 1 )] −
E
[ f ( Y t + 1
, t + 1 )] = f ( X
0
, 0 ) − f ( Y
0
, 0 ) > 0 .
If the coupling X and Y meet then they stay together. A simple expectation inequality shows X and Y may never meet . . . .
LECTURE
Answers to exercises in Perfection (CFTP I)
Answers to exercises in Perfection (CFTP I)
Answer to Exercise on CFTP (I)
Answer to Exercise on CFTP (II)
Answer to Exercise on CFTP (III)
Answer to Exercise on CFTP (IV)
Answer to Exercise on CFTP (V)
Answer to Exercise on Falling Leaves
Answer to Exercise
on CFTP (I): I
LECTURE
Use, for example, χ
2
-tests on the output of many iterations of the following.
First define the length of the first run of innovations:
Time <- 2**10
This length Time is far more than sufficient to ensure coalescence will always be achieved (this is a handy way of avoiding tricky iterations!)
In principle we should extend a CFTP cycle till coalescence is achieved. For ease of programming, we simply start at time
Time , and return a NA answer if coalescence is not achieved!
(Sample R code on next pages.)
LECTURE
R code for Exercise
simulate <- function (innov) upper <- 4 lower <- 1 for (i in 1:length(innov)) upper <- min(max(upper+innov[i],1),4) lower <- min(max(lower+innov[i],1),4) if (upper!=lower) return(NA) upper
R code for Exercise
ctd.
Now iterate a number of times (with different innovations in innov !)
2 and carry out statistical tests on the answer data to detect whether there is departure from the uniform distribution over { 1 , 2 , 3 , 4 } .
data <- rep(NA,100) for (i in 1:length(data)) data[i] <- simulate(2*rbinom(Time,1,1/2)-1) chisq.test(tabulate(data),p=rep(0.25,4))
2
All this is very clumsy. Could you do better?!
Answer to Exercise
on CFTP (II): I
LECTURE
Examine the output of many iterations of an appropriate modification of your answer to the previous exercise. Here is a recursive form (try it with Time=5 for example!): There should be a substantial deviation from the equilibrium distribution
(uniform on { 1 , 2 , 3 , 4 } )!
(Sample R code on next page.)
LECTURE
R code for Exercise
simulate2 <- function (innov) upper <- 4 lower <- 1 for (i in 1:length(innov)) upper <- min(max(upper+innov[i],1),4) lower <- min(max(lower+innov[i],1),4) if (upper!=lower) return(simulate2(c(innov,2*rbinom(Time,1,1/2)-1))) upper
Answer to Exercise
on CFTP (III): I
LECTURE
Use, for example, χ
2
-tests on the output of many iterations of an appropriate modification of your answer to the previous exercises. Your modification should first try CFTP for an innovation run of length short enough for the probability of coalescence to be about 1 / 2. In the event of coalescence failure, true CFTP would extend the innovation run back in time.
Your modification should deviate from this by then trying a
completely new longer innovation run.
Answer to Exercise
on CFTP (III): II
Here is a recursive form (try it with Time=5 for example!). You should find it informative to examine the output from the short innovation run and note the kind of bias which would be obtained by looking only at the cases where coalescence has occurred. With further thought you should be able to see intuitively why an extension of the innovation run backwards in time will correct this bias.
(Sample R code on next page.)
LECTURE
R code for Exercise
simulate3 <- function (innov) upper <- 4 lower <- 1 for (i in 1:length(innov)) upper <- min(max(upper+innov[i],1),4) lower <- min(max(lower+innov[i],1),4) if (upper!=lower) return(simulate3(2*rbinom(2*length(innov),1,1/2)-1)) upper
Answer to Exercise
on CFTP (IV): I
LECTURE
There is a recursive form on next page (try it with Time=5 for example!) . . .
(Sample R code on next page.)
LECTURE
R code for Exercise
simulate4 <- function (innov) upper <- 4 lower <- 1 for (i in 1:length(innov)) upper <- min(max(upper+innov[i],1),4) lower <- min(max(lower+innov[i],1),4) if (upper!=lower) return(simulate4((2*rbinom(Time,1,1/2)-1,innov))) upper
Answer to Exercise
on CFTP (V): I
This tests your ability to use R to compute with matrices!
LECTURE
LECTURE
Answer to Exercise
on Falling Leaves: I
LECTURE
Consider the event A that the final pattern consists of a single super-leaf covering the whole window.
For a given set of n falling leaves we have three possibilities:
1.
The window is not covered;
2.
The window is covered, but none of the leaves is a super-leaf;
3.
The window is covered, and at least one leaf is a super-leaf.
For large n the case
is of vanishingly small probability. In case
we know A cannot occur.
Answer to Exercise
on Falling Leaves: II
In case
we know A occurs for CFTP exactly when the first leaf is a super-leaf. However A will occur in the forward-time variant not only in this case but also when the window is not completely covered until a super-leaf falls. Hence
P
[ A | CFTP ] <
P
[ A | forward-time variant ] .
A variation on this argument shows that in general the forward-time variant is more likely than CFTP (and hence equilibrium) to cover a patch of the window by a single leaf – strictly more likely to do so whenever the patch can be so covered.
LECTURE
Answers to exercises in Perfection (CFTP II)
Answers to exercises in Perfection (CFTP II)
Answer to Exercise on Small set CFTP
Answer to Exercise
on Small set CFTP: I
LECTURE
At each time-step there is a chance 1 / 2 of being captured by the small set. So the CFTP construction shows the density π ( x ) results from going back N time steps to the most recent coalescence (where
P
[ N = n ] = 2
− n + 1 for n = 0, 1 . . . ), drawing from p ( 1 / 2 , · ) , then running forwards to time 0 using the residual kernel, which is the kernel conditioned on not coalescing: r ( x , y ) = p ( x , y ) − p ( 1 / 2 , y ) / 2
1 − 1 / 2
= 2p ( x , y ) − p ( 1 / 2 , y ) .
LECTURE
Answers to exercises in Perfection (FMMR)
Answers to exercises in Perfection (FMMR)
Answer to Exercise on Siegmund (I)
Answer to Exercise on Siegmund (II)
Answer to Exercise
on Siegmund (I): I
LECTURE
Take y = 0 in
P
[ X t
≥ y | X
0
= x ] =
P
[ Y t
≤ x | Y
0
= y ] and note that the left-hand side is then equal to 1. Set x = 0 to get the absorption result
P
[ Y t
≤ 0 | Y
0
= 0 ] = 1.
LECTURE
Answer to Exercise
on Siegmund (II): I
Work with
P
[ X t
≥ y | X
0
= x ] =
P
[ Y t
≤ x | Y
0
= y ] .
LECTURE
I Take y = x + 2 to deduce
P
[ Y t
≤ x | Y
0
= x + 2 ] = 0, so Y cannot jump by less than − 1.
I Similarly take y = x − 2, y = x − 1 to deduce
P
[ Y t
≤ x | Y
0
= x − 2 ] =
P
[ Y t
≤ x | Y
0
= x − 1 ] , so Y cannot jump by more than + 1.
Answer to Exercise
on Siegmund (II): II
I Similarly deduce
P
[ Y t
= x | Y
0
= x + 1 ] =
P
[ X t
≥ x + 1 | X
0
= x ] −
P
[ X t
≥ x + 1 | X
0
= x − 1 ] = as long as x ≥ 0.
I Similarly deduce
1
2
P
[ Y t
= x + 1 | Y
0
= x + 1 ] =
P
[ X t
≥ x + 1 | X
0
= x + 1 ] −
P
[ X t
≥ x + 1 | X
0
= x ] = 0 as long as x ≥ 0.
This is sufficient to identify Y as required.
LECTURE
Answers to exercises in sundry further topics in CFTP
Answers to exercises in sundry further topics in CFTP
Answer to Exercise on Realizable monotonicity
Answer to Exercise
on Realizable monotonicity: I
LECTURE
Consider horses 1, 2, 3. Horse 1 is to be chosen in { 1 , 2 , 3 } with probability 1 / 3, in { 1 , 2 } with probability 1 / 2, in { 1 , 3 } with probability 1 / 2, and in { 1 } with probability 1.
The coupling must specify
1.
the choice i from { 1 , 2 , 3 } ,
2.
the choice j = i to be made from the subset { 1 , 2 , 3 } \ { i } .
Answer to Exercise
on Realizable monotonicity: II
Each distinct ordered pair ( i , j ) has probability p ij
. We require p ij
+ p ik p
+ p ji ij
+ p
+ p ik ki
=
=
But then p ji
+ p ki
= 1 / 6. This would lead to
2 × ( p
12
+ p
13
+ p
21
+ p
23
+ p
31
+ p
32
) =
1
3
+
1
3
+
1
3
+
1
6
+
1
6
+
1
6
=
3
2 contradicting
1
,
3
1
.
2 p
12
+ p
13
+ p
21
+ p
23
+ p
31
+ p
32
= 1 .
LECTURE
“You are old, Father William,” the young man said,
“All your papers these days look the same;
Those William’s would be better unread –
Do these facts never fill you with shame?”
“In my youth,” Father William replied to his son,
“I wrote wonderful papers galore;
But the great reputation I found that I’d won,
Made it pointless to think any more.”
“You are old,” said the youth, “and I’m told by my peers
That your lectures bore people to death.
Yet you talk at one hundred conventions per year –
Don’t you think that you should save your breath?”
“I have answered three questions and that is enough,”
Said his father, “Don’t give yourself airs!
Do you think I can listen all day to such stuff?
Be off, or I’ll kick you downstairs!”
“You are old, Father William,” the young man said,
“All your papers these days look the same;
Those William’s would be better unread –
Do these facts never fill you with shame?”
“In my youth,” Father William replied to his son,
“I wrote wonderful papers galore;
But the great reputation I found that I’d won,
Made it pointless to think any more.”
“You are old,” said the youth, “and I’m told by my peers
That your lectures bore people to death.
Yet you talk at one hundred conventions per year –
Don’t you think that you should save your breath?”
“I have answered three questions and that is enough,”
Said his father, “Don’t give yourself airs!
Do you think I can listen all day to such stuff?
Be off, or I’ll kick you downstairs!”
“You are old, Father William,” the young man said,
“All your papers these days look the same;
Those William’s would be better unread –
Do these facts never fill you with shame?”
“In my youth,” Father William replied to his son,
“I wrote wonderful papers galore;
But the great reputation I found that I’d won,
Made it pointless to think any more.”
“You are old,” said the youth, “and I’m told by my peers
That your lectures bore people to death.
Yet you talk at one hundred conventions per year –
Don’t you think that you should save your breath?”
“I have answered three questions and that is enough,”
Said his father, “Don’t give yourself airs!
Do you think I can listen all day to such stuff?
Be off, or I’ll kick you downstairs!”
“You are old, Father William,” the young man said,
“All your papers these days look the same;
Those William’s would be better unread –
Do these facts never fill you with shame?”
“In my youth,” Father William replied to his son,
“I wrote wonderful papers galore;
But the great reputation I found that I’d won,
Made it pointless to think any more.”
“You are old,” said the youth, “and I’m told by my peers
That your lectures bore people to death.
Yet you talk at one hundred conventions per year –
Don’t you think that you should save your breath?”
“I have answered three questions and that is enough,”
Said his father, “Don’t give yourself airs!
Do you think I can listen all day to such stuff?
Be off, or I’ll kick you downstairs!”
Bibliography
This is a rich hypertext bibliography. Journals are linked to their homepages, and stable
URL links (as provided for example by JSTOR or Project Euclid ) have been added where known. Access to such URLs is not universal: in case of difficulty you should check whether you are registered (directly or indirectly) with the relevant provider. In the case of preprints, icons , , , linking to homepage locations are inserted where available: note that these are probably less stable than journal links!.
Breiman, L. (1992).
Probability, Volume 7 of Classics in Applied Mathematics.
Philadelphia, PA: Society for Industrial and Applied Mathematics (SIAM).
Corrected reprint of the 1968 original.
Diaconis, P. (1988).
Group Representations in Probability and Statistics, Volume 11 of IMS Lecture
Notes Series .
Hayward, California: Institute of Mathematical Statistics .
Fill, J. A. and M. Machida (2001).
Stochastic monotonicity and realizable monotonicity.
The Annals of Probability 29(2), 938–978, .
Kendall, W. S. and J. Møller (2000, September).
Perfect simulation using dominating processes on ordered state spaces, with application to locally stable point processes.
Advances in Applied Probability 32(3), 844–865, ; Also University of Warwick
Department of Statistics Research Report 347 .