1. Page 363, problem 11. The price of one share of stock in the Pilsdorff Beer Company (see Exercise 8.2.12) is given by Yn on the nth day of the year. Finn observes that the differences Xn = Yn+1 − Yn appear to be independent random variables with a common distribution having mean µ = 0 and variance σ2 = 1/4. If Y1 = 100, estimate the probability that Y365 is

(a) ≥ 100

The probability that Y365≥ 100 is 0.5.
Using the formula from the problem statement \[X_n=Y_{n+1}-Y_n\], Then \[Y_{365}-Y_1=\sum_{n=1}^{364}X_n=S_n\] The sum of independent variables X_n should be between 0 and +∞ with n=364 is \[0\leq Sn \leq +\infty, \mu=0,n=364,\sigma=\frac{1}{2}\] \[\frac {Sn-n\mu}{\sqrt{n\cdot\sigma^2}}=\frac {Y_{365}-Y_1-n\mu}{\sqrt{n}\cdot\sigma}\] We will get \[\frac{100-100-364*0}{\sqrt{364}\cdot\frac{1}{2}}=0\], And \[\frac{+\infty-100-364*0}{\sqrt{364\cdot\frac{1}{4}}}=+\infty\]. Using standard Normal Distribution Table, the probability of the sum for \[z=0\] The probability of the sum \[P(0\leq S_n \leq +\infty)=0.5\] Let’s check the answer using R:

yn=100
y1 <- 100
n<- 364
var <- sqrt(n)*1/2
mean <- 0
pnorm(yn-y1,mean,var,lower.tail=FALSE)
## [1] 0.5

(b) ≥ 110

The probability that Y365≥ 110 is 0.147.
We will get \[\frac{110-100-364*0}{\sqrt{364}\cdot\frac{1}{2}}=\frac{10}{\sqrt{91}}\], And \[\frac{+\infty-100-364*0}{\sqrt{364\cdot\frac{1}{4}}}=+\infty\]. Using standard Normal Distribution Table, the probability of the sum for \[z=-\frac{10}{\sqrt{91}}\] The probability of the sum\[P(10\leq S_n \leq +\infty)=0.147\] Let’s check the answer using R:

yn <- 110
y1 <- 100
n<- 364
var <- sqrt(n)*1/2
mean <- 0
pnorm(yn-y1,mean,var,lower.tail=FALSE)
## [1] 0.1472537

(c) ≥ 120

The probability that Y365≥ 120 is 0.018.
We will get \[\frac{120-100-364*0}{\sqrt{364}\cdot\frac{1}{2}}=\frac{20}{\sqrt{91}}\]. Using standard Normal Distribution Table, the probability of the sum for \[z=-\frac{20}{\sqrt{91}}\] The probability of the sum \[P(20\leq S_n \leq +\infty)=0.018\] Let’s check the answer using R:

yn <- 120
y1 <- 100
n<- 364
var <- sqrt(n)*1/2
mean <- 0
pnorm(yn-y1,mean,var,lower.tail=FALSE)
## [1] 0.01801584

2. Calculate the expected value and variance of the binomial distribution using the moment generating function.

The moment generating function for binomial distribution \[g(t)=\sum_{j=0}^n e^{tj} (_j^n) p^j q^{n-1}=\sum_{j=0}^n (pe^{t})^j (_j^n) q^{n-1}=(pe^t+q)^n\] To find the variance and the expected value, we will need to calculate the first and the second derivative of the moment generating function (p+q=1): \[g'(t=0)= n(pe^t + q)^{n−1}pe^t|_{t=0}=n(pe^0 + q)^{n−1}pe^0=n(p + q)^{n−1}p=n\cdot1\cdot p=np\] \[g''(t=0)= n(n-1) (pe^t + q)^{n−2} (pe^t)^2 + n(pe^t + q)^{n−1}pe^t |_{t=0}= n(n-1)(p+q)^{n-2}p^2+n(p+q)^{n-1}p = np^2(n − 1) + np\] The expected value equals to the first derivative \[\mu = g'(t=0) = np\] Variance will be equal to the difference between the first and the second derivative: \[\sigma^2=g''(t=0)-(g'(t=0))^2=np^2(n − 1) + np - (np)^2=np-np^2=np(1-p)=npq\]

3. Calculate the expected value and variance of the exponential distribution using the moment generating function.

The moment generating function for exponential distribution \[g(t)=\sum_{j=0}^\infty e^{tj} \frac{e^{-\lambda}\lambda^j}{j!}=e^{-\lambda} \sum_{j=0}^\infty \frac{(e^t\lambda)^j}{j!}=e^{-\lambda}e^{\lambda e^t}=e^{\lambda (e^t-1)}\] To find the variance and the expected value, we will need to calculate the first and the second derivative of the moment generating function: \[g'(t=0)=\lambda e^t e^{\lambda (e^t-1)}|_{t=0}=\lambda\] \[g"(t=0)= \lambda e^t e^{\lambda (e^t-1)} + \lambda^2 e^{2t} e^{\lambda (e^t-1)}|_{t=0}=e^{\lambda (e^t-1)}(\lambda e^t + \lambda^2 e^{2t})|_{t=0}=\lambda + \lambda^2\] The expected value equals to the first derivative \[\mu = g'(t=0) = \lambda\] Variance will be equal to the difference between the first and the second derivative: \[\sigma^2=g''(t=0)-(g'(t=0))^2=\lambda + \lambda^2 - \lambda^2=\lambda\]