# valid probability density function?

• Feb 22nd 2008, 08:28 AM
Jason Bourne
valid probability density function?
1. For each of the following functions how do you determine whether it is a valid probabilty density function??????????????

(a) $\displaystyle f(x) = \frac{x}{2} , ~~~~~~~~ 0\leq x\leq 2$
(b) $\displaystyle f(x) = 4e^{-4x} , ~~~~~~~~~ x\geq 0$
(c) $\displaystyle f(x) = e^{x} + 1 , ~~~~~~~~~ 0\leq x \leq 1$

2.

(a) Find the value of a that makes $\displaystyle f(x) = ax(1-x)$ for $\displaystyle 0\leq x\leq 1$ a valid probability density function
(b) Evaluate the mean of this distribution
(c) Evaluate the variance of this distribution

Thanks for help (Hi)
• Feb 22nd 2008, 08:39 AM
ThePerfectHacker
Quote:

Originally Posted by Jason Bourne

(a) $\displaystyle f(x) = \frac{x}{2} , ~~~~~~~~ 0\leq x\leq 2$
(b) $\displaystyle f(x) = 4e^{-4x} , ~~~~~~~~~ x\geq 0$
(c) $\displaystyle f(x) = e^{x} + 1 , ~~~~~~~~~ 0\leq x \leq 1$

A function $\displaystyle \geq 0$ is a probability density function when its integral is 1. So just get whether the integrals are 1. Just be careful on (b) the integral has limits 0 to +oo.

Quote:

2.

(a) Find the value of a that makes $\displaystyle f(x) = ax(1-x)$ for $\displaystyle 0\leq x\leq 1$ a valid probability density function
(b) Evaluate the mean of this distribution
(c) Evaluate the variance of this distribution
(a) Solve the equation $\displaystyle \int_0^1 ax(1-x) ~ dx = 1$.
(b) Once you find 'a' compute $\displaystyle E[X]=\int_0^1 ax^2(1-x) ~ dx$
(c) Find $\displaystyle \int_0^1 ax^2(1-x^2)~dx - E[X]$.

EDIT: Mistake, but too lazy to fix it.
• Feb 22nd 2008, 10:30 AM
CaptainBlack
Quote:

Originally Posted by ThePerfectHacker
A function $\displaystyle \geq 0$ is a probability density function when its integral is 1. So just get whether the integrals are 1. Just be careful on (b) the integral has limits 0 to +oo.

(a) Solve the equation $\displaystyle \int_0^1 ax(1-x) ~ dx = 1$.
(b) Once you find 'a' compute $\displaystyle E[X]=\int_0^1 ax^2(1-x) ~ dx$
(c) Find $\displaystyle \int_0^1 ax^2(1-x^2)~dx - E[X]$.

Err.. hn..

(c) Evaluate the variance of this distribution

$\displaystyle \sigma^2=E((X-\mu)^2)=E(X^2)-\mu^2$

$\displaystyle \sigma^2=\int_0^1 ax^3(1-x)~dx - (E[X])^2$

RonL
• Feb 23rd 2008, 02:52 AM
Jason Bourne
Quote:

Originally Posted by CaptainBlack

$\displaystyle \sigma^2=\int_0^1 ax^3(1-x^2)~dx - (E[X])^2$

RonL

Sorry, shouldn't this be $\displaystyle \sigma^2=\int_0^1 ax^3(1-x)~dx - (E[X])^2$

where does the $\displaystyle x^2$ come from ?
• Feb 23rd 2008, 03:39 AM
CaptainBlack
Quote:

Originally Posted by Jason Bourne
Sorry, shouldn't this be $\displaystyle \sigma^2=\int_0^1 ax^3(1-x)~dx - (E[X])^2$

where does the $\displaystyle x^2$ come from ?

Of course it should, just goes to show that you should not just copy someone else's LaTeX (Doh)

The $\displaystyle x^2$ comes from $\displaystyle E(X^2)=\int_0^1 x^2 ~p(x) dx$, where $\displaystyle p(x)$ is the pdf of $\displaystyle X$

RonL