Skip to main content
Home
plus.maths.org

Secondary menu

  • My list
  • About Plus
  • Sponsors
  • Subscribe
  • Contact Us
  • Log in
  • Main navigation

  • Home
  • Articles
  • Collections
  • Podcasts
  • Maths in a minute
  • Puzzles
  • Videos
  • Topics and tags
  • For

    • cat icon
      Curiosity
    • newspaper icon
      Media
    • graduation icon
      Education
    • briefcase icon
      Policy

      Popular topics and tags

      Shapes

      • Geometry
      • Vectors and matrices
      • Topology
      • Networks and graph theory
      • Fractals

      Numbers

      • Number theory
      • Arithmetic
      • Prime numbers
      • Fermat's last theorem
      • Cryptography

      Computing and information

      • Quantum computing
      • Complexity
      • Information theory
      • Artificial intelligence and machine learning
      • Algorithm

      Data and probability

      • Statistics
      • Probability and uncertainty
      • Randomness

      Abstract structures

      • Symmetry
      • Algebra and group theory
      • Vectors and matrices

      Physics

      • Fluid dynamics
      • Quantum physics
      • General relativity, gravity and black holes
      • Entropy and thermodynamics
      • String theory and quantum gravity

      Arts, humanities and sport

      • History and philosophy of mathematics
      • Art and Music
      • Language
      • Sport

      Logic, proof and strategy

      • Logic
      • Proof
      • Game theory

      Calculus and analysis

      • Differential equations
      • Calculus

      Towards applications

      • Mathematical modelling
      • Dynamical systems and Chaos

      Applications

      • Medicine and health
      • Epidemiology
      • Biology
      • Economics and finance
      • Engineering and architecture
      • Weather forecasting
      • Climate change

      Understanding of mathematics

      • Public understanding of mathematics
      • Education

      Get your maths quickly

      • Maths in a minute

      Main menu

    • Home
    • Articles
    • Collections
    • Podcasts
    • Maths in a minute
    • Puzzles
    • Videos
    • Topics and tags
    • Audiences

      • cat icon
        Curiosity
      • newspaper icon
        Media
      • graduation icon
        Education
      • briefcase icon
        Policy

      Secondary menu

    • My list
    • About Plus
    • Sponsors
    • Subscribe
    • Contact Us
    • Log in
    • Maths in a minute: Conditional probability

      17 November, 2023
      1 comments

      Suppose I roll a die and ask you to guess the number I roll. What's the chance of you getting it right?

      As long as the die is fair, so all numbers are equally likely to be rolled, the probability of you guessing correctly is 1/6. But what if I tell you, before I uncover the result, that the number I have rolled is odd? Then there are only three possible outcomes: 1, 3, and 5. The chance of you guessing correctly is now 1/3. Halving the number of possible outcomes has doubled your chance of getting it right.

      What we have been looking at here is a conditional probability: the probability of you guessing correctly given that I told you that I have rolled an odd number.

      More generally, given to events A and B, the conditional probability of B occurring given that A has occurred is written as P(B|A). To work it out, you can use the formula P(B|A)=P(AandB)P(A),

      where P(AandB) is the probability of both A and B occurring.

      But why is that formula true? We can view the probability of an event as the proportion among all possible outcomes in which the event occurs. In our example, this is why the probability of rolling a 5 is 1/6: there are six possible outcomes of which a 5 is one. This means that the probability P(AandB) that both A and B occurred is the proportion among all possible outcomes in which both A and B occurred. Now if we're looking for the probability P(B|A) (e.g. the number I rolled is a 5 given that it's odd) then we're also looking for a proportion among outcomes in which both A and B occurred. However, we're no longer looking for this proportion among the collection of all possible outcomes (e.g. the numbers 1 to 6), but only among the collection of all outcomes in which A has already occurred (e.g. the numbers 1,3, and 5). This means that, to get P(B|A), we have to divide the initial probability P(AandB) by the proportion of outcomes in which A has occurred, which is P(A). So P(B|A)=P(AandB)P(A),

      as we claimed above.

      If you prefer some visual intuition, look at the Venn diagram below. The entire rectangle represents all possible outcomes. The left circle represents all the outcomes in which A occurred. The right circle represents all the outcomes in which B occurred. The intersection represents all the outcomes in which both A and B occurred. Let's assume the areas of all the regions shown reflect the probabilities: the area of the entire rectangle is 1, the area of the circle representing A is P(A), etc. Then the area of the intersection of the two circles is P(AandB). The conditional probability P(B|A) is the area of the intersection, not as a proportion of the area of the entire rectangle, but as a proportion of the area of the circle representing A, which is P(A). This gives the result.

      Venn diagram

      As a little extra, note that we can rearrange the equation P(B|A)=P(AandB)P(A),

      to say P(B|A)P(A)=P(AandB).

      Noting that P(AandB)=P(BandA), we get P(AandB)=P(B|A)P(A)=P(A|B)P(B)=P(BandA).

      Rearranging the middle part of this string of equations gives P(B|A)=P(A|B)P(B)P(A).

      This is nothing less than the famous Bayes' theorem, which you can read about here.

      • Log in or register to post comments

      Comments

      DOUGLAS JORDAN

      20 May 2024

      Permalink

      One of the best explanations that I've seen on this Th. Hopefully this will help me understand the Monty Hall problem from Numberphile on Youtube.
      Thanks

      • Log in or register to post comments

      Read more about...

      probability
      conditional probability
      bayes theorem
      maths4DL
      Maths in a minute
      INI
      University of Cambridge logo

      Plus Magazine is part of the family of activities in the Millennium Mathematics Project.
      Copyright © 1997 - 2025. University of Cambridge. All rights reserved.

      Terms