For general problem, let the probability be P(k).www.ddhw.com We have the following equations: P(0) = (1-p) * 1 + p * P(1), ... P(k) = (1-p) * P(k-1) + p * P(k+1), ... We can derive the following equations: p * P(k+1) - (1-p) * P(k) = p * P(k) - (1-p) * P(k-1). Therefore, p * P(k+1) - (1-p) P(k) = ... = p * P(0) - (1-p) * 1. When k approaches 0, both P(k) and P(k+1) approach 0. Hence, P(0) = (1-p) / p, P(1) = P(0)^2, ..., P(k) = P(0)^(k-1). www.ddhw.com
|