Completing the Square

Transform quadratics into perfect square form

What is Completing the Square?

Completing the square is a technique that rewrites a quadratic expression \(ax^2 + bx + c\) in the form \(a(x + p)^2 + q\), where the quadratic part becomes a perfect square.

This form is useful for finding the vertex of a parabola, solving quadratic equations, and deriving the quadratic formula.

The Key Formula

\[x^2 + bx + \left(\frac{b}{2}\right)^2 = \left(x + \frac{b}{2}\right)^2\]

To complete the square, add \(\left(\frac{b}{2}\right)^2\) to make a perfect square trinomial.

Step-by-Step Method

Example 1: Simple Case (a = 1)

Complete the square for \(x^2 + 6x + 5\)

1 Identify the coefficient of x: Here, \(b = 6\)
2 Calculate half of b, then square it:

\[\left(\frac{6}{2}\right)^2 = 3^2 = 9\]

3 Add and subtract this value:

\[x^2 + 6x + 9 - 9 + 5\]

4 Group the perfect square trinomial:

\[(x^2 + 6x + 9) - 4\]

5 Write as a perfect square:

\[(x + 3)^2 - 4\]

Example 2: When a ≠ 1

Complete the square for \(2x^2 + 8x + 3\)

1 Factor out the coefficient of x²:

\[2(x^2 + 4x) + 3\]

2 Complete the square inside the bracket:

\[\left(\frac{4}{2}\right)^2 = 4\]

\[2(x^2 + 4x + 4 - 4) + 3\]

3 Distribute the factor:

\[2(x^2 + 4x + 4) - 8 + 3\]

4 Simplify:

\[2(x + 2)^2 - 5\]

Solving Quadratics by Completing the Square

Example 3: Solving an Equation

Solve \(x^2 - 4x - 5 = 0\) by completing the square

1 Move constant to the right:

\[x^2 - 4x = 5\]

2 Add \(\left(\frac{-4}{2}\right)^2 = 4\) to both sides:

\[x^2 - 4x + 4 = 5 + 4\]

\[(x - 2)^2 = 9\]

3 Take the square root of both sides:

\[x - 2 = \pm 3\]

4 Solve for x:

\[x = 2 + 3 = 5 \quad \text{or} \quad x = 2 - 3 = -1\]

Interactive Completing the Square Calculator

Step-by-Step Calculator

Enter a quadratic in the form \(ax^2 + bx + c\)

x² + x +

Solution

Enter coefficients and click the button to see the step-by-step solution.

Finding the Vertex

Vertex Form

When a quadratic is written as \(a(x - h)^2 + k\), the vertex of the parabola is at the point \((h, k)\).

If \(a > 0\), the vertex is the minimum point.

If \(a < 0\), the vertex is the maximum point.

Example 4: Finding Maximum/Minimum

Find the minimum value of \(f(x) = x^2 - 6x + 11\)

1 Complete the square:

\[x^2 - 6x + 11 = (x^2 - 6x + 9) - 9 + 11\]

\[= (x - 3)^2 + 2\]

2 Identify the vertex:

Vertex is at \((3, 2)\)

3 Conclusion:

Since \(a = 1 > 0\), the parabola opens upward.

The minimum value is 2, occurring when \(x = 3\).

Practice Problems

Question 1: Complete the square for \(x^2 + 10x + 21\)

Show Solution

\(\left(\frac{10}{2}\right)^2 = 25\)

\(x^2 + 10x + 25 - 25 + 21\)

\(= (x + 5)^2 - 4\)

Question 2: Solve \(x^2 + 8x + 12 = 0\) by completing the square

Show Solution

\(x^2 + 8x = -12\)

\(x^2 + 8x + 16 = -12 + 16\)

\((x + 4)^2 = 4\)

\(x + 4 = \pm 2\)

\(x = -2\) or \(x = -6\)

Question 3: Express \(3x^2 - 12x + 7\) in the form \(a(x + p)^2 + q\)

Show Solution

\(3(x^2 - 4x) + 7\)

\(3(x^2 - 4x + 4 - 4) + 7\)

\(3(x - 2)^2 - 12 + 7\)

\(= 3(x - 2)^2 - 5\)

Question 4: Find the maximum value of \(f(x) = -2x^2 + 8x + 3\)

Show Solution

\(-2(x^2 - 4x) + 3\)

\(-2(x^2 - 4x + 4 - 4) + 3\)

\(-2(x - 2)^2 + 8 + 3\)

\(= -2(x - 2)^2 + 11\)

Since \(a = -2 < 0\), the parabola opens downward.

Maximum value is 11 at \(x = 2\)

Quick Reference

\(x^2 + bx + c = \left(x + \frac{b}{2}\right)^2 - \frac{b^2}{4} + c\)

\(ax^2 + bx + c = a\left(x + \frac{b}{2a}\right)^2 - \frac{b^2}{4a} + c\)

Scroll to Top