# Homework Help: Geometric distribution problem

1. Feb 6, 2005

### semidevil

a couple decides that they will have kids until a girl is born. the outcome of each birth is independent event, and the probability that a girl will be born is 1/2. The birht at which the first girl appears is a geometric distribution. what is the expected family size.

ok, so we know that the probability of having a girl is 1/2.

geometric distribution formula, it is the sum from 1 to k of (1- p) * (p)^k, where k = 1, 2, 3, 4,......k.

but when I tihnk about it, I have an expected value formula, where E(X) = 1/p. so if I put 1/(1/2), I get the answer is 2. So the expected family size is 2?

I don't know..I have this geometric formula that I dont know what to do with, and I have this expected value formula that makes it seem this problem is too easy....

any tips?

2. Feb 6, 2005

### vincentchan

don't over-complicated the problem

3. Feb 7, 2005

### xanthym

An important point is there are actually several slightly different forms of the Geometric Distribution, and each has a slightly different E(x). For example, the E(x) you quoted in your msg is NOT correct for the specific Discrete Geometric Density function you presented.

Let's begin with the Geometric Density function you presented, which indicates the probability that success will be achieved on the (k+1)-th trial after "k" failures for an event whose probability of success is (0 < p < 1):

$$P(X=k) = p*(1 - p)^{k} \ \ \ k=0,1,2,3,...$$

The expected value E(x) is then given by:

$$E(X) = \sum\limits_{k = 0}^{\inf} k*p*(1 - p)^{k}$$
$$E(X) = p*\sum\limits_{k = 0}^{\inf} k*(1 - p)^{k} \ \ \color{green} Eq:1$$
$$E(X) = p*\sum\limits_{k = 1}^{\inf} k*(1 - p)^{k} \ \ \ \color{green} Eq:2$$

Multiply both sides of Eq #1 by (1 - p):

$$(1 - p)*E(X) = p*\sum\limits_{k = 0}^{\inf} k*(1 - p)^{k+1}$$
$$(1 - p)*E(X) = p*\sum\limits_{k = 1}^{\inf} (k - 1)*(1 - p)^{k} \ \ \ \color{green} Eq:3$$

Now subtract Eq #3 from Eq #2:

$$E(X) - (1 - p)*E(X) = p*\sum\limits_{k = 1}^{\inf} [(k) - (k - 1)]*(1 - p)^{k}$$
$$p*E(X) = p*\sum\limits_{k = 1}^{\inf} (1 - p)^{k}$$
$$E(X) = \sum\limits_{k = 1}^{\inf} (1 - p)^{k} \ \ \ \color{green} Eq:4$$

The infinite sum in Eq #4 is a geometric series with term ratio (1 - p), so that it may be written:

$$E(X) = \frac {1 - p} {1 - (1 - p)}$$
$$E(X) = \frac {1 - p} {p}$$

Thus, E(X) for your presented Geometric Distribution is (1-p)/p and NOT (1/p). However, the conclusions are the same. The average family will consist of (1-p)/p members PLUS 1 MORE because your presented distribution indicated the probability of "k" failures (with success being at the (k+1)-th trial), thus indicating:

$$(Average \ Family \ Size) = E(X) + 1 = 1 + \frac {1 - p} {p}$$

Thus, for p=(1/2):

$$\color{red} (Average \ Family \ Size \ for \ p=(1/2)) = 2$$

Incidentally, your quoted E(X)=(1/p) corresponds to the following form of the Geometric Distribution:

$$P(X=k) = p*(1 - p)^{k - 1} \ \ \ \ k = 1,2,3,...$$

Last edited: Feb 7, 2005