Experimental

Catalan Number Calculator

Calculate the nth Catalan number and list the sequence. Catalan numbers count many combinatorial structures like balanced parentheses and binary trees.

Last reviewed by the Radiatus Cloud team

Calculate the nth Catalan number and view the sequence.

Need this done properly for your business?

Radiatus delivers secure cloud, DevOps & compliance engineering.

Book a free consult

Calculate Catalan numbers

The Catalan numbers are a famous sequence that appears throughout combinatorics, counting an astonishing variety of structures. This calculator computes the nth Catalan number exactly, using big-integer arithmetic so even large values are precise, and lists the start of the sequence. The sequence begins one, one, two, five, fourteen, forty-two, and grows rapidly. The nth Catalan number is given by the binomial coefficient two-n-choose-n divided by n plus one.

The fifth Catalan number, for example, is forty-two.

What Catalan numbers count

The same Catalan number counts the ways to correctly match n pairs of parentheses, the number of distinct binary trees with n nodes, the ways to triangulate a polygon, the paths that stay above a diagonal on a grid, and dozens of other combinatorial objects. This ubiquity makes them one of the most celebrated sequences in mathematics. They also satisfy a neat recurrence and a closed-form binomial formula.

Because the numbers grow very quickly, exact computation needs big-integer arithmetic, which this tool uses. All calculation happens locally in your browser.

About this tool

Because the catalan number calculator runs entirely in your browser, you can use it as many times as you like for free, with nothing uploaded and no sign-up required. Everything is computed locally on your own device, so it is fast and private.

Related tools

Frequently Asked Questions

What is a Catalan number?

It is a member of a sequence, one, one, two, five, fourteen, forty-two and so on, that counts many combinatorial structures.

What do Catalan numbers count?

Balanced parentheses, binary trees, polygon triangulations, lattice paths and many other structures all share the same Catalan counts.

How is the nth Catalan number calculated?

It equals the binomial coefficient two-n-choose-n divided by n plus one, which this tool computes with exact big-integer arithmetic.

Why use big integers?

Catalan numbers grow extremely fast, so ordinary numbers lose precision. Big-integer arithmetic keeps the results exact for large n.

Privacy & Security

Everything runs in your browser; nothing is uploaded.

Data: None
Client-side-Side
Active
v1.0

How to Use

Enter n to compute the nth Catalan number.

Disclaimer: This tool is provided "as is" without warranty of any kind. Results are for educational and utility purposes.