Home / Math / Probability Calculator
Probability Calculator: Single Events, Two Events and Binomial
Work out a simple probability from counts, combine two events as independent or mutually exclusive, or find the chance of exactly, at most or at least k successes in a number of identical trials.
The basic rules
A probability is a number from 0 (impossible) to 1 (certain), often written as a percentage. When all outcomes are equally likely, P(event) = favourable outcomes ÷ total outcomes. A fair die shows a six with probability 1/6, about 16.67%. The chance an event does not happen is the complement, 1 − P. Odds are a different way to express the same thing: odds in favour of 1 to 5 correspond to a probability of 1/6, because the probability compares the event with all outcomes while odds compare it with the remaining outcomes.
Combining two events
Two rules cover most questions about two events. For independent events, where one outcome does not influence the other, the chance of both is the product: P(A and B) = P(A) × P(B). The chance of at least one is P(A) + P(B) − P(A and B), subtracting the overlap that would otherwise be counted twice. For mutually exclusive events, which cannot happen together, the overlap is zero, so P(A or B) = P(A) + P(B). Rolling a 2 and rolling a 5 on a single die are mutually exclusive. Rolling a 2 on one die and a 5 on another are independent. Events can be neither, for example drawing two cards without replacement, and then conditional probability is needed.
Repeated trials: the binomial distribution
If you repeat the same yes/no trial n times, each with success probability p and independent of the others, the chance of exactly k successes is:
P(X = k) = C(n, k) × pk × (1 − p)n − k
For 10 fair coin tosses and 3 heads, C(10, 3) = 120 and each specific sequence has probability 1/1024, so the answer is 120/1024 = 0.1171875. The page also sums the distribution to give "at most k" and "at least k", and shows the chance of at least one success, 1 − (1 − p)n, which is the quickest route to questions such as "what are the odds of at least one six in four rolls?". The mean is n p and the standard deviation is √(n p (1 − p)).
Common mistakes
- The gambler's fallacy. After five heads in a row, a fair coin is still 50% to land heads. Independent trials have no memory.
- Assuming independence. Multiplying probabilities is only correct when events do not affect each other. Related events, such as two faults caused by the same power surge, need more careful treatment.
- Adding probabilities of overlapping events. Adding without subtracting the overlap can produce totals above 100%.
- Confusing odds and probability. Odds of 1:1 mean a 50% probability, not 100%.
- Wrong inputs for the binomial. The model needs a fixed number of trials and a constant success probability. Sampling without replacement from a small population breaks that assumption.
Worked example
A fair coin is tossed 10 times. What is the chance of getting exactly 3 heads?
Inputs
| What do you want to calculate? | Repeated trials (binomial) |
|---|---|
| Number of trials n | 10 |
| Probability of success on each trial | 50 % |
| Number of successes k | 3 |
Result
That is 11.7188%. Exact binomial formula with success probability 50% per trial.
| P(X = 3) | 0.117188 |
|---|---|
| P(X ≤ 3) | 0.171875 |
| P(X ≥ 3) | 0.945313 |
| P(at least one success) | 0.999023 |
| Expected successes n × p | 5 |
| Standard deviation √(n p (1 − p)) | 1.5811 |
Accuracy note: Results use standard double-precision arithmetic, so very large or very small values may be rounded. Check important results by another method.
Frequently asked questions
How do I calculate the probability of two independent events both happening?
Multiply their individual probabilities. For two events with 50% and 30% chances, the chance of both is 0.5 × 0.3 = 0.15, which is 15%.
What is the difference between probability and odds?
Probability compares the event with all outcomes, while odds compare it with the outcomes where it does not happen. A probability of 1/6 corresponds to odds of 1 to 5.
What does mutually exclusive mean?
Two events are mutually exclusive when they cannot happen at the same time, such as heads and tails on one toss. Their chances add, and the chance of both is zero.
How do I find the probability of at least one success?
Subtract the chance of no successes from one. With n independent trials the chance of none is (1 − p) to the power n, so at least one has probability 1 − (1 − p)^n.
Is the binomial result exact?
The probabilities are computed from the exact binomial formula using logarithms of factorials, so they are accurate to roughly ten significant digits for up to 1,000 trials.
Related calculators
References and sources
- Standard probability theory: the addition and multiplication rules and the binomial distribution, as in any introductory statistics text.