Calculators

Triangular Number Calculator

Calculate the nth triangular number and sum of integers from 1 to n exactly in your browser.

Find the sum of the first n positive integers with exact integer arithmetic. Your data stays in your browser.

Enter a non-negative whole number of up to 100 digits. Use digits only, without commas or exponent notation. Zero returns zero.

Your triangular number will appear here.

Sum the first n positive integers.

The nth triangular number is T(n) = n × (n + 1) ÷ 2, the number of dots in a triangle with rows of 1 through n dots. For n = 10, the sum 1 + 2 + … + 10 is 55. We include T(0) = 0 for an empty sum. Enter a non-negative integer using up to 100 digits, without separators, decimals, signs or scientific notation. Leading zeros are accepted. Exact browser BigInt arithmetic avoids rounding even beyond the usual safe-integer limit. This tool calculates a triangular number from its index; it does not test whether a supplied number is triangular. All processing stays in your browser.

Frequently Asked Questions

Everything you need to know about this tool, how it works, and privacy.

What is a triangular number?

It counts dots arranged in rows of 1, 2, 3, and so on through n. The first five positive triangular numbers are 1, 3, 6, 10, and 15.

How is the nth triangular number calculated?

Multiply n by n + 1, then divide by 2. For n = 10, this is 10 × 11 ÷ 2 = 55, the sum of integers from 1 to 10.

Can I use zero, negative numbers or decimals?

Zero is accepted and gives the empty sum T(0) = 0. Negative numbers and decimals are rejected because the index must be a non-negative whole number.

Are large results rounded?

No. BigInt arithmetic produces exact integer results for indices containing up to 100 digits. Enter digits only; scientific notation and thousands separators are not supported.