Discussion Prompt

Pick one of the exercises in the readings this week. Solve the exercise as best as you can. If you have issues, explicate them, so that all of us can help.

You may use any exercise, even if assigned as homework.

Discussion Solution

11.1.2 In Example 11.4, let a = 0 and b = 1/2. Find P, P2, and P3. What would Pn be? What happens to Pn as n tends to infinity? Interpret this result.

Example 11.4 The President of the United States tells person A his or her intention to run or not to run in the next election. Then A relays the news to B, who in turn relays the message to C, and so forth, always to some new person. We assume that there is a probability a that a person will change the answer from yes to no when transmitting it to the next person and a probability b that he or she will change it from no to yes. We choose as states the message, either yes or no. The transition matrix is then:

The initial state represents the President’s choice.

Answer:

Let a = 0 and b = 1/2. Then the transition matrix in its initial state P is:

P<-matrix(c(1,0,1/2,1/2), nrow=2, byrow=TRUE)
P
##      [,1] [,2]
## [1,]  1.0  0.0
## [2,]  0.5  0.5

P2 then is:

P2<-P%*%P
P2
##      [,1] [,2]
## [1,] 1.00 0.00
## [2,] 0.75 0.25

P3 then is:

P3<-P2%*%P
P3
##       [,1]  [,2]
## [1,] 1.000 0.000
## [2,] 0.875 0.125

Pn becomes closer and closer to

matrix(c(1,0,1,0), byrow=TRUE, nrow=2)
##      [,1] [,2]
## [1,]    1    0
## [2,]    1    0

as n tends to infinity. See below which show the first 9 iterations. In short, very quickly, Pn stabilizes to only yield a “yes” answer for any subsequent state.

Pn <-P
for(i in 2:1000){
  Pn<-Pn%*%P
  
  if(Pn[2,2]>0.001){
    print(paste0("n = ",i))
    print(Pn)
  }
}
## [1] "n = 2"
##      [,1] [,2]
## [1,] 1.00 0.00
## [2,] 0.75 0.25
## [1] "n = 3"
##       [,1]  [,2]
## [1,] 1.000 0.000
## [2,] 0.875 0.125
## [1] "n = 4"
##        [,1]   [,2]
## [1,] 1.0000 0.0000
## [2,] 0.9375 0.0625
## [1] "n = 5"
##         [,1]    [,2]
## [1,] 1.00000 0.00000
## [2,] 0.96875 0.03125
## [1] "n = 6"
##          [,1]     [,2]
## [1,] 1.000000 0.000000
## [2,] 0.984375 0.015625
## [1] "n = 7"
##           [,1]      [,2]
## [1,] 1.0000000 0.0000000
## [2,] 0.9921875 0.0078125
## [1] "n = 8"
##           [,1]       [,2]
## [1,] 1.0000000 0.00000000
## [2,] 0.9960938 0.00390625
## [1] "n = 9"
##           [,1]        [,2]
## [1,] 1.0000000 0.000000000
## [2,] 0.9980469 0.001953125
round(Pn, digits = 2)
##      [,1] [,2]
## [1,]    1    0
## [2,]    1    0