Completing the Square Calculator

Introduction: from standard form to a parabola's turning point

Completing the square is the algebra move that takes a quadratic written the ordinary way, ax2+bx+c, and rewrites it so the parabola's turning point is sitting right there in the expression. The rewritten shape is a(x-h)2+k, and the pair (h,k) is the vertex — the lowest point when the curve opens upward, the highest point when it opens downward. Type in your three coefficients and this calculator does the conversion, returning the vertex form so you can read the horizontal and vertical shift straight off the answer.

The two expressions describe the exact same function; the graph does not move an inch. What changes is where the useful facts live. In standard form the vertex is buried inside the coefficients, so you have to do arithmetic to find it. In vertex form the vertex, the axis of symmetry at x=h, and the minimum or maximum value k are all visible without another step. That is exactly why the technique shows up so often the moment a quadratic models something real: the peak height of a projectile, the price that maximizes revenue, or the dimensions that enclose the largest area are all just the vertex of some parabola.

Why bother completing the square instead of using the quadratic formula?

Finding roots is not the same job as finding the vertex. The quadratic formula, x=-b±b2-4ac2a, answers "where does the curve cross zero," while completing the square answers "where does the curve turn." A parabola can sit entirely above the x-axis with no real roots — that is the case when the discriminant b2-4ac<0 — and it still has a perfectly good vertex, so vertex form works even when the quadratic formula returns complex numbers. Completing the square is also the argument that produces the quadratic formula in the first place — run the same steps with letters instead of numbers and the formula falls out.

Reading the vertex form back geometrically, h slides the basic parabola left or right, k lifts or lowers it, the sign of a decides whether it opens up or down, and the size of a makes it narrow or wide. Four separate facts about the graph are packed into one compact line, which is what makes vertex form so quick to sketch from. The name itself is literal: you start with a square that is missing a corner piece, add exactly the piece needed to finish it, and subtract the same amount back so the value never changes.

How to use the a, b, and c inputs

Enter the coefficient of x2 in the field labeled a, the coefficient of x in the field labeled b, and the constant term in c, then press Complete the Square. The vertex form appears directly below the form. Integers and decimals both work — a=1, b=-6, c=5 is fine, and so is something like a=0.5 or b=-2.75. There are no units attached, because the same three coefficients could come from a physics model or a profit curve; whatever units your problem carries stay with your problem.

Read the output as the same quadratic wearing different clothes. If it shows 2(x + 1.0000)² - 1.0000, the vertex form is 2(x+1)2-1. The one sign that trips people up is inside the parentheses: because the template is x-h, a plus sign there means h is negative. So (x + 1) puts the vertex at x=-1, and the constant outside gives the vertex's height. Checking homework? Compare line by line against your own work — the calculator surfaces the vertex first, which is where most sign slips hide in standard form.

The formula the calculator applies

For a quadratic in standard form, the horizontal coordinate of the vertex is

Formula: h = (- b) / (2 a)

h=-b2a

and the vertical coordinate is

k=c-b24a.

Dropping h and k into a(x-h)2+k reproduces the original quadratic exactly, which is the whole point. Where do these two formulas come from? The engine is a single identity, (x+p)2=x2+2px+p2 — build its left side and the right side falls out. Factor a out of the first two terms, take half of the resulting x coefficient and square it to build the perfect-square trinomial, then subtract the same square back out so nothing changes:

ax2+bx+c

Formula: = a (x^2 + b / a x) + c

=a(x2+bax)+c

Formula: = a (x^2 + b / a x + (b/(2a))^2) - a (b/(2a))^2 + c

=a(x2+bax+(b2a)2)-a(b2a)2+c

Formula: = a (x+b/(2a))^2 - b^2 / (4 a) + c

=a(x+b2a)2-b24a+c

That last line is already a(x-h)2+k in disguise: the shift b2a supplies h, and the leftover subtraction is precisely the -b24a term that lands in k. Each coefficient plays a fixed role in the result:

Coefficient Role in the vertex form
a Stays out front unchanged; sets the opening direction and how narrow or wide the parabola is.
b Drives the horizontal shift h=-b2a.
c Anchors the vertical position, finishing the value of k once the square is balanced.

A worked example: rewriting 2x² + 4x + 1

Take a=2, b=4, c=1, so the expression is 2x2+4x+1. The horizontal coordinate is h=-422=-1, and the vertical one is k=1-4242=1-2=-1. The vertex is therefore (-1,-1).

You can also complete the square directly on the numbers rather than quoting the vertex formulas. Factor the leading 2 out of the first two terms, add and subtract the square that finishes the bracket, then carry the extra term back outside:

Formula: 2 x^2 + 4 x + 1

2x2+4x+1

Formula: = 2 (x^2 + 2 x) + 1

=2(x2+2x)+1

Formula: = 2 (x^2 + 2 x + 1 - 1) + 1

=2(x2+2x+1-1)+1

Formula: = 2 (x+1)^2 - 2 + 1

=2(x+1)2-2+1

Formula: = 2 (x+1)^2 - 1

=2(x+1)2-1

Same vertex form, reached without ever leaning on the h and k shortcuts.

Since h=-1, the factor x-h becomes x+1, giving the vertex form 2(x+1)2-1. In one glance: the parabola opens upward (because a=2 is positive), its lowest value is -1, and that minimum happens at x=-1. To be sure nothing drifted, expand it back: 2(x2+2x+1)-1=2x2+4x+2-1=2x2+4x+1, which is the original quadratic.

Reading the result, and what it assumes

The tool assumes a single-variable quadratic in the pattern ax2+bx+c; it never asks what the variable is called, because the conversion depends only on the three numbers. The vertex form it prints is rounded to four decimal places, which keeps decimals like 1.5000 readable while still handling messy coefficients. When you read the answer back, keep the sign rule in mind — x-3 means the vertex sits at h=3, while x+3 means h=-3 — and remember the number outside the square is the vertex height k.

Limitations to keep in mind

The one hard requirement is that a cannot be zero. With a=0 the expression is linear (or constant), there is no parabola and no vertex to find, and the formulas would divide by zero — so the calculator refuses that input and says so rather than printing nonsense. Beyond that, the limits are about presentation, not correctness: a repeating value such as 13 shows as 0.3333, so if you need an exact fraction for a proof, redo that last step by hand. The calculator also reports the finished vertex form rather than narrating each intermediate line, so treat it as a fast checkpoint for work you are practicing on paper, and reach for a separate tool if you specifically need the roots or a plotted graph.

Enter the numeric coefficients a, b, and c from the quadratic expression ax² + bx + c. The calculator returns the equivalent vertex form, and the result below can be read directly to identify the parabola's shift.

Enter coefficients to see the vertex form.

Mini-game: Vertex Forge

This optional mini-game turns the same algebra into a quick pattern-and-reaction challenge. Each round shows a quadratic in standard form, and your job is to lock in the matching vertex form before time runs out. First you select the correct h value, which comes from the horizontal shift. Then you select the matching k value, which finishes the expression a(x - h)² + k. Early rounds are gentle, but later waves introduce half-step vertices, negative leading coefficients, tighter decoys, and faster orbiting choices. The idea is not to replace paper practice. It is to train your eye to notice the same relationships the calculator uses above.

Score0
Time75.0s
Streak0
Progress0 built
Best0

Optional practice game

Vertex Forge

Each round shows a quadratic in standard form. Tap the correct h value first, then tap the matching k value to lock in a(x - h)² + k. Wrong picks cost time, and later waves add half-step vertices and faster decoys.

Controls: tap or click the glowing orbs, or press number keys 1 to 7. Goal: build as many correct vertex forms as you can before the timer expires.

The game is separate from the calculator result above. It is just a fast, replayable way to practice reading the same quadratic structure.

Embed this calculator

Copy and paste the HTML below to add the Completing the Square Calculator - Convert Quadratics to Vertex Form to your website.