Home▸Combinatorics▸Pascal's Triangle (2D): Binomial Distribution & Combinatorics

Pascal's Triangle (2D): Binomial Distribution & Combinatorics

A Canvas2D companion to the 3D Pascal's Triangle: build the triangle row by row, watch the last row's normalized values converge to a Gaussian bell curve (De Moivre–Laplace theorem), and inspect any C(n,k) cell.

Combinatorics2DEasy60 FPS⇄ 3D version
2d-pascal-triangle ↗ Open standalone

This 2D companion draws the same Pascal recurrence C(n,k) = C(n−1,k−1) + C(n−1,k) on a plain canvas, built for reading the mathematics rather than orbiting a rendered scene. Beyond the three color modes and structural highlights carried over from the 3D version, it adds a dedicated readout: the last row's values, normalized into probabilities, are drawn as a bar chart and overlaid with a dashed Gaussian curve of mean n/2 and σ = √n/2 — the De Moivre–Laplace approximation that a Binomial(n, ½) distribution converges to. A row-by-row "animate construction" toggle rebuilds the triangle at an adjustable speed so you can watch that bell shape sharpen as more rows accumulate.

⚙ Under the hood

2D Pascal's triangle built from the C(n,k) = C(n−1,k−1) + C(n−1,k) recurrence, rendered as colored cells with parity/mod-N/log-value coloring, Fibonacci/triangular/power-of-2 highlight overlays, row-by-row animated construction, and a live bar-chart panel comparing the normalized last row to its Gaussian (De Moivre–Laplace) approximation.

pascal's trianglebinomial coefficientscombinatoricssierpinski trianglebinomial distributionfibonacci sequence

2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install

What did you find?

Add reproduction steps (optional)