I am presented with a problem as follows:
A listener is receiving messages with a wait time in between two consecutive messages that is exponentially distributed with a mean of 1 time unit. After any given message, there is a 1/2 chance that no further messages will be received. What is the mean and variance of the time until the final message is received?
Before considering the chance of no further messages arriving, the time taken until the nth message arrives seems to be modeled by a Gamma distribution with
This would mean the mean time until the nth message is $n$, and the variance is also $n$. But then there's the issue of the 1/2 chance of a message being the final message. This makes a geometric distribution for which message will be the final message, with a mean of $2$, and a variance of $(1-1/2)/(1/2)^2 = 2$, if I am not mistaken. The mean time until this final message would then be expected to be $n$ where $n=2$, ergo $2$, but how do I go about finding the variance in a situation like this?