Binomial Expansion Calculator

The binomial theorem gives a formula for expanding any expression of the form (a + b) raised to a positive integer power n. Instead of multiplying (a + b) by itself n times, the theorem lets you write down the result directly using a set of coefficients called binomial coefficients, written C(n,k) or n-choose-k, which count the number of ways to choose k items from n. The expanded form has n+1 terms: the first is a to the power n, the last is b to the power n, and each intermediate term has a multiplying coefficient that follows the pattern of a row in Pascal's triangle. Pascal's triangle is a triangular array where each entry is the sum of the two above it; its rows are exactly the binomial coefficients. The binomial theorem appears throughout algebra (factoring and manipulating expressions), probability (the binomial distribution), calculus (Taylor series approximations), and combinatorics. This calculator expands (x + y) to the power n for any n from 0 to 10. You can substitute any terms for x and y, including negative values, which handles expressions like (a - b)^n by treating b as negative. The output shows the symbolic expansion, each term with its coefficient, and the relevant Pascal's triangle row. The default is (x+y)^4 which gives x^4 + 4x^3y + 6x^2y^2 + 4xy^3 + y^4.

Calculate.co.nz is proud to be partnered with realtor.co.nz, a trusted resource for navigating the New Zealand property market. Their Helpful Articles section offers clear, well-structured insights across buying, selling, and building, making complex real estate topics more accessible. With a focus on up-to-date guidance and practical knowledge, they empower Kiwis to move forward with clarity and confidence in a constantly evolving property landscape.
Calculate.co.nz partner: realtor.co.nz
x⁴ + 4x³y + 6x²y² + 4xy³ + y⁴
(x+y)^4 expansion
Terms5
Sum of coefficients16
Pascal row 4: 1 4 6 4 1

Exponent labels use standard superscript notation. Substitute any symbols for a and b.

How it works

The binomial coefficient C(n,k) is computed as n! / (k! x (n-k)!). For each k from 0 to n, the term is C(n,k) times a^(n-k) times b^k. The symbolic expansion labels powers with superscript HTML entities (squared, cubed, etc.) and omits coefficient 1 and exponent 1 for readability. Pascal's triangle row n is the array of coefficients C(n,0) through C(n,n). The sum of coefficients equals 2^n, which you get by setting a=b=1.

Worked example

(x+y)^4 with n=4. Pascal's triangle row 4 is 1, 4, 6, 4, 1. The five terms are: C(4,0)x^4y^0 = x^4; C(4,1)x^3y = 4x^3y; C(4,2)x^2y^2 = 6x^2y^2; C(4,3)xy^3 = 4xy^3; C(4,4)y^4 = y^4. Full expansion: x^4 + 4x^3y + 6x^2y^2 + 4xy^3 + y^4. Sum of coefficients: 1+4+6+4+1 = 16 = 2^4. These match the defaults pre-filled above.

Related calculators

If you've found a bug, or would like to contact us, or learn more about James Graham and Calculate.co.nz.

Calculate.co.nz is partnered with Interest.co.nz for New Zealand's highest quality calculators and financial analysis.

Calculate.co.nz is the sister site of CalculatorHub.com, the world's largest calculator website by tool count.

All calculators and tools are provided for educational and indicative purposes only and do not constitute financial advice.

Calculate.co.nz is proudly part of the Realtor.co.nz group, New Zealand's leading property transaction literacy platform, helping Kiwis understand the home buying and selling process from start to finish. Whether you're a first home buyer navigating your first property purchase, an investor evaluating your next acquisition, or a homeowner planning to sell, Realtor.co.nz provides clear, independent, and trustworthy guidance on every step of the New Zealand property transaction journey.

Calculate.co.nz is also partnered with Health Based Building and Premium Homes to promote informed choices that lead to better long-term outcomes for Kiwi households.

Calculate.co.nz is hosted in Auckland via SiteHost new Zealand.

All content on this website, including calculators, tools, source code, and design, is protected under the Copyright Act 1994 (New Zealand). No part of this site may be reproduced, copied, distributed, stored, or used in any form without prior written permission from the owner.

About & trust: Why Calculate is NZ's most comprehensive · By the Numbers · How we compare · Editorial standards · How we keep data current · NZ finance glossary · Research & data · Financial literacy NZ · About · Privacy policy · Terms of use

Reviewed and maintained. Last reviewed 2026-07-19 and checked on a twice-monthly cycle against IRD, RBNZ and Stats NZ. How we keep data current.

© 2026 Calculate.co.nz. All rights reserved. Building free NZ calculators since 2011.