Results 1 to 9 of 9

Math Help - Simulating continuos RVs - Inverse Distribution Method

  1. #1
    Newbie
    Joined
    Nov 2008
    Posts
    24

    Simulating continuos RVs - Inverse Distribution Method



    I know that if I want to simulate a value X it's X=F^-1(U). Just need some help as to what the limits are when I integrate f(x) to get F(X). Would they be 0 to 6 for x/36 and 6 to 12 for (12-x)/36? Because I thought one of the limits had to be x so that I would be able to substitute my U value to get X.

    Thanks.
    Follow Math Help Forum on Facebook and Google+

  2. #2
    Grand Panjandrum
    Joined
    Nov 2005
    From
    someplace
    Posts
    14,972
    Thanks
    4
    Quote Originally Posted by ZTM1989 View Post


    I know that if I want to simulate a value X it's X=F^-1(U). Just need some help as to what the limits are when I integrate f(x) to get F(X). Would they be 0 to 6 for x/36 and 6 to 12 for (12-x)/36? Because I thought one of the limits had to be x so that I would be able to substitute my U value to get X.

    Thanks.
    As f(x)=0 when x\le 0:

     F(x)=0 for x \le 0

    Then:

    F(x)=\int_0^x f(\xi)\;d\xi for x>0

    but you may as well note that F(x)=1 for x \ge 12 (at least if the density is set up correctly)

    CB
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Newbie
    Joined
    Nov 2008
    Posts
    24
    So you're saying I use 0 and x as the limits? Well that's what all the questions I've encountered have done too but I've never encountered this sort of a question with split density functions, do I just do both of them with 0 to x or what?
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Newbie
    Joined
    Aug 2009
    Posts
    9
    (*)  \int_0^x \frac{t}{36} dt
    (**)  \int_0^6 \frac{t}{36} dt + \int_6^x \frac{12-t}{36}dt

    I hope it helps
    Follow Math Help Forum on Facebook and Google+

  5. #5
    Grand Panjandrum
    Joined
    Nov 2005
    From
    someplace
    Posts
    14,972
    Thanks
    4
    Quote Originally Posted by temp View Post
    (*)  \int_0^x \frac{t}{36} dt
    (**)  \int_0^6 \frac{t}{36} dt + \int_6^x \frac{12-t}{36}dt

    I hope it helps
    With a bit more detail:

    (*)  \int_0^x \frac{t}{36} dt for 0<x<6,
    (**)  \int_0^6 \frac{t}{36} dt + \int_6^x \frac{12-t}{36}dt  for 6<x<12.

    CB
    Follow Math Help Forum on Facebook and Google+

  6. #6
    Newbie
    Joined
    Nov 2008
    Posts
    24
    Thank you very much, both of you.
    Follow Math Help Forum on Facebook and Google+

  7. #7
    Newbie
    Joined
    Nov 2008
    Posts
    24
    Just another issue. Since i've not got any similar worked examples to look at, I'm finding hard to figure out where I go since I have two different F^-1(u) equations (36u and 12-36u) for the two separate ranges. How do I present these in the final answer with regards to the ranges?
    Follow Math Help Forum on Facebook and Google+

  8. #8
    Moo
    Moo is offline
    A Cute Angle Moo's Avatar
    Joined
    Mar 2008
    From
    P(I'm here)=1/3, P(I'm there)=t+1/3
    Posts
    5,618
    Thanks
    6
    Like this ... ?

    F^{-1}(u)=\begin{cases} \dots \quad \text{if } ?<u<? \\ \dots \quad \text{if } ?<u<? \end{cases}
    Follow Math Help Forum on Facebook and Google+

  9. #9
    Newbie
    Joined
    Nov 2008
    Posts
    24
    U is simulated from Uniform[0,1]. So would I have 0 < u < 0.5 and 0.5 < u < 1 for the two of them respectively?
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. f(x) differentiable f'(x) not continuos?
    Posted in the Calculus Forum
    Replies: 8
    Last Post: November 18th 2010, 05:20 AM
  2. Help with simulating distributions....
    Posted in the Statistics Forum
    Replies: 2
    Last Post: October 30th 2010, 02:51 PM
  3. Continuos functions in R^n
    Posted in the Advanced Algebra Forum
    Replies: 0
    Last Post: November 16th 2009, 09:10 AM
  4. Simulating - Acceptance/Rejection method
    Posted in the Advanced Statistics Forum
    Replies: 7
    Last Post: August 18th 2009, 09:25 PM
  5. continuos function
    Posted in the Calculus Forum
    Replies: 1
    Last Post: September 26th 2007, 10:56 AM

Search Tags


/mathhelpforum @mathhelpforum