How to use the GDC to find median from probability density function

433 Views Asked by At

So, for example, find the median of the probability density function $f(x) = 1.13e^{-x^2}$ for $0 \le x \le 2$.

I really don't know how to use the calculator to do this. I am using TI-84.

1

There are 1 best solutions below

0
On

Hint: I don't use the TI-84, so I can only guess. Unless the error function $\operatorname{erf}(x)$ is built-in (and I doubt it is), you will have to write a function to perform numerical integration. See this link.

$$\operatorname{erf}(x)=\frac2{\sqrt{\pi}}\int_0^x e^{-t^2}\; dt$$

If you are requiring all of the probability to be on $[0,2]$, you will need to modify it and use $$G(x) = \begin{cases} 0,&\textrm{if }x<0\\ \dfrac{g(x)}{g(2)},&\textrm{if }0\leq x \leq 2\\ 1,&\textrm{if }x>2\\ \end{cases}$$ where $g(x) = \int_0^x e^{-t^2}\; dt$ (note we can leave off the constants out front since we are normalizing anyway).

So what I am advising is that you implement a function to perform numerical integration to get the desired function. To get the median, you need to then find $G^{-1}(0.5)$, which may involve another numerical algorithm.