MRS  1.0
A C++ Class Library for Statistical Set Processing
Example target densities for optimisation and sampling

On this page we show some examples of using Moore Rejection Sampling with selected targets

The function of Levy

The function of Levy is $ \Re^2 \rightarrow \Re $ with

\[ f(x,y) = \sum_{i=1}^5 i \cos((i - 1)x + i)\sum_{j=1}^5j\cos((j + 1)y + j) \]

Levy_function.png
Function of Levy on a domain [-2,2]x[-2,2]

We convert the above function into a target shape by exponentiating its negative that is scaled by a temperature parameter $T$ :

\[ l_{T}(x) = \exp \left( - \frac{1}{T}\sum_{i=1}^5 i \cos((i - 1)x_1 + i) \sum_{j=1}^5j\cos((j + 1)x_2 + j) \right) \]

Levy Target Shape $l_{40}(x_1,x_2): [-10,10]\times [-10,10] \to \Re $ is plotted below.

LevyT40TargetShape.png
Levy Target Shape on a domain [-10,10]x[-10,10]

Rosenbrock's Multi-dimensional function

Rosenbrock's $ D $-dimensional function $ \Re^2 \rightarrow \Re $ with

\[ f(x) = \exp \left( - \sum_{i=2}^D \left( 100(x_i - x_{i-1}^2)^2 + ( 1 - x_{i-1})^2 \right) \right) \]

Rosenbrock_function.png
Rosenbrock's D=2 dimensional function on a domain [-2,2]x[-1,3]
 All Classes Namespaces Functions Variables Typedefs Enumerations Friends