Documentation

BGW.Tree.Forest

First passage at forest component boundaries #

An ordered forest is encoded by concatenating its component increment sequences. Its path first reaches minus the number of components at its terminal time. More generally, the end of the first r components is the first visit to -r. The statements use finite prefix sums and include the empty forest.

A forest path stays strictly above its terminal level before its final step.

The first r components occupy exactly their total size in the full code. This also holds when r exceeds the component count, since List.take saturates.

At the end of the first r components, the path has value -r.

The path has not yet reached -r before the end of the first r components.