Tutorials › Exam P - Probability › Building Mixed Cumulative Distribution Functions

Exam P · Integrated Probability Problem Solving · Tutorial 883 of 915

Building Mixed Cumulative Distribution Functions

Build a mixed cumulative distribution function by combining density integrals with the probability masses that create jumps.

Advanced 11 min read

What You'll Learn

  • Distinguish point masses from probability accumulated through a density.
  • Construct a mixed cdf from its atoms, continuous density, and support.
  • Check normalization, right-continuity, and jump sizes.
  • Calculate interval probabilities using cdf values and the correct endpoints.
  • Identify common boundary errors when an interval includes or excludes an atom.

Why a Mixed CDF Needs Both Jumps and Integrals

A cumulative distribution function records the probability that a random variable is at most a given value. For a purely continuous variable, this probability accumulates through an integral of its density. For a discrete variable, it accumulates through jumps at possible values. A mixed variable has both features: probability can accumulate smoothly over intervals and can also arrive all at once at particular points.

The distinction matters whenever an event includes or excludes a point carrying positive probability. A single endpoint can change the answer, even when the continuous part assigns probability zero to that endpoint. To construct a mixed cdf reliably, identify every point mass, integrate the continuous density over the relevant support, and then combine the two contributions.

Definition: The cumulative distribution function of a random variable \(X\) is \(F_X(x)=P(X\le x)\). A point \(a\) is an atom if \(P(X=a)>0\); its mass is \(P(X=a)=F_X(a)-F_X(a-)\), where \(F_X(a-)=\lim_{x\uparrow a}F_X(x)\). A continuous density contributes probability by integration and, by itself, creates no jump at an individual point.

In this tutorial, a mixed model consists of a density together with a finite or countable collection of atoms, with no additional component of probability. That assumption is important: the atom masses and the density must account for the entire distribution. In particular, their total probability must be one.

The Construction Rule

Suppose the atoms are at points \(a_j\), with masses \(p_j=P(X=a_j)\), and the continuous part has density \(f_X(t)\) on its support. The density is understood to be zero outside that support. The cdf at \(x\) is the sum of all atom masses at or below \(x\), plus the continuous probability accumulated at or below \(x\).

$$ F_X(x)=\sum_{j:\,a_j\le x}p_j+\int_{-\infty}^{x}f_X(t)\,dt. $$

The use of \(a_j\le x\), rather than \(a_j<x\), follows directly from the definition \(F_X(x)=P(X\le x)\): an atom at \(x\) is included. The integral can be written from \(-\infty\) because the density is zero outside its support; in a calculation, it is usually simpler to integrate only over the part of the support below \(x\).

Normalization check: For this model, \(\sum_j p_j+\int_{-\infty}^{\infty}f_X(t)\,dt=1\). A cdf must be nondecreasing, right-continuous, tend to zero as \(x\) tends to \(-\infty\), and tend to one as \(x\) tends to \(+\infty\). At each atom \(a_j\), its jump must equal \(p_j\).

Here is the justification for the construction rule. The event \(\{X\le x\}\) contains each event \(\{X=a_j\}\) for which \(a_j\le x\), and it also contains the continuous outcomes up to \(x\). These parts have no probability in common: the density assigns probability zero to each individual point, while each atom is separately counted. Adding their probabilities gives the displayed formula. This reasoning also explains why a density integral alone misses every atom.

For interval events, subtracting cdf values handles endpoints precisely. For \(a<b\), the two most useful forms are:

$$ P(a<X\le b)=F_X(b)-F_X(a),\qquad P(a\le X\le b)=F_X(b)-F_X(a-). $$

The first expression removes all probability at or below \(a\); the second removes only probability strictly below \(a\). Thus the second expression includes any atom at \(a\), while the first excludes it. If there is no atom at \(a\), then \(F_X(a-)=F_X(a)\), and the two endpoint conventions make no numerical difference.

Worked Example: Combining Two Atoms With a Uniform Continuous Component

A hypothetical loss index \(X\) has probability \(0.20\) at \(-1\), probability \(0.25\) at \(2\), and a continuous component with density \(0.55\) on \(0<x<1\), zero elsewhere. Construct \(F_X\), check the total probability, and find \(P(0.4<X\le2)\).

Method. First verify that the stated density and atoms sum to one. Then add the atom masses at or below \(x\) to the continuous integral up to \(x\). This avoids treating the atoms as if they were spread across an interval.

Step 1: Check the model. The continuous mass is \(0.55(1-0)=0.55\). Therefore total probability is \(0.20+0.55+0.25=1.00\), as required.

Step 2: Construct the cdf by regions. For \(x<-1\), no probability has accumulated, so \(F_X(x)=0\). At \(-1\), the atom is included, giving \(F_X(x)=0.20\) for \(-1\le x<0\). On \(0\le x\le1\), the continuous contribution is \(0.55x\), in addition to the atom at \(-1\). For \(1<x<2\), all of the continuous mass and the atom at \(-1\) are included. At \(2\), the final atom is included.

$$ F_X(x)= \begin{cases} 0, & x<-1,\\ 0.20, & -1\le x<0,\\ 0.20+0.55x, & 0\le x\le1,\\ 0.75, & 1<x<2,\\ 1, & x\ge2. \end{cases} $$

At \(x=1\), the formula gives \(0.20+0.55=0.75\), so the next region also begins at \(0.75\). At \(x=2\), the cdf jumps from \(0.75\) to \(1.00\), a jump of \(0.25\), matching the atom there.

Step 3: Calculate the interval probability. Since the interval is open at \(0.4\) and closed at \(2\), \(P(0.4<X\le2)=F_X(2)-F_X(0.4)\). The values are \(F_X(2)=1.00\) and \(F_X(0.4)=0.20+0.55(0.4)=0.42\). Thus the answer is \(1.00-0.42=0.58\). As a check, this includes \(0.55(1-0.4)=0.33\) of continuous probability and the atom \(0.25\) at \(2\), for \(0.33+0.25=0.58\).

Common mistake avoided: Integrating the density all the way to \(2\) would give only \(0.55\), omitting both atoms. The cdf must include the masses at \(-1\) and \(2\), not just the area under the density.

Reading Jumps and Handling Boundaries

A cdf is defined using “less than or equal to,” so its value at an atom is the value after the jump. The left-hand limit is the value immediately before the jump. Their difference is the atom’s probability. Between atoms, the cdf changes according to the integrated density; on a gap with neither density nor atoms, it stays constant.

It is useful to check a piecewise cdf at each breakpoint. Evaluate the formula immediately to the left and at the breakpoint, confirm that the difference is the specified atom, and verify that the formula reaches one at the end of the support. These checks catch errors that may be hidden by a plausible-looking expression.

Worked Example: A Density With a Gap and an Atom at a Boundary

A hypothetical score \(X\) has an atom of \(0.15\) at \(0\), an atom of \(0.25\) at \(2\), density \(0.25\) for \(0<x<2\), and density \(0.10\) for \(3<x<4\). The density is zero elsewhere. Construct the cdf and calculate \(P(1<X\le3.5)\).

Method. Integrate separately on each region where the density is nonzero, and include each atom at its exact location. The gap from \(2\) to \(3\) contributes no probability.

Step 1: Check total probability. The density on \((0,2)\) contributes \(0.25(2)=0.50\); the density on \((3,4)\) contributes \(0.10(1)=0.10\). Adding the atoms gives \(0.50+0.10+0.15+0.25=1.00\).

Step 2: Accumulate probability by region. Before zero, the cdf is zero. At zero it jumps to \(0.15\). Between zero and two, the integral contributes \(0.25x\). Just before two the cdf is \(0.15+0.25(2)=0.65\), and at two it jumps by \(0.25\) to \(0.90\). It stays at \(0.90\) through the gap. From three to four, it gains \(0.10(x-3)\).

$$ F_X(x)= \begin{cases} 0, & x<0,\\ 0.15+0.25x, & 0\le x<2,\\ 0.90, & 2\le x<3,\\ 0.90+0.10(x-3), & 3\le x\le4,\\ 1, & x>4. \end{cases} $$

At \(x=0\), the first nonzero value is \(0.15\). At \(x=2\), the cdf value is \(0.90\), not \(0.65\), because the atom at \(2\) is included. At \(x=4\), the cdf is \(0.90+0.10(1)=1.00\).

Step 3: Evaluate the requested probability. Since \(1<2\), \(F_X(1)=0.15+0.25=0.40\). Since \(3\le3.5\le4\), \(F_X(3.5)=0.90+0.10(0.5)=0.95\). Therefore \(P(1<X\le3.5)=0.95-0.40=0.55\).

A component check gives the same result: the density from \(1\) to \(2\) contributes \(0.25(1)=0.25\), the atom at \(2\) contributes \(0.25\), and the density from \(3\) to \(3.5\) contributes \(0.10(0.5)=0.05\). The sum is \(0.25+0.25+0.05=0.55\).

Common mistake avoided: The interval from \(2\) to \(3\) is a gap for the continuous density, but the atom at \(2\) still contributes. A density value of zero in a region does not imply there are no atoms at its boundary.

A Nonconstant Density Can Share a Location With an Atom

A point mass does not prevent a continuous density from assigning probability to nearby intervals. The two contributions must still be kept separate: the integral accounts for continuous outcomes, while the atom is added as a jump. In particular, a density’s value at a single point does not determine whether that point is an atom.

Worked Example: A Curved Density and an Interior Atom

A hypothetical index \(X\) has density \(f_X(x)=0.25x\) for \(0<x<2\), an atom of \(0.30\) at \(1\), and an atom of \(0.20\) at \(3\). The density is zero elsewhere. Construct the cdf and find \(P(0.5<X\le1.5)\).

Method. Integrate the density from the start of its support, then add the atom at \(1\) only once \(x\) reaches \(1\), and add the atom at \(3\) only once \(x\) reaches \(3\).

Step 1: Verify normalization. The continuous mass is \(\int_0^2 0.25t\,dt=0.25[t^2/2]_0^2=0.25(2)=0.50\). Adding the two atoms gives \(0.50+0.30+0.20=1.00\).

Step 2: Integrate the continuous component. For \(0\le x\le2\), its accumulated probability is \(\int_0^x 0.25t\,dt=0.25x^2/2=x^2/8\). The atom at \(1\) is included for \(x\ge1\), and the atom at \(3\) is included for \(x\ge3\). Consequently,

$$ F_X(x)= \begin{cases} 0, & x<0,\\ x^2/8, & 0\le x<1,\\ x^2/8+0.30, & 1\le x<2,\\ 0.80, & 2\le x<3,\\ 1, & x\ge3. \end{cases} $$

The jump at \(1\) is \(F_X(1)-F_X(1-)=\bigl(1/8+0.30\bigr)-1/8=0.30\). At \(2\), the continuous part has accumulated \(2^2/8=0.50\), and the atom at \(1\) has added \(0.30\), so the cdf is \(0.80\). It then jumps by \(0.20\) at \(3\), reaching one.

Step 3: Find the interval probability. The lower endpoint is excluded, so subtract \(F_X(0.5)\), not its left limit. We have \(F_X(0.5)=0.5^2/8=0.03125\). The upper endpoint is \(1.5\), so \(F_X(1.5)=1.5^2/8+0.30=2.25/8+0.30=0.28125+0.30=0.58125\). The difference is \(0.58125-0.03125=0.55000\).

The same probability can be checked by components. The continuous mass from \(0.5\) to \(1.5\) is \(\int_{0.5}^{1.5}0.25x\,dx=0.25[(1.5^2-0.5^2)/2]=0.25(1)=0.25\). The interval also includes the atom \(0.30\) at \(1\), giving \(0.25+0.30=0.55\).

Common mistake avoided: The atom at \(1\) must be included in \(F_X(1.5)\). Using only the integral would give \(0.28125-0.03125=0.25\), which omits the \(0.30\) point mass.

Common Endpoint Trap and a Reliable Checklist

Suppose the event is \(0<X\le1\) in the second example. The correct calculation is \(F_X(1)-F_X(0)=0.40-0.15=0.25\). A common incorrect calculation is \(F_X(1)-F_X(0-)=0.40-0=0.40\). That result includes the atom at zero, even though the event requires \(X>0\). The left limit is appropriate when the lower endpoint is included, not when it is excluded.

For an exam problem, a short sequence of checks keeps the construction organized:

1
List the components.
Record each atom and its mass, and identify every interval on which the density is nonzero.
2
Check total probability.
Add all atom masses to the integrals of the density over its support; the result must be one.
3
Build the cdf from left to right.
Accumulate density by integration and add an atom at its location, including it in \(F_X(x)\) when its location is at most \(x\).
4
Check breakpoints and endpoints.
Confirm each jump size, constancy on gaps, right-continuity, and a final cdf value of one.
5
Translate the event before subtracting.
Use \(F_X(b)-F_X(a)\) for \(a<X\le b\), and \(F_X(b)-F_X(a-)\) for \(a\le X\le b\).

Mixed cdfs are useful because they give one consistent way to answer probability questions even when a model combines gradual variation with exact outcomes. The essential discipline is to preserve both parts of the distribution and to respect the event’s endpoint inequalities.

Check Your Understanding

For each problem, construct or use the cdf carefully, paying particular attention to atoms at interval boundaries.

  1. A random variable has mass \(0.10\) at \(0\), mass \(0.20\) at \(3\), and density \(0.70/2\) on \(1<x<3\), with density zero elsewhere. Find \(F_X(2)\) and \(P(0<X\le3)\). (Answer: \(F_X(2)=0.45\); \(P(0<X\le3)=0.90\))
  2. A variable has atoms of \(0.25\) at \(-2\) and \(0.15\) at \(1\), and density \(0.60\) on \(2<x<3\). Give its cdf on \(-2\le x<1\), at \(x=1\), and on \(2\le x\le3\). (Answer: \(F_X(x)=0.25\) for \(-2\le x<1\); \(F_X(1)=0.40\); \(F_X(x)=0.40+0.60(x-2)\) for \(2\le x\le3\))
  3. A variable has density \(0.20x\) for \(0<x<2\) and an atom of \(0.60\) at \(2\), with no other probability. Find \(P(1<X\le2)\). (Answer: \(0.20\int_1^2 x\,dx+0.60=0.30+0.60=0.90\))
  4. A mixed variable has an atom of \(0.20\) at \(1\), an atom of \(0.10\) at \(4\), and density \(0.70\) on \(2<x<3\). Find \(P(1\le X\le2.5)\) and \(P(1<X\le2.5)\). (Answer: \(0.55\) and \(0.35\), respectively)
  5. A variable has atoms of \(0.10\) at \(0\) and \(0.20\) at \(2\), density \(0.35\) on \(0<x<1\), and density \(0.35\) on \(1<x<2\). Find \(F_X(1-)\), \(F_X(1)\), and the jump at \(2\). (Answer: \(F_X(1-)=0.45\), \(F_X(1)=0.45\), and the jump at \(2\) is \(0.20\))
Clinical Biostats