My Math Forum Problems finding the Moment Generating Function

 September 16th, 2017, 02:08 PM #1 Senior Member   Joined: Oct 2015 From: Antarctica Posts: 109 Thanks: 0 Problems finding the Moment Generating Function Let the random variable X equal the number of flips of a fair coin that are required to observe heads - tails on consecutive flips. Find the pmf of X and find the moment generating function of X. The PMF is straightforward since there are always two desired outcomes divided by 2^n (where n >= 2). So the PMF should simply be 1/(2^(n-1)). The moment generating function is where I'm struggling. I should be able to use use properties of geometric series to obtain the moment generating function, but something keeps going wrong and I'm not sure what. I'm supposed to obtain: M(t) = e^(2t)/(e^t - 2)^2 but I keep ending up with M(t) = e^(2t)/(2 - e^t) I honestly don't know what's going wrong, as I've checked over my work several times. Do I have the wrong PMF, perhaps? If not, how did you calculate the moment generating function?
 September 16th, 2017, 02:24 PM #2 Senior Member     Joined: Sep 2015 From: USA Posts: 1,693 Thanks: 860 I get... $P[m] = \left . p(1-p)^{m-1}+p^{m-1}(1-p) \right|_{p=\frac 1 2} = 2^{1-m},~m=2,3, \dots$ $M(t) = E[e^{t X}] = \displaystyle \sum_{m=2}^\infty~2^{1-m}e^{m t} = \dfrac{e^{2t}}{2-e^t}$
 September 16th, 2017, 03:12 PM #3 Senior Member   Joined: Oct 2015 From: Antarctica Posts: 109 Thanks: 0 Yeah, that's exactly what I get! But I don't understand what's wrong. Here's the problem statement: Yet our answers are clearly different than the one they want us to find.
 September 16th, 2017, 04:29 PM #4 Senior Member     Joined: Sep 2015 From: USA Posts: 1,693 Thanks: 860 Ok, I did it assuming you could either go heads-tails or tails-heads. This problem is different. Let me look at this a bit further.
 September 16th, 2017, 05:12 PM #5 Senior Member     Joined: Sep 2015 From: USA Posts: 1,693 Thanks: 860 Ok I have it. Legit sequences that take $m$ flips to obtain a $HT$ transition are of the following form. $k$ occurrences of $T$ followed by $m-k-1$ occurences of $H$, followed by $T$ $k = 0, 1, \dots m-2$ These have probability $pr_k(m) = (1-p)^{k+1}p^{m-k-1}$ $pr(m) = \displaystyle \sum_{k=0}^{m-2} pr_k(m) = \dfrac{p^{m+1}-p^m+p (1-p)^m}{1-2 p}$ notice you can't just substitute $p=\dfrac 1 2$ addenda: You can however take the limit as $p \to \dfrac 1 2$ and proceed that way. You get $p(m) = 2^{-m}(m-1)$ You can then find $M(t)$ using that expression. This is probably much easier. : end addenda Then $M(t) = \displaystyle \sum_{m=2}^\infty ~e^{t m} pr(m) = \sum_{m=2}^\infty ~e^{t m} \dfrac{p^{m+1}-p^m+p (1-p)^m}{1-2 p} = \dfrac{(p-1) p e^{2 t}}{\left(p e^t-1\right) \left(p e^t-e^t+1\right)}$ Now, letting $p=\dfrac 1 2$, and probably churning through a ton of algebra we get. $M(t) = \dfrac{e^{2 t}}{\left(e^t-2\right)^2}$ Last edited by romsek; September 16th, 2017 at 05:17 PM.
 September 16th, 2017, 07:18 PM #6 Senior Member   Joined: Oct 2015 From: Antarctica Posts: 109 Thanks: 0 Although I understand how to find the MGF from the PMF you said the limit was equal to (2^-m * (m-1)), I'm still not quite sure how to interpret the PMF in the context of the problem. To me, when I read the problem, I don't understand how to derive the PMF from it. Edit; I understand it much more intuitively now. Without going through the binomial stuff, the m-1/2^m makes sense if you write out a few sets. Last edited by John Travolski; September 16th, 2017 at 07:31 PM.

 Tags finding, function, generating, moment, problems

 Thread Tools Display Modes Linear Mode

 Similar Threads Thread Thread Starter Forum Replies Last Post calypso Advanced Statistics 1 May 22nd, 2016 02:52 AM calypso Advanced Statistics 0 November 15th, 2015 12:35 PM theorem Advanced Statistics 3 May 3rd, 2014 01:54 PM FreaKariDunk Algebra 3 October 19th, 2012 08:01 AM 450081592 Advanced Statistics 1 November 26th, 2011 02:04 PM

 Contact - Home - Forums - Cryptocurrency Forum - Top