1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Homework Help: Minimize expected value of the absolute difference

  1. Aug 21, 2010 #1
    1. The problem statement, all variables and given/known data
    Let X be a continuous random variable with median m.
    Minimize E[|X - b|] as a function of b. Hint: Show that E[|X - b|] = E[|X - m|] + 2 [tex]\int[/tex] (x - b) f(x) dx , where the integral is from b to m.

    2. Relevant equations



    3. The attempt at a solution
    I wanted to try a solution but I even don't know how to determine whether it is minimum or not. Please help.
     
  2. jcsd
  3. Aug 21, 2010 #2

    lanedance

    User Avatar
    Homework Helper

    treat is as a function of b
    f(b) = E(|X-b|)

    how would you find the minima of f w.r.t. b?
     
  4. Aug 21, 2010 #3

    statdad

    User Avatar
    Homework Helper

    Can you show the expression given above? If so, what do you know about the sign of

    [tex]
    \int_b^m (x-b) f(x) \, dx
    [/tex]

    Finally, note that the right-side is a function of the number [itex] b [/itex]. What happens when you evaluate at that function at a (cleverly) chosen value?
     
  5. Sep 16, 2010 #4
    I am having a hard time how to evaluate this integral because the function f(x) is not given.
    [tex]
    \int_b^m (x-b) f(x) \, dx
    [/tex]
     
  6. Sep 16, 2010 #5

    statdad

    User Avatar
    Homework Helper

    Aaaaah, that's the point: if you were given a specific [tex] f(x) [/tex], any result you obtained would apply only to that particular function , not in general. This exercise is meant to give a general result.

    Hint: In the integral

    [tex]
    \int_a^m (x-b) f(x) \, dx
    [/tex]

    the interval of integration consists of values [tex] x \ge b [/tex], so

    i) What is the sign of [tex] (x-b)f(x) [/tex] over the interval?
    ii) What does this say about the sign of the integral of [tex] (x-b)f(x)[/tex]?
    iii) Using your answers to `i' and `ii'', if you want to choose [tex] b [/tex] to minimize

    [tex]
    E(|X-m|) + 2 \int_b^m (x-b) f(x) \, dx
    [/tex]

    as a function of [tex] b [/tex], what choice does it?
     
  7. Sep 19, 2010 #6

    okay, let me see if I figure this out right.
    i) The sign of [tex] (x-b)f(x) [/tex] over the interval is positive.
    ii) The sign of the integral of [tex] (x-b)f(x)[/tex] is positive.
    iii) Substituting b to m in the expression [tex]
    E(|X-m|) + 2 \int_b^m (x-b) f(x) \, dx
    [/tex]

    results to [tex]
    E(|X-b|) + 2 \int_b^b (x-b) f(x) \, dx
    [/tex]
    which becomes E(|X - b|) + 2*(0)
    and finally to E(|X - b|)
    ...so E[|X - b|] is minimized when b = m.
    I hope this time I finally got it right with your guidance.. =)
     
  8. Sep 20, 2010 #7
    However, I'm wondering what is the use of 2 when the integral is just zero?
     
  9. Sep 20, 2010 #8

    statdad

    User Avatar
    Homework Helper

    The 2 comes in when the expression on the right is developed.
     
  10. Dec 7, 2010 #9
    Stat Dad -- Thank you for your guidance on this problem -- I was terribly lost and had a very similar question!
     
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook