calculator completing the square

Completing the Square Calculator

Enter coefficients for y = ax2 + bx + c and get the completed-square (vertex) form instantly.

What is completing the square?

Completing the square is an algebra method used to rewrite a quadratic expression from standard form, ax2 + bx + c, into vertex form, a(x - h)2 + k. This makes the graph's key features easier to see, especially the vertex and axis of symmetry.

If you have ever used a vertex form calculator, this is the exact transformation happening behind the scenes. The calculator above performs the same math automatically while still showing the intermediate values.

Why use a completing the square calculator?

  • Quickly converts standard form to vertex form.
  • Finds the vertex (h, k) with less algebraic error.
  • Computes the discriminant and roots at the same time.
  • Great for homework checks, teaching, and exam review.

How the calculator works

1) Start with the quadratic

You input a, b, and c for: y = ax2 + bx + c.

2) Compute the key values

The calculator uses these formulas:

  • h = -b / (2a)
  • k = c - b2 / (4a)

Then it writes the equivalent form y = a(x - h)2 + k.

3) Return graph information

Since the expression is now in vertex form, you immediately get:

  • The vertex: (h, k)
  • The axis of symmetry: x = h
  • Whether the parabola opens up (a > 0) or down (a < 0)

Example walkthrough

Suppose your equation is y = x2 + 6x + 5. Completing the square gives:

  • h = -6 / 2 = -3
  • k = 5 - 36/4 = -4

So the vertex form is y = (x + 3)2 - 4. From that, the vertex is (-3, -4) and axis of symmetry is x = -3.

Common mistakes this tool helps prevent

  • Forgetting to divide b by 2a (not just 2).
  • Sign mistakes when converting to (x - h) form.
  • Dropping the outside coefficient a in front of the square.
  • Incorrectly combining constants after square completion.

FAQ

Can this work with decimals or negatives?

Yes. The calculator accepts decimal coefficients and negative values.

What if a = 0?

Then the expression is not quadratic, so completing the square is not applicable. The calculator will show an error message in that case.

Does this also solve for roots?

Yes. It shows real roots when the discriminant is non-negative, and complex roots when it is negative.

Final note

Completing the square is one of the most useful quadratic techniques in algebra, precalculus, and calculus. Use this calculator to speed up your workflow, verify classwork, and build intuition about quadratic graphs.

🔗 Related Calculators