Continuous Random Variable
We say that a
random variable is continuous if
for every
.
This is not the same as saying that is not a discrete random variable. A discrete random variable has a countable set of possible values. A continuous random variable has no single value with positive probability. These are different conditions.
Continuous Random Variable Has Uncountable Range
Suppose, toward a contradiction, that
is countable. Since every outcome
has
,
Because
is continuous, each event
has probability
. By countable additivity in the definition of a
probability measure,
This contradicts
, so
is not countable.
Uncountable Range Does Not Imply Continuous
A
random variable can have an uncountable set of possible values without being
continuous.
Let
be a random variable with
whose
distribution function is
The set of possible values of
contains
, so it is not
countable because nontrivial intervals are
uncountable. Thus
is not a
discrete random variable. However,
so
is not continuous.
Random Variable Neither Discrete Nor Continuous
Give an example of a
random variable that is neither
discrete nor
continuous.
Let
be a random variable with
whose
distribution function is
The set of possible values of
contains
, which is
uncountable. Therefore
is not
countable, so
is not discrete.
On the other hand,
so it is not true that
for every
. Therefore
is not continuous.
This is different from a die roll. If is the result of a fair six-sided die, then , so a single exact outcome can have positive probability. Here is shorthand for the probability of the event determined by the binary relation . For a continuous random variable, every exact value has probability ; probabilities live on intervals or regions rather than individual values.
One way to picture the transition is to imagine a fair die with equally likely faces. Each single face has probability . As gets larger, gets smaller. If the faces become tiny patches approximating a smooth sphere and the limiting roll is modeled as landing on a point of the sphere, then any single exact point has limiting probability , even though a region of the sphere can still have positive probability.
Density Function
Let
be a
random variable. A function
is a
density function for
if, for every interval
,
For example, the function defined by for and otherwise is a density function for a random variable uniformly distributed on . For any interval , the integral is the length of the part of that lies inside .
The reason an integral appears is not that we add the probabilities of the individual points. For a discrete random variable, that pointwise method works because the possible values form a countable set. The analogous object is usually called a probability mass function, not a density function. If is a fair six-sided die roll, then its mass function satisfies for . For the interval , the probability is the sum of the masses at the possible values in that interval:
For a continuous random variable, trying to keep this rule fails: if every point has probability , then summing point probabilities cannot recover a positive probability for an interval. The repair is to assign probability to the event that the random value lands in a small interval, not to the individual points. A density says that if is a small interval of length near , for example , then
These small interval probabilities are compatible with the basic additivity rule for disjoint events, because adjacent small intervals contribute by addition. When the interval is divided into finer and finer pieces, the limiting sum of these interval contributions is the integral. Thus the integral is the continuous replacement for summing masses at possible values, while the value itself is not the probability of the point .
Density Determines Distribution Function
If
has
density , then its
distribution function satisfies
for every
.
Apply the definition of density to the interval .
Density Determines Interval Probabilities
If
has
density , then for
,
Apply the definition of density to the interval .
Expectation of a Continuous Random Variable
If
has
density , then
whenever the integral is defined.
Expectation of an Interval Indicator
Suppose that
has
density and
with
. Then
Let
For every
,
so
by the definition of an
indicator random variable. Therefore, by
expectation of an indicator,
By
density determines interval probabilities,
Since
is
on
and
off
,
Expectation of a Function of a Continuous Random Variable
If
has
density and
is
measurable, then
whenever the integral is defined.
The formula holds for interval indicators by
expectation of an interval indicator. By finite additivity and
linearity of expectation for finite sums, the same formula holds for every non-negative simple function
built from finitely many intervals:
For a non-negative measurable function
, choose an increasing sequence of non-negative simple functions
with
. Applying the simple-function case to each
, then using the
monotone convergence theorem on both sides, gives
For a general measurable
, apply the non-negative case to the
positive part and the
negative part , then subtract, whenever the resulting integral is defined.
Continuous Expectation Respects Scalar Multiplication
Suppose that
has
density ,
is measurable, and
. If the expectations are defined, then
Continuous Expectation is Linear for Finite Sums
Suppose that are continuous random variables and are measurable functions. If the expectations are defined, then
Joint Density Function
Random variables
and
have joint density
if it is a two-variable analogue of a
density function:
,
, and
for suitable sets
.
Continuous Marginal Density Functions
If
and
have
joint density , then their marginal densities are
Independent Continuous Random Variables
Continuous random variables
and
are
independent if their joint density factors as
for all
except possibly on a set of area zero.
Conditional Density Function
If
and
have
joint density and
, the conditional density of
given
is
Continuous Conditional Expectation Given a Value
If the
conditional density is defined, then
whenever the integral is defined.
Change of Variables for Joint Densities
Let
, where
is one-to-one and differentiable with differentiable inverse. If
has
joint density , then
Density Gives Zero Probability to Points
If
has a
density function, then
for every
.
Apply the definition of density to the interval . The integral of a density over a single point is , so .
Probability of an Interval in the Exponential Distribution
Suppose that
. Using
uniform interval probabilities,
Observe that the following sets are equal: therefore we know that