Maths notes

Probability Notes: Formulas, Tricks and Solved Examples

Classical probability with counting, conditional probability and independence, Bernoulli trials and the binomial distribution, random variables with mean and variance, total probability and Bayes theorem, and the addition rule.

By Sunil Kumar. Updated 5 December 2026.

Classical probability and counting

Definition
Complement
  • Count the total and the favourable cases with the same rule. If the total uses ordered outcomes, the favourable count must be ordered too.
  • Two dice: 36 outcomes. Number of ways to get each sum:
Sum23456789101112
Ways12345654321
  • Three dice: 216 outcomes. Ways for sums 3 to 10: 1, 3, 6, 10, 15, 21, 25, 27. The table is symmetric about 10.5.
  • Cards: 52 cards, 4 suits of 13, 26 red and 26 black, 12 face cards (J, Q, K), 4 aces.
  • Drawing without replacement: use combinations, for of one kind and of another.
  • Drawing with replacement: the draws are independent; multiply the single-draw probabilities.
  • Numbers chosen from to : for conditions like "sum is even", "product is divisible by 3", "numbers are in AP", sort the numbers into classes (odd and even, or remainders) and count from the classes.
  • Three numbers from to in AP: the first and third must have the same parity. Number of such triples for even .
  • Arrangements: probability that two given people sit together in a row of is ; around a round table .
  • Leap year has 53 Sundays with probability ; an ordinary year .
  • Divisibility by a number in random digits or random integers: use the cycle of remainders. For divisible by 5, the last digits of powers of 7 repeat as 7, 9, 3, 1.
  • Odds in favour means . Odds against means .
Shortcut "At least one", "not all", "at most" are faster through the complement. Work out which of the event and its opposite has fewer cases before counting.

Worked example. Two dice are thrown. Find the probability that the sum is a prime number.

Show the method
  1. Prime sums are 2, 3, 5, 7, 11 with ways.
  2. Probability .

Conditional probability and independence

Conditional probability
Multiplication rule
Independent events
  • Conditional probability shrinks the sample space to . Often the fastest way is to list the outcomes in and count those that are also in .
  • If and are independent, so are and , and , and .
  • Independent events: . Probability that exactly one occurs .
  • A problem solved independently by people with probabilities : it is solved with probability .
  • Mutually exclusive means . Independent means . Two events with non-zero probabilities cannot be both.
  • Three events are independent only if all three pair conditions and hold.
  • , but has no such simple link with .
  • exactly when .
  • Turn by turn games: if the player who starts wins with probability at each turn, for two players, where . For three players the chances are in the ratio .
Common mistake "Given that at least one is a six" and "given that the first is a six" are different conditions with different reduced sample spaces (11 outcomes and 6 outcomes for two dice).

Worked example. A family has two children and at least one is a boy. Find the probability that both are boys.

Show the method
  1. Reduced sample space: BB, BG, GB. Three equally likely outcomes.
  2. Probability .

Bernoulli trials and the binomial distribution

Binomial distribution
Mean and variance
  • Conditions: a fixed number of independent trials, two outcomes, the same in each trial.
  • Mean is always greater than the variance, and . Given mean and variance: , , .
  • . To find the least number of trials for this to exceed a given value, solve .
  • is greatest at . If is an integer, both and are the most likely.
  • A fair coin tossed times: . for odd is .
  • Sum of the given mean and variance, or their product, gives two equations for and .
  • First success on the th trial: . Success on an even numbered trial for the first time: .

Worked example. The mean and variance of a binomial distribution are 4 and 2. Find .

Show the method
  1. , so and .
  2. .

Random variables, mean and variance

Probabilities add to one
Mean
Variance
  • If the table has an unknown , first use . Reject values of that make any probability negative.
  • and .
  • Number of successes in draws without replacement: find with combinations, then use the formulas.
  • For sampling without replacement the mean is still (fraction of the wanted kind). Two cards drawn from a pack: mean number of aces .
  • One die: mean , variance . Sum of two dice: mean , variance .
  • Expected gain in a game: , with losses negative.

Worked example. A random variable takes the values 0, 1, 2, 3 with probabilities , , , . Find its mean.

Show the method
  1. gives .
  2. Mean .

Total probability and Bayes theorem

Total probability
Bayes theorem
  • Use them when the experiment has two stages: first a choice among cases (which bag, which machine, which coin), then the observed result .
  • Total probability answers "what is the chance of the result". Bayes answers "the result happened; what is the chance it came from case ".
  • Lay the work out as a table with one row per case: , , and their product. The sum of the products is the total probability; each product divided by the sum is the Bayes answer.
  • Transfer problems (a ball moved from bag 1 to bag 2, then a draw from bag 2): the cases are the colours of the transferred ball.
  • A person who speaks the truth with probability reports an event of probability : .
  • Testing problems: a rare condition with an imperfect test gives a posterior far smaller than the accuracy of the test.

Worked example. Bag I has 3 red and 4 black balls. Bag II has 5 red and 6 black balls. One bag is chosen at random and a ball drawn from it is red. Find the probability that it came from bag II.

Show the method
  1. .
  2. .

Addition rule and algebra of events

Two events
Three events
  • : only .
  • Exactly one of , : .
  • Neither: . De Morgan's laws turn "not (A or B)" into "not A and not B".
  • Bounds: and .
  • Exactly two of three events: . Exactly one: .
  • A Venn diagram with the regions filled from the inside outwards settles most questions of this kind.
Revise with the short notesSolve questions of this chapterAll maths notes