# How do derive this result in stat-mech style

I'm going through (well, at least I'm planning to) Rief's book about statistical mechanic (I want to improve my knowledge). I want to be serious about this so I'm trying to solve as much problem as I can (and understand them). I came upon this one (1.5):

In a game of a Russian roulette (not recommended by the author), one inserts a single cartridge into the drum and of a revolver, leaving the other five chambers of the drum empty. One then spins the drum, aims at one's head, and pulls the trigger.
(a) What it the probability of being still alive after playing the game $N$ times?
(b) What it the probability of surviving ($N-1$) turns in this game and then being shot the $N$th time one pulls the trigger?
(c) What is the mean number of times a player gets the opportunity of pulling the trigger in this macabre game?

I believe that the starting point for (c) is:

$\left \langle n\right \rangle = \sum_{n=1}^\infty n \left(\frac{5}{6}\right)^{(n-1)} \frac{1}{6}$

Wolfram alpha tells me this is an exact sum which equals to 6 (logical). I want however, to try and imply the standard derivative trick (and this is why I'm asking this here and not in the math thread):

$\left \langle n\right \rangle = \frac{1}{6}\sum_{n=1}^\infty \frac{\partial}{\partial n} \left(\frac{5}{6}\right)^{n} = \frac{1}{6} \frac{\partial}{\partial n} \sum_{n=1}^\infty \left(\frac{5}{6}\right)^{n}$

But this is an exact sum (that equals to 1) and I can't take it's derivative. I know I could use some table to solve this, the question is if there some way to solve this in a way that a student can do this in the exam?

I hope any of what I wrote is clear and approved by the site policy.

-
you can't take the derivative outside the summation symbol -- that is, the two operations don't commute. (When you use the derivative trick in an integral, you take some derivative with respect to some parameter; not the integration variable) –  wsc Nov 15 '11 at 16:07

The trick works, you just need to apply it differently. The problem is that you are differentiating with respect to $n$, which won't work because you are summing over $n$.

Instead, the sum you wish to evaluate is,

$$\langle n \rangle = \sum_{n=1}^\infty n x^{n-1}(1-x) = (1-x) \sum_{n=1}^\infty n x^{n-1}$$ with $x=5/6$. Now this can be written as,

$$\langle n \rangle = (1-x)\frac{\partial}{\partial x} \sum_{n=1}^\infty x^{n} = (1-x)\frac{\partial}{\partial x}\left(\frac{1}{1-x} -1\right) = 1/(1-x)$$

which gives 6 for x = 5/6.

-
Thanks. Reading your answer I realized that I took the wrong derivative. It is bound to happen if you try and solve stuff when you are tired. –  Yotam Nov 15 '11 at 19:13

$$\left \langle n\right \rangle ~=~ \frac{1}{6}\sum_{n=1}^\infty n \left(\frac{5}{6}\right)^{n-1}~=~ \left.\frac{1}{6}\sum_{n=1}^\infty n x^{n-1} \right|_{x=\frac{5}{6}} ~=~ \left.\frac{1}{6}\sum_{n=1}^\infty \frac{d}{dx} x^n \right|_{x=\frac{5}{6}}$$ $$~=~ \left.\frac{1}{6}\frac{d}{dx}\sum_{n=1}^\infty x^n \right|_{x=\frac{5}{6}} ~=~ \left.\frac{1}{6}\frac{d}{dx}\frac{x}{1-x} \right|_{x=\frac{5}{6}}~=~ \left.\frac{1}{6}\frac{1}{(1-x)^2} \right|_{x=\frac{5}{6}}~=~6.$$

-