\textbf{A model with all kinds of stochastic dependencies}

Apart from the model description the sizes of the entities are set by the testing program, since there is no data from which the sizes could be calculated.

Only acceptation codes are so non-trivial that they are described here. Nothing should be prited when calculating new values for functional parameters since there are none. Acceptation codes include updating only the current parameter.

Acceptation formula for a1:

\begin{verbatim}
!  P(a1') / P(a1)

p_acc = 1
CALL user_dist_1_freq(3, a1 % one_dim(1) % new_value, new_frequency)
CALL user_dist_1_freq(3, a1 % one_dim(1) % value, frequency)
p_acc = p_acc * new_frequency / frequency

! q( a1', a1) / q(a1, a1')

CALL user_dist_prop_1_freq(1, 2, a1 % one_dim(1) % value, frequency)
CALL user_dist_prop_1_freq(1, 2, a1 % one_dim(1) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for a2:

\begin{verbatim}
!  P(a2') / P(a2)

p_acc = 1
CALL user_dist_2_freq(4, a2 % one_dim(1) % new_value, new_frequency)
CALL user_dist_2_freq(4, a2 % one_dim(1) % value, frequency)
p_acc = p_acc * new_frequency / frequency

! P( b2 | a2') / P( b2 | a2)

CALL user_dist_2-_freq(a2% one_dim(1) % new_value, b2 % one_dim(1), &
    new_frequency)
CALL user_dist_2-_freq(a2% one_dim(1) % value, b2 % one_dim(1), frequency)
p_acc = p_acc * new_frequency / frequency

! q( a2', a2) / q(a2, a2')

CALL user_dist_prop_2_freq(1, 2, a2 % one_dim(1) % value, frequency)
CALL user_dist_prop_2_freq(1, 2, a2 % one_dim(1) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for b2:

\begin{verbatim}
!  P(b2') / P(b2)

p_acc = 1
CALL user_dist_2-_freq(a2 % one_dim(1) % value, b2 % one_dim(1) % new_value, &
    new_frequency)
CALL user_dist_2-_freq(a2 % one_dim(1) % value, b2 % one_dim(1) % value, &
    frequency)
p_acc = p_acc * new_frequency / frequency

! q( b2', b2) / q(b2, b2')

CALL user_dist_prop_2_freq(1, 2, b2 % one_dim(1) % value, frequency)
CALL user_dist_prop_2_freq(1, 2, b2 % one_dim(1) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for a3:

\begin{verbatim}
!  P(a3') / P(a3)

p_acc = 1
CALL user_dist_3_freq(5, a3 % one_dim(i) % new_value, new_frequency)
CALL user_dist_3_freq(5, a3 % one_dim(i) % value, frequency)
p_acc = p_acc * new_frequency / frequency


! q( a3', a3) / q(a3, a3')

CALL user_dist_prop_3_freq(1, 2, a3 % one_dim(i) % value, frequency)
CALL user_dist_prop_3_freq(1, 2, a3 % one_dim(i) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for a4:

\begin{verbatim}
!  P(a4') / P(a4)

p_acc = 1
CALL user_dist_4_freq(6, a4 % one_dim(1) % new_value, new_frequency)
CALL user_dist_4_freq(6, a4 % one_dim(1) % value, frequency)
p_acc = p_acc * new_frequency / frequency

! P( b4 | a4') / P( b4 | a4)

DO i=1, 2
    CALL user_dist_4-_freq(a4 % one_dim(1) % new_value, b4 % one_dim(i) % &
        value, new_frequency)
    CALL user_dist_4-_freq(a4 % one_dim(1) % value, b4 % one_dim(i) % value, &
        frequency)
    p_acc = p_acc * new_frequency / frequency
END DO

! q( a4', a4) / q(a4, a4')

CALL user_dist_prop_4_freq(1, 2, a4 % one_dim(1) % value, frequency)
CALL user_dist_prop_4_freq(1, 2, a4 % one_dim(1) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Where 2 is the size of e4.

Acceptation formula for b4:

\begin{verbatim}
!  P(b4') / P(b4)

p_acc = 1
CALL user_dist_4-_freq(a4 % one_dim(1) % value, b4 % one_dim(i) % new_value, &
    new_frequency)
CALL user_dist_4-_freq(a4 % one_dim(1) % value, b4 % one_dim(i) % value, &
    frequency)
p_acc = p_acc * new_frequency / frequency


! q( b4', b4) / q(b4, b4')

CALL user_dist_prop_4_freq(1, 2, b4 % one_dim(i) % value, frequency)
CALL user_dist_prop_4_freq(1, 2, b4 % one_dim(i) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for a5 (note that the proposal strategy is random walk):

\begin{verbatim}
!  P(a5') / P(a5)

p_acc = 1
CALL user_dist_5_freq(7, a5 % one_dim(i) % new_value, new_frequency)
CALL user_dist_5_freq(7, a5 % one_dim(i) % value, frequency)
p_acc = p_acc * new_frequency / frequency


! P( b5 | a5') / P( b5 | a5)

CALL user_dist_5-_freq(a5 % one_dim(i) % new_value, b5 % one_dim(i) % value, &
    new_frequency)
CALL user_dist_5-_freq(a5 % one_dim(i) % value, b5 % one_dim(i) % value, &
    frequency)
p_acc = p_acc * new_frequency / frequency

! q( a5', a5) / q(a5, a5')

transition_int = a5 % one_dim(i) % new_value - a5 % one_dim(i) % value
CALL user_dist_prop_5_freq(1, 2, -transition_int, frequency)
CALL user_dist_prop_5_freq(1, 2, transition_int, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for b5:

\begin{verbatim}
!  P(b5') / P(b5)

p_acc = 1
CALL user_dist_5-_freq(a5 % one_dim(i) % value, b5 % one_dim(i) % new_value, &
    new_frequency)
CALL user_dist_5-_freq(a5 % one_dim(i) % value, b5 % one_dim(i) % value, &
    frequency)
p_acc = p_acc * new_frequency / frequency


! q( b5', b5) / q(b5, b5')

CALL user_dist_prop_5_freq(1, 2, b5 % one_dim(i) % value, frequency)
CALL user_dist_prop_5_freq(1, 2, b5 % one_dim(i) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for a6:

\begin{verbatim}
!  P(a6') / P(a6)

p_acc = 1
CALL user_dist_6_freq(5, a6 % two_dim(i, j) % new_value, new_frequency)
CALL user_dist_6_freq(5, a6 % two_dim(i, j) % value, frequency)
p_acc = p_acc * new_frequency / frequency

! q( a6', a6) / q(a6, a6')

CALL user_dist_prop_6_freq(1, 2, a6 % two_dim(i, j) % value, frequency)
CALL user_dist_prop_6_freq(1, 2, a6 % two_dim(i, j) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for a7:

\begin{verbatim}
!  P(a7') / P(a7)

p_acc = 1
CALL user_dist_7_freq(8, a7 % one_dim(1) % new_value, new_frequency)
CALL user_dist_7_freq(8, a7 % one_dim(1) % value, frequency)
p_acc = p_acc * new_frequency / frequency

! P( b7 | a7') / P( b7 | a7)

DO i=1, 6
    DO j=1, 7
        CALL user_dist_7-_freq(a7 % one_dim(1) % new_value, b7 % two_dim(i, &
            j) % value, new_frequency)
        CALL user_dist_7-_freq(a7 % one_dim(1) % value, b7 % two_dim(i, j) % &
            value, frequency)
        p_acc = p_acc * new_frequency / frequency
    END DO
END DO

! q( a7', a7) / q(a7, a7')

CALL user_dist_prop_7_freq(1, 2, a7 % one_dim(1) % value, frequency)
CALL user_dist_prop_7_freq(1, 2, a7 % one_dim(1) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for b7:

\begin{verbatim}
!  P(b7') / P(b7)

p_acc = 1
CALL user_dist_7-_freq(a7 % one_dim(1) % value, b7 % two_dim(i, j) % &
    new_value, new_frequency)
CALL user_dist_7-_freq(a7 % one_dim(1) % value, b7 % two_dim(i, j) % value, &
    frequency)
p_acc = p_acc * new_frequency / frequency

! q( b7', b7) / q(b7, b7')

CALL user_dist_prop_7_freq(1, 2, b7 % two_dim(i, j) % value, frequency)
CALL user_dist_prop_7_freq(1, 2, b7 % two_dim(i, j) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for a8:

\begin{verbatim}
!  P(a8') / P(a8)

p_acc = 1
CALL user_dist_8_freq(9, a8 % one_dim(i) % new_value, new_frequency)
CALL user_dist_8_freq(9, a8 % one_dim(i) % value, frequency)
p_acc = p_acc * new_frequency / frequency


! P( b8 | a8') / P( b8 | a8)

DO j=1, 9
    CALL user_dist_8-_freq(a8 % one_dim(i) % new_value, b8 % two_dim(i, j) % &
        value, new_frequency)
    CALL user_dist_8-_freq(a8 % one_dim(i) % value, b8 % two_dim(i, j) % &
        value, frequency)
    p_acc = p_acc * new_frequency / frequency
END DO

! q( a8', a8) / q(a8, a8')

CALL user_dist_prop_8_freq(1, 2, a8 % one_dim(i) % value, frequency)
CALL user_dist_prop_8_freq(1, 2, a8 % one_dim(i) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for b8:

\begin{verbatim}
!  P(b8') / P(b8)

p_acc = 1
CALL user_dist_8-_freq(a8 % one_dim(i) % value, b8 % two_dim(i, j) % &
    new_value, new_frequency)
CALL user_dist_8-_freq(a8 % one_dim(i) % value, b8 % two_dim(i, j) % value, &
    frequency)
p_acc = p_acc * new_frequency / frequency

! q( b8', b8) / q(b8, b8')

CALL user_dist_prop_8_freq(1, 2, b8 % two_dim(i, j) % value, frequency)
CALL user_dist_prop_8_freq(1, 2, b8 % two_dim(i, j) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for a9:

\begin{verbatim}
!  P(a9') / P(a9)

p_acc = 1
CALL user_dist_9_freq(10, a9 % one_dim(i) % new_value, new_frequency)
CALL user_dist_9_freq(10, a9 % one_dim(i) % value, frequency)
p_acc = p_acc * new_frequency / frequency


! P( b9 | a9') / P( b9 | a9)

DO j=1, 10
    CALL user_dist_9-_freq(a9 % one_dim(i) % new_value, b9 % two_dim(j, i) % &
        value, new_frequency)
    CALL user_dist_9-_freq(a9 % one_dim(i) % value, b9 % two_dim(j, i) % &
        value, frequency)
    p_acc = p_acc * new_frequency / frequency
END DO

! q( a9', a9) / q(a9, a9')

CALL user_dist_prop_9_freq(1, 2, a9 % one_dim(i) % value, frequency)
CALL user_dist_prop_9_freq(1, 2, a9 % one_dim(i) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for b9:

\begin{verbatim}
!  P(b9') / P(b9)

p_acc = 1
CALL user_dist_9-_freq(a9 % one_dim(j) % value, b9 % two_dim(i, j) % &
    new_value, new_frequency)
CALL user_dist_9-_freq(a9 % one_dim(j) % value, b9 % two_dim(i, j) % value, &
    frequency)
p_acc = p_acc * new_frequency / frequency

! q( b9', b9) / q(b9, b9')

CALL user_dist_prop_9_freq(1, 2, b9 % two_dim(i, j) % value, frequency)
CALL user_dist_prop_9_freq(1, 2, b9 % two_dim(i, j) % new_value, new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for a10:

\begin{verbatim}
!  P(a10') / P(a10)

p_acc = 1
CALL user_dist_10_freq(10, a10 % two_dim(i, j) % new_value, new_frequency)
CALL user_dist_10_freq(10, a10 % two_dim(i, j) % value, frequency)
p_acc = p_acc * new_frequency / frequency

! P( b10 | a10') / P( b10 | a10)

CALL user_dist_10-_freq(a10 % two_dim(i, j) % new_value, b10 % two_dim(i, j) &
    % value, new_frequency)
CALL user_dist_10-_freq(a10 % two_dim(i, j) % value, b10 % two_dim(i, j) % &
    value, frequency)
p_acc = p_acc * new_frequency / frequency

! q( a10', a10) / q(a10, a10')

CALL user_dist_prop_10_freq(1, 2, a10 % two_dim(i, j) % value, frequency)
CALL user_dist_prop_10_freq(1, 2, a10 % two_dim(i, j) % new_value, &
    new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}

Acceptation formula for b10:

\begin{verbatim}
!  P(b10') / P(b10)

p_acc = 1
CALL user_dist_10-_freq(a10 % two_dim(i, j) % value, b10 % two_dim(i, j) % &
    new_value, new_frequency)
CALL user_dist_10-_freq(a10 % two_dim(i, j) % value, b10 % two_dim(i, j) % &
    value, frequency)
p_acc = p_acc * new_frequency / frequency

! q( b10', b10) / q(b10, b10')

CALL user_dist_prop_10_freq(1, 2, b10 % two_dim(i, j) % value, frequency)
CALL user_dist_prop_10_freq(1, 2, b10 % two_dim(i, j) % new_value, &
    new_frequency)
p_acc = p_acc * frequency / new_frequency
\end{verbatim}