TOPICS
Search

Quadratic Equation


A quadratic equation is a second-order polynomial equation in a single variable x

 ax^2+bx+c=0,
(1)

with a!=0. Because it is a second-order polynomial equation, the fundamental theorem of algebra guarantees that it has two solutions. These solutions may be both real, or both complex.

Among his many other talents, Major General Stanley in Gilbert and Sullivan's operetta the Pirates of Penzance impresses the pirates with his knowledge of quadratic equations in "The Major General's Song" as follows: "I am the very model of a modern Major-General, I've information vegetable, animal, and mineral, I know the kings of England, and I quote the fights historical, From Marathon to Waterloo, in order categorical; I'm very well acquainted too with matters mathematical, I understand equations, both the simple and quadratical, About binomial theorem I'm teeming with a lot o' news-- With many cheerful facts about the square of the hypotenuse."

The roots x can be found by completing the square,

 x^2+b/ax=-c/a
(2)
 (x+b/(2a))^2=-c/a+(b^2)/(4a^2)=(b^2-4ac)/(4a^2)
(3)
 x+b/(2a)=(+/-sqrt(b^2-4ac))/(2a).
(4)

Solving for x then gives

 x=(-b+/-sqrt(b^2-4ac))/(2a).
(5)

This equation is known as the quadratic formula.

The first known solution of a quadratic equation is the one given in the Berlin papyrus from the Middle Kingdom (ca. 2160-1700 BC) in Egypt. This problem reduces to solving

x^2+y^2=100
(6)
y=3/4x
(7)

(Smith 1953, p. 443). The Greeks were able to solve the quadratic equation by geometric methods, and Euclid's (ca. 325-270 BC) Data contains three problems involving quadratics. In his work Arithmetica, the Greek mathematician Diophantus (ca. 210-290) solved the quadratic equation, but giving only one root, even when both roots were positive (Smith 1951, p. 134).

A number of Indian mathematicians gave rules equivalent to the quadratic formula. It is possible that certain altar constructions dating from ca. 500 BC represent solutions of the equation, but even should this be the case, there is no record of the method of solution (Smith 1953, p. 444). The Hindu mathematician Āryabhata (475 or 476-550) gave a rule for the sum of a geometric series that shows knowledge of the quadratic equations with both solutions (Smith 1951, p. 159; Smith 1953, p. 444), while Brahmagupta (ca. 628) appears to have considered only one of them (Smith 1951, p. 159; Smith 1953, pp. 444-445). Similarly, Mahāvīra (ca. 850) had substantially the modern rule for the positive root of a quadratic. Srīdhara (ca. 1025) gave the positive root of the quadratic formula, as stated by Bhāskara (ca. 1150; Smith 1953, pp. 445-446). The Persian mathematicians al-Khwārizmī (ca. 825) and Omar Khayyám (ca. 1100) also gave rules for finding the positive root.

Viète was among the first to replace geometric methods of solution with analytic ones, although he apparently did not grasp the idea of a general quadratic equation (Smith 1953, pp. 449-450).

An alternate form of the quadratic equation is given by dividing (◇) through by x^2:

 a+b/x+c/(x^2)=0
(8)
 c(1/(x^2)+b/(cx))+a=0
(9)
 c(1/x+b/(2c))^2=c(b/(2c))^2-a=(b^2)/(4c)-(4ac)/(4c)=(b^2-4ac)/(4c).
(10)

Therefore,

 1/x+b/(2c)=+/-(sqrt(b^2-4ac))/(2c)
(11)
 1/x=(-b+/-sqrt(b^2-4ac))/(2c)
(12)
 x=(2c)/(-b+/-sqrt(b^2-4ac)).
(13)

This form is helpful if b^2>>4ac, where >> denotes much greater, in which case the usual form of the quadratic formula can give inaccurate numerical results for one of the roots. This can be avoided by defining

 q=-1/2[b+sgn(b)sqrt(b^2-4ac)]
(14)

so that b and the term under the square root sign always have the same sign. Now, if b>0, then

 q=-1/2(b+sqrt(b^2-4ac))
(15)
1/q=(-2)/(b+sqrt(b^2-4ac))(b-sqrt(b^2-4ac))/(b-sqrt(b^2-4ac))=(-2(b-sqrt(b^2-4ac)))/(b^2-(b^2-4ac))
(16)
=(-2(b-sqrt(b^2-4ac)))/(4ac)=(-b+sqrt(b^2-4ac))/(2ac),
(17)

so

x_1=q/a=(-b-sqrt(b^2-4ac))/(2a)
(18)
x_2=c/q=(-b+sqrt(b^2-4ac))/(2a).
(19)

Similarly, if b<0, then

 q=-1/2(b-sqrt(b^2-4ac))=1/2(-b+sqrt(b^2-4ac))
(20)
1/q=2/(-b+sqrt(b^2-4ac))(b+sqrt(b^2-4ac))/(b+sqrt(b^2-4ac))=(2(b+sqrt(b^2-4ac)))/(-b^2+(b^2-4ac))
(21)
=(b+sqrt(b^2-4ac))/(-2ac)=(-b-sqrt(b^2-4ac))/(2ac),
(22)

so

x_1=q/a=(-b+sqrt(b^2-4ac))/(2a)
(23)
x_2=c/q=(-b-sqrt(b^2-4ac))/(2a).
(24)

Therefore, the roots are always given by x_1=q/a and x_2=c/q.

Now consider the equation expressed in the form

 a_2x^2+a_1x+a_0=0,
(25)

with solutions z_1 and z_2. These solutions satisfy Vieta's formulas

z_1+z_2=-(a_1)/(a_2)
(26)
z_1z_2=(a_0)/(a_2).
(27)

The properties of the symmetric polynomials appearing in Vieta's formulas then give

z_1^2+z_2^2=(a_1^2-2a_0a_2)/(a_2^2)
(28)
z_1^3+z_2^3=-(a_1^3-3a_0a_1a_2)/(a_2^3)
(29)
z_1^4+z_2^4=(a_1^4-4a_0a_1^2a_2+2a_0^2a_2^2)/(a_2^4).
(30)
QuadraticEquationFactorable

Given a quadratic integer polynomial x^2+ax+b, consider the number of such polynomials that are factorable over the integers for a and b taken from some set of integers S subset Z. For example, for S={1,2,3,4}, there are four such polynomials,

x^2+2x+1=(x+1)^2
(31)
x^2+3x+2=(x+1)(x+2)
(32)
x^2+4x+3=(x+1)(x+3)
(33)
x^2+4x+4=(x+2)^2.
(34)

The following table summarizes the counts of such factorable polynomials for simple S subset Z and small n. Plots of the fractions of factorable polynomials for S={-n,...,n-1,n} (red), S={0,1,...,n} (blue), and S={1,2,...,n} (green) are also illustrated above. Amazingly, the sequence for [-n,n] has the recurrence equation

 a_n=a_(n-1)+2[d(n)+1]+chi_(n^2)(n),
(35)

where d(n)=sigma_0(n) is the number of divisors of n and chi_(n^2)(n) is the characteristic function of the square numbers.

S subset ZOEISfactorable over S for n=0, 1, ...
[-n,n]A0672741, 4, 10, 16, 25, 31, 41, 47, 57, ...
[0,n]A0916261, 2, 4, 6, 9, 11, 14, 16, 19, 22, ...
[1,n]A0916270, 0, 1, 2, 4, 5, 7, 8, 10, 12, 14, ...

See also

Biquadratic Equation, Carlyle Circle, Completing the Square, Conic Section, Cubic Equation, Fermat's Factorization Method, Polynomial Discriminant, Quadratic, Quadratic Formula, Quartic Equation, Quintic Equation, Sextic Equation Explore this topic in the MathWorld classroom

Explore with Wolfram|Alpha

References

Abramowitz, M. and Stegun, I. A. (Eds.). Handbook of Mathematical Functions with Formulas, Graphs, and Mathematical Tables, 9th printing. New York: Dover, p. 17, 1972.Beyer, W. H. CRC Standard Mathematical Tables, 28th ed. Boca Raton, FL: CRC Press, p. 9, 1987.Borwein, P. and Erdélyi, T. "Quadratic Equations." §1.1.E.1a in Polynomials and Polynomial Inequalities. New York:Springer-Verlag, p. 4, 1995.Courant, R. and Robbins, H. What Is Mathematics?: An Elementary Approach to Ideas and Methods, 2nd ed. Oxford, England: Oxford University Press, pp. 91-92, 1996.King, R. B. Beyond the Quartic Equation. Boston, MA: Birkhäuser, 1996.Press, W. H.; Flannery, B. P.; Teukolsky, S. A.; and Vetterling, W. T. "Quadratic and Cubic Equations." §5.6 in Numerical Recipes in FORTRAN: The Art of Scientific Computing, 2nd ed. Cambridge, England: Cambridge University Press, pp. 178-180, 1992.Sloane, N. J. A. Sequences A067274, A091626, and A091627 in "The On-Line Encyclopedia of Integer Sequences."Smith, D. History of Mathematics, Vol. 1. New York: Dover, 1951.Smith, D. History of Mathematics, Vol. 2. New York: Dover, 1953.Spanier, J. and Oldham, K. B. "The Quadratic Function ax^2+bx+c and Its Reciprocal." Ch. 16 in An Atlas of Functions. Washington, DC: Hemisphere, pp. 123-131, 1987.

Referenced on Wolfram|Alpha

Quadratic Equation

Cite this as:

Weisstein, Eric W. "Quadratic Equation." From MathWorld--A Wolfram Web Resource. https://mathworld.wolfram.com/QuadraticEquation.html

Subject classifications