Compound Probability Calculator (AND / OR)

Compute P(A and B), P(A or B), and P(A|B) for two events, whether they are independent or dependent.

Inputs

Probability of event A (0 to 1).

Probability of event B (0 to 1).

Independent events: P(A∩B) = P(A)·P(B). Otherwise enter the joint probability.

Joint probability, used only in dependent mode.

Result

Loading calculator…

How to use this calculator

  • Enter the individual probabilities P(A) and P(B), each between 0 and 1.
  • Choose whether the events are independent or dependent.
  • For dependent events, enter the joint probability P(A and B).
  • Read P(A and B), P(A or B), and the conditional probabilities.

About this calculator

Compound probability deals with how two events combine. The "AND" probability, P(A and B), is the chance both happen; for independent events — where one has no effect on the other, like two separate coin flips — it is simply the product P(A)·P(B). The "OR" probability, P(A or B), is the chance at least one happens, found by adding the individual probabilities and subtracting the overlap so it is not double-counted: P(A) + P(B) − P(A and B). The conditional probability P(A|B) is the chance of A given that B has occurred, equal to the joint probability divided by P(B). This calculator handles both independent events (where it computes the joint probability for you) and dependent events (where you supply the joint probability), and reports all the combinations along with a check of whether the events are actually independent.

How it works — the formula

Independent: P(A∩B) = P(A)·P(B) P(A∪B) = P(A) + P(B) − P(A∩B) P(A|B) = P(A∩B) ÷ P(B)

The union adds the two probabilities and removes the double-counted overlap; the conditional renormalizes the joint probability by the probability of the conditioning event.

Worked examples

Example 1
Independent: P(A)=0.5, P(B)=0.4
Inputs:
pa=0.5, pb=0.4, mode=independent
Output:
AND 0.2, OR 0.7, P(A|B) 0.5
Example 2
Two coin heads
Inputs:
pa=0.5, pb=0.5, mode=independent
Output:
AND 0.25, OR 0.75
Example 3
Dependent: P(A)=0.5, P(B)=0.4, P(A∩B)=0.3
Inputs:
pa=0.5, pb=0.4, mode=dependent, pand=0.3
Output:
OR 0.6, P(A|B) 0.75

Limitations

  • Dependent mode requires a valid joint probability you supply.
  • Assumes well-defined probabilities in [0, 1].
  • Does not handle more than two events at once.

Results follow from the probability axioms given consistent inputs.

Frequently asked

How do I find the probability of A and B?+
For independent events, multiply: P(A and B) = P(A) × P(B). For dependent events, P(A and B) = P(A) × P(B|A), so you need the conditional or the joint probability directly.
How do I find the probability of A or B?+
Add the two probabilities and subtract the overlap: P(A or B) = P(A) + P(B) − P(A and B). Subtracting the intersection avoids counting the cases where both occur twice.
What does independent mean?+
Two events are independent if knowing one occurred does not change the probability of the other, so P(A|B) = P(A) and P(A and B) = P(A)·P(B). Coin flips and dice rolls are classic independent events; drawing cards without replacement is not.
What is conditional probability P(A|B)?+
It is the probability of A given that B has happened, computed as P(A and B) ÷ P(B). It restricts attention to the cases where B occurred and asks how often A also occurs among them.
Can P(A and B) be larger than P(A) or P(B)?+
No. The joint probability can never exceed either individual probability, since the intersection is a subset of each event. If you enter a larger joint probability in dependent mode, the inputs are inconsistent.
Are mutually exclusive events the same as independent?+
No — they are nearly opposite. Mutually exclusive events cannot both happen (P(A and B) = 0), so they are strongly dependent: if one occurs, the other definitely did not.

Related calculators

More tools you might like

Hand-picked tools that pair well with this one — same audience, same intent.