Probability is a branch of mathematics that deals with the likelihood or chance of events occurring. It provides a framework for quantifying uncertainty and making informed decisions in the face of randomness. Probability theory is widely used in various fields, including statistics, science, engineering, finance, and artificial intelligence.

### Key Concepts in Probability:

**Experiment:**

- An experiment is a process that produces an outcome. It could be a coin toss, rolling a die, or conducting a scientific experiment.

**Sample Space (S):**

- The sample space is the set of all possible outcomes of an experiment. It is denoted by (S).

**Event:**

- An event is a subset of the sample space, representing a specific outcome or a collection of outcomes.

**Probability (P):**

- Probability is a numerical measure of the likelihood of an event occurring. It ranges from 0 (impossible) to 1 (certain).
- Probability is denoted by (P) and is calculated as the ratio of the number of favorable outcomes to the total number of possible outcomes. [ P(A) = \frac{\text{Number of favorable outcomes for event } A}{\text{Total number of possible outcomes}} ]

**Complement of an Event ((A’) or (A^c)):**

- The complement of an event (A) is the set of all outcomes in the sample space that are not in (A).

**Mutually Exclusive Events:**

- Two events are mutually exclusive (or disjoint) if they cannot occur at the same time.

**Independent Events:**

- Two events are independent if the occurrence of one event does not affect the occurrence of the other.

### Probability Rules:

**Addition Rule:**

- ( P(A \cup B) = P(A) + P(B) – P(A \cap B) )
- The probability of the union of two events is the sum of their individual probabilities minus the probability of their intersection.

**Multiplication Rule for Independent Events:**

- ( P(A \cap B) = P(A) \cdot P(B) )
- The probability of the intersection of two independent events is the product of their individual probabilities.

**Conditional Probability:**

- ( P(A|B) = \frac{P(A \cap B)}{P(B)} )
- The probability of event (A) given that event (B) has occurred.

**Law of Total Probability:**

- ( P(A) = P(A \cap B_1) + P(A \cap B_2) + \ldots + P(A \cap B_n) )
- The probability of event (A) is the sum of the probabilities of (A) intersecting with each mutually exclusive event (B_i).

### Example:

Consider rolling a fair six-sided die. The sample space (S) is ({1, 2, 3, 4, 5, 6}). The probability of rolling an even number ((A)) is (P(A) = \frac{3}{6} = \frac{1}{2}).

If we define (B) as the event of rolling a number less than 4, then (P(B) = \frac{3}{6} = \frac{1}{2}). The intersection of (A) and (B) is the event of rolling an even number less than 4, which is ({2}). Therefore, (P(A \cap B) = \frac{1}{6}).

The complement of (A) is the event of rolling an odd number, denoted as (A’). (P(A’) = 1 – P(A) = \frac{1}{2}).

These concepts and rules provide a foundation for more advanced topics in probability theory, such as conditional probability, Bayes’ theorem, and probability distributions. Probability theory is a fundamental tool for reasoning about uncertainty and randomness in diverse fields.