0
$\begingroup$

I am trying to simulate n random discrete variable which has the following pmf

$P(X = k) = (1-p)^2kp^{k-1}$

I am thinking about using the inverse transform sampling method and I am trying to find the cdf.

$P(X \le k) = 1 - P(X > k) = 1- P(X \ge k+1) = \sum_{x=k+1}^{\infty} (1-p)^2kp^{k-1} = 1-[ (1-p)^2\sum_{x=k+1}^{\infty}kp^{k-1}]$

= $1-(1-p)^2[(k+1)p^k + (k+2)p^{k+1}+ (k+3)p^{k+4} + ...] $

I can't seem to calculate this sum ($\sum_{x=k+1}^{\infty}kp^{k-1}$).

Any help or hint will be appreciated !

$\endgroup$

1 Answer 1

1
$\begingroup$

\begin{align}S &= (k+1) p^k + (k+2) p^{k+1} + (k+3) p^{k+2} + \cdots \\ pS &= \phantom{(k+1) p^k +{}} (k+1) p^{k+1} + (k+2) p^{k+2} + (k+3) p^{k+2} + \cdots \end{align} Subtracting the two equations yields $$(1-p) S = p^k + p^{k+1} + p^{k+2} + \cdots.$$ The right-hand side is a geometric series I assume you can compute. Then divide both sides by $1-p$.

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .