Visual Tools
Calculators
Tables
Mathematical Keyboard
Converters
Other Tools


Expected Value






Understanding Expected Value


Expected value is the number that describes the long-run average outcome of a random variable.If you could repeat the same random experiment over and over, the expected value tells you what the results would settle around on average.

It works the same way for:

• discrete random variables (like dice, counts, or outcomes from models), and
• continuous random variables (like time, distance, or measurements),

even though the way we calculate it differs.

Expected value is one of the most important ideas in probability.It connects the outcome of a random experiment to the overall behavior of a distribution and
provides the foundation for variance, covariance, risk calculations, and many principles in probability and statistics.



The Intuition Behind Expected Value


The simplest way to think about expected value is as the long-run average of a random variable.
If you could run the same random experiment again and again, the results would fluctuate from trial
to trial, but the average of all outcomes would settle around a single number. That number is the
expected value.

For discrete random variables, this average is formed by giving more weight to outcomes that are more likely.
For continuous variables, the density curve shows where values tend to concentrate, and the expected
value reflects the balance point of that curve.

The value that occurs most often and the expected value are not necessarily the same.
In fact, the expected value might not match any specific outcome at all.
It is simply the number that reflects the overall behavior of the distribution — a kind of “center of gravity” for probability.

Notation We Use for Expected Value


When we talk about expected value, a few symbols appear again and again.
Here is what they mean in plain language, without the formal overload.

E(X)E(X) or 𝔼[X]𝔼[X] — the expected value of the random variable XX.
This is the most common way to write “the long-run average of XX.”

ΣΣ (the summation sign) — used in the discrete case.
It tells us we are adding together the contributions from all possible values of XX,
each weighted by its probability.

(the integral sign) — used in the continuous case.
It represents adding up contributions continuously along the density curve.

p(x)p(x) — the probability that XX takes the value x (for discrete variables).
This comes from the PMF.

f(x)f(x) — the probability density at x (for continuous variables).
It shows where values tend to concentrate.

E[g(X)]E[g(X)] — the expected value of some function of XX.
This appears when computing variance, powers of XX, or transformations.

All of these symbols simply help express the same idea:
expected value is a weighted average based on the probability function of the variable.

See All Probability Symbols and Notations


How to Calculate Expected Value


Expected value is always computed the same way: we take each possible value of the random variable, give it the weight it deserves based on its probability, and combine all those weighted contributions into a single average. The only difference between discrete and continuous variables is how we perform this combination.

Discrete Random Variables (using a PMF)
For discrete variables, we use a weighted sum: multiply each value xx by its probability p(x)p(x), then add all these products together. This gives the formula E(X)=Σxp(x)E(X) = Σ x · p(x). It is simply a probability-weighted average of all possible outcomes.

Continuous Random Variables (using a PDF)
For continuous variables, we replace the weighted sum with a weighted integral: multiply each x by its density f(x)f(x), and integrate over all possible values. This gives the formula E(X)=xf(x)dxE(X) = ∫ x · f(x) dx. Here, the density f(x)f(x) plays a role similar to p(x)p(x), except probabilities come from the area under the curve rather than point values.

In both cases, the underlying idea is identical: expected value is the average of all possible outcomes, each weighted by how likely it is.

Special Formulas for Common Distributions
Every well-known probability distribution—both discrete and continuous—comes with its own closed-form formula for expected value. These formulas are derived once from the summation or integral definitions and then reused to make calculations much faster. For example, the binomial distribution has E(X)=npE(X) = np, the geometric has E(X)=1/pE(X) = 1/p, and the exponential has E(X)=1/λE(X) = 1/λ. Using these established results saves time and avoids repeating long sums or integrals each time.


Properties of Expected Value


Expected value follows a small set of structural rules that make it one of the most useful ideas in probability. These properties describe how expectation behaves when random variables are combined or transformed, and they allow many calculations to be broken into simpler parts.

Linearity of Expectation (Expected Value of a Sum)
The most important property is linearity: E(X+Y)=E(X)+E(Y)E(X + Y) = E(X) + E(Y). This works for any random variables, even if they are dependent. The idea extends to any number of variables: E(X1+X2+...+Xn)=E(X1)+E(X2)+...+E(Xn)E(X1 + X2 + ... + Xn) = E(X1) + E(X2) + ... + E(Xn). Linearity is what allows us to compute the average of a complicated expression by breaking it into smaller pieces whose expectations are known.

Scaling and Shifting
If we multiply a random variable by a constant or shift it by adding a constant, the expected value behaves in a predictable way:
E(aX+b)=aE(X)+bE(aX + b) = aE(X) + b.
This shows how expectation responds to changes of units, rescaling, or adding fixed adjustments.

Expectation of a Product (Independence Case)
For independent variables, expectation interacts cleanly with multiplication: E(XY)=E(X)E(Y)E(XY) = E(X)E(Y). This is not true in general when X and Y are dependent, but it is an important special case that appears often in probability and statistics.

When Expected Value Exists
Expected value is not guaranteed to be finite for every distribution. Some distributions, such as the Cauchy distribution, have no defined expected value because the integral diverges. This reminds us that expectation is a mathematical quantity that depends on the shape and behavior of the probability function.

These properties make expectation a powerful tool: they let us simplify expressions, evaluate combinations of random variables, and understand how averages behave under transformations.

Expected Value of a Function


Sometimes we are not interested in the expected value of XX itself, but in the expected value of some function of XX. This happens in many situations: when computing variance, when working with powers of XX, when modeling profits or losses, or any time we transform the random variable into something new. The idea is exactly the same as before: we weight the values of g(X)g(X) by the probability function of XX.

Discrete Case
For discrete variables, we take all possible values of XX, apply the function gg to each one, multiply by the probability p(x)p(x), and add the results. The formula is E[g(X)]=Σg(x)p(x)E[g(X)] = Σ g(x) · p(x). This gives the long-run average of the transformed quantity g(X)g(X).

Continuous Case
For continuous variables, we do the same but with an integral instead of a sum. We multiply g(x)g(x) by the density f(x)f(x) and integrate across all possible values. The formula is E[g(X)]=g(x)f(x)dxE[g(X)] = ∫ g(x) f(x) dx. The density determines how much each transformed value contributes to the final average.

Expected value of a function is a fundamental idea because it appears everywhere: in variance, in risk analysis, in moments of distributions, and in many applied calculations where the quantity of interest is built from XX rather than XX itself.

Expected Value of a Sum


A key fact about expected value is that it adds up cleanly when random variables are added. If we combine two random variables by adding them, the expected value of the total is simply the sum of their individual expected values. In symbols, E(X+Y)=E(X)+E(Y)E(X + Y) = E(X) + E(Y). This rule works whether the variables are independent or dependent, which makes it unusually powerful.

The same idea extends to any number of variables: E(X1+X2+...+Xn)=E(X1)+E(X2)+...+E(Xn)E(X1 + X2 + ... + Xn) = E(X1) + E(X2) + ... + E(Xn). This property allows complicated expressions to be handled piece by piece, turning difficult problems into simple ones whose individual expectations are easy to compute. Because of this, linearity of expectation is one of the most widely used tools in probability.

Examples of Expected Value


These short examples show how expected value works for different types of random variables. They are not full derivations, just quick illustrations of the idea.

Fair Die
A fair six-sided die has outcomes 1 through 6, all equally likely. The expected value is the average of these values with equal weights, which gives E(X)=3.5E(X) = 3.5. This number does not need to be one of the outcomes.

Bernoulli (p)(p)
A Bernoulli variable takes the value 11 with probability pp and 00 with probability 1p1 − p. The expected value is E(X)=pE(X) = p, reflecting the long-run proportion of successes.

Exponential (λ)(λ)
An exponential distribution with rate λ has expected value E(X)=1/λE(X) = 1/λ. This gives the average waiting time between events in many real-world models.

Simple Profit Model
If a game pays +10 with probability 0.2 and −4 with probability 0.8, the expected profit is E(X) = 10·0.2 + (−4)·0.8 = −1.2. This tells you the average change in wealth per play over the long run.

These examples highlight how expected value captures the broad tendency of a random variable, whether the situation is discrete, continuous, or based on a practical scenario.