The Java applet described on this page was commissioned by Prof. David Aldous of the Department of Statistics, University of California, Berkeley to illustrate some of these connections, and more details can be found at his site.

The PWIT is a system of *vertices* or *nodes* connected
by *edges*. There is a distinguished node called the
*root* node. From the root radiates an infinite sequence of edges
to *nearest-neighbour* nodes. The lengths of these edges are
determined by a *Poisson process*. That is, the length of the
first edge and the difference in length of successive edges are
independent random variables with the exponential distribution. These
nodes are said to be at *depth* 1 from the root. Each of these
nodes is surrounded by its own nearest neighbours (at depth 2) with
similarly randomly chosen edge lengths, and they have their own
neighbours (at depth 3), and so on ad infinitem.

- A
*Model*. This is a data structure and associated algorithm for constructing a simulated tree and associated edge-colouring functions. The applet implements two models specified by Prof. Aldous that demonstrate applications of the PWIT and two elementary tree models that were useful during development. - A
*Model Tree*. Having run the model a conventional tree data structure can be extracted from it to represent the PWIT. We do this*lazily*, constructing only those nodes that are visited in the visualisation. - A
*Visual Tree*. This is a second tree data structure corresponding exactly to the currently displayed node and edge diagram. It can be thought of as a copy of a subtree of the model tree decorated with coordinate, colour, and other visualisation attributes. The root node of the visual tree (displayed in yellow at the centre) represents an arbitrary node in the model tree. You can explore the PWIT by clicking on displayed nodes. The applet adjusts the visual tree (lazily expanding the model tree as needed) by re-rooting it at the selected node, and these transitions are smoothly*animated*.

## Typical applet appearanceClick on a node to re-root at the selected node. |

Note: If the area to the right of "Typical applet appearance" remains resolutely blank it's probably because your browser does not have the appropriate Java runtime plug-in installed. In particular, the Java runtime supplied by Microsoft for Internet Explorer on Windows does not cut the mustard. You will need the genuine article from Sun MicroSystems, downloadable from here. It takes about 30 minutes to download and install over a 56k line. Apple Macintosh OS X users should look here, and Solaris users here. Check forJava(TM) Plug-In 1.4.2_03or a more recent version.

*Radius-limited*mode displays just those nodes whose accumulated distance from the chosen root node is less than a given*radius*.*Depth-limited*mode displays all nodes within a given depth from the root node regardless of edge lengths.

- Zoom In. Reduces the window radius. If less than 2 it is halved else decremented by 1.
- Zoom Out. Increases the window radius. If less than 1 it is doubled else incremented by 1.
- Depth/Radius Limited Window. Toggles between tree visualisation modes.
- Step Towards Root. Re-roots the visual tree one node closer to the root of the model.
- Reset. Re-displays the root region of the model.
- Show MM Edges.
If checked, edges in the
*minimal matching*set are coloured blue (Off). - Show TSP Edges.
If checked, edges in the
*minimal tour*set are coloured yellow (Off). - Show MST Edges.
If checked, directed edges in the
*minimal spanning tree*are coloured green and arrowed (Off). - Another Realisation. Displays the next tree from the simulation.

Note: If you ask for two or more colouring schemes at once edges that would be multiply-coloured appear white.

- Window Radius. Radius of window into tree space used in radius-limited mode (3.0).
- Window Depth. Depth of tree used in depth-limited mode (2).
- Node Radius. Radius in pixels of discs representing nodes (6).
- Animation Steps. Number of "sub-frames" generated to animate panning between nodes. The more the smoother and the slower (10).
- Print Model Depth. Number of generations dumped by the Print Model function.
- Node Labels. If checked, model-dependent labels appear against the displayed nodes (Off).

- Generations. Number of iterations of the algorithm (100).
- Width. Number of nodes in each generation (1000).
- Depth. Number of generations retained at end of algorithm (20).
- Precursors. Number of edges incident on each node (15).
- Run Aldine Model. Starts a new PWIT simulation run using the parameters set above and displays the first tree resulting, centred on its root node.

- Nodes. Number of nodes in the simulation (1000).
- Children. Number of child nodes to each node (15).
- Alpha. Parameter of the violet edge probability distribution function (0.75).
- Lambda. Parameter of the violet edge probability distribution function (1.3333).
- Run Linade Model. Starts a new PWIT simulation run using the parameters set above and displays the first tree resulting, centred on its root node.

- Debug. If checked, enables debugging printouts into Java console (Off).
- Blue Property Checking. If checked, displayed nodes with two or more blue edges are shown in red. If any such nodes are detected an alert appears in the browser status bar. (On).
- Print Visual Tree. Prints the displayed tree into the Java console
- Print Model Tree. Prints all of the tree produced by the model that's been visited (appeared within a display window) so far.
- Print Model. Prints the cells in the last few generations of the Aldine algorithm that contribute to the node at the centre of the displayed tree.
- Blue Meany. Calculates the mean length of displayed blue edges and shows result in browser status bar.
- Y Distribution. Displays a bar chart showing the distribution of Y values in the Aldine generation corresponding to the node at the centre of the displayed tree.
- Run Poisson Model. Replaces the current simulation with a randomly generated sequence of PWITs and presents the first tree in this sequence.
- Branching. The branching ratio for the finite tree model.
- Depth. The depth for the finite tree model.
- Run Finite Tree Model. Replaces the current simulation with a simple finite tree model of given branching and depth and presents this tree.

- radius. (Float) Initial window radius (3.0).
- depth. (Int) Initial window depth (2).
- noderadius. (Int) Initial node radius in pixels (6)
- debug. (yes/no) Enable debug printout (no).
- animatedstart. (yes/no) Enable pretentious startup (no).
- disablegui. (yes/no) Run without the Control Panel (no).
- expandlimit. (Int) Maximum number of nodes by which (model) tree may be expanded before confirmation is required (5000).
- model. (aldine/linade/poisson/finite) Select initial simulation (aldine).
- aldine-generations. (Int) Default number of generations in Aldine model (100).
- aldine-width. (Int) Default nodes per generation in Aldine model (1000).
- aldine-depth. (Int) Default retained generations in Aldine model (20).
- aldine-precursors. (Int) Default branching in Aldine model (15).
- linade-nodes. (Int) Default number of nodes in Linade model (100).
- linade-children. (Int) Default children per node in Linade model (15).
- linade-alpha. (Float) Default alpha parameter of violet edge pdf (0.75).
- linade-lambda. (Float) Default lambda parameter of violet edge pdf (1.3333).

These are in the form
G*g*K*k*(G*g'*K*k'P p*). For
example, G3K205(G2K687P4). The last generation of nodes is numbered
0, the next to last 1, and so on. So our example node represents node
205 in generation 3. It turns out that this is the 4'th precursor to
node 687 in generation 2.
The labelling is there for debugging purposes and also appears in
the various tree printouts.