Homepage Solution manuals Kevin P. Murphy Machine Learning: a Probabilistic Perspective Exercise 23.2 - Rejection sampling from a Gamma using a Cauchy proposal

Exercise 23.2 - Rejection sampling from a Gamma using a Cauchy proposal

Answers

The p.d.f. of a Cauchy is:

𝒯 ( x | μ , σ 2 , 1 ) = 1 Z 1 1 + ( x μ σ ) 2 ,

where Z = 𝜋𝜎 .

That of a Gamma is:

Ga ( x | a , b ) = b a Γ ( a ) x a 1 e 𝑥𝑏 .

Finally, we determine M from:

M = max x { Ga ( x | a , b ) 𝒯 ( x | μ , σ 2 , 1 ) } ,

where x takes value from the zeros of the polynomial:

f ( x ) = ( a 1 𝑏𝑥 ) [ 1 + ( x μ σ ) 2 ] + 2 x ( x μ ) σ 2 ,

and can be solved analytically. The optimal value for μ and σ 2 should be:

arg min μ , σ 2 { M ( μ , σ 2 | a , b ) }

in order to increase the rate of acceptance.

User profile picture
2021-03-24 13:42
Comments