Slides 📊

Open the Chapter 6 slides in a new tab

The original PowerPoint slides remain available as a legacy download:

Download Chapter 6 slides (PPTX)

6.1. Continuous Random Variables and Probability Density Functions

What happens when we want to model measurements rather than counts? How do we handle quantities like height, weight, temperature, or time—variables that can take on any value within a continuous range? This section explores the shift in mathematical framework that occurs when we move from the discrete world of “how many” to the continuous world of “how much.”

Road Map 🧭

  • Understand why continuous random variables require a different mathematical approach than discrete ones.

  • Define probability density functions (PDFs) as the continuous analog to probability mass functions.

  • Master the key concept that probabilities are areas under a PDF.

  • Learn the essential properties that make a function a valid PDF.

  • Find probabilities for continuous random variables by integrating the PDF.

6.1.1. Discrete vs. Continuous Random Variables

For random variables with a discrete support, we could assign positive probabilities to individual outcomes. It made perfect sense to say “the probability of getting exactly 3 heads in 10 coin flips is some specific value” because 3 was one of only eleven distinct outcomes (0 through 10 heads). Even when the support is countably infinite—as in the Poisson distribution—we could still assign probabilities in such a way that each value in the support had a positive probability (however small) while the total sum remains 1.

But many real-world phenomena involve measurements along a continuous scale, which has a vastly larger support than that of any discrete random variable. While we might record a person’s height as “5 feet 9 inches,” the actual height could be 5.75000… feet or 5.750001… feet. Between any two measurements, no matter how close, there are uncountably many possible intermediate values. If we tried to assign positive probabilities to each possible height—no matter how cleverly—we would end up with an infinite total, violating the fundamental requirement that all probabilities sum (or integrate) to 1.

The Resolution: Zero Probability for Any Single Point

We resolve this paradox by accepting that any single exact value has probability zero for continuous random variables. The probability that someone’s height is exactly 5.750000000… feet with infinite precision is zero, even though this height is perfectly possible.

This might seem counterintuitive at first. How can something be possible but have zero probability? Recall that probability can be seen as the relative size of an event compared to the whole. In the continuous case, we’re dealing with uncountably many possible values packed into any interval, so many that any single point is negligible in comparison. This makes the relative size, and thus the probability, of any one value equal to zero.

Then What Has a Positive Probability?

For continuous random variables, we discuss probabilities of intervals of values rather than single points. This aligns naturally with the graphical interpretation of probabilities as areas under a curve–regions with non-zero width will have a positive area, while a single point always has zero area.

6.1.2. Probability Density Functions: The Continuous Analog of Probability Mass Functions

From Histograms to Curves

Since we can’t assign probabilities to individual points, we need a different approach than PMF to describe the distribution of a continuous random variable. We can think of a continuous probability distribution as a curve that represents the limiting behavior of increasingly fine histograms for an increasingly large dataset.

In Fig. 6.1, the jagged histogram begins to approximate a curve as we collect more data and make the bins narrower. In the limit—with infinite data and infinitesimally narrow bins—we get a probability density function.

Evolution from histogram to probability density function

Fig. 6.1 Evolution from histogram to a probability density function

Describe this figure in detail

Three panels side by side, with no axis labels or numbers. Below them, a wide arrow points to the right and is labeled “bin width ↓, sample size ↑”.

The left panel is a histogram with fairly wide bars. Its overall shape is a single mound, but the outline is jagged: neighboring bars differ noticeably in height, and a few short, isolated bars sit out in both tails. The middle panel is a histogram with many very narrow bars; its outline is a nearly smooth, symmetric bell shape with only small ragged edges. The right panel is a smooth, symmetric bell-shaped curve drawn as a black line, with the area under it shaded purple.

Mathematical Definition

A probability density function (PDF) for a continuous random variable \(X\), denoted \(f_X(x)\), specifies how “dense” the probability is around each point.

Mathematically,

\[f_X(x) = \lim_{\Delta \to 0^+} \frac{P(x < X \leq x + \Delta)}{\Delta}.\]

Interpreting a PDF

It is important to note that \(f_X\) evaluated at any point \(x\) tells us about the relative likelihood of values in that neighborhood. Suppose a random variable \(X\) gives \(f_X(5.8) = 3\) and \(f_X(6.2) = 1\). We observe that:

  • Values in a small neighborhood around 5.8 are three times more likely to occur than values in the neighborhood of 6.2.

  • \(f_X\) does NOT give probabilities directly. \(f_X(6.2) = 1\) does NOT mean that the exact value of 6.2 occurs with probability 1.

  • Evaluations of \(f_X\) are not restricted to be at most 1. The set of rules for validity of a PDF will be discussed below.

Support

Support shown on a pdf graph
Describe this figure in detail

Graph of a probability density function. The vertical axis is labeled \(f_X(x)\) and runs from 0 to 0.20 in steps of 0.05; the horizontal axis has no labels. The curve is flat at 0 on the left, then rises in a smooth, symmetric arch that peaks at about 0.19 in the middle of the graph, falls back to 0, and is flat at 0 again on the right.

Below the graph, a green double-headed arrow labeled “Support of X” spans the horizontal axis from the point where the arch leaves 0 to the point where it returns to 0.

The support of a continuous random variable \(X\) is the set of all possible values that \(X\) can take, or equivalently, the set of values where its PDF is strictly positive:

\[\text{supp}(X) = \{x \in \mathbb{R} \mid f_X(x) > 0\}.\]

When writing the support as an interval, we may include endpoints where the PDF equals zero. Including or excluding these endpoints does not change any probability, since individual points have probability zero for a continuous random variable.

6.1.3. Computing Probabilities: Areas Under the PDF

Probability between a and b on a PDF
Describe this figure in detail

An arch-shaped density curve. The vertical axis is labeled \(f_X(x)\) and runs from 0 to 0.20; the horizontal axis is labeled x. The curve is flat at 0 on both sides and rises to a symmetric peak of about 0.19 in the middle.

Two points, a and b, are marked on the horizontal axis, both to the left of the peak. At a, on the rising part of the arch, the curve is at about 0.08; at b, nearer the peak, it is at about 0.175. Black vertical lines rise from a and from b to the curve, and the region under the curve between them is shaded purple.

For a continuous random variable \(X\) with PDF \(f_X(x)\), the probability that \(X\) takes a value between \(a\) and \(b\) is equal to the area under \(f_X(x)\) between points \(a\) and \(b\). Mathematically,

\[P(a \leq X \leq b) = \int_a^b f_X(x) \, dx\]

Special Case: Probability at a Single Point

Probability of a single point
Describe this figure in detail

An arch-shaped density curve, flat at 0 on both sides, with a peak of about 0.19 on the vertical axis, which runs from 0 to 0.20. One point, a, is marked on the horizontal axis, on the rising part of the arch.

A red vertical segment rises from a up to the curve. From the top of that segment a dashed horizontal line runs left to the vertical axis at about 0.14; an arrow labeled \(f_X(a) \neq 0\) points to where the dashed line meets the axis. A second arrow points to the red segment and is labeled \(P(X = a) = \int_a^a f_X(x)\,dx = 0\).

For any specific value \(a\),

\[P(X = a) = P(a \leq X \leq a) = \int_a^a f_X(x) \, dx = 0\]

Any integral from a point to itself is zero because the interval has zero width. Note that \(f_X(a)\) evaluated at any \(a\) in the support is positive. This again highlights the fact that evaluating \(f_X\) at a point does not directly give its probability.

An Important Consequence: Equality Doesn’t Matter

Since any single point has zero probability, using strict or weak inequalities does not affect the probabilities:

\[P(a \leq X \leq b) = P(a \leq X < b) = P(a < X \leq b) = P(a < X < b)\]

This is a major difference from discrete random variables, where \(P(X = k)\) could be positive, making the choice between \(<\) and \(\leq\) crucial.

6.1.4. Properties of A Valid Probability Density Function

Not every function can serve as a PDF. A valid PDF must satisfy two essential properties that parallel those required of discrete probability mass functions.

Property 1: Non-Negativity

A PDF must be non-negative everywhere. That is,

\[f_X(x) \geq 0 \text{ for all } x \in \mathbb{R}.\]

This makes sense—there cannot be a likelihood smaller than none. However, unlike discrete PMFs, PDFs are not constrained to values less than or equal to 1. They can take arbitrarily large values at some points, as long as they satisfy the next property.

Property 2: Total Area Equals One

The total area under a PDF must equal 1, or equivalently,

\[\int_{-\infty}^{\infty} f_X(x) \, dx = 1.\]

This implies that the probability of observing some value within the support is equal to 1.

Example💡: Validating and Working with a Simple PDF

Suppose the maximum diameter of a potato chip (\(X\)) produced at Factory A, in inches, follows the following probability density:

\[\begin{split}f_X(x) = \begin{cases} &12(x-0.5)^2(1.5-x), &0.5 \leq x \leq 1.5\\ &0, &\text{ Otherwise} \end{cases}\end{split}\]
  1. Identify the support of \(X\), sketch \(f_X(x)\), then verify that it is a legitimate PDF.

    Sketch of the pdf of max diameter of potato chips

    Fig. 6.2 Sketch of the PDF of maximum diameters of potato chips

    Describe this figure in detail

    Graph titled “Distribution of maximum diameter of potato chips.” The horizontal axis is x, from about 0.3 to 1.7; the vertical axis is f(x), from 0 to about 1.85, with ticks every 0.25.

    The orange curve is 0 up to x = 0.5. It then rises, slowly at first and then more steeply, passes about 1.5 at x = 1.0, and reaches a single peak of about 1.78 at about x = 1.17. After the peak it falls steeply to 0 at x = 1.5 and stays at 0 out to 1.7. The area under the curve between 0.5 and 1.5 is shaded light orange. The rise on the left of the peak is longer and more gradual than the drop on the right.

    \(\text{supp}(X) = [0.5, 1.5]\). \(f_X(x)\) takes a non-negative value at any \(x \in \mathbb{R}\) as evident from the sketch. We now verify that the integral of the PDF from \(-\infty\) to \(\infty\) equals 1:

    \[\begin{split}\int_{-\infty}^\infty f_X(x)dx &= \int_{-\infty}^{0.5} f_X(x)dx + \int_{0.5}^{1.5}f_X(x)dx + \int_{1.5}^{\infty} f_X(x)dx\\ &= 0 + \int_{0.5}^{1.5} 12(x-0.5)^2(1.5-x) dx + 0\\\end{split}\]

    Above, we first split the beginning integral to a sum of integrals over three intervals. This step makes it evident that the integrals below \(0.5\) and above \(1.5\) are not just arbitrarily omitted from computation—they simply contribute zero area to the integral. Continuing,

    \[\begin{split}&\int_{0.5}^{1.5} 12(x-0.5)^2(1.5-x) dx\\ &= \int_{0.5}^{1.5} (-12x^3 + 30x^2-21x + 4.5)dx\\ &=\frac{-12x^4}{4} + \frac{30x^3}{3} - \frac{21x^2}{2} + 4.5x \Bigg\rvert_{0.5}^{1.5}\\ &=-3x^4 + 10x^3 - 10.5x^2 + 4.5x \Bigg\rvert_{0.5}^{1.5}\\ &= 1.6875-0.6875 = 1.\end{split}\]

    Therefore, \(f_X\) satisfies both requirements for a valid PDF.

  2. For a quality control procedure, managers of the factory has collected all the potato chips whose maximum diameter is smaller than 1”. What is the probability that a randomly selected potato chip in this pool has a maximum diameter greater than 0.8”?

    The first task is to write the goal of the problem in correct probability statement. Since we have the information that the chips will always have a maximum diameter less than 1,

    \[P(X > 0.8 | X < 1) = \frac{P(\{X > 0.8\} \cap \{X < 1 \})}{P(X < 1)}.\]

    The diameter can be greater than 0.8 and less than 1 only if it is between the two values. We simplify the numerator accordingly:

    \[P(X > 0.8 | X < 1) = \frac{P(0.8 <X < 1)}{P(X < 1)}.\]

    Now integrate for each probability:

    • Numerator

      \[\begin{split}P(0.8 < X < 1) &= \int_{0.8}^{1} f_X(x)dx \\ &=-3x^4 + 10x^3 - 10.5x^2 + 4.5x \Bigg\rvert_{0.8}^{1}\\ &=0.2288\end{split}\]
    • Denominator

      The denominator only has an upper boundary. This is equivalent to having a lower boundary of negative infinity, which gives us

      \[\begin{split}P(X < 1) &= \int_{-\infty}^{1} f_X(x)dx = \int_{0.5}^1 f_X(x)dx\\\end{split}\]

      The final step above is true because the integral of \(f_X(x)\) in any region below \(0.5\) results in 0. Continuing,

      \[P(X < 1) =-3x^4 + 10x^3 - 10.5x^2 + 4.5x \Bigg\rvert_{0.5}^{1} = 0.3125\]

    Finally,

    \[P(X > 0.8 | X < 1) = \frac{0.2288}{0.3125} = 0.73216\]

6.1.5. Important Types of Problems involving PDFs

A. Handling Complex Distributions

Real-world continuous distributions aren’t always described by simple functions. Common examples of more complex distributions are:

Three valid PDFs: a curve decaying from x = 0, a bell curve centered at 0, and a triangle followed by a separate rectangle.

Fig. 6.3 A legitimate PDF can have many different functional forms

Describe this figure in detail

Three panels under the title “Examples of valid PDFs.” In each, the density is an orange line with the area under it shaded light orange, and the horizontal axis is labeled x. The vertical axes have no tick values; the left panel’s is labeled f(x).

Left panel: x from 0 to 10. The curve is highest at x = 0 and decreases steadily, flattening out just above the axis by about x = 6 and continuing along the axis to 10. Middle panel: x from -5 to 5. A symmetric bell-shaped curve peaks at x = 0 and is nearly 0 below about -3 and above about 3.

Right panel: x from about -14 to 59, with ticks at 0, 20 and 40. The density rises in a straight line from 0 at about x = -10 to a peak at x = 0, drops straight down to 0 there, and stays at 0 until about x = 50. It then forms a flat-topped rectangle from about x = 50 to about x = 55, a little under half as tall as the triangle’s peak.

  • PDFs with one or both ends of the support extending to infinity (left two on Fig. 6.3)

    • PDFs of this type usually includes an exponential function. Make sure to review integration of simple exponential functions.

  • Piecewise-defined PDFs taking different functional forms over different regions of the support (right on Fig. 6.3)

    When dealing with piecewise PDFs,

    1. Identify all boundaries where the function forms change.

    2. Break down any integrals spanning multiple regions into a sum of integrals, each spanning only a single region.

Example💡: A Piecewise-defined PDF

A professor of STAT 1234 drops by a coffee shop on campus before or after his 50-minute lecture. Suppose the time he enters the coffee shop has a PDF shown below. The time \(x\) is expressed in minutes relative to the start time of his lecture.

\[\begin{split}f_X(x) = \begin{cases} &\frac{7}{500}(x+10), &-10 \leq x \leq 0\\ &\frac{3}{50}, &50 \leq x \leq 55\\ &0, &\text{ Otherwise} \end{cases}\end{split}\]

What is the probability that the professor enters the coffee shop within 3 minutes from his lecture?

We are looking for

\[P(-3 \leq X \leq 53) = \int_{-3}^{53} f_X(x)dx.\]

This interval spans three regions:

  • part of the first non-trivial region where \(-3 \leq x\leq 0\),

  • the middle region \(0 \leq x\leq 50\) where the PDF is zero, then

  • part of the second non-trivial region where \(50\leq x\leq 53\).

We must break up the integral into three pieces accordingly:

\[\begin{split}P(-3 \leq X \leq 53) &= \int_{-3}^{0} f_X(x)dx + \int_{0}^{50} f_X(x)dx + \int_{50}^{53} f_X(x)dx\\ &=\int_{-3}^{0} \frac{7}{500}(x+10) dx + \int_{0}^{50} 0 dx + \int_{50}^{53} \frac{3}{50}dx\\ &=\frac{7}{500}\left(\frac{x^2}{2} + 10x\right)\Bigg\rvert_{-3}^0 + \frac{3x}{50}\Bigg\rvert_{50}^{53}\\ &=0.357+0.18 = 0.537\end{split}\]

B. Completing a Partially Known PDF

Sometimes we encounter functions that have the right shape to be PDFs but don’t integrate to 1. We must fix this by finding an appropriate normalization constant.

Example💡: Finding the Normalization Constant

Suppose we have a function:

\[\begin{split}g(x) = \begin{cases} & x^2, & 0 \leq x \leq 2\\ &0, &\text{ elsewhere} \end{cases}.\end{split}\]

Q: What is the constant \(k\) which makes \(kg(x)\) a valid PDF?

We need to find \(k\) such that \(\int_{-\infty}^{\infty} kg(x) \, dx = 1\).

First, we compute the integral of \(g(x)\).

\[\int_{-\infty}^{\infty}g(x)dx = \int_{0}^{2} x^2 \, dx = \left[\frac{x^3}{3}\right]_0^2 = \frac{8}{3}.\]

To make the total area equal 1, we need

\[k \frac{8}{3} = 1 \implies k = \frac{3}{8}.\]

Therefore, the valid PDF is:

\[\begin{split}f_X(x) = \begin{cases} \frac{3}{8}x^2 & \text{for } 0 \leq x \leq 2 \\ 0 & \text{elsewhere} \end{cases}.\end{split}\]

6.1.6. Bringing It All Together

The transition from discrete to continuous random variables represents a fundamental shift in thinking. Instead of asking “what’s the probability of exactly this value?” we ask “what’s the probability of values in this range?” This change enables us to model the rich variety of measurement data we encounter.

Key Takeaways 📝

  1. Continuous random variables model measurable quantities that can take any value within an interval, unlike discrete variables that count distinct outcomes.

  2. Probability density functions (PDFs) describe how probability is distributed across the continuous range, with higher values indicating more likely regions.

  3. Probabilities are areas under the PDF, computed using integration: \(P(a < X < b) = \int_a^b f_X(x) \, dx\).

  4. Individual points have probability zero for continuous variables—only intervals have positive probability.

  5. Valid PDFs must be non-negative everywhere and integrate to 1 over their entire support.

In the next section, we’ll explore how to calculate expected values and variances for continuous random variables, extending the concepts we mastered in the discrete case.

6.1.7. Exercises

These exercises develop your skills in working with probability density functions, computing probabilities through integration, and verifying PDF validity.

Exercise 1: Validating and Computing Probabilities with a Basic PDF

A mechanical engineer models the deviation \(X\) (in millimeters) of a machined component from its target dimension. Based on production data, the PDF is:

\[\begin{split}f_X(x) = \begin{cases} \frac{3}{4}(1 - x^2), & -1 \leq x \leq 1\\ 0, & \text{elsewhere} \end{cases}\end{split}\]
  1. Verify that \(f_X(x)\) is a valid PDF by checking both required properties.

  2. Sketch the PDF. What shape does it have? Is it symmetric?

  3. Find \(P(-0.5 \leq X \leq 0.5)\), the probability that the deviation is within half a millimeter of target.

  4. Find \(P(X > 0)\). Does your answer make sense given the symmetry?

  5. Find \(P(X = 0.3)\).

Solution

Part (a): Verify PDF validity

Property 1: Non-negativity

We need \(f_X(x) \geq 0\) for all \(x\). On the support \([-1, 1]\):

  • At \(x = 0\): \(f_X(0) = \frac{3}{4}(1-0) = \frac{3}{4} > 0\)

  • At \(x = \pm 1\): \(f_X(\pm 1) = \frac{3}{4}(1-1) = 0 \geq 0\)

  • For \(-1 < x < 1\): since \(|x| < 1\), we have \(x^2 < 1\), so \(1 - x^2 > 0\)

Therefore, \(f_X(x) \geq 0\) everywhere. ✓

Property 2: Total area equals 1

\[\begin{split}\int_{-\infty}^{\infty} f_X(x) \, dx &= \int_{-1}^{1} \frac{3}{4}(1 - x^2) \, dx\\ &= \frac{3}{4} \left[ x - \frac{x^3}{3} \right]_{-1}^{1}\\ &= \frac{3}{4} \left[ \left(1 - \frac{1}{3}\right) - \left(-1 + \frac{1}{3}\right) \right]\\ &= \frac{3}{4} \left[ \frac{2}{3} + \frac{2}{3} \right] = \frac{3}{4} \cdot \frac{4}{3} = 1 \text{ ✓}\end{split}\]

Both properties are satisfied, so \(f_X(x)\) is a valid PDF.

Part (b): Sketch and shape

The PDF is a downward-opening parabola with:

  • Maximum at \(x = 0\) where \(f_X(0) = \frac{3}{4}\)

  • Zeros at \(x = \pm 1\)

The function is symmetric about \(x = 0\) since \(f_X(-x) = \frac{3}{4}(1 - (-x)^2) = \frac{3}{4}(1 - x^2) = f_X(x)\).

Parabolic PDF with shaded region showing P(-0.5 ≤ X ≤ 0.5)
Describe this figure in detail

Graph titled “Exercise 1: Parabolic PDF” followed by \(f_X(x) = \frac{3}{4}(1 - x^2)\), with the subtitle “Symmetric about x = 0; Shaded region shows P(-0.5 ≤ X ≤ 0.5) = 0.6875”. The horizontal axis is x (deviation in mm), from -1.5 to 1.5 with ticks at -1, 0 and 1; the vertical axis is density, from 0 to about 0.75.

The blue curve is 0 from -1.5 to -1, rises as a downward-opening parabola to a peak of 0.75 at x = 0, falls back to 0 at x = 1, and stays at 0 out to 1.5. The region under the curve from -0.5 to 0.5 is shaded light blue; at its two edges the curve is at about 0.56. A red dashed vertical line at x = 0 is labeled “E[X] = 0” in red.

Part (c): P(-0.5 ≤ X ≤ 0.5)

\[\begin{split}P(-0.5 \leq X \leq 0.5) &= \int_{-0.5}^{0.5} \frac{3}{4}(1 - x^2) \, dx\\ &= \frac{3}{4} \left[ x - \frac{x^3}{3} \right]_{-0.5}^{0.5}\\ &= \frac{3}{4} \left[ \left(0.5 - \frac{0.125}{3}\right) - \left(-0.5 + \frac{0.125}{3}\right) \right]\\ &= \frac{3}{4} \left[ 1 - \frac{0.25}{3} \right] = \frac{3}{4} \cdot \frac{11}{12} = \frac{11}{16} = 0.6875\end{split}\]

About 68.75% of components have deviations within ±0.5 mm.

Part (d): P(X > 0)

By symmetry of \(f_X(x)\) about \(x = 0\):

\[P(X > 0) = P(X < 0) = \frac{1}{2} = 0.5\]

This makes sense—the symmetric PDF assigns equal probability to positive and negative deviations.

Part (e): P(X = 0.3)

For any continuous random variable:

\[P(X = 0.3) = \int_{0.3}^{0.3} f_X(x) \, dx = 0\]

Any single point has probability zero for continuous random variables, even though \(x = 0.3\) is in the support and has positive density.


Exercise 2: PDF with Non-Zero Starting Point (Support Not Starting at 0)

A biomedical engineer studies the response time \(X\) (in seconds) of a nerve impulse. The PDF is:

\[\begin{split}f_X(x) = \begin{cases} \frac{1}{8}(x - 2), & 2 \leq x \leq 6\\ 0, & \text{elsewhere} \end{cases}\end{split}\]

Note that the support begins at \(x = 2\), not \(x = 0\).

  1. Verify this is a valid PDF.

  2. Find \(P(3 \leq X \leq 5)\) by direct integration.

  3. Find \(P(X > 4)\).

  4. Common Mistake Alert: A student incorrectly computes \(P(X \leq 4)\) by integrating \(\int_0^4 f_X(x) \, dx\). Explain their error and compute the correct value.

Solution

Part (a): Verify PDF validity

Non-negativity: On \([2, 6]\), since \(x \geq 2\), we have \(x - 2 \geq 0\), so \(f_X(x) = \frac{1}{8}(x-2) \geq 0\). ✓

Total area equals 1:

\[\begin{split}\int_{-\infty}^{\infty} f_X(x) \, dx &= \int_{2}^{6} \frac{1}{8}(x - 2) \, dx\\ &= \frac{1}{8} \cdot \frac{(x-2)^2}{2} \Bigg|_{2}^{6}\\ &= \frac{1}{16} \left[ (6-2)^2 - (2-2)^2 \right]\\ &= \frac{1}{16} \cdot 16 = 1 \text{ ✓}\end{split}\]
PDF with support starting at x=2
Describe this figure in detail

Graph titled “Exercise 2: PDF with Support [2, 6]”, with the subtitle “Support starts at x = 2, NOT at x = 0”. The horizontal axis is x (response time in seconds), from 0 to 8; the vertical axis is density, from 0 to 0.5 in steps of 0.1.

The blue line is at 0 from x = 0 to x = 2. From x = 2 it rises in a straight line, labeled in blue “f(x) = (1/8)(x-2)”, to a density of 0.5 at x = 6. At x = 6 it drops straight down to 0 and stays at 0 out to x = 8. A red dashed vertical line marks x = 2, with the red label “f(x) = 0 for x < 2” to its left.

Part (b): P(3 ≤ X ≤ 5) by direct integration

\[\begin{split}P(3 \leq X \leq 5) &= \int_{3}^{5} \frac{1}{8}(x - 2) \, dx\\ &= \frac{1}{8} \cdot \frac{(x-2)^2}{2} \Bigg|_{3}^{5}\\ &= \frac{1}{16} \left[ (5-2)^2 - (3-2)^2 \right]\\ &= \frac{1}{16} \left[ 9 - 1 \right] = \frac{8}{16} = 0.5\end{split}\]

Part (c): P(X > 4)

\[\begin{split}P(X > 4) &= \int_{4}^{6} \frac{1}{8}(x - 2) \, dx\\ &= \frac{1}{16} \left[ (6-2)^2 - (4-2)^2 \right]\\ &= \frac{1}{16} \left[ 16 - 4 \right] = \frac{12}{16} = 0.75\end{split}\]

Part (d): Common Mistake Explanation

The student’s error: They integrated from 0, but the PDF equals 0 for \(x < 2\). The correct approach:

\[P(X \leq 4) = \int_{-\infty}^{4} f_X(t) \, dt = \underbrace{\int_{-\infty}^{2} f_X(t) \, dt}_{= 0} + \int_{2}^{4} \frac{1}{8}(t-2) \, dt = \frac{(4-2)^2}{16} = \frac{4}{16} = 0.25\]

Key insight: When computing probabilities, only the region where \(f_X(x) > 0\) contributes. When the support doesn’t start at 0, be careful to integrate from the actual start of the support.


Exercise 3: Piecewise PDF with Multiple Regions

An aerospace engineer models wind gust intensity \(X\) (in m/s deviation from average) with the following PDF:

\[\begin{split}f_X(x) = \begin{cases} \frac{1}{9}(x + 3), & -3 \leq x \leq 0\\ \frac{1}{9}(3 - x), & 0 < x \leq 3\\ 0, & \text{elsewhere} \end{cases}\end{split}\]
  1. Verify this is a valid PDF. What is the geometric shape?

  2. Use geometry (not calculus) to find \(P(-1 \leq X \leq 1)\).

  3. Find \(P(X > 1)\) using integration.

  4. Find the probability that the wind gust intensity exceeds 1 m/s given that it is positive: \(P(X > 1 | X > 0)\).

Solution

Part (a): Verify PDF and identify shape

The PDF forms a triangle with:

  • Vertex at \((0, \frac{3}{9}) = (0, \frac{1}{3})\)

  • Base from \(x = -3\) to \(x = 3\) (length = 6)

Non-negativity: Both pieces are non-negative on their respective domains. ✓

Total area = 1 (using triangle area formula):

\[\text{Area} = \frac{1}{2} \times \text{base} \times \text{height} = \frac{1}{2} \times 6 \times \frac{1}{3} = 1 \text{ ✓}\]
Triangular piecewise PDF symmetric about x=0
Describe this figure in detail

Graph titled “Exercise 3: Triangular Piecewise PDF”, with the subtitle “Symmetric about x = 0; Peak at (0, 1/3); Shaded: P(-1 ≤ X ≤ 1) = 5/9”. The horizontal axis is x (wind gust deviation, m/s), from -4 to 4; the vertical axis is density, from 0 to about 0.35.

The blue line is at 0 from -4 to -3, rises in a straight line labeled “f(x) = (1/9)(x+3)” to a peak at x = 0, falls in a straight line labeled “f(x) = (1/9)(3-x)” to 0 at x = 3, and stays at 0 out to 4, forming a triangle. A red dashed vertical line at x = 0 is topped by the label “Peak = 1/3”, and a gray dotted horizontal line marks that height across the plot. The region under the triangle from -1 to 1 is shaded light blue; its left and right edges are at about 0.22 on the density axis, and its top follows the two sides of the triangle up to the peak.

Part (b): Geometric probability calculation

The region \(-1 \leq x \leq 1\) forms a trapezoid inside the triangle.

At \(x = -1\): \(f_X(-1) = \frac{1}{9}(-1+3) = \frac{2}{9}\)

At \(x = 0\): \(f_X(0) = \frac{1}{3}\)

At \(x = 1\): \(f_X(1) = \frac{1}{9}(3-1) = \frac{2}{9}\)

Alternative geometric approach:

Total triangle area = 1. The triangles outside \([-1, 1]\):

  • Left triangle (\(-3 \leq x \leq -1\)): base = 2, height = \(\frac{2}{9}\), area = \(\frac{1}{2} \times 2 \times \frac{2}{9} = \frac{2}{9}\)

  • Right triangle (\(1 \leq x \leq 3\)): base = 2, height = \(\frac{2}{9}\), area = \(\frac{2}{9}\)

\[P(-1 \leq X \leq 1) = 1 - \frac{2}{9} - \frac{2}{9} = 1 - \frac{4}{9} = \frac{5}{9} \approx 0.556\]

Part (c): P(X > 1) using integration

\[\begin{split}P(X > 1) &= \int_{1}^{3} \frac{1}{9}(3 - x) \, dx\\ &= \frac{1}{9}\left[3x - \frac{x^2}{2}\right]_{1}^{3}\\ &= \frac{1}{9}\left[\left(9 - \frac{9}{2}\right) - \left(3 - \frac{1}{2}\right)\right]\\ &= \frac{1}{9}\left[\frac{9}{2} - \frac{5}{2}\right] = \frac{1}{9} \cdot 2 = \frac{2}{9}\end{split}\]

Part (d): Conditional probability P(X > 1 | X > 0)

\[P(X > 1 | X > 0) = \frac{P(X > 1 \cap X > 0)}{P(X > 0)} = \frac{P(X > 1)}{P(X > 0)}\]

By symmetry: \(P(X > 0) = 0.5\)

From part (c): \(P(X > 1) = \frac{2}{9}\)

\[P(X > 1 | X > 0) = \frac{2/9}{1/2} = \frac{4}{9} \approx 0.444\]

Exercise 4: Finding the Normalizing Constant

A chemical engineer proposes the following function to model reaction time \(X\) (in minutes):

\[\begin{split}g(x) = \begin{cases} c(4x - x^2), & 0 \leq x \leq 4\\ 0, & \text{elsewhere} \end{cases}\end{split}\]

where \(c\) is an unknown constant.

  1. Find the value of \(c\) that makes \(g(x)\) a valid PDF.

  2. With this value of \(c\), find \(P(1 \leq X \leq 3)\).

  3. Sketch the PDF. Where is the mode (peak) of this distribution?

Solution

Part (a): Find normalizing constant c

For a valid PDF, \(\int_{-\infty}^{\infty} g(x) \, dx = 1\):

\[\int_{0}^{4} c(4x - x^2) \, dx = 1\]
\[c \left[ 2x^2 - \frac{x^3}{3} \right]_{0}^{4} = 1\]
\[c \left[ 2(16) - \frac{64}{3} \right] = c \left[ 32 - \frac{64}{3} \right] = c \cdot \frac{32}{3} = 1\]
\[c = \frac{3}{32}\]

Part (b): P(1 ≤ X ≤ 3)

\[\begin{split}P(1 \leq X \leq 3) &= \int_{1}^{3} \frac{3}{32}(4x - x^2) \, dx\\ &= \frac{3}{32} \left[ 2x^2 - \frac{x^3}{3} \right]_{1}^{3}\\ &= \frac{3}{32} \left[ \left(18 - 9\right) - \left(2 - \frac{1}{3}\right) \right]\\ &= \frac{3}{32} \left[ 9 - \frac{5}{3} \right] = \frac{3}{32} \cdot \frac{22}{3} = \frac{22}{32} = \frac{11}{16} = 0.6875\end{split}\]

Part (c): Sketch and mode

The function \(f_X(x) = \frac{3}{32}(4x - x^2) = \frac{3}{32}x(4-x)\) is a downward-opening parabola.

To find the mode, take the derivative and set to zero:

\[\frac{d}{dx}\left[\frac{3}{32}(4x - x^2)\right] = \frac{3}{32}(4 - 2x) = 0\]

Solving: \(x = 2\)

The mode is at x = 2 minutes, where \(f_X(2) = \frac{3}{32}(8 - 4) = \frac{3}{8}\).


Exercise 5: Piecewise PDF with Gap in Support

A data scientist models server response categories with the following PDF for response time \(X\) (in milliseconds):

\[\begin{split}f_X(x) = \begin{cases} \frac{1}{25}, & 0 \leq x \leq 10 \quad \text{(fast responses)}\\ \frac{3}{250}(x - 20), & 20 \leq x \leq 30 \quad \text{(slow responses)}\\ 0, & \text{elsewhere} \end{cases}\end{split}\]

Note the gap in support from \(x = 10\) to \(x = 20\) (no responses in this range).

  1. Verify this is a valid PDF.

  2. Find \(P(5 < X < 25)\). Be careful with the gap!

  3. What percentage of responses are “fast” (under 10 ms)?

  4. Given that a response is in the “slow” category (\(X \geq 20\)), what is \(P(X > 25 | X \geq 20)\)?

Solution

Part (a): Verify PDF validity

Non-negativity:

  • Region 1: \(\frac{1}{25} > 0\) ✓

  • Region 2: For \(20 \leq x \leq 30\), \(x - 20 \geq 0\), so \(\frac{3}{250}(x-20) \geq 0\) ✓

Total area = 1:

\[\begin{split}\text{Area}_1 &= \int_{0}^{10} \frac{1}{25} \, dx = \frac{10}{25} = \frac{2}{5}\\ \text{Area}_2 &= \int_{20}^{30} \frac{3}{250}(x - 20) \, dx = \frac{3}{250} \cdot \frac{(x-20)^2}{2} \Bigg|_{20}^{30}\\ &= \frac{3}{500} \cdot 100 = \frac{3}{5}\end{split}\]

Total: \(\frac{2}{5} + \frac{3}{5} = 1\) ✓

PDF with gap in support from x=10 to x=20
Describe this figure in detail

Graph with a two-line title, “Piecewise PDF with Gap in Support” and “Server Response Time Distribution”. The horizontal axis is response time x in milliseconds, from about -2 to 33 with ticks every 5; the vertical axis is \(f_X(x)\), from about -0.015 to 0.14 in steps of 0.02. A black horizontal line marks density 0 across the plot.

On the left, a blue shaded rectangle spans x = 0 to 10 at height 0.04, labeled “Fast responses” and “f(x) = 1/25” above it and “Area = 2/5” inside. Filled blue dots sit at both top corners, (0, 0.04) and (10, 0.04); the left edge is a solid line, the right edge is dashed, and an open circle sits at (10, 0). Between x = 10 and 20, a gray double-headed arrow at height 0.02 is labeled “Gap (no responses)”.

On the right, an orange shaded triangle rises in a straight line from a filled dot at (20, 0) to a filled dot at (30, 0.12), with a dashed vertical edge from (30, 0.12) down to the axis. It is labeled “Slow responses” and “f(x) = (3/250)(x − 20)” above it and “Area = 3/5” inside.

Part (b): P(5 < X < 25)

This spans multiple regions. We need:

\[P(5 < X < 25) = P(5 < X \leq 10) + \underbrace{P(10 < X < 20)}_{= 0 \text{ (gap)}} + P(20 \leq X < 25)\]

Calculate each part:

\[\begin{split}\begin{aligned} P(5 < X \leq 10) &= \int_{5}^{10} \frac{1}{25} \, dx = \frac{5}{25} = \frac{1}{5}\\ P(20 \leq X < 25) &= \int_{20}^{25} \frac{3}{250}(x-20) \, dx = \frac{3}{500}(5)^2 = \frac{75}{500} = \frac{3}{20} \end{aligned}\end{split}\]
\[P(5 < X < 25) = \frac{1}{5} + \frac{3}{20} = \frac{4}{20} + \frac{3}{20} = \frac{7}{20} = 0.35\]

Part (c): Percentage of fast responses

\[P(X \leq 10) = \int_{0}^{10} \frac{1}{25} \, dx = \frac{10}{25} = \frac{2}{5} = 40\%\]

Part (d): Conditional probability P(X > 25 | X ≥ 20)

Since slow responses are in the region \([20, 30]\):

\[P(X \geq 20) = \frac{3}{5} = 0.6\]
\[P(X > 25) = \int_{25}^{30} \frac{3}{250}(x-20) \, dx = \frac{3}{500}\left[(10)^2 - (5)^2\right] = \frac{3}{500} \cdot 75 = \frac{225}{500} = 0.45\]
\[P(X > 25 | X \geq 20) = \frac{P(X > 25)}{P(X \geq 20)} = \frac{0.45}{0.6} = 0.75\]

Exercise 6: Exponential-Type Function

A reliability engineer models component lifetime \(X\) (in years) with PDF:

\[\begin{split}f_X(x) = \begin{cases} ce^{-x/2}, & x \geq 0\\ 0, & x < 0 \end{cases}\end{split}\]
  1. Find the constant \(c\) that makes this a valid PDF.

  2. Find \(P(X > 3)\), the probability a component lasts more than 3 years.

  3. Find \(P(1 < X < 4)\).

  4. If a component has already lasted 2 years, what is \(P(X > 5 | X > 2)\)?

Solution

Part (a): Find c

\[\int_{0}^{\infty} ce^{-x/2} \, dx = c \cdot \left[-2e^{-x/2}\right]_{0}^{\infty} = c \cdot (0 - (-2)) = 2c = 1\]

Therefore, \(c = \frac{1}{2}\).

The PDF is \(f_X(x) = \frac{1}{2}e^{-x/2}\) for \(x \geq 0\).

Exponential PDF f(x) = (1/2)e^(-x/2) starting at 1/2 at x = 0, with the area to the right of x = 3 shaded
Describe this figure in detail

Graph of the PDF \(f_X(x) = \frac{1}{2}e^{-x/2}\), titled “Exercise 6: Exponential-Type PDF”. The horizontal axis is x, component lifetime in years, from about -1.5 to 12; the vertical axis is density, from 0 to 0.5. For x < 0 the blue curve lies on the horizontal axis, ending at an open circle at (0, 0). At x = 0 a filled dot marks f(0) = 1/2, and from there the curve decreases steadily: it is about 0.18 at x = 2, 0.11 at x = 3, 0.07 at x = 4 and 0.025 at x = 6, and it is nearly on the axis by x = 12.

A dashed red vertical line stands at x = 3. The region under the curve to the right of it is shaded light blue and labeled P(X > 3) = 0.223; the subtitle reads “c = 1/2, so f(x) = (1/2)e^(-x/2) for x ≥ 0; Shaded: P(X > 3) = e^(-1.5) ≈ 0.223”.

Part (b): P(X > 3)

\[P(X > 3) = \int_{3}^{\infty} \frac{1}{2}e^{-x/2} \, dx = \left[-e^{-x/2}\right]_{3}^{\infty} = 0 - (-e^{-3/2}) = e^{-1.5} \approx 0.223\]

Part (c): P(1 < X < 4)

\[P(1 < X < 4) = \int_{1}^{4} \frac{1}{2}e^{-x/2} \, dx = \left[-e^{-x/2}\right]_{1}^{4} = -e^{-2} - (-e^{-0.5}) = e^{-0.5} - e^{-2} \approx 0.471\]

Part (d): Conditional probability (Memoryless property)

This is an exponential distribution with rate \(\lambda = \frac{1}{2}\). By the memoryless property:

\[P(X > 5 | X > 2) = P(X > 3) = e^{-3/2} \approx 0.223\]

The probability of surviving an additional 3 years is the same regardless of how long the component has already lasted—this is the defining characteristic of exponential distributions.


Exercise 7: Finding Normalizing Constants — Polynomial Functions

For each of the following functions, find the constant \(k\) that makes it a valid PDF.

  1. \(g(x) = kx^3\) for \(0 \leq x \leq 2\), and 0 elsewhere.

  2. \(g(x) = k(x - 1)^2\) for \(1 \leq x \leq 4\), and 0 elsewhere.

  3. \(g(x) = k(6x - x^2)\) for \(0 \leq x \leq 6\), and 0 elsewhere.

  4. \(g(x) = k\sqrt{x}\) for \(0 \leq x \leq 9\), and 0 elsewhere.

Solution

Part (a): g(x) = kx³ on [0, 2]

For a valid PDF: \(\int_{0}^{2} kx^3 \, dx = 1\)

\[k \cdot \frac{x^4}{4} \Bigg|_{0}^{2} = k \cdot \frac{16}{4} = 4k = 1\]

Therefore, \(k = \frac{1}{4}\).

Verification: \(f_X(x) = \frac{1}{4}x^3 \geq 0\) on \([0, 2]\). ✓

Part (b): g(x) = k(x-1)² on [1, 4]

\[\int_{1}^{4} k(x-1)^2 \, dx = k \cdot \frac{(x-1)^3}{3} \Bigg|_{1}^{4} = k \cdot \frac{27}{3} = 9k = 1\]

Therefore, \(k = \frac{1}{9}\).

Part (c): g(x) = k(6x - x²) on [0, 6]

\[\int_{0}^{6} k(6x - x^2) \, dx = k \left[ 3x^2 - \frac{x^3}{3} \right]_{0}^{6} = k \left[ 108 - 72 \right] = 36k = 1\]

Therefore, \(k = \frac{1}{36}\).

Verification of non-negativity: \(6x - x^2 = x(6-x) \geq 0\) for \(0 \leq x \leq 6\). ✓

Part (d): g(x) = k√x on [0, 9]

\[\int_{0}^{9} k\sqrt{x} \, dx = k \cdot \frac{2}{3}x^{3/2} \Bigg|_{0}^{9} = k \cdot \frac{2}{3} \cdot 27 = 18k = 1\]

Therefore, \(k = \frac{1}{18}\).

Comparison of polynomial PDFs with different normalizing constants
Describe this figure in detail

Graph titled “Exercise 8: Polynomial PDFs with Normalizing Constants”, with the subtitle “Different shapes require different normalizing constants k”. The horizontal axis is x, from 0 to about 6.5; the vertical axis is density, from 0 to 2.0 in steps of 0.5. A legend titled “PDF” names two curves: blue, “(a) f(x) = (1/4)x³ on [0,2]”, and green, “(c) f(x) = (1/36)(6x-x²) on [0,6]”.

The blue curve starts at 0 at x = 0, rises slowly and then steeply to 2.0 at x = 2, drops straight down to 0 there, and stays at 0 out to 6.5. The green curve is a low, symmetric arch: it starts at 0 at x = 0, peaks at about 0.25 at x = 3, and returns to 0 at x = 6. The two curves cross near x = 0.75 at a density of about 0.11; to the left of that point the green curve is higher, and from there to x = 2 the blue curve is higher.


Exercise 8: Finding Normalizing Constants — Exponential Functions

For each of the following functions, find the constant \(c\) that makes it a valid PDF.

  1. \(g(x) = ce^{-3x}\) for \(x \geq 0\), and 0 elsewhere.

  2. \(g(x) = ce^{-x/5}\) for \(x \geq 0\), and 0 elsewhere.

  3. \(g(x) = cxe^{-x}\) for \(x \geq 0\), and 0 elsewhere. (Hint: Use integration by parts)

  4. \(g(x) = ce^{-(x-2)}\) for \(x \geq 2\), and 0 elsewhere. (Note: Support starts at 2, not 0)

Solution

Part (a): g(x) = ce^{-3x} for x ≥ 0

\[\int_{0}^{\infty} ce^{-3x} \, dx = c \cdot \left[ -\frac{1}{3}e^{-3x} \right]_{0}^{\infty} = c \cdot \left( 0 - \left(-\frac{1}{3}\right) \right) = \frac{c}{3} = 1\]

Therefore, \(c = 3\).

The PDF is \(f_X(x) = 3e^{-3x}\) for \(x \geq 0\) (Exponential with rate \(\lambda = 3\)).

Part (b): g(x) = ce^{-x/5} for x ≥ 0

\[\int_{0}^{\infty} ce^{-x/5} \, dx = c \cdot \left[ -5e^{-x/5} \right]_{0}^{\infty} = c \cdot (0 - (-5)) = 5c = 1\]

Therefore, \(c = \frac{1}{5}\).

The PDF is \(f_X(x) = \frac{1}{5}e^{-x/5}\) for \(x \geq 0\) (Exponential with rate \(\lambda = \frac{1}{5}\), or mean \(\mu = 5\)).

Part (c): g(x) = cxe^{-x} for x ≥ 0

Use integration by parts with \(u = x\), \(dv = e^{-x}dx\):

Then \(du = dx\), \(v = -e^{-x}\).

\[\begin{split}\int_{0}^{\infty} cxe^{-x} \, dx &= c \left[ -xe^{-x} \Big|_{0}^{\infty} + \int_{0}^{\infty} e^{-x} \, dx \right]\\ &= c \left[ 0 + \left( -e^{-x} \Big|_{0}^{\infty} \right) \right]\\ &= c \left[ 0 - (-1) \right] = c = 1\end{split}\]

Therefore, \(c = 1\).

The PDF is \(f_X(x) = xe^{-x}\) for \(x \geq 0\). This is a Gamma distribution with shape \(\alpha = 2\) and rate \(\beta = 1\).

Part (d): g(x) = ce^{-(x-2)} for x ≥ 2

The support starts at \(x = 2\), so we integrate from 2:

\[\int_{2}^{\infty} ce^{-(x-2)} \, dx = c \cdot \left[ -e^{-(x-2)} \right]_{2}^{\infty} = c \cdot (0 - (-1)) = c = 1\]

Therefore, \(c = 1\).

The PDF is \(f_X(x) = e^{-(x-2)}\) for \(x \geq 2\). This is a shifted exponential distribution.

Comparison of exponential-type PDFs with different normalizing constants
Describe this figure in detail

Graph titled “Exercise 9: Exponential-Type PDFs with Normalizing Constants”, with the subtitle “Different rate parameters yield different normalizing constants”. The horizontal axis is x, from 0 to 8; the vertical axis is density, from 0 to 3. A legend titled “PDF” names three curves: blue, “(a) f(x) = 3e^(-3x), c=3”; red, “(b) f(x) = (1/5)e^(-x/5), c=1/5”; and green, “(c) f(x) = xe^(-x), c=1”.

The blue curve starts at 3 at x = 0 and falls very steeply, nearly reaching 0 by about x = 2. The red curve starts at 0.2 and declines slowly, still at about 0.04 at x = 8. The green curve starts at 0, rises to a peak of about 0.37 at x = 1, then declines gradually to nearly 0 at x = 8.

The green curve rises above the red near x = 0.25; the blue curve drops below the green near x = 0.7 and below the red near x = 1. Beyond about x = 3.6 the red curve is the highest of the three.


Exercise 9: Piecewise Triangular PDF

A computer scientist models network packet sizes \(X\) (in kilobytes) with the following proposed density:

\[\begin{split}g(x) = \begin{cases} cx, & 0 \leq x \leq 2\\ c(4 - x), & 2 < x \leq 4\\ 0, & \text{elsewhere} \end{cases}\end{split}\]
  1. Find the constant \(c\) that makes this a valid PDF.

  2. Sketch the PDF. What shape is it?

  3. Find \(P(1 < X < 3)\).

  4. Find \(P(X > 3)\).

Solution

Part (a): Find normalizing constant c

The PDF must integrate to 1 over the entire support:

\[\int_{0}^{2} cx \, dx + \int_{2}^{4} c(4-x) \, dx = 1\]

First integral:

\[\int_{0}^{2} cx \, dx = c \cdot \frac{x^2}{2} \Bigg|_{0}^{2} = c \cdot 2 = 2c\]

Second integral:

\[\int_{2}^{4} c(4-x) \, dx = c \left[ 4x - \frac{x^2}{2} \right]_{2}^{4} = c \left[ (16 - 8) - (8 - 2) \right] = c \cdot 2 = 2c\]

Total: \(2c + 2c = 4c = 1\), so \(c = \frac{1}{4}\).

Part (b): Sketch and shape

The PDF forms a triangle with:

  • Base from \(x = 0\) to \(x = 4\) (length = 4)

  • Peak at \(x = 2\) where \(f_X(2) = \frac{1}{4} \cdot 2 = \frac{1}{2}\)

Verification using triangle area: \(\frac{1}{2} \times 4 \times \frac{1}{2} = 1\) ✓

Triangular piecewise PDF with c = 1/4
Describe this figure in detail

Graph titled “Exercise 10: Triangular PDF (c = 1/4)”, with the subtitle “Symmetric about x = 2; Peak = 0.5; Shaded: P(1 < X < 3) = 3/4”. The horizontal axis is x (packet size in KB), from -0.5 to 4.5; the vertical axis is density, from 0 to 0.5, with ticks at 0.0, 0.2 and 0.4.

The blue line is 0 left of x = 0, rises in a straight line labeled “f(x) = x/4” to a peak of 0.5 at x = 2, falls in a straight line labeled “f(x) = (4-x)/4” to 0 at x = 4, and is 0 after that. A red dashed vertical line at x = 2 is topped by the label “Peak = 1/2”. The region under the triangle from x = 1 to x = 3 is shaded light blue; its edges are at 0.25 on the density axis, and it carries the bold dark blue label “P(1 < X < 3) = 3/4”.

Part (c): P(1 < X < 3)

This spans both pieces of the PDF:

\[\begin{split}P(1 < X < 3) &= \int_{1}^{2} \frac{x}{4} \, dx + \int_{2}^{3} \frac{4-x}{4} \, dx\\ &= \frac{1}{4}\left[\frac{x^2}{2}\right]_{1}^{2} + \frac{1}{4}\left[4x - \frac{x^2}{2}\right]_{2}^{3}\\ &= \frac{1}{4}\left[2 - \frac{1}{2}\right] + \frac{1}{4}\left[\left(12 - \frac{9}{2}\right) - \left(8 - 2\right)\right]\\ &= \frac{1}{4} \cdot \frac{3}{2} + \frac{1}{4} \cdot \frac{3}{2} = \frac{3}{8} + \frac{3}{8} = \frac{3}{4}\end{split}\]

Part (d): P(X > 3)

\[P(X > 3) = \int_{3}^{4} \frac{4-x}{4} \, dx = \frac{1}{4}\left[4x - \frac{x^2}{2}\right]_{3}^{4} = \frac{1}{4}\left[8 - \frac{15}{2}\right] = \frac{1}{4} \cdot \frac{1}{2} = \frac{1}{8}\]

6.1.8. Additional Practice Problems

True/False Questions (1 point each)

  1. For a continuous random variable, \(P(X = a) = f_X(a)\) where \(f_X\) is the PDF.

    Ⓣ or Ⓕ

  2. If \(f_X(x) = 0.5\) for \(2 \leq x \leq 4\) and 0 elsewhere, then this is a valid PDF.

    Ⓣ or Ⓕ

  3. For continuous random variables, \(P(a < X < b) = P(a \leq X \leq b)\).

    Ⓣ or Ⓕ

  4. For a valid PDF, \(f_X(x) \leq 1\) for all \(x\).

    Ⓣ or Ⓕ

  5. If \(g(x) = kx^2\) for \(0 \leq x \leq 3\) is a valid PDF, then \(k = \frac{1}{9}\).

    Ⓣ or Ⓕ

  6. If \(g(x) = ce^{-2x}\) for \(x \geq 0\) is a valid PDF, then \(c = 2\).

    Ⓣ or Ⓕ

Multiple Choice Questions (2 points each)

  1. For \(f_X(x) = 3x^2\) on \([0, 1]\), what is \(P(X > 0.5)\)?

    Ⓐ 0.125

    Ⓑ 0.5

    Ⓒ 0.75

    Ⓓ 0.875

  2. For a continuous random variable with PDF symmetric about \(x = 5\) on support \([0, 10]\), what is \(P(X < 5)\)?

    Ⓐ 0.25

    Ⓑ 0.5

    Ⓒ 0.75

    Ⓓ Cannot determine without the specific PDF

  3. What value of \(k\) makes \(g(x) = k(4 - x^2)\) a valid PDF on \([-2, 2]\)?

    Ⓐ \(k = \frac{1}{32}\)

    Ⓑ \(k = \frac{3}{32}\)

    Ⓒ \(k = \frac{1}{16}\)

    Ⓓ \(k = \frac{3}{16}\)

  4. What value of \(c\) makes \(g(x) = ce^{-x/4}\) a valid PDF on \([0, \infty)\)?

    Ⓐ \(c = 4\)

    Ⓑ \(c = \frac{1}{4}\)

    Ⓒ \(c = e^{-4}\)

    Ⓓ \(c = 1\)

  5. If \(g(x) = k(x-1)(5-x)\) for \(1 \leq x \leq 5\) is a valid PDF, what is \(k\)?

    Ⓐ \(k = \frac{1}{32}\)

    Ⓑ \(k = \frac{3}{32}\)

    Ⓒ \(k = \frac{1}{16}\)

    Ⓓ \(k = \frac{3}{16}\)

  6. For \(f_X(x) = \frac{3}{8}x^2\) on \([0, 2]\), what is \(P(X < 1)\)?

    Ⓐ \(\frac{1}{8}\)

    Ⓑ \(\frac{1}{4}\)

    Ⓒ \(\frac{3}{8}\)

    Ⓓ \(\frac{1}{2}\)

Answers to Practice Problems

True/False Answers:

  1. False — \(f_X(a)\) is the density at point \(a\), NOT the probability. \(P(X = a) = 0\) for continuous random variables.

  2. True — The function is non-negative, and \(\int_2^4 0.5 \, dx = 0.5 \times 2 = 1\). ✓

  3. True — For continuous random variables, individual points have probability zero, so including or excluding the endpoints doesn’t change the probability.

  4. False — PDFs can exceed 1 as long as the total area equals 1. For example, \(f_X(x) = 4\) for \(0 \leq x \leq 0.25\) is valid.

  5. True — \(\int_0^3 kx^2 \, dx = k[\frac{x^3}{3}]_0^3 = k \cdot 9 = 1\), so \(k = \frac{1}{9}\). ✓

  6. True — \(\int_0^\infty ce^{-2x} \, dx = c \cdot [-\frac{1}{2}e^{-2x}]_0^\infty = c \cdot \frac{1}{2} = 1\), so \(c = 2\). ✓

Multiple Choice Answers:

  1. Ⓓ — \(P(X > 0.5) = \int_{0.5}^{1} 3x^2 \, dx = [x^3]_{0.5}^{1} = 1 - 0.125 = 0.875\).

  2. Ⓑ — By symmetry about \(x = 5\), exactly half the probability is below 5 and half above. \(P(X < 5) = 0.5\).

  3. Ⓑ — \(\int_{-2}^{2} k(4 - x^2) \, dx = k[4x - \frac{x^3}{3}]_{-2}^{2} = k[(8 - \frac{8}{3}) - (-8 + \frac{8}{3})] = k \cdot \frac{32}{3} = 1\), so \(k = \frac{3}{32}\).

  4. Ⓑ — \(\int_0^\infty ce^{-x/4} \, dx = c[-4e^{-x/4}]_0^\infty = c \cdot 4 = 1\), so \(c = \frac{1}{4}\).

  5. Ⓑ — First expand: \((x-1)(5-x) = -x^2 + 6x - 5\). Integrate:

    \(\int_1^5 k(-x^2 + 6x - 5) \, dx = k[-\frac{x^3}{3} + 3x^2 - 5x]_1^5\)

    \(= k[(-\frac{125}{3} + 75 - 25) - (-\frac{1}{3} + 3 - 5)] = k[(-\frac{125}{3} + 50) - (-\frac{7}{3})]\)

    \(= k[\frac{-125 + 150 + 7}{3}] = k \cdot \frac{32}{3} = 1\)

    So \(k = \frac{3}{32}\).

  6. Ⓐ — \(P(X < 1) = \int_0^1 \frac{3}{8}x^2 \, dx = \frac{3}{8} \cdot \frac{x^3}{3}\Big|_0^1 = \frac{1}{8}\).