Probability Calculator
For two events: the chance of A or B, A given B and whether they are independent. Also Bayes' theorem.
How it works
For two events give P(A), P(B) and, if you know it, P(A and B). Leave P(A and B) empty if the events are independent. The tool gives the union, the chance of neither, conditional chances and whether they are independent. Bayes mode updates a prior after seeing evidence.
The formula
P(A or B) = P(A) + P(B) - P(A and B) P(A given B) = P(A and B) / P(B) Bayes: P(H given E) = P(E given H) P(H) / P(E)
Worked example
A disease affects 1% of people. A test catches 90% of cases and gives a false alarm to 5% of healthy people. A positive test means only about a 15% chance of disease.
Good to know
- A and B can only overlap by a possible amount. The tool rejects impossible values.
- Independent means P(A and B) = P(A) x P(B).
- A rare condition makes most positives false alarms.
Common questions
- Are mutually exclusive events independent?
- No. If they cannot both happen, P(A and B) is 0, which is not P(A) x P(B) unless one of them is 0.
- What if I only know P(A given B)?
- Multiply it by P(B) to get P(A and B), then type that.
- Why is the Bayes answer small?
- Because the prior is small. The evidence has to beat it.
More in Math, Science & Engineering.
Type a whole expression and see the answer with each step in the order it was worked out.
OPEN →Matrix SolverDeterminant, inverse, rank, transpose, products and linear systems for small matrices.
OPEN →Laplace Transform TableStandard Laplace pairs and properties. Type part of a function like sin or e^ to filter.
OPEN →