Could you tell me if my reasoning is right? I'm new in probability so I'm still not secure of how I should use the classical distributions to model problems.
My problem is the following: I have a success-failure experiment such that the probability of success is $p\in(0,1)$ ($p$ is supposed to be very little, but this shouldn't change the reasoning). If we run the experiment one time, the probability of success is $p$. If we run the experiment $n$ times, the probability of having $k$ successes is $\binom{n}{k}p^k(1-p)^{n-k}$, for $0\leq k\leq n$. This is modeled by the binomial distribution.
What I want to know is an inverse problem, we can say. How many experiments we should run to have one success with probability at least $50\%$? I'm looking for the minimal number $n$ of experiments.
My idea: We can keep $n$ unknown and ask for the probability of having at least one success in $n$ experiments. This is given by $\sum_{k=1}^n \binom{n}{k}p^k(1-p)^{n-k}$. It's possible to use some program to find the minimum $n$ such that $\sum_{k=1}^n \binom{n}{k}p^k(1-p)^{n-k}\geq \frac{1}{2}$. In fact, I did this for some values of $p$, in particular, for $p=\frac{1}{10000}$ we have $n=6932$.
But I'm not sure of this argument. I was looking for the number of experiments necessary to have one success with probability at least $50\%$, but ended up calculating the number of experiments necessary to have at least one success with probability at least $50\%$.
The number of experiments necessary to have at least one success with probability at least $50\%$ can be calculated as the number of experiments necessary to have no success with probability at most $50\%$. This requires $(1-p)^n \le \frac12$ so $n \ge \dfrac{\log 2}{- \log(1-p)}.$ With your example of $p=\frac{1}{10000}$ this gives $n\ge 6931.1$ (approximately, and you will round up to the next integer).
The number of experiments necessary to have exactly one success with probability at least $50\%$ requires $n p(1-p)^{n-1} \ge \frac{1}{2}$ and this will not have a closed form solution if you do not use something like Lambert-W functions. But for small $p$ there will be no sensible solution to this anyway: in your example of $p=\frac{1}{10000}$, the maximum probability of exactly one success happens when $n=9999$ or $10000$ and is then about $36.78978\% \approx \exp(-1)$ which is too low to answer your question.