Results 1 to 4 of 4

Math Help - c.d.f. of a random variable, given pdf

  1. #1
    Member
    Joined
    Feb 2011
    Posts
    83
    Thanks
    2

    c.d.f. of a random variable, given pdf

    pdf is given by

    f(x) = 2-4|x| if -1/2 < x < 1/2 and 0 otherwise

    I cant do the integral of 2-4|x| so I am going to make 2 cases, x < 0 and x > 0.

    If x < 0 , f(x) = 2+4x for -1/2 < x < 0

    So we look at \int_{x}^{0} 2+4t \text{d}t = -2x(x+1)

    If x > 0 , f(x) = 2x-4x for 0 < x < 1/2

    So we look at \int_{0}^{x} 2-4t \text{d}t = -2x(x-1)

    So I figure the cdf should be

    F_X(x) =

    0 if x \leq -1/2

    -2x(x+1) if -1/2 < x < 0

    -2x(x-1) + \int_{-1/2}^{0} 2+4t \text{d}t = -2x(x-1) + 1/2
    if  0 \leq x < 1/2

    1 if x \geq 1/2

    So i think is make sense to put 0 with the positive case. Since the adding of the 1/2 captures all the probabilities for negative values. However I think the function for -1/2 < x < 0 is wrong. Lower numbers are giving me higher probabilities than numbers close to 0. So something must be wrong.
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Flow Master
    mr fantastic's Avatar
    Joined
    Dec 2007
    From
    Zeitgeist
    Posts
    16,948
    Thanks
    5
    Quote Originally Posted by Jame View Post
    pdf is given by

    f(x) = 2-4|x| if -1/2 < x < 1/2 and 0 otherwise

    I cant do the integral of 2-4|x| so I am going to make 2 cases, x < 0 and x > 0.

    If x < 0 , f(x) = 2+4x for -1/2 < x < 0

    So we look at \int_{x}^{0} 2+4t \text{d}t = -2x(x+1)

    If x > 0 , f(x) = 2x-4x for 0 < x < 1/2

    So we look at \int_{0}^{x} 2-4t \text{d}t = -2x(x-1)

    So I figure the cdf should be

    F_X(x) =

    0 if x \leq -1/2

    -2x(x+1) if -1/2 < x < 0

    -2x(x-1) + \int_{-1/2}^{0} 2+4t \text{d}t = -2x(x-1) + 1/2
    if  0 \leq x < 1/2

    1 if x \geq 1/2

    So i think is make sense to put 0 with the positive case. Since the adding of the 1/2 captures all the probabilities for negative values. However I think the function for -1/2 < x < 0 is wrong. Lower numbers are giving me higher probabilities than numbers close to 0. So something must be wrong.
    It should be apparent that:

    Case 1: x < -\frac{1}{2}. \displaystyle F(x) = 0.

    Case 2: -\frac{1}{2} \leq x \leq 0. \displaystyle F(x) = \int_{-1/2}^{x} (2 + 4t) \, dt.

    Case 3: 0 < x \leq \frac{1}{2}. \displaystyle F(x) = \frac{1}{2} + \int_{0}^{x} (2 - 4t) \, dt.

    Case 4: x > \frac{1}{2}. \displaystyle F(x) = 1.
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Member
    Joined
    Feb 2011
    Posts
    83
    Thanks
    2
    I have another question about this random variable.

    I got that the expected value,

    E[X] = \int_{-1/2}^{0} x(2+4x) \; \text{d}x + \int_{0}^{1/2} x(2-4x) \; \text{d}x = 0

    Can I not break up the function to calculate the expected value?
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Flow Master
    mr fantastic's Avatar
    Joined
    Dec 2007
    From
    Zeitgeist
    Posts
    16,948
    Thanks
    5
    Quote Originally Posted by Jame View Post
    I have another question about this random variable.

    I got that the expected value,

    E[X] = \int_{-1/2}^{0} x(2+4x) \; \text{d}x + \int_{0}^{1/2} x(2-4x) \; \text{d}x = 0

    Can I not break up the function to calculate the expected value?
    Yes you can, which is what you appear to have done. But I would have used the fact that f(x) is even and hence xf(x) is odd to get \displaystyle \int_{-1/2}^{1/2} x f(x) \, dx = 0.
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. Replies: 1
    Last Post: October 15th 2012, 11:37 PM
  2. exponential random variable with a random mean?
    Posted in the Advanced Statistics Forum
    Replies: 2
    Last Post: March 21st 2010, 03:05 PM
  3. Replies: 9
    Last Post: January 28th 2010, 08:26 AM
  4. Replies: 3
    Last Post: January 13th 2010, 11:44 AM
  5. Mean of random variable
    Posted in the Advanced Statistics Forum
    Replies: 4
    Last Post: March 31st 2008, 09:42 PM

Search Tags


/mathhelpforum @mathhelpforum