In elementary algebra, completing the square is a technique for converting a quadratic polynomial of the form
, this expression is a quadratic polynomial with no linear term.
represents the area of a pair of congruent rectangles with sides
This crucial step completes a larger square of side length
Completing the square is the oldest method of solving general quadratic equations, used in Old Babylonian clay tablets dating from 1800–1600 BCE, and is still taught in elementary algebra courses today.
It is also used for graphing quadratic functions, deriving the quadratic formula, and more generally in computations involving quadratic polynomials, for example in calculus evaluating Gaussian integrals with a linear term in the exponent,[2] and finding Laplace transforms.
[5] Muhammad ibn Musa Al-Khwarizmi, a famous polymath who wrote the early algebraic treatise Al-Jabr, used the technique of completing the square to solve quadratic equations.
[6] The formula in elementary algebra for computing the square of a binomial is:
In any perfect square, the coefficient of x is twice the number p, and the constant term is equal to p2.
However, it is possible to write the original quadratic as the sum of this square and a constant:
This square differs from the original quadratic only in the value of the constant term.
it is possible to factor out the coefficient a, and then complete the square for the resulting monic polynomial.
This process of factoring out the coefficient a can further be simplified by only factorising it out of the first 2 terms.
The result of completing the square may be written as a formula.
In analytic geometry, the graph of any quadratic function is a parabola in the xy-plane.
the numbers h and k may be interpreted as the Cartesian coordinates of the vertex (or stationary point) of the parabola.
That is, h is the x-coordinate of the axis of symmetry (i.e. the axis of symmetry has equation x = h), and k is the minimum value (or maximum value, if a < 0) of the quadratic function.
One way to see this is to note that the graph of the function f(x) = x2 is a parabola whose vertex is at the origin (0, 0).
Therefore, the graph of the function f(x − h) = (x − h)2 is a parabola shifted to the right by h whose vertex is at (h, 0), as shown in the top figure.
In contrast, the graph of the function f(x) + k = x2 + k is a parabola shifted upward by k whose vertex is at (0, k), as shown in the center figure.
For an equation involving a non-monic quadratic, the first step to solving them is to divide through by the coefficient of x2.
shows that some idempotent 2×2 matrices are parametrized by a circle in the (a,b)-plane: The matrix
Since x2 represents the area of a square with side of length x, and bx represents the area of a rectangle with sides b and x, the process of completing the square can be viewed as visual manipulation of rectangles.
Simple attempts to combine the x2 and the bx rectangles into a larger square result in a missing corner.
The term (b/2)2 added to each side of the above equation is precisely the area of the missing corner, whence derives the terminology "completing the square".
[8] As conventionally taught, completing the square consists of adding the third term, v2 to
we show that the sum of a positive number x and its reciprocal is always greater than or equal to 2.
(the last line being added merely to follow the convention of decreasing degrees of terms).
without term of degree two, which is called the depressed form of the original polynomial.
More generally, a similar transformation can be used for removing terms of degree