One of the most important formulas encountered by students of second level maths is the quadratic formula, or what some students call the “minus B” formula.
The video below gives a very nice intuitive description of how this can be derived using the method known as “completing the Square”.
Completing the Square to write ax2+ bx + c = 0
in the form a(x-h)2 + k = 0 (Vertex Form)
In the more general case where the coefficient of the squared term is not 1, we divide across by this coefficient first.
The general form of a quadratic function is: f(x) = ax2 +bx +c. The formula to find the vertex of a quadratic function in general form is: (-b/2a, f(-b/2a)).
This can be derived from the formula used to find the roots of the equation.
The roots are the values of x where the graph cuts the x-axis. The x-axis is described by y=0. In other words the above formula gives the values of x when f(x) = ax2 +bx +c equals 0.
More generally the above formula gives the values of x when the graph cuts any horizontal line described by a constant value of y for which the graph exists. For all but one point on the graph their will be two solutions because a horizontal line will cut the parabola in two places except at the vertex. There only one point will be touched by a horizontal line. So here the discriminant (the bit under the root sign) will be zero as the + or – must give the same answer. The discriminant will be zero. The y ordinate for any point on the graph is a function of the x ordinate. Our coordinates can be written in the form (x, f(x)).
So at the apex: x = -b/2a and y = f(x)
f(x) = ax2 + bx + c
= a(-b/2a)2 + b(-b/2a) + c
= ab2/4a2 – b2/2a + c
= (ab2– 2ab2 + 4a2 c ) / 4a2
= (4a2c – ab2) / 4a2
= (4ac – b2) / 4a
Giving the vertex as (-b/2a , (4ac – b2) / 4a)
You could start with the general vertex form f(x) = a(x-h)2 + k and expand it out. Then equate the resulting coefficients with those of f(x) = ax2 + bx + c
a(x-h)2 + k = a(x2 + h2 -2hx) + k
= ax2 + ah2 -2ahx + k = ax2 + bx + c
a = a
b = -2ah => h = -b/2a
c = ah2 + k => k = c – ah2 = c – a (-b/2a)2 = c – a (b2/4a2) => k = (4ac – b2) / 4a
Similarly for cubic equations: