Adding and Subtracting Polynomials Calculator

This calculator adds and subtracts two polynomials for you, combining like terms automatically so you can check homework answers or work through algebra revision quickly. Type each polynomial using x as the variable, with terms like 3x^2, -4x or 7 separated by plus and minus signs, and the calculator parses both expressions, lines up the terms with matching powers, and returns the simplified sum. It also shows both differences, A minus B and B minus A, because subtraction order matters and the two answers differ only by their signs, which is a useful pattern to see side by side. The degree of the sum is reported as well, so you can spot cases where the leading terms cancel and the result drops to a lower degree than either input. The tool handles decimal coefficients, missing terms and constants without complaint, and powers can be any whole number, so it copes with everything from a simple linear pair through to higher-degree expressions from NCEA Level 1 and 2 algebra or first-year university work. Because subtraction is where most sign errors creep in, comparing your hand working against the A minus B line is a fast way to catch a dropped negative before it costs you marks.

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
4x^2 - 2x + 2
A + B with like terms combined
A - B2x^2 + 6x - 12
B - A-2x^2 - 6x + 12
Degree of A + B2

Use x as the variable, ^ for powers (whole numbers only) and + or - between terms. Decimal coefficients such as 2.5x are fine; spaces are ignored.

How it works

Each polynomial is broken into its terms, and every term is reduced to a coefficient and a power of x: 3x^2 has coefficient 3 and power 2, -4x has coefficient -4 and power 1, and a constant like 7 has power 0. Addition then simply adds the coefficients of matching powers, while subtraction flips the sign of every coefficient in the second polynomial before adding, which is exactly the distribute-the-minus step you do by hand. Any power that appears in only one of the polynomials carries through unchanged. Terms whose coefficients cancel to zero are dropped from the answer, and the remaining terms are written from the highest power down to the constant, the standard form used in textbooks. The degree reported is the highest power left in the sum after cancellation.

Worked example

Take A = 3x^2 + 2x - 5 and B = x^2 - 4x + 7, the calculator's defaults. Adding matches up the powers: (3 + 1)x^2 + (2 - 4)x + (-5 + 7), which gives 4x^2 - 2x + 2, a degree 2 result. Subtracting B from A flips every sign in B first: 3x^2 + 2x - 5 - x^2 + 4x - 7, and combining like terms gives (3 - 1)x^2 + (2 + 4)x + (-5 - 7), which is 2x^2 + 6x - 12. Reversing the order, B - A, produces the same terms with opposite signs: -2x^2 - 6x + 12. Notice how the x term in the sum came out negative even though both inputs look "mostly positive": the -4x in B outweighs the 2x in A, which is the kind of detail that is easy to miss by hand.

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 by 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-08-07 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.