Solve quadratic equations by factorising, completing the square, the quadratic formula and technology, solve quadratic inequalities from a sketch, and use the discriminant to decide how many roots an equation has.
IB Mathematics: Analysis and Approaches
Part of 2 Functions
SL and HL
Key terms introduced here
Each is in the Maths AA glossary, with every other term in the subject.
A root that occurs twice, as in a(x−h)2=0, which happens exactly when Δ=0. The graph touches the x-axis at x=h without crossing it.
Solve equations that can be written in quadratic form using a substitution.
A quadratic equation asks where a quadratic function takes a particular value, most often zero. Geometrically, its real solutions are the x-coordinates of the points where a parabola meets the x-axis, so an equation can have two solutions, one, or none. Quadratic equations appear wherever quadratic models do: the time at which a ball lands, the width of a path that gives a particular area, or the speed at which a car can stop within a given distance.
There are four methods of solving a quadratic equation, and a single number, the discriminant, decides in advance how many real solutions to expect. The same ideas, applied to the graph, solve quadratic inequalities, and a substitution turns many equations that do not look quadratic into ones that are.
Quadratic equations and their roots
The roots of the quadratic equation ax2+bx+c=0 are the zeros of the function f(x)=ax2+bx+c: the x-coordinates of the points where its graph crosses or touches the x-axis. A parabola meets the x-axis at most twice, so a quadratic equation has at most two real roots. The language distinguishes the two: an equation has roots, and a function has zeros.
Before any method is used, the equation is rearranged so that one side is zero. An equation such as x2=5x−6 becomes x2−5x+6=0. Every method in the table relies on this form.
Method
Best used when
Gives
Factorising
The quadratic factorises with whole numbers or simple fractions
Exact roots
Completing the square
b is even and a=1, or the vertex form is already known
Exact roots, including surds
Quadratic formula
Any quadratic, especially one that does not factorise
Exact roots, including surds
GDC
A calculator is allowed and decimal answers are acceptable
Decimal approximations
Solving by factorising
The null factor law
Factorising works because of a basic property of numbers: if a product of two numbers is zero, at least one of them is zero.
AB=0⇒A=0 or B=0
So once ax2+bx+c is written as a product of two linear factors, each factor is set equal to zero. Only zero has this property: if AB=6, nothing can be said about A or B on their own.
Factorising techniques
Four patterns cover most quadratics.
Common factor (when c=0): 3x2−12x=3x(x−4).
Difference of two squares (when b=0 and c<0): 4x2−25=(2x−5)(2x+5).
Trinomial with a=1: find two numbers with product c and sum b. For x2−x−12
Trinomial with a=1: find two numbers with product ac and sum b, use them to split the middle term, then factorise in pairs.
Rearranging first
Equations often arrive in a form that hides the quadratic. Expand brackets, clear fractions and collect every term on one side before factorising.
Solving by completing the square
When an equation is in the form (x−h)2=k with k≥0, taking the square root of both sides gives two solutions, because both k and −k square to k.
(x−h)2=k⇒x−h=±k⇒x=h±k
Completing the square, as in 2.6, puts any quadratic equation into this form. The method gives exact answers even when the roots are irrational, which factorising cannot.
The quadratic formula
Deriving the formula
Completing the square on the general equation ax2+bx+c=0 produces a formula for its roots. Dividing by a (allowed, since a=0) and completing the square:
In the fourth line, 4a2=2∣a∣, but the ± sign covers both signs of a, so 2a can be written. The derivation only works when b2−4ac≥0, since otherwise there is no real square root.
The quadratic formula always works, so it is the method to use when a quadratic does not factorise easily. The two roots are symmetric about x=−2ab, the axis of symmetry of the parabola, at a distance of 2ab2−4ac on each side.
Using the formula
Solving with technology
With a graphic display calculator (GDC), a quadratic equation can be solved in two ways: with the polynomial equation solver, by entering a, b and c, or by graphing y=ax2+bx+c and finding its zeros. Both give decimal approximations. The graph has the advantage of showing how many roots there are and roughly where, which helps to spot an input error.
Quadratic inequalities
Solving from a sketch
A quadratic inequality asks for the values of x for which the graph of y=ax2+bx+c is on one side of the x-axis. Solving the corresponding equation gives the roots, where the sign can change. A sketch then shows which values of x satisfy the inequality.
Rearrange so that one side is 0.
Solve the equation ax2+bx+c=0 to find the roots.
Sketch the parabola, using the sign of a for its shape and the roots as its x-intercepts.
Read off the values of x for which the graph is above the axis (for >0) or below it (for <0).
y = x² − 2x − 3
The parabola is below the x-axis between its roots, where x² − 2x − 3 < 0, and above the axis outside them, where x² − 2x − 3 > 0.
For x2−2x−3=(x+1)(x−3), the roots are −1 and 3. The graph opens upwards, so it is below the axis between the roots and above the axis outside them.
x2−2x−3<0 for −1<x<3.
x2−2x−3>0 for x<−1 or x>3.
For ≤ and ≥, the roots themselves are included, because the expression equals zero there. On a number line, an included endpoint is shown by a filled dot and an excluded one by an open circle.
A strict inequality excludes the roots (open circles); a non-strict one includes them (filled dots). For a > 0, "greater than zero" gives two outer pieces and "less than zero" one middle piece.
Interval notation
A solution can also be written as an interval. A square bracket facing the number includes the endpoint, and a bracket facing away excludes it; the symbol ∪ (union) joins two separate pieces.
Inequality
Interval notation
−1≤x≤3
[−1,3]
−1<x<3
]−1,3[
−1≤x<3
[−1,3[
x<−1 or x>3
]−∞,−1[∪]3,∞[
x≥3
[3,∞[
Many books write open intervals with round brackets, (−1,3) instead of ]−1,3[. Both mean the same set. Infinity is never included, because it is not a number.
Worked inequalities
When the roots are irrational, the method is the same; only the roots come from the quadratic formula or a GDC. If the quadratic has no real roots, the graph lies entirely on one side of the axis. For example, x2+2x+5=(x+1)2+4 is always positive, so x2+2x+5>0 is true for all real x and x2+2x+5<0 has no solution.
A quadratic inequality in context
The stopping distance of a car is the distance it travels while the driver reacts plus the distance it travels while braking. The thinking distance is proportional to the speed and the braking distance roughly to the square of the speed, so the total is modelled well by a quadratic. With speed v in miles per hour and stopping distance d in metres, the model d=0.3v+0.015v2 matches published typical stopping distances closely.
Speed v (mph)
20
30
40
50
60
70
Typical stopping distance (m)
12
23
36
53
73
96
Model 0.3v+0.015v2 (m)
12
22.5
36
52.5
Typical stopping distances: The Highway Code, UK Department for Transport (2022 edition).
The discriminant and the nature of the roots
Three cases
The expression under the square root in the quadratic formula decides how many real roots there are. If it is positive, ±x gives two different values; if it is zero, the ± term vanishes and both roots are equal; if it is negative, there is no real square root at all.
The discriminant links the algebra to the graph: it shows whether the parabola crosses the x-axis twice, touches it once, or misses it. When Δ=0, the quadratic is a perfect square, a(x−h)2, and the root x=h is a repeated root: the vertex lies on the x-axis.
y = x² − 4x + 3, Δ = 4
y = x² − 4x + 4, Δ = 0
y = x² − 4x + 5, Δ = −4
Changing only c moves the parabola up. With Δ > 0 it crosses the x-axis twice, with Δ = 0 it touches the axis at its vertex, and with Δ < 0 it lies wholly above the axis.
When a, b and c are integers and Δ is a perfect square (0, 1, 4, 9, …), the roots are rational and the quadratic factorises over the integers or simple fractions. When Δ is positive but not a perfect square, the roots are irrational surds. This gives a quick test of whether factorising is worth trying.
Problems with a parameter
When a coefficient of a quadratic contains an unknown constant, often k or m, the discriminant gives an equation or an inequality in that constant. An equation in k gives particular values; an inequality in k is a quadratic inequality, solved with a sketch exactly as in the work on inequalities.
Sometimes the discriminant is itself a perfect square in the parameter. Then its sign can be decided for every value of the parameter at once, which proves a result about a whole family of equations.
Quadratics that are always positive or always negative
A quadratic ax2+bx+c is positive for every real x when its graph lies entirely above the x-axis. That needs the parabola to open upwards and to have no x-intercepts.
ax2+bx+c>0 for all x⇔a>0 and Δ<0
ax2+bx+c<0 for all x⇔a<0 and Δ<0
Intersections of a line and a curve
To find where a line meets a parabola, set the two expressions for y equal. The result is a quadratic equation in x, and its discriminant shows how many intersection points there are.
Δ>0: the line crosses the curve at two points.
Δ=0: the line touches the curve at one point; it is a tangent.
Δ<0: the line misses the curve.
The tangent condition Δ=0 is an algebraic way of finding a tangent without calculus. Calculus gives a second method, using the gradient of the curve, in 5.4; both methods give the same line.
Equations in quadratic form
Spotting a hidden quadratic
Some equations of higher degree, or with exponentials, roots or trigonometric functions, have the structure a(…)2+b(…)+c=0, where the same expression appears squared and on its own. A substitution u=(…) turns such an equation in quadratic form into an ordinary quadratic in u.
Equation
Substitution
Quadratic in u
x4−5x2+4=0
u=x2
u2−5u+4=0
e2x−5ex+6=0
u=ex
x−5x+6=0
u=x
2sin2x−sinx−1=0
u=sinx
2u2−u−1=0
The method has three steps: substitute, solve the quadratic for u, then convert back to x, rejecting any value of u that the substitution cannot take. A value such as ex=−2 or x2=−1 has no real solution.
Exponential and trigonometric equations
Exponential equations use the law a2x=(ax)2 from 1.7, and trigonometric ones use sin2x=(sinx)2. Solving the resulting equations in x uses logarithms (1.7) and the unit circle (3.8).
Exam-style questions on quadratic equations and inequalities
The second question combines a modelling equation, a quadratic inequality and a GDC.
Self-check
To do:
I can solve a quadratic equation by factorising, including when the coefficient of x2 is not 1.
To do:
I can solve a quadratic equation by completing the square and give exact surd answers.
To do:
I can derive the quadratic formula and use it accurately, and solve quadratics with a GDC.
To do:
I can solve a quadratic inequality from a sketch and write the answer in inequality and interval notation.
To do:
I can use the discriminant to decide whether a quadratic equation has two distinct, two equal or no real roots.
To do:
I can find the values of a parameter for which a line is a tangent to a curve or a quadratic is always positive.
To do:
I can solve equations in quadratic form, such as x4−5x2+4=0 and e2x−5ex+6=0, rejecting impossible values.
. The distance between
P
and
Q
is
25
.
(a)
Find the possible values of k.
[4]4 marks
Markscheme (a)
PQ2=(3−k)2+(2k−2)2+(1−(−1))2(M1)
Note: Accept the square root of this expression.
(3−k)2+(2k−2)2+4=20(M1)
5k2−14k−3=0A1
(5k+1)(k−3)=0
k=3 or k=−51A1
Note: Award M1M1A1A0 if only one value of k is given.
(b)
For the integer value of k, find the coordinates of the midpoint of [PQ].
[2]2 marks
Markscheme (b)
P(3,2,−1), Q(3,6,1)
Question 2 · AA-000807 marks
In triangle ABC, AB=x cm, AC=(x+4) cm and BA^C=150°. The area of the triangle is 15 cm2.
So x≈3.73 or x≈0.268. Simplifying 12=23 allows the 2 to cancel throughout.
and
x=−3
. The parabola opens upwards, so it is on or above the axis outside the roots, including them.
x≤−3 or x≥21,]−∞,−3]∪[21,∞[
(b) Here a=−1. One method is to multiply by −1, which reverses the inequality sign.
x2−x−6<0⇒(x−3)(x+2)<0
The parabola y=x2−x−6 opens upwards and is below the axis between its roots.
−2<x<3,]−2,3[
(Sketching y=6+x−x2 directly gives the same result: it opens downwards and is above the axis between −2 and 3.)
(c) Rearrange: x2−9≤0, so (x−3)(x+3)≤0. The graph is on or below the axis between the roots.
−3≤x≤3,[−3,3]
72
94.5
.
Find the roots with the quadratic formula, a=0.015, b=0.3, c=−50.
v=0.03−0.3±0.09+3=0.03−0.3±3.09
So v=48.594… or v=−68.594….
The parabola opens upwards, so the inequality holds between the roots: −68.6≤v≤48.6. Speed cannot be negative, so the car can stop within 50 m for 0≤v≤48.6 mph.
, it has two equal real roots (a
repeated root
).
If Δ<0, it has no real roots.
. There are no real roots.
(b) Δ=(−12)2−4(9)(4)=144−144=0. There are two equal real roots (a repeated root). In fact 9x2−12x+4=(3x−2)2, so the root is x=32.
(c) Δ=12−4(1)(−1)=5>0. There are two distinct real roots. Since 5 is not a perfect square, they are irrational: x=2−1±5.
Check: k=6 gives x2+6x+9=(x+3)2, and k=−6 gives (x−3)2.
(b) Two distinct real roots means Δ>0, with a=k, b=4, c=k−3.
16−4k(k−3)16−4k2+12kk2−3k−4(k−4)(k+1)>0>0<0(dividing by −4 reverses the sign)<0
The parabola y=(k−4)(k+1) is below the axis between its roots, so −1<k<4.
The equation is only quadratic if k=0; when k=0 it becomes 4x−3=0, which has just one root. So the answer is −1<k<4, k=0.
A square is never negative, so Δ≥0 for every real k. The equation therefore has real roots for all values of k.
The roots are equal when Δ=0, that is, when (k−2)2=0, so k=2. The equation is then x2+2x+1=(x+1)2=0, with repeated root x=−1.
In fact the equation factorises as (x+1)(x+k−1)=0 for every k, with roots −1 and 1−k, which confirms the result.
-axis. The expression is positive for all
x
.
Method 2: complete the square. x2−6x+11=(x−3)2+2. Since (x−3)2≥0, the expression is at least 2 for every x, so it is always positive.
(b) Since a=1>0, the condition is Δ<0.
(m−2)2−16<0⇒(m−2)2<16⇒−4<m−2<4
So −2<m<6.
at two distinct points.
.
For a tangent, this equation has equal roots: Δ=0.
22−4(1)(5−c)=0⇒4−20+4c=0⇒c=4
Then x2+2x+1=0, so (x+1)2=0 and x=−1. On the line, y=2(−1)+4=2. The point of contact is (−1,2).
y = x² + 4x + 5
y = 2x + 4
The line touches the parabola at exactly one point, (−1, 2), because the equation for the intersections has a repeated root.
(b) At an intersection, x2+3=mx−1, so x2−mx+4=0.
Two distinct points means Δ>0.
m2−16>0⇒(m−4)(m+4)>0
The parabola y=m2−16 is above the axis outside its roots, so m<−4 or m>4.
u2−5u+6=0
u2−5u+6=0
Convert back: x2=1 gives x=±1, and x2=4 gives x=±2. There are four solutions: x=−2,−1,1,2.
(b) Let u=x, so x=u2 and u≥0.
u2−5u+6=0⇒(u−2)(u−3)=0⇒u=2 or u=3
Both values are non-negative. Convert back: x=2 gives x=4, and x=3 gives x=9.
Check: 4−5(2)+6=0 and 9−5(3)+6=0.
.
So ex=2 or ex=3, giving x=ln2 or x=ln3.
(b) Let u=2x, so 22x=u2.
u2−3u−4=0⇒(u−4)(u+1)=0⇒u=4 or u=−1
2x=4 gives x=2. 2x=−1 has no solution, because 2x>0 for every real x. So x=2 only.
(c) Let u=sinx.
2u2−u−1=0⇒(2u+1)(u−1)=0⇒u=−21 or u=1
sinx=1 gives x=2π. sinx=−21 gives x=67π or x=611π in the interval. The solutions are x=2π,67π,611π.
. [1]
(M1). The graph opens upwards and does not meet the
x
-axis, so
f(x)>0
for all
x
(R1). Completing the square,
f(x)=(x−2)2+3≥3
, is an equally valid method.
(b) Set the expressions equal and rearrange (A1).
x2−4x+7=mx+3⇒x2−4x−mx+4=0⇒x2−(4+m)x+4=0
(c) A tangent needs equal roots, so Δ=0 (M1).
(4+m)2−4(1)(4)=0⇒(4+m)2=16⇒4+m=±4
So m=0 or m=−8 (A1 A1, with A1 for the correct equation).
(d) For m=0: x2−4x+4=0, so (x−2)2=0, x=2 and y=3. Point (2,3).
For m=−8: x2+4x+4=0, so (x+2)2=0, x=−2 and y=−8(−2)+3=19. Point (−2,19).
Check: f(2)=4−8+7=3 and f(−2)=4+8+7=19.
(e) Two distinct points need Δ>0: (4+m)2>16 (M1). From the sketch of y=(4+m)2−16, which is zero at m=0 and m=−8 and opens upwards, m<−8 or m>0 (A1).
(b) Solve 4x2+40x+96=180, that is, 4x2+40x−84=0, or x2+10x−21=0 (M1).
The GDC gives x=1.7823… or x=−11.782… (A1). A width cannot be negative, so the path is 1.78 m wide (A1).
(c) Solve 4x2+40x+96≤200, that is, x2+10x−26≤0 (M1).
The roots are x=−5±51, that is, x=2.1414… or x=−12.141… (A1). The parabola opens upwards, so the inequality holds between the roots. With x>0, the greatest possible width is 2.14 m (A1).