# Discrete random variable summation problem.

$X$ is a discrete random variable taking on the values $X = 1,3,3^2,3^3,\dots,3^m$ and $f(x) = P(X=x)=\dfrac c x$ for a constant $c$. Find $c$.

Solution: Since $P(X)=1$, we know that $\dfrac c x=1$, so $c=x$. To find x, we have $x = \sum_0^m 3^m$. Since this series summation diverges to infinity, $c = \infty$. This is a fascinating problem, however, something doesn't seem right ... in other words, how can $x = \infty$? Is the first statement $c=x$ incorrect?

-

I think you're making a number of erroneous assumptions. You have $f(x)=P(X=x)=c/x$ is the probability distribution of $X$ and the state space is $1,3,\ldots,3^m$. It seems like the problem is asking you to find the normalization $c$ for the probability distribution. To wit, you must have that:

$1=\sum_{i=0}^m P(X=3^i)=\sum_{i=0}^m \frac{c}{3^i}=c\frac{1-(1/3)^{m+1}}{1-(1/3)}$.

which you can check by a similar argument to Peter's answer. Now solve for $c$.

The point is that you don't want to say that $P(X=x)=c/x=1$ for every $x$, that doesn't make much sense since you'd be assigning probability 1 to each event. It's the sum that should equal 1. As well, take care in interpreting $P(X=x)$, this is lingo for asking the probability of the random variable $X$ being equal to $x$, which the problem says is proportional to $1/x$. The point is $x$ lives in the range of $X$, so it doesn't make much sense to try and solve for $x$.

-

The probability that $X=1$ is $\dfrac{c}{1}$, the probability that $X=3$ is $\dfrac{c}{3}$, and so on. It follows that $$\frac{c}{1}+\frac{c}{3}+\frac{c}{3^2}+\cdots +\frac{c}{3^m}=1.$$ We want to find the sum of the finite geometric series $1+x+x^2+\cdots+x^m$. where $x=1/3$. Let
$$f(m)=1+x+x^2+\cdots+x^m.$$ Note that $$xf(m)=x+x^2+x^3+\cdots+x^{m+1}.$$ Subtract. We get $$(1-x)f(m)=1-x^{m+1},$$ and therefore $$f(m)=\frac{1-x^{m+1}}{1-x}.$$ Finally, put $x=1/3$ and note that $c=1/f(m)$.

Remark: If instead of stopping at $3^m$, we continue forever, then instead of the finite sum of the answer, we have an infinite sum. But since $(1/3)^{n+1}$ approaches $0$ as $n\to\infty$, the infinite geometric series has sum $1/(1-x)=3/2$, and therefore we get $c=2/3$.

-