I need to compute $f(x)=\sum_{i=0}^\infty \left(\left\lfloor\frac{i}{2^x}\right\rfloor+x+1\right)(1-p)^{i-1}p$and minimize it with respect to $x$ (an expression which will depend on $p$).
Compute infinite sum
-
0Actually if I had $f(x)=x+1+\sum$, everything would be so much nicer. – 2012-12-29
1 Answers
You can break the sum up into pieces that can be handled as follows:
$\frac{p}{1-p} \left [ (1+x) \sum_{i=0}^{\lceil{2^x}\rceil} (1-p)^i + (2+x) \sum_{i=\lceil{2^x}\rceil + 1}^{2 \lceil{2^{x}}\rceil} (1-p)^i + (3+x) \sum_{i=2 \lceil{ 2^{x}}\rceil + 1}^{3 \lceil{2^{x}}\rceil} (1-p)^i + \ldots \right ]$
$ =\frac{p}{1-p} \sum_{k=1}^{\infty} (k+x) \sum_{i=(k-1)\lceil{2^x}\rceil + 1}^{k \lceil{2^x}\rceil} (1-p)^i $
You can see that this is going to end up as a simple geometric series (and its derivative):
$ = \frac{p}{1-p} \sum_{k=1}^{\infty} (k+x) \left [ (1-p)^{(k-1)\lceil{2^x}\rceil} - (1-p)^{k\lceil{2^x}\rceil} \right ] $
$ = \frac{p^2}{1-p} \sum_{k=1}^{\infty} (k+x)\left[(1-p)^{\lceil{2^x}\rceil} \right ]^{k-1} $
Using the fact that $\sum_{k=1}^{\infty} k q^{k-1}$ = 1/(1-q)^2, we get the following expression for the sum:
$ = \frac{p^2}{1-p} \left [\frac{(1-p)^{\lceil{2^x}\rceil}}{1- (1-p)^{\lceil{2^x}\rceil}} + \frac{x}{\left [1- (1-p)^{\lceil{2^x}\rceil}\right ]^2} \right ] $
As for minimizing the quantity represented by this expression, I would plot it for values of $x$ of interest.
-
0I am adding more steps. – 2012-12-30