# Decoding Probability Formulas: Understand Chance and Uncertainty

In this article, we will briefly discuss the probability formulas that can be used to calculate the probability of any event.

Probability is a branch of mathematics that deals with randomness, chance, and uncertainty. It is a measure or estimation of how likely an event will occur. From weather forecasting to estimating a stock’s potential return, probability assesses the likelihood of various events and guides decision-making. While making decisions, we often rely on intuitions to make sense of the likelihood of various events. However, these intuitions can be misleading; to overcome this problem, we use probability formulas. This article will briefly discuss different probability formulas and how to use them.

**Must Read: Introduction to Probability**

But before that, let’s glimpse some key terminologies used in Probability.

**Key Terminologies Used in Probability**

Terms |
Description |

Experiment |
A process that produces a well-defined outcome. Example: tossing a coin, drawing a card from the deck of 52 cards. |

Sample Space |
Set of all possible outcomes of an experiment. Example: when rolling a dice, the sample space is {1, 2, 3, 4, 5, 6}. |

Event |
Subset of a sample space.Example: In rolling a die, the event “rolling an odd number” includes the outcomes {1, 3, 5}. We use different events in probability, such as Independent Events, Dependent Events, and Mutually Exclusive Events. |

Random Variable |
A function that assigns a numeric value to each outcome in the sample space. |

Probability |
It is the ratio of the number of favourable outcomes to the number of possible outcomes. In simple terms, it is defined as “How likely is something to happen”. |

Probability Distribution |
A function that describes the possibility of all possible values of a random variable. A table, formula, or graph can represent it. |

Till now, we got enough understanding of the basics of probability. Now, it’s time to explore the formulas of probability.

Let’s start with the basic probability formula.

**The Basic Formula: Formula of Probability**

Probability is the ratio of the number of favourable outcomes to the total number of outcomes.

Let A be any event, then

**P(A) = Number of Favourable Outcomes / Total Number of Possible Outcomes**

where

P(A): Probability of Event A and **0 <= P(A) <= 1**

**Example: What is the probability of getting exactly one head when two coins are tossed?**

**Solution: **Sample Space for tossing two coins:

S = {HH, HT, TH, TT}

Therefore, the total number of possible outcomes is 4.

A: Event of getting exactly two heads

=> Favourable Outcome = {HH}

=> P(A) = a number of favourable outcomes / Total number of outcomes = 1/ 4

Hence, P(A) = 1/4

**Must Read: What is the Difference Between Probability and Likelihood**

**The Addition Rule**

Let A and B be two events, and then the addition rule calculates the probability of either event A or event B occurring.

**Formula: P(A U B) = P(A) + P(B) – P(A ∩ B)**

Note: If A and B are two mutually exclusive events, then the formula will be:

**P(A U B) = P(A) + P (B)**

*Related Read – Probability and Non Probability Sampling*

**The Multiplication Rule**

The multiplication rule occurs simultaneously when two events (let A and B) occur.

**Formula:**

**P(A ∩ B) = P(A) x P(B|A)**

P(B|A) represents the probability of occurrence of B, given that event A already occurred.

Note: If events A and B are independent events, then,

**P(A ∩ B) = P(A) x P(B)**

**Conditional Probability**

Condition Probability is the probability of an event occurring given that another event has already occurred. i.e. we try to calculate the probability of the second event given that the first event has already occurred.

The formula for conditional probability is

**P(A|B) = P(A ∩ B) / P(B)**

P(A|B) represents the probability of occurrence of A, given that event B already occurred.

**Example:** **Consider a deck of 52 playing cards. The deck contains 26 Red Cards (13 Hearts and 13 Diamonds**) and 26 Black Cards (13 Clubs and 13 Spades).

Let’s consider two cases:

A = Drawing a Red Card

B = Drawing a Heart

Then, what will be the probability of drawing a Heart given that the card drawn is Red?

**Answer:** Here, we have two events, drawing a red card and drawing a heart, since we have to find the probability of drawing a heart given that the card is red.

i.e., P(B|A)

From the conditional probability formula, we have:

P(B|A) = P (B **∩** A) / P(A)……(i)

P(A) = Number of Red Cards / Total Number of Cards = 26/52 = 1/2

=> P(A) = 1/2

P(B **∩** A) = Number of Common Cards (Heart and Red) / Total Number of Cards = 13/ 52 = 1/4

=> P(B **∩** A) = 1/4

Now, substituting the value of P(A), and P(B intersect A) in (i), we get

=> P(B|A) = P(B **∩** A)/ P(A) = (1/4) / (1/2) = 2/4 = 1/2

=> P(B|A) = 1/2

*Must Check: Conditional Probability*

**Bayes Theorem**

It is one of the fundamental theorems of probability. It describes the relationship between the probability of an event given some evidence and the probability of the evidence without any evidence.

In simple terms, it gives the relationship between the conditional probabilities of two events.

Mathematically, it can be expressed as

**P(A|B) = (P(B|A) *P(A) ) / P(B)**

where,

P(A|B) represents the probability of event A occurring, given that event B has occurred.

P(B|A) is the probability of event B occurring, given that event A has occurred.

**Example: Consider a case where 1% of the population has a rare genetic disease.**

A new test has been developed to detect the disease. The test has a 95% True Positive Rate (i.e., the probability that a person with the disease will test positive) and a 2% False Positive Rate (i.e., the probability that a person without the disease will test positive).

If the test is performed over any random person, the result is positive for the disease. What is the probability that the person

**has the disease?**

Solution:

Firstly, let’s segregate the above question into two different events:

A: Having a genetic disease

B: Testing positive for the disease

=> P(A) = 0.01 (the probability of having the disease)

To Find: Probability of having the disease given a positive test result, i.e. P(A|B)

Now, let’s find all the probabilities:

P(A) = 0.01 (the probability of having the disease)

TPR = P(B|A) = 0.95 (the probability that a person with the disease will test positive)

TNR = P (B|A’) = 0.02 (probability that a person without the disease will test positive)

Now, we will use the Law of Total Probability:

P(B) = P(B|A) * P(A) + P(B|A’) * P(A’)

and since P(A’) = 1 – P(A)

=> P(B) = 0.95 * 0.01 + 0.02 (1-0.01) = 0.0095 + (0.02)(0.99) = 0.0287

=> P(B) = 0.0287

Now, applying Baye’s Thoerem, to find the value of P(A|B)

=> P(A|B) = (P(B|A) * P(A)) / P(B) = (0.95 * 0.01) / 0.0287

=> P(A|B) = 0.3306

Hence, the Probability of having the disease given a positive test result is 33.06%.

**Must Check: Baye’s Theorem**

**Conclusion**

The role of probability is not just limited to finding the solution using these probability formulas. Probability is important in data science, providing a foundation for understanding and interpreting data while making predictions.

Knowing the basics concepts will not only help calculate an event’s uncertainty, but it will also be useful to understand the complex machine learning algorithms (Naive Bayes Classifier, Decision Tree, Random Forest, etc.) and the working mechanism of Natural Language Processing.

This article briefly covers all probability formulas, including probability formulas class 12 and probability formulas class 10.

Hope you will like the article.

Happy Learning!!

## FAQs

**What is Probability?**

Probability is a branch of mathematics that deals with randomness, chance, and uncertainty. It is a measure or estimation of how likely an event will occur.

**What is the formula of Probability?**

Probability is the ratio of the number of favourable outcomes to the total number of outcomes. Let A be any event, then P(A) = Number of Favourable Outcomes / Total Number of Possible Outcomes

**What is Conditional Probability?**

Condition Probability is the probability of an event occurring given that another event has already occurred. i.e. we try to calculate the probability of the second event given that the first event has already occurred.

**What is Bayes Theorem?**

It is one of the fundamental theorems of probability. It describes the relationship between the probability of an event given some evidence and the probability of the evidence without any evidence. In simple terms, it gives the relationship between the conditional probabilities of two events.

**About the Author**

Vikram has a Postgraduate degree in Applied Mathematics, with a keen interest in Data Science and Machine Learning. He has experience of 2+ years in content creation in Mathematics, Statistics, Data Science, and Mac... Read Full Bio