Line 43: | Line 43: | ||
<math>E(Y)=2(n-1)p(1-p)</math>. | <math>E(Y)=2(n-1)p(1-p)</math>. | ||
− | + | ---- | |
+ | ==Solution 2== | ||
− | + | For n flips, there are n-1 changeovers at most. Assume random variable <math>k_i</math> for changeover, | |
− | <math | + | <math>P(k_i=1)=p(1-p)+(1-p)p=2p(1-p)</math> |
+ | |||
+ | <math>E(k)=\sum_{i=1}^{n-1}P(k_i=1)=2(n-1)p(1-p)</math> | ||
+ | |||
+ | <font color="red"><u>'''Critique on Solution 2:'''</u> | ||
+ | |||
+ | The solution is correct. However, it's better to explicitly express <math>k_i</math> as a Bernoulli random variable. This makes it easier for readers to understand. | ||
+ | |||
+ | </font> | ||
− | |||
− | |||
− | |||
− | |||
---- | ---- | ||
− | [[ | + | [[ECE-QE_CS1-2013|Back to QE CS question 1, August 2013]] |
[[ECE_PhD_Qualifying_Exams|Back to ECE Qualifying Exams (QE) page]] | [[ECE_PhD_Qualifying_Exams|Back to ECE Qualifying Exams (QE) page]] |
Revision as of 15:26, 4 November 2014
Communication, Networking, Signal and Image Processing (CS)
Question 1: Probability and Random Processes
August 2013
Part 1
Consider $ n $ independent flips of a coin having probability $ p $ of landing on heads. Say that a changeover occurs whenever an outcome differs from the one preceding it. For instance, if $ n=5 $ and the sequence $ HHTHT $ is observed, then there are 3 changeovers. Find the expected number of changeovers for $ n $ flips. Hint: Express the number of changeovers as a sum of Bernoulli random variables.
Solution 1
The number of changeovers $ Y $ can be expressed as the sum of n-1 Bernoulli random variables:
$ Y=\sum_{i=1}^{n-1}X_i $.
Therefore,
$ E(Y)=E(\sum_{i=1}^{n-1}X_i)=\sum_{i=1}^{n-1}E(X_i) $.
For Bernoulli random variables,
$ E(X_i)=p(E_i=1)=p(1-p)+(1-p)p=2p(1-p) $.
Thus
$ E(Y)=2(n-1)p(1-p) $.
Solution 2
For n flips, there are n-1 changeovers at most. Assume random variable $ k_i $ for changeover,
$ P(k_i=1)=p(1-p)+(1-p)p=2p(1-p) $
$ E(k)=\sum_{i=1}^{n-1}P(k_i=1)=2(n-1)p(1-p) $
Critique on Solution 2:
The solution is correct. However, it's better to explicitly express $ k_i $ as a Bernoulli random variable. This makes it easier for readers to understand.