Quadratic formula derivation

Derivation #

Let’s start with a quadratic equation written in a standard form \( ax^2 + bx + c = 0,\ a \ne 0 \) .

Step 1 #

Subtract \( c \) from both sides

\[\begin{aligned} ax^2 + bx + c - c & = -c \\ ax^2 + bx & = -c \tag{1} \end{aligned}\]

Step 2 #

Divide \( (1) \) through \( a \)

\[\begin{aligned} \frac{ax^2}{a} + \frac{bx}{a} & = \frac{-c}{a} \\ x^2 + \left(\frac{b}{a}\right)x & = -\left(\frac{c}{a}\right) \tag{2} \end{aligned}\]

Step 3 #

Complete the square by adding \( b^2 / 4a^2 \) on both sides of \( (2) \)

\[\begin{aligned} x^2 + \left(\frac{b}{a}\right)x + \frac{b^2}{4a^2} & = -\left(\frac{c}{a}\right) + \frac{b^2}{4a^2} \\ x^2 + \left(\frac{b}{a}\right)x + \left(\frac{b}{2a}\right)^2 & = \frac{b^2}{4a^2} - \frac{c}{a} \tag{3} \end{aligned}\]

Step 4 #

Write left-hand side of \( (3) \) as a complete square and simplify the right-hand side. In order to simplify right-hand side we multiply the fraction \( c / a \) by \( 4a \) which makes it \( 4ac / 4a^2 \)

Now the denominators are same so we can just add the numerators of the two fractions.

$$ \left( x + \frac{b}{2a} \right)^2 = \frac{b^2 - 4ac}{4a^2} \tag{4}$$

Step 5 #

Take square roots on both sides of \( (4) \)

\[\begin{aligned} \sqrt{\left( x + \frac{b}{2a} \right)^2 } & = \sqrt{\frac{b^2 - 4ac}{4a^2}} \\ x + \frac{b}{2a} & = \frac{\pm \sqrt{b^2 - 4ac}}{2a} \tag{5} \end{aligned}\]

Step 6 #

Subtract \( b / 2a \) from both sides of \( (5) \)

\[\begin{aligned} x + \frac{b}{2a} - \frac{b}{2a} & = \frac{\pm \sqrt{b^2 - 4ac}}{2a} - \frac{b}{2a} \\ x & = - \frac{b}{2a} \pm \frac{\sqrt{b^2 - 4ac}}{2a} \tag{6} \end{aligned}\]

Step 7 #

Simplify the right-hand side of \( (6) \) $$ x = \frac{-b \pm \sqrt{b^2 - 4ac}}{2a}$$

This is it! 🎉

Explaining step 3 #

We wish to wrap the left-hand side of \( (2) \) into a square indentity: $$ m^2 + 2mn + n^2 = (m+n)^2 $$

Now if we compare left-hand side of equation \( (2) \) to \( m^2 + 2mn + n^2 \) term by term, we observe: $$ m^2 = x^2 \implies m = x \tag{7a}$$ $$ 2mn = \left( \frac{b}{a} \right)x \tag{7b}$$ $$ n^2 =\ ??? $$

The term \( n^2 \) is missing and unknown.

But we can use \( (7a) \) and \( (7b) \) to determine the value of \( n \) which we can add on both sides of \( 2 \) to complete the square on the left-hand side.

From \( (7b) \) we get $$ n = \frac{b}{2a} $$ given the fact that \( m =x \) from \( (7a) \).

Consequently we add \( n^2 \) that is \( b^2 / 4 a^2 \) on both sides of \( (2) \).