Let the random variable X represent the number of times a fair coin needs to be tossed till two consecutive heads appear for the first time. The expectation of X is
Let x be random variable which denotes number of tosses to get two heads.
x |
outcome |
p(x) |
2 |
HH |
(12)2 |
3 |
THH |
(12)3 |
4 |
TTHH |
(12)4 |
⋮ |
⋮ |
⋮ |
⋮ |
⋮ |
⋮ |
⋮ |
⋮ |
⋮ |
E(x)=∑pixi
=2(12)2+3(12)3+4(12)4+...
=12[(1+2(12)+3(12)2+4(12)3+.....)−1]
=12[(1−12)2−1]
(∵(1−x)2=1+2x+3x2+4x3+.....)
=12(4−1)=1.5