# I know the probability of an event to occur, so how do I find how many times the event must be attempted to get a reasonably chance of success?

If there is a 2% chance of event X to occur, how many times must X be attempted to have a reasonable probability of occurring at least once?

What is the formula used called, and how do I solve this?

• bernoulli experiments – Aksakal Mar 23 '16 at 20:07
• If this is a homework question, please add the self-study tag and read its wiki here – Marquis de Carabas Mar 23 '16 at 20:15
• Nope, not a homework question, just can't remember how to find the answer or what it's called hahaha – bob jim Mar 23 '16 at 21:32

As @Greenparker mentioned above, the number of successes (success defined as event X occurs) out of n trials follows a Binomial distribution: $Y \sim Bin(n, 0.02)$

You just need to find $P(Y \geq 1) \geq a$ , where $a$ is the probability of event occurring at least once, the above probability is equivalent to $$1 - P(Y = 0) \geq a$$ $$1 - \binom{n}{0}(1 - .02)^n \geq a$$

which simplifies to $$(1 - .02)^n \leq 1 - a$$ taking log of both sides, and dividing to $log(1-.02)$: $$n \geq \frac{log(1-a)}{log(1-.02)}$$

If we want .9 probability of success then n must be at least 114

for $a = .8$: $n >= 80$

for $a = .7$: $n >= 60$

First lets find the probability of seeing the even occur at least once in $n$ attempts. Let $Y$ be the number of times the event occurs out of $n$ attempts, where $X$ is the event, and $P(X$ occurs$)$ = .2

Then assuming the attempts are independent, $Y \sim Binomial(0.2, n)$.

Now essentially, $P(Y \geq 1) = 1 - P(Y = 0)$.

$P(Y = 0)$ is the probability that $X$ never occurs in all $n$ draws, you can find this.

Now to answer your question, if you define reasonable probability as some number $a$, you need to find $n$ such that $P(Y \geq 1) \geq a$.

My intuitive answer is 50 times, because you have a 1 in 50 chance (2%).

So, P(X) = 0.02. but that's the probability you get it to happen at least once. You can lower it to, say, 25 times, but then the chance it happens is lower.

We're looking for long answers that provide some explanation and context. Don't just give a one-line answer; explain why your answer is right, ideally with citations. Answers that don't include explanations may be removed.

• This intuitive answer is unfortunately wrong. To see why, change the 2% of the question to 50%. Apparently your intuition would then tell you to make 1/0.50 = 2 attempts. But in two attempts, there is a 3/4 chance that $X$ will occur at least once--as you can see by enumerating the four equiprobable outcomes. – whuber Mar 23 '16 at 20:14