Roulette Wheel

The Roulette Wheel serves as our representation of a discrete Random Variable and consists of a single wheel or several concentric wheels. The basic tools used to construct a generic Roulette Wheel are described below. We begin with some general characteristics of the Roulette Wheel and then give a description of each of the side buttons.
In general, the outermost wheel only is used to determine the value of the Random Variable. The size of each region and thus the probability associated with any given event can be adjusted by dragging the corresponding circle along the edge of the Roulette Wheel.
Any region of the wheel can be selected by simply clicking on it. The value of the region and it's probability will be displayed in the "Region Controls" panel (see below). The arrow keys may also be used to change the currently selected region/wheel.
You may spin the wheel by simply dragging the wheel to the left or right. As soon as the mouse leaves the Roulette Wheel, the wheel will begin to spin on its own. The faster you drag the mouse, the faster the wheel will spin.
Wheel Controls
 Wheel Select: select from a number of predefined Roulette Wheels, including a Coin, a Die, a Pair of Dice, the Sum of Two Dice and two wheels representing the Monty Hall Problem
 Insert: insert a new wheel immediately after the currently selected wheel.
 Remove: remove the currently selected wheel.
 Repeat: creates a new outermost wheel, representing an independent trial of the currently selected wheel, that is each region of the original outermost wheel is divided into regions according to the values and probabilities of the current wheel.
 Total: creates a new outermost wheel; the value of each region is the sum of the values of the corresponding region of each of the other wheels.
 Invert:
reverses the order of the wheels while preserving the probabilities.
 Simplify:
combines regions of the Roulette Wheel that represent the same event, reading from the inner most wheel to the outermost wheel.
 Spin: spin the Roulette Wheel; when the wheel stops spinning, the value of the Random Variable (determined by the value shown on the outermost wheel) and it's corresponding probability is displayed in the "Region Controls" panel (see below). The value of the Random Variable is also recorded and the current histogram is updated accordingly.
 Random: immediately produces a random value from the Roulette Wheel. This value is recorded and the current histogram is updated accordingly.
Region Controls
 Insert: insert a new region immediately after (in the counterclockwise direction) the currently selected region.
 Remove: remove the currently selected region.
 Value: displays the value of the currently selected region; the value of the currently selected region can be changed by simply editing this field.
 Probability Select: displays the Probability/Conditional Probability/Ratio of the currently selected region; "Probability" represents the probability that the wheel will land on that region of the wheel, "Conditional Probability" represents the probability that the wheel will land on the currently selected region of the wheel given that it lands on the corresponding region of the preceding wheel, "Ratio" represents the size of the currently selected region relative to that of the size of other regions of the wheel that correspond to the same region of the preceding wheel.
 Color Select: choose from among several colors for the currently selected region; the color you select is purely for aesthetic reasons, except in the case of the color black; if the wheel lands on a black region of the outermost wheel, then the wheel will automatically spin again, see for example the "Monty Hall (Doesn't Know)" wheel.
