Bernoulli-Laplace Experiment

Description

The Bernoulli-Laplace experiment models a simple diffusion process as a Markov chain. Suppose that we have two urns: urn 0 contains \(j\) balls and urn 1 contains \(k\) balls. Of the \(j + k\) balls, \(r\) are red, where \(0 \le r \le j + k\). At each discrete time unit, a ball is selected at random from each urn, and the balls are switched to the opposite urns. The state of the system at any time is the number of red balls in urn 1. This forms a Markov chain with transition matrix \(P\) given by \begin{align} P(x, x - 1) & = \frac{(j - r + x) x}{j k} \\ P(x, x) & = \frac{(r - x) x + (j - r + x) (j - x)}{j k} \\ P(x, x + 1) & = \frac{(j - x) (k - x)}{j k} \end{align} for \(x\) in the state space \(S = \{\max\{0, r - j\}, \ldots, \min\{k, r\}\}\)

The top graph shows the state space with the current state colored red and the initial state colored blue. As the process runs, the chain moves from state to state. The time and the sate are recorded at each update in the record table. The limiting distribution and the proportion of time that the chain is in each state are shown in the distribution graph and distribution table. The limiting distribution is hypergeometric with parameters \(j + k\), \(r\) and \(k\).

The parameters \(j\), \(k\), \(r\) and the initial state \(x_0\) can be varied with the input controls.