Probability Density
1. **Problem Statement:** The probability density function (pdf) $f(x)$ is defined as:
$$f(x) = \begin{cases} c(x + 3), & 0 < x < 2 \\ c(7 - x), & 2 < x < 4 \\ 0, & \text{elsewhere} \end{cases}$$
We are asked to:
(i) Sketch $f(x)$ and find $c$.
(ii) Determine the expectation $E(x)$.
(iii) Find $P(1 \leq x < 3)$.
---
2. **Sketch and find $c$:**
- The function is piecewise linear on $(0,4)$.
- From $0$ to $2$, $f(x) = c(x+3)$.
- At $x=0$, $f(0) = c(3)$; at $x=2$, $f(2) = c(5)$.
- From $2$ to $4$, $f(x) = c(7 - x)$.
- At $x=2$, $f(2) = c(5)$; at $x=4$, $f(4) = 0$.
The plot forms a triangle shape with vertices at $(0,3c)$, $(2,5c)$ and $(4,0)$.
Since $f(x)$ is a pdf, \textbf{area under $f(x)$ equals 1}:
$$ \int_0^2 c(x+3) dx + \int_2^4 c(7 - x) dx = 1 $$
Calculate each integral:
$$ \int_0^2 (x+3) dx = \left[\frac{x^2}{2} + 3x\right]_0^2 = \frac{4}{2} + 6 = 2 + 6 = 8 $$
$$ \int_2^4 (7 - x) dx = \left[7x - \frac{x^2}{2}\right]_2^4 = (28 - 8) - (14 - 2) = 20 - 12 = 8 $$
Total area:
$$ c \times 8 + c \times 8 = 16 c = 1 \Rightarrow c = \frac{1}{16} $$
---
3. **Determine the expectation $E(x)$:**
$$ E(x) = \int_0^2 x f(x) dx + \int_2^4 x f(x) dx $$
Substitute $f(x)$ and $c = \frac{1}{16}$:
$$ E(x) = \int_0^2 x \frac{1}{16} (x+3) dx + \int_2^4 x \frac{1}{16} (7 - x) dx $$
Calculate first integral:
$$ \int_0^2 x (x +3) dx = \int_0^2 (x^2 + 3x) dx = \left[\frac{x^3}{3} + \frac{3x^2}{2}\right]_0^2 = \frac{8}{3} + 6 = \frac{8}{3} + \frac{18}{3} = \frac{26}{3} $$
Calculate second integral:
$$ \int_2^4 x (7 - x) dx = \int_2^4 (7x - x^2) dx = \left[\frac{7x^2}{2} - \frac{x^3}{3}\right]_2^4 = \left(\frac{7 \times 16}{2} - \frac{64}{3}\right) - \left(\frac{7 \times 4}{2} - \frac{8}{3}\right) = 56 - \frac{64}{3} - 14 + \frac{8}{3} = 42 - \frac{56}{3} = \frac{126}{3} - \frac{56}{3} = \frac{70}{3} $$
Therefore,
$$ E(x) = \frac{1}{16} \left( \frac{26}{3} + \frac{70}{3} \right) = \frac{1}{16} \times \frac{96}{3} = \frac{96}{48} = 2 $$
---
4. **Find $P(1 \leq x < 3)$:**
Split integral:
$$ P(1 \leq x < 3) = \int_1^2 f(x) dx + \int_2^3 f(x) dx $$
Calculate each:
$$ \int_1^2 \frac{1}{16} (x+3) dx = \frac{1}{16} \left[ \frac{x^2}{2} + 3x \right]_1^2 = \frac{1}{16} \left( 2 + 6 - \left( \frac{1}{2} + 3 \right) \right) = \frac{1}{16} \times 4.5 = \frac{9}{32} $$
$$ \int_2^3 \frac{1}{16} (7 - x) dx = \frac{1}{16} \left[ 7x - \frac{x^2}{2} \right]_2^3 = \frac{1}{16} \left( 21 - \frac{9}{2} - 14 + 2 \right) = \frac{1}{16} \times 7.5 = \frac{15}{32} $$
Therefore,
$$ P(1 \leq x < 3) = \frac{9}{32} + \frac{15}{32} = \frac{24}{32} = \frac{3}{4} $$
---
Final answers:
- $(i)$ $c = \frac{1}{16}$
- $(ii)$ $E(x) = 2$
- $(iii)$ $P(1 \leq x < 3) = \frac{3}{4}$