The question:
In a group of $n+1$ men, one of them creates a secret (I called him the Creator in my answer), and tells it to another man, every man keeps telling another man the secret (chosen randomly from the $n$ men - not including himself). all the events of telling the secret between eachother are independent.
What are the probability function of the number of times the secret has been told until it gets back..:
a) to it's creator.
b) to a man that has already heard the secret.
My Work:
a) Let $X$ be the number of times the secret has been told until it gets back to the secret's creator,
Then I'm searching for $P(X=k)$, but $k$ must be at least two since the creator cannot tell himself his own secret. So $k=2,3,4,\dots$
$P(X=2)=P(\text{Creator}\to \text{RandomMan}\to \text{Creator})= \frac{1}{n}$
$P(X=3)=P(\text{Creator}\to \text{Man}\to \text{Man}\to \text{Creator})=\frac{n-1}{n} \frac{1}{n}$ (The first man must not tell the creator so $n-1$).
$P(X=4)=(\frac{n-1}{n})^2 \cdot \frac {1}{n}$
$\dots$
$P(X=k)=(\frac{n-1}{n})^{k-2} \cdot \frac{1}{n}$.
b) let Y be the number of times the secret has been told until it gets back to a man that has already heard the secret.
$k=2,3,4,\dots,n+1$ since after $n$ times surely the secret will be told to a man that has already heard it because after $n$ times all of them will know the secret.
$P(Y=2)=P(\text{Creator}\to \text{man} \to \text{creator})=\frac{1}{n}$.
$P(Y=3)=P(\text{Creator} \to \text{man_1} \to \text{man_2} \to \text{man_1 OR Creator})=\frac{n-1}{n} \cdot \frac{2}{n}$
$P(Y=4)=P(\text{Creator}\to \text{Man_1}\to \text{Man_2}\to \text{Man_3}\to \text{Man_1 Or Man_2 Or Creator})$ $=\frac{n-1}{n} \frac{n-2}{n} \frac{3}{n}$.
$\dots$
$P(Y=k)=\frac{(n-1)(n-2)\cdots (n-k+2)}{n^{k-2}} \frac{k-1}{n}=\frac{(n-1)!}{(n-k+1)!\cdot n^{k-2}} \frac{k-1}{n}$.
Done
I would love to hear feedback if my solution is correct or not and what mistakes did I make, also I'm open to hear if any notation I wrote it somewhat incorrect since I'm new to random variables.
Thanks in advance
This is wrong. Actually $P(X=2) = 1/n$ (the probability is that the second randomly chosen person is the creator). $P(X=3)$ is the probability that the second person is not the creator, while the third is, i.e. $\frac{n-1}{n}\cdot \frac 1n$.
The probabilities for $Y$ are flawed similarly. Actually, to compute its expected value, it is better to use the formula (which is valid for non-negative integer-valued random variables) $$ E[Y] = \sum_{n= 0}^\infty P(Y>n). $$
– zhoraster Apr 24 '21 at 18:42