A quadratic equation has the form ax2+bx+c=0ax^2 + bx + c = 0 with a0a \neq 0. There are three routes, and picking the right one saves time: factoring for incomplete equations, sum and product when the roots are integers, and the general formula for everything else.

Incomplete equations

  • b=0b = 0: x29=0x2=9x=±3x^2 - 9 = 0 \Rightarrow x^2 = 9 \Rightarrow x = \pm 3.
  • c=0c = 0: x24x=0x(x4)=0x=0x^2 - 4x = 0 \Rightarrow x\,(x - 4) = 0 \Rightarrow x = 0 or x=4x = 4.

Resist dividing x24x=0x^2 - 4x = 0 by xx: that erases the root x=0x = 0.

The quadratic formula

Δ=b24acx=b±Δ2a\Delta = b^2 - 4ac \qquad x = \frac{-b \pm \sqrt{\Delta}}{2a}

The discriminant Δ\Delta tells you how many real roots there are:

Sign of Δ\DeltaReal roots
Δ>0\Delta > 0two, distinct
Δ=0\Delta = 0one (double root)
Δ<0\Delta < 0none

Worked example: x25x+6=0x^2 - 5x + 6 = 0

  1. Coefficients: a=1a = 1, b=5b = -5, c=6c = 6.
  2. Δ=(5)2416=2524=1\Delta = (-5)^2 - 4 \cdot 1 \cdot 6 = 25 - 24 = 1.
  3. x=5±12x = \dfrac{5 \pm 1}{2}, so x1=3x_1 = 3 and x2=2x_2 = 2.

Worked example: 2x2+3x2=02x^2 + 3x - 2 = 0

  1. a=2a = 2, b=3b = 3, c=2c = -2.
  2. Δ=942(2)=9+16=25\Delta = 9 - 4 \cdot 2 \cdot (-2) = 9 + 16 = 25.
  3. x=3±54x = \dfrac{-3 \pm 5}{4}, so x1=12x_1 = \dfrac{1}{2} and x2=2x_2 = -2.
  4. Check: 2(12)2+3122=12+322=02 \cdot \left(\tfrac{1}{2}\right)^2 + 3 \cdot \tfrac{1}{2} - 2 = \tfrac{1}{2} + \tfrac{3}{2} - 2 = 0.

Worked example: x2+2x+5=0x^2 + 2x + 5 = 0

  1. Δ=420=16<0\Delta = 4 - 20 = -16 < 0.
  2. No real roots. Over the complex numbers, x=2±4i2=1±2ix = \dfrac{-2 \pm 4i}{2} = -1 \pm 2i.

Where the formula comes from

It comes from completing the square. Divide by aa and add (b2a)2\left(\tfrac{b}{2a}\right)^2 to both sides:

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

Take the square root of both sides and isolate xx to reach the formula. Knowing this helps you remember why the denominator is 2a2a and not just 22.

Sum and product of the roots

For roots x1x_1 and x2x_2 of ax2+bx+c=0ax^2 + bx + c = 0:

x1+x2=bax1x2=cax_1 + x_2 = -\frac{b}{a} \qquad x_1 \cdot x_2 = \frac{c}{a}

Worked example: x27x+12=0x^2 - 7x + 12 = 0

  1. Sum =7= 7 and product =12= 12.
  2. Pairs with product 12: (1,12)(1, 12), (2,6)(2, 6), (3,4)(3, 4). Only (3,4)(3, 4) adds to 7.
  3. Roots: 33 and 44.

Worked example: x2+x6=0x^2 + x - 6 = 0

  1. Sum =1= -1 and product =6= -6. A negative product means the roots have opposite signs.
  2. The pair (2,3)(2, -3) has sum 1-1 and product 6-6.
  3. Roots: 22 and 3-3.

Common mistakes

  1. Forgetting that bb carries its sign: in x25x+6x^2 - 5x + 6, b=5b = -5 and b=5-b = 5.
  2. Computing 52-5^2 as 25-25 when the correct value is (5)2=25(-5)^2 = 25.
  3. Dividing only b-b by 2a2a and forgetting the ±Δ\pm\sqrt{\Delta}.

Frequently asked questions

Why is it called Bhaskara's formula in Brazil?

It is a Brazilian naming habit. The formula was known before the Indian mathematician Bhaskara II; elsewhere it is simply called the quadratic formula.

What if the discriminant is negative?

There are no real roots. In the complex numbers the roots exist and are conjugates, such as −1 ± 2i for x² + 2x + 5 = 0.

Do I need the quadratic formula for incomplete equations?

No. If b = 0, isolate x². If c = 0, factor out x. It is faster and avoids sign errors.

When is sum and product worth using?

When a = 1 and the roots are small integers. If no obvious pair shows up within a few seconds, switch to the formula.