How to use the probability calculator
- Enter P(A), the probability of the first event, as a decimal between 0 and 1.
- Enter P(B), the probability of the second event, in the same format.
- Read the computed joint, union, conditional and complement probabilities below.
- Adjust either value to see how changes affect every result instantly.
How the probability formulas work
This probability calculator assumes events A and B are independent unless you interpret the outputs differently. For independent events, the joint probability is simply the product of the two individual probabilities:
P(A ∩ B) = P(A) × P(B)
The union (the chance that at least one event occurs) uses the addition rule:
P(A ∪ B) = P(A) + P(B) - P(A ∩ B)
Conditional probability measures the likelihood of A given that B has already occurred:
P(A | B) = P(A ∩ B) / P(B)
For example, if P(A) = 0.6 and P(B) = 0.4, then P(A ∩ B) = 0.24, P(A ∪ B) = 0.6 + 0.4 - 0.24 = 0.76, and P(A | B) = 0.24 / 0.4 = 0.6. Because the events are independent, P(A | B) equals P(A).
Common probability values reference
The table below shows precomputed results for frequently used probability pairs assuming independence.
| P(A) | P(B) | P(A ∩ B) | P(A ∪ B) | P(A | B) |
|---|---|---|---|---|
| 0.5 | 0.5 | 0.25 | 0.75 | 0.5 |
| 0.5 | 0.1667 | 0.08335 | 0.58335 | 0.5 |
| 0.2 | 0.3 | 0.06 | 0.44 | 0.2 |
| 0.9 | 0.8 | 0.72 | 0.98 | 0.9 |
| 1.0 | 0.5 | 0.5 | 1.0 | 1.0 |
Use these benchmarks to sanity-check your own calculations or to understand how extreme values behave.
Practical use cases
Event probability calculations appear across many fields. In quality control, engineers multiply defect rates of independent components to find the chance that an entire assembly fails. If component A fails 2% of the time and component B fails 5% of the time, the joint failure rate is 0.02 × 0.05 = 0.001, or 0.1%.
In medical testing, conditional probability helps interpret results. If a disease affects 1 in 1,000 people and a test has a 5% false positive rate, Bayes' theorem (which builds on conditional probability) reveals the actual likelihood of disease after a positive result.
Game designers use union probability to balance loot drops. If item A drops with P(A) = 0.1 and item B with P(B) = 0.15, the chance of getting at least one is 0.1 + 0.15 - 0.015 = 0.235.
Independent versus dependent events
This tool computes joint probability using the multiplication rule for independent events: P(A ∩ B) = P(A) × P(B). Two events are independent when the occurrence of one does not change the likelihood of the other. Rolling a die and flipping a coin are classic examples.
When events are dependent, the formula changes to P(A ∩ B) = P(A) × P(B | A). Drawing cards without replacement is dependent because removing one card alters the composition of the deck. If you need to model dependent events, calculate P(B | A) manually first, then enter the resulting joint probability into a workflow that accounts for it.
A common mistake is applying the independent formula to dependent scenarios, which overestimates or underestimates the true joint probability. Always verify whether knowing that A occurred gives you information about B.
Complement and mutually exclusive events
The complement of an event is everything outside it: P(not A) = 1 - P(A). Complements are useful when calculating "at least one" scenarios. The probability of at least one success in three independent trials, each with P = 0.2, is 1 - (0.8)^3 = 0.488.
Mutually exclusive events cannot happen together, meaning P(A ∩ B) = 0. In that case the union simplifies to P(A ∪ B) = P(A) + P(B). Note that mutually exclusive events with nonzero probabilities are never independent, because knowing A occurred guarantees B did not. This probability calculator assumes independence rather than mutual exclusivity, so keep that distinction in mind when interpreting the joint output.
Worked examples
Each result below was produced by the same code the tool runs, so you can check your own numbers against them.
| Example | Input | Result |
|---|---|---|
| Fair coin and die roll | P(A): Probability of event A: 0.5; P(B): Probability of event B: 0.1667 | P(A): 0.5; P(B): 0.1667; P(A ∩ B) joint: 0.08335; P(A ∪ B) union: 0.58335; P(A | B) conditional: 0.5; P(B | A) conditional: 0.1667; P(not A): 0.5; P(not B): 0.8333 |
| Two independent draws (20% and 40%) | P(A): Probability of event A: 0.2; P(B): Probability of event B: 0.4 | P(A): 0.2; P(B): 0.4; P(A ∩ B) joint: 0.08; P(A ∪ B) union: 0.52; P(A | B) conditional: 0.2; P(B | A) conditional: 0.4; P(not A): 0.8; P(not B): 0.6 |
| Certain and impossible events | P(A): Probability of event A: 1; P(B): Probability of event B: 0 | P(A): 1; P(B): 0; P(A ∩ B) joint: 0; P(A ∪ B) union: 1; P(A | B) conditional: Undefined; P(B | A) conditional: 0; P(not A): 0; P(not B): 1 |
| High probability overlap | P(A): Probability of event A: 0.9; P(B): Probability of event B: 0.8 | P(A): 0.9; P(B): 0.8; P(A ∩ B) joint: 0.72; P(A ∪ B) union: 0.98; P(A | B) conditional: 0.9; P(B | A) conditional: 0.8; P(not A): 0.1; P(not B): 0.2 |
FAQ
What is a probability calculator?
A probability calculator takes the likelihoods of individual events and applies standard formulas to produce joint, union, conditional and complement probabilities. It removes manual arithmetic errors and updates instantly as you change inputs.
Does this tool handle dependent events?
The calculator assumes events A and B are independent, using P(A ∩ B) = P(A) × P(B). For dependent events, you must first determine the conditional probability manually and adjust your approach accordingly.
Why is P(A | B) undefined sometimes?
Conditional probability divides the joint probability by P(B). When P(B) is zero, division by zero is mathematically undefined because event B can never occur.
Can I enter percentages instead of decimals?
No. Probabilities must be entered as decimals between 0 and 1. To convert a percentage, divide it by 100 first. For example, 25% becomes 0.25.
Is my data sent to a server?
No. All calculations run locally in your browser. Nothing is uploaded or stored anywhere.
What is the difference between joint and union probability?
Joint probability P(A ∩ B) is the chance both events occur together. Union probability P(A ∪ B) is the chance that at least one of them occurs.