Probability formula solvers

Classical Probability

P=fnP = \frac{f}{n}

ProbabilityStatisticsProbability of an event as the number of favourable outcomes divided by the total number of equally likely outcomes.

Complement Rule

P(Ac)=1P(A)P(A^{c}) = 1 - P(A)

ProbabilityStatisticsThe chance an event does not happen is one minus the chance it does, because every trial must end in one case or the other.

Addition Rule (Mutually Exclusive Events)

P(AB)=P(A)+P(B)P(A \cup B) = P(A) + P(B)

ProbabilityStatisticsFor events that cannot both happen, the chance that either one occurs is simply the sum of their separate probabilities.

General Addition Rule

P(AB)=P(A)+P(B)P(AB)P(A \cup B) = P(A) + P(B) - P(A \cap B)

ProbabilityStatisticsThe chance that either of two events happens, correcting the simple sum by subtracting the overlap that would be counted twice.

Multiplication Rule (Independent Events)

P(AB)=P(A)P(B)P(A \cap B) = P(A) \, P(B)

ProbabilityStatisticsWhen one event has no influence on the other, the chance that both occur is the product of their separate probabilities.

Conditional Probability

P(AB)=P(AB)P(B)P(A \mid B) = \frac{P(A \cap B)}{P(B)}

ProbabilityStatisticsThe chance of A once B is known to have happened, found by rescaling the overlap to the reduced sample space B.

General Multiplication Rule

P(AB)=P(A)P(BA)P(A \cap B) = P(A) \, P(B \mid A)

ProbabilityStatisticsChance that both events happen when the second depends on the first, as in drawing two cards without replacement from a deck.

Bayes' Theorem (Two Hypotheses)

P(AB)=P(BA)P(A)P(BA)P(A)+P(BAc)(1P(A))P(A \mid B) = \frac{P(B \mid A) \, P(A)}{P(B \mid A) \, P(A) + P(B \mid A^{c}) \, \left(1 - P(A)\right)}

ProbabilityStatisticsUpdates a prior belief into a posterior after evidence arrives, weighing the true-positive rate against the false-positive rate.

Odds and Probability

O=P1PO = \frac{P}{1 - P}

ProbabilityStatisticsConverts between a probability and odds in favour, the ratio of the chance it happens to the chance it does not.

Factorial

n!=n×(n1)××2×1n! = n \times (n-1) \times \cdots \times 2 \times 1

ProbabilityAlgebraThe product of every whole number from n down to 1, counting the ways that n distinct objects can be arranged in order.

Permutations (nPr)

nPr=n!(nr)!{}_{n}P_{r} = \frac{n!}{(n-r)!}

ProbabilityAlgebraNumber of ways to choose r items from n distinct items when the order of the selection matters, as with podium finishes.

Combinations (nCr)

nCr=(nr)=n!r!(nr)!{}_{n}C_{r} = \binom{n}{r} = \frac{n!}{r! \, (n-r)!}

ProbabilityAlgebraNumber of ways to choose r items from n distinct items when the order does not matter, as with poker hands or lottery tickets.

Arrangements with Repetition

N=nrN = n^{r}

ProbabilityAlgebraNumber of sequences of length r drawn from n available choices when repeats are allowed, as with PIN codes and passwords.

Binomial Probability

P(X=k)=(nk)pk(1p)nkP(X = k) = \binom{n}{k} p^{k} (1 - p)^{\,n-k}

ProbabilityStatisticsChance of exactly k successes in n independent trials that each succeed with the same fixed probability p, as with coin tosses.

Binomial Distribution Mean

μ=np\mu = n p

ProbabilityStatisticsExpected number of successes across n independent trials that each succeed with probability p — the mean of the binomial distribution.

Binomial Distribution Variance

σ2=np(1p)\sigma^{2} = n p (1 - p)

ProbabilityStatisticsSpread of the number of successes across n independent trials, at its largest when the per-trial chance p sits at one half.

Geometric Distribution (First Success)

P(X=k)=(1p)k1pP(X = k) = (1 - p)^{\,k-1} p

ProbabilityStatisticsChance that the first success in a run of repeated independent trials arrives exactly on trial number k, after k - 1 failures.

Expected Trials Until First Success

E[X]=1pE[X] = \frac{1}{p}

ProbabilityStatisticsAverage number of independent attempts needed before the first success when each attempt succeeds with probability p.

Poisson Probability

P(X=k)=λkeλk!P(X = k) = \frac{\lambda^{k} e^{-\lambda}}{k!}

ProbabilityStatisticsChance of exactly k events in a fixed interval when events occur independently at a constant average rate lambda.

Expected Value of a Bet

E=pW(1p)LE = p \, W - (1 - p) \, L

ProbabilityStatisticsAverage profit per play of a two-outcome wager that pays W with probability p and costs L the rest of the time, over many plays.

Probability of At Least One Success

P=1(1p)nP = 1 - (1 - p)^{n}

ProbabilityStatisticsChance that at least one of n independent attempts succeeds, found as one minus the chance that every single attempt fails.

Birthday Problem (All Distinct)

P=N!(Nn)!  NnP = \frac{N!}{(N - n)! \; N^{\,n}}

ProbabilityStatisticsChance that n independent picks from N equally likely options are all different, the engine behind the birthday paradox.

Hypergeometric Probability

P(X=k)=(Kk)(NKnk)(Nn)P(X = k) = \frac{\binom{K}{k} \binom{N - K}{n - k}}{\binom{N}{n}}

ProbabilityStatisticsChance of drawing exactly k successes in a sample of n taken without replacement from a population of N holding K successes.