Tip: press ± to flip a sign quickly.
The completing the square calculator helps you rewrite a quadratic equation in completed-square form and solve it step by step. Enter the coefficients of your quadratic, and you can find the completed-square form, vertex, axis of symmetry, and roots when applicable.
Completing the square is useful when you need to convert standard form into vertex form or solve a quadratic equation that is difficult to factor. In this guide, you will see how the calculator works, which formula it uses, and how to complete the square by hand.
Key Takeaways
- Completing the square rewrites a quadratic as a squared binomial plus or minus a constant.
- For a quadratic in standard form, the leading coefficient must satisfy a ≠ 0.
- The completed-square form makes the vertex and axis of symmetry easier to identify.
- When the leading coefficient is not 1, factor it out or divide the equation by it before completing the square.
- The completing-the-square method can solve quadratic equations and leads directly to the quadratic formula.
How the Completing the Square Calculator Works
The calculator starts with a quadratic in standard form:
Enter the three coefficients:
- a is the coefficient of x².
- b is the coefficient of x.
- c is the constant term.
The calculator then rewrites the quadratic by forming a perfect square. Depending on the input, the result can show the completed-square or vertex form and the corresponding solutions.
For a quadratic equation, the calculator can help you see both the algebraic steps and the final result. This is useful when you want to check your own work rather than see only the final value of x.
What Is Completing the Square?
Completing the square is an algebraic method for rewriting a quadratic expression so that part of it becomes a perfect square.
A quadratic can be written in standard form as:
The completed-square form is:
This form is called vertex form. For the function represented by this expression, the vertex is (h, k).
The method works by taking half of the coefficient of x, squaring that value, and using it to create a perfect square trinomial. The same value must be accounted for elsewhere in the expression so the original quantity does not change.
OpenStax demonstrates this process by adding the square of half the x-coefficient to both sides of a quadratic equation before factoring the resulting perfect square.
What Formula Does Completing the Square Use?
For the simple case where the coefficient of x² is 1, the key identity is:
The number added to complete the square is:
For a general quadratic with a ≠ 0, the completed-square form can be written as:
where:
and:
This gives the vertex directly:
The axis of symmetry is:
The completed-square representation is useful for graphing since the turning point can be read from the vertex form.
How to Complete the Square Step by Step
For a quadratic where the coefficient of x² is 1, use these steps:
- Move the constant term to the other side of the equation.
- Take half of the coefficient of x.
- Square that value.
- Add the squared value to both sides.
- Factor the left side as a perfect square.
- Take the square root of both sides when solving for x.
- Isolate x and check the result in the original equation.
The key step is easy to remember:
Take half of b, then square it.
This is the value that creates the perfect square.
Example: x² + 6x − 7 = 0
Start with:This example follows the standard completing-the-square process presented in OpenStax and other university-level algebra resources.
How to Complete the Square When a ≠ 1
When the coefficient of x² is not 1, you need to account for that coefficient before completing the square.
For:
Then work with the coefficient inside the parentheses.
Another common approach is to divide the entire equation by a when solving an equation. CalculatorSoup and OpenStax both describe this adjustment for quadratics whose leading coefficient is not 1.
Example: 2x² − 12x + 7 = 0
Start with:
This example shows why the leading coefficient must be handled before the square is completed. If the factor of 2 is lost during the process, the final constant will be incorrect.
How Completing the Square Gives Vertex Form
Completing the square is especially useful for converting standard form into vertex form.
Standard form:
Vertex form makes these features visible directly from the equation. Ohio State’s Ximera material uses completing the square to convert a quadratic from standard form to vertex form and identify the vertex.
What Happens When b = 0?
If b = 0, there is no x term.
The quadratic becomes:
For example:
This is a useful special case to recognize before starting the full procedure.
Can You Complete the Square for Every Quadratic?
Yes. The completing-the-square method applies to quadratic expressions of the form:
For example:
The algebraic square-completion process still works. The type of solution changes based on the value obtained after the square is formed.
Completing the Square vs. the Quadratic Formula
Completing the square and the quadratic formula are two methods for solving quadratic equations.
The quadratic formula is:
Completing the square is useful when you need the vertex form or want to see how the quadratic is transformed step by step.
The quadratic formula is useful when you want the roots directly from the coefficients.
The two methods are closely connected. The quadratic formula can be derived by applying completing the square to the general quadratic equation. Khan Academy includes this derivation as part of its completing-the-square material, and Ohio State’s Ximera material shows the algebraic connection.
Common Mistakes to Avoid
A few errors appear often when completing the square:
- Forgetting to divide by a: If the coefficient of x² is not 1, handle the leading coefficient before completing the square.
- Using b instead of half of b: The value to square is b⁄2 when a = 1.
- Adding the value to only one side: For an equation, the same value must be added to both sides.
- Losing a negative sign: If b is negative, half of b remains negative before it is squared.
- Forgetting the ± sign: Taking the square root of both sides can produce two real solutions.
- Skipping the original-equation check: Substituting the final answers back into the original equation can catch arithmetic errors.
A calculator can show the algebraic steps, but checking the structure of each step is still useful when you are learning the method.
