Completing the square
From Wikipedia, the free encyclopedia
Completing the square is a technique used in algebra to solve quadratic equations, in analytic geometry for determining the shapes of graphs, and in calculus for computing integrals, including, but hardly limited to, the integrals that define Laplace transforms. The essential objective is to reduce a quadratic polynomial in a variable in an equation or expression to a squared polynomial of linear order. This can reduce an equation or integral to one that is more easily solved or evaluated.
The purpose of completing the square is to fill in the following blank:
The expression that will replace the blank depends of course on the variable x. The "constant" does not; that is why it is a "constant".
This amounts to solving the following equation for k1 and k2:
where a, b, c are known. This is an identity in x, meaning that it should be true for all x.
Contents |
[edit] Overview
In elementary algebra, completing the square is a technique in which an expression involving a quadratic polynomial is transformed to one involving a squared linear polynomial and a constant. It converts a polynomial fragment of the form
to one of the form
The coefficients a, b, c, d and e above can be expressions in their own right, containing variables other than x.
Completing the square is commonly used to derive the quadratic formula, which solves a quadratic equation.
[edit] General formula
Assume a is positive. To achieve
we must set
This gives
[edit] Examples
[edit] Concrete example
With this we can find the values of x that produce zero, the roots of the polynomial.
We can also find the x value where the function defined by the polynomial,
achieves its most extreme values. The highest power, x2, has a positive coefficient, so large positive or negative values of x produce large values of y. Thus the interesting extreme is the minimum value for y. From the squared form,
we see that if
then y = 169⁄20 = 8.45; but if x is any other number, then y is 169⁄20 plus a nonzero square. Since squares of nonzero real numbers are positive, it must be that whenever x is any other number than −7⁄10, then y > 8.45. Thus the point (x, y) = (−7⁄10, 169⁄20) = (−0.7, 8.45) has the minimum possible value of y.
[edit] Calculus example
Consider the problem of finding this antiderivative:
- .
This can be done by completing the square of the denominator. The denominator is
- .
Completing the square by adding (10⁄2)2 = 25 to x2−10x gives a perfect square, x2 − 10x + 25 = (x−5)2. The denominator becomes
So our integral is
The point is that the revised denominator allows us to match a known result from a table of integrals,
[edit] Complex number examples
Consider the expression
where z and b are complex numbers, z* and b* are the complex conjugates of z and b, respectively, and c is a real number. Using the identity |u|2 = uu* we can rewrite this as
which is clearly a real quantity. This is because
As another example, the expression
where a, b, c, x, and y are real numbers, with a > 0 and b > 0, may be expressed in terms of the square of the absolute value of a complex number. Define
Then
so
[edit] A variation on the technique
As conventionally taught, completing the square consists of adding the third term, v 2 to
to get a square. There are also cases in which one can add the middle term, either 2uv or −2uv, to
to get a square.
[edit] Example: the sum of a positive number and its reciprocal
By writing
we show that the sum of a positive number x and its reciprocal is always greater than or equal to 2. The square of a real expression is always greater than or equal to zero, which gives the stated bound; and here we achieve 2 just when x is 1, causing the square to vanish.
[edit] Example: factoring a simple quartic polynomial
Consider the problem of factoring the polynomial
This is
so the middle term is 2(x2)(18) = 36x2. Thus we get
(the last line being added merely to follow the convention of decreasing degrees of terms).