Interactive application
Interactive
Seemingly unrelated formations following the same rule.

Catalan structures

Different combinatorial objects share one recursive structure. Explore the bijections between trees, balanced parentheses, lattice paths and triangulations, then watch the reflection principle account for invalid paths. A focused combinatorics study with the correspondence made explicit.

Explore connections
Many objects; one counting sequence
ConstructPairCount
Open Catalan structures Explore the live application and its controls.
Dyck-Path (Classic)
Dyck-Path (Classic)
Quick start · live feature guide

Open the application, then follow what changes

Trees, parentheses, lattice paths and triangulations share a recursive structure. This focused combinatorics study makes their correspondences concrete and uses the reflection principle to show exactly which paths a Catalan count excludes.

  1. 01

    Choose an object

    Begin with a balanced expression, tree, path or triangulation.

  2. 02

    Follow a bijection

    Translate its structure into another representation.

  3. 03

    Read the recursion

    See how smaller valid objects combine into larger ones.

  4. 04

    Reflect the failures

    Account for lattice paths that cross the forbidden boundary.

A building block for thinking about structure

The shared count is the beginning. The useful question is how the same recursive split appears in a tree, a balanced expression, a lattice path or a triangulation. This is a compact idea showcase rather than a large software system; it supplies structural intuition for the tree-based tools elsewhere in the portfolio.

One count, several concrete objects

Catalan numbers appear in objects that initially look unrelated: balanced parentheses, full binary trees, non-crossing circle matchings and polygon triangulations. This study builds the small cases explicitly and lets the viewer browse one configuration at a time, animate through the collection or display the whole set.

The application generates the structures recursively. Parenthesis generation enforces valid prefixes; tree generation combines possible left and right subtrees; matching and triangulation generators split their boundary into smaller subproblems. You can inspect the objects that contribute to each count.

Show why some paths are excluded

The lattice-path view separates valid paths from unrestricted monotone paths. Turning on invalid examples reveals the first crossing of the diagonal, and a reflection overlay exchanges the remaining horizontal and vertical steps. Their reflected endpoints land at the same off-diagonal destination, making the subtraction in the counting argument visible.

This view includes valid and invalid totals, individual path strings and a zoomable overview. It gives the closed-form count a geometric explanation that can be checked against every generated example at the selected size.

Connect the representations

Balanced parentheses also appear as up-and-down mountain paths, connecting a symbolic sequence to its geometric profile. A paired view places a non-crossing matching beside a polygon triangulation at the corresponding position in their recursive enumerations. The two drawings make the repeated splitting pattern easier to compare.

React manages the selected size, view and playback state; Canvas draws the structures, while the interface supplies mathematical notation and explanatory controls. For the selected size, every generated object can be inspected individually or in the complete collection.

Current scope

  • The interface deliberately limits n to 1–5. It enumerates complete collections in memory, so the approach is intended for small cases rather than large combinatorial generation.
  • The matching/triangulation view pairs generated examples; it does not provide arbitrary object conversion or animate a correspondence between individual chords and diagonals.
Explore this fieldSymbolic Unfolded Seven search trees Fortune’s Loom
Page reviewed September 12, 2026. Demonstrations and technical notes reflect the showcased version.
Project overview