Answers: PMFs, PDFs, and CDFs

Author

Sophie Chowgule

Summary
Answers to questions relating to the guide on PMFs, PDFs, and CDFs.

These are the answers to Questions: PMFs, PDFs, and CDFs.

Please attempt the questions before reading these answers!

Q1

1.1.

The given PMF is valid because:

Non-negativity: All \(P(X = x) \geq 0\)

Honesty: The sum of all probabilities equals 1: \[ \sum_{x=1}^{4} p(x) = \sum_{x=1}^{4} P(X = x) = \dfrac{1}{10} + \dfrac{1}{5} + \dfrac{1}{2} + \dfrac{1}{5} = 1 \]

\(P(X = 4) = \dfrac{1}{5}\).

1.2.

The given PMF is valid because:

Non-negativity: All \(P(X = x) \geq 0\)

Honesty: The sum of all probabilities equals 1: \[ \sum_{x=1}^{4} p(x) = \sum_{x=1}^{4} P(X = x) = 0.25 + 0.35 + 0.05 + 0.2 + 0.1 = 1 \]

\(P(X = 3 \textsf{ or } X = 4) = 0.05 + 0.2 = 0.25\)

1.3.

The completed PMF table for the biased coin toss is:

\(x\) Heads Tails
\(P(X=x)\) 0.3 0.7

This is a valid PMF because:

Non-negativity: Both \(P(X = x) \geq 0\)

Honesty: The sum of both probabilities equal 1: \[ \sum_{x}p(x) = \sum_{x}P(X = x) = 0.3 + 0.7 = 1 \] #### 1.4. {-}

This is not a valid PMF since it fails the honesty condition:

Honesty: The sum of the given probabilities does not equal 1: \[ \sum_{x=1}^{7} p(x) = \sum_{x=1}^{7} P(X = x) = 0.1 + 0.05 + 0.05 + 0.3 + 0.25 + 0.75 + 0.35 = 1.85 \neq 1 \]

1.5.

  1. \(\displaystyle P(\textsf{Blue}) = \dfrac{3}{10} = 0.3\)

  2. The PMF for the given scenario is:

\(x\) Red Blue Green
\(P(X=x)\) 0.5 0.3 0.2

This is a valid PMF because:

Non-negativity: All \(P(X = x) \geq 0\)

Honesty: The sum of all three probabilities equals to 1: \[ \sum_{x}p(x) = \sum_{x}P(X = x) = 0.5 + 0.3 + 0.2 = 1 \]

1.6.

  1. For the given PMF to be valid, you must have \(p = \dfrac{1}{10}\).

  2. For \(p = \dfrac{1}{10}\), then \(P(X = 3) = \dfrac{3}{10}\).

Q2

2.1.

This is a valid PDF because:

Non-negativity: \(\displaystyle f(x) \geq 0\) for all values of \(x\).

Honesty: \(\displaystyle \int_{-\infty}^{\infty} f(x) \, \textrm{d}x = \int_{0}^{2} \dfrac{1}{2} \, \textrm{d}x = \left[\, \dfrac{x}{2} \,\right]_{0}^{2} = 1\)

\(\displaystyle P(1 \leq x \leq 2) = \int_{1}^{2} \dfrac{1}{2} \, \textrm{d}x = \left[\, \dfrac{x}{2} \,\right]_{1}^{2} = \dfrac{1}{2}\)

2.2.

This is a valid PDF because:

Non-negativity: \(\displaystyle f(x) \geq 0\) for all values of \(x\)

Honesty: \(\displaystyle \int_{-\infty}^{\infty} f(x) \, \textrm{d}x = \int_{0}^{1} \dfrac{x}{2} \, \textrm{d}x = \left[\, x^2 \,\right]_{0}^{1} = 1\)

  1. \(\displaystyle P(0.5 \leq X \leq 1) = \int_{0.5}^{1} 2x \, \textrm{d}x = \left[ x^2 \right]_{0.5}^{1} = 1^2 - (0.5)^2 = 1 - 0.25 = 0.75\)

  2. \(\displaystyle P(0.25 \leq X \leq 0.75) = \int_{0.25}^{0.75} 2x \, \textrm{d}x = \left[ x^2 \right]_{0.25}^{0.75} = (0.75)^2 - (0.25)^2 = 0.5625 - 0.0625 = 0.5\)

2.3.

This is a valid PDF because:

Non-negativity: \(\displaystyle f(x) \geq 0\) for all values of \(x\)

Honesty: \(\displaystyle \int_{-\infty}^{\infty} f(x) \, \textrm{d}x = \int_{3}^{7} \dfrac{1}{4} \, \textrm{d}x = \left[ \dfrac{x}{4} \right]_{3}^{7} = 1\)

\(\displaystyle P(3 \leq X \leq 6) = \int_{3}^{6} \dfrac{1}{4} \, \textrm{d}x = \left[ \dfrac{x}{4} \right]_{3}^{6} = \dfrac{6}{4} - \dfrac{3}{4} = \dfrac{3}{4}\)

2.4.

This is not a valid PDF since it does not meet the honesty condition:

Honesty: \(\displaystyle \int_{-\infty}^{\infty} f(x) \, \textrm{d}x = \int_{1}^{4} \dfrac{1}{9} \, \textrm{d}x + \int_{5}^{7} \dfrac{1}{4} \, \textrm{d}x \neq 1\)

Calculating the individual integrals:

  • \(\displaystyle \int_{1}^{4} \dfrac{1}{9} \, \textrm{d}x = \dfrac{1}{9} \left[ x \right]_{1}^{4} = \dfrac{1}{3}\)

  • \(\displaystyle \int_{5}^{7} \dfrac{1}{4} \, \textrm{d}x = \dfrac{1}{4} \left[ x \right]_{5}^{7} = \dfrac{1}{2}\)

And adding them together:

\(\displaystyle \int_{-\infty}^{\infty} f(x) \, \textrm{d}x = \dfrac{1}{3} + \dfrac{1}{2} = \dfrac{5}{6} \neq 1\)

2.5.

  1. For the given PDF to be valid, you must have \(k = 3\).

  2. \(\displaystyle P(0.2 \leq X \leq 0.3) = \int_{0.2}^{0.3} 3 x^2 \, \textrm{d}x = 3 \left[ \dfrac{x^3}{3} \right]_{0.2}^{0.3} = \left[ x^3 \right]_{0.2}^{0.3} = 0.019\)

2.6.

This is a valid PDF because:

Non-negativity: \(f(x) \geq 0\) for all values of \(x\)

Honesty: \(\displaystyle \int_{-\infty}^{\infty} f(x) \, \textrm{d}x = \int_{0}^{0.5} 4x \, \textrm{d}x + \int_{0.5}^{0.75} (4 - 4x) \, \textrm{d}x + \int_{0.75}^{1} 0.5 \, \textrm{d}x\)

Calculating the individual integrals:

  • \(\displaystyle \int_{0}^{0.5} 4x \, \textrm{d}x = \left[ 2x^2 \right]_{0}^{0.5} = 0.5\)

  • \(\displaystyle \int_{0.5}^{0.75} (4 - 4x) \, \textrm{d}x = \left[ 4x - 2x^2 \right]_{0.5}^{0.75} = 0.375\)

  • \(\displaystyle \int_{0.75}^{1} 0.5 \, \textrm{d}x = \left[ 0.5x \right]_{0.75}^{1} = 0.125\)

and adding them together gives \(0.5 + 0.375 + 0.125 = 1\).

Q3

3.1.

  1. \(F(3) = P(X \leq 3) = 0.1 + 0.3 + 0.5 = 0.9\)

  2. \(P(X > 2) = 1 - P(X \leq 2) = 1 - (0.1 + 0.3 + 0.5) = 1 - 0.9 = 0.1\)

3.2.

  1. The CDF for values \(0.5\), \(1\), and \(2\):

    • \(\displaystyle F(0.5) = \int_0^{0.5} \dfrac{1}{2} \, \textrm{d}x = \left[ \dfrac{x}{2} \right]_0^{0.5} = \dfrac{0.5}{2} = 0.25\)

    • \(\displaystyle F(1) = \int_0^{1} \dfrac{1}{2} \, \textrm{d}x = \left[ \dfrac{x}{2} \right]_0^{1} = \dfrac{1}{2} = 0.5\)

    • \(\displaystyle F(2) = \int_0^{2} \dfrac{1}{2} \, \textrm{d}x = \left[ \dfrac{x}{2} \right]_0^{2} = \dfrac{2}{2} = 1\)

  2. \(\displaystyle F(3) = 1\) (since the CDF for any \(x \geq 2\) is \(1\).)

3.3.

  1. The CDF at points \(4\), \(5\), and \(6\):

    • \(\displaystyle F(4) = \int_3^4 \dfrac{1}{4} \, \textrm{d}x = \left[ \dfrac{x}{4} \right]_3^4 = \dfrac{4}{4} - \dfrac{3}{4} = \dfrac{1}{4}\)

    • \(\displaystyle F(5) = \int_3^5 \dfrac{1}{4} \, \textrm{d}x = \left[ \dfrac{x}{4} \right]_3^5 = \dfrac{5}{4} - \dfrac{3}{4} = \dfrac{2}{4} = \dfrac{1}{2}\)

    • \(\displaystyle F(6) = \int_3^6 \dfrac{1}{4} \, \textrm{d}x = \left[ \dfrac{x}{4} \right]_3^6 = \dfrac{6}{4} - \dfrac{3}{4} = \dfrac{3}{4}\)

  2. \(P(X > 5) = 1 - F(5) = 1 - \dfrac{1}{2} = \dfrac{1}{2}\).

3.4.

This is not a valid CDF because the CDF should be non-decreasing as \(x\) increases.


Version history and licensing

v1.0: initial version created 12/24 by Sophie Chowgule as part of a University of St Andrews VIP project.

This work is licensed under CC BY-NC-SA 4.0.

Mailing List



Feedback

Your feedback is appreciated and useful. Feel free to leave a comment here,
but please be specific with any issues you encounter so we can help to resolve them
(for example, what page it occured on, what you tried, and so on).