Note Chapter 3 Mathematics (SM025)
Note Chapter 3 Mathematics (SM025)
Note Chapter 3 Mathematics (SM025)
SET INDUCTION
1. Solve x 2 4 x 5 0
Solution : x 2 4 x 5 0
(x + 1)(x – 5) = 0
So (x + 1) = 0 or (x – 5) = 0
x 1 or x 5
2. Solve x 3 8 0
Solution : x 3 8 0
x3 8 , So x 3 8 2
3. Solve x3 e x 0
Solution :
We cannot find the exact root of the equation above.
So, in this subtopic we are going discuss numerical methods to find the approximate
numerical solutions of such equations.
CONTENT
1
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
Introduction
Many equations cannot be solved exactly, but various methods of finding approximate
numerical solutions exist.
Initial Values:
Graphical Method:
Either
Or
2
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
Example 1
Solution :
The root is x 0
Example 2
3
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
Find the approximate value of the equation ln x + x 4 = 0 by using the graphical method.
Solution:
the intersection is at x 2.
Example 3
Draw the graphs of y1 x and y2 e x on the same coordinate’s axes. Estimate the root
of the equation of x e x 0 .
Solution:
4
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
Algebraic Method
Find two values a and b such that f (a) and f (b) have different signs.
At least one root must lie between a and b if f (x) is continuous.
If more than one root is suspected between a and b, sketch a graph of y f (x) .
Example 1
Solution:
f ( x) ln x x 2
f (1) ln 1 1 2 1 0 (ve)
f (2) ln 2 2 2 0.69 0 (ve)
The root is between x = 1 and x = 2, so we can choosing x₀ = 1.5 for initial value.
Example 2
The root of the equation 2 x e x lies between x = a and x = b. Find the values of a and b.
Solution:
f x 2 x e x
f 0 2 0 e0 1 0
5
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
Example 3
Show that the root of the equation 3x x3 lies in the interval 2.4 2.5 .
Solution:
When x = 2.4
f (2.4) (2.4)3 32.4
0.1426 0 (ve)
When x = 2.5
f (2.5) (2.5)3 32.5
0.0356 0 (ve)
The sign is difference, therefore the root lies in the interval 2.4 2.5 .
Exercises:
1. Show that the equation sin x x 0.5 0 has a root lying in the interval 2,1 .
3. Using the graphical method, show that the equation e2 x 4 x 5 0 has only one
real root. Find the unit interval where the root lies.
Answer : 0,1
6
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
OBJECTIVE : The objective of this lesson is to enable students to find the root by
the Newton-Raphson method using the formula
f ( xn )
xn+1 = xn - , n = 1,2,3, …
f ' ( xn )
CONTENT
Newton-Raphson Method
f ( x1 )
x2 x1 .
f ( x1 )
f ( xn )
xn 1 xn
f ( xn )
Example 1
Solution
Let f x x ex
So f ' x 1 ex
x0 0.5
7
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
f ( xn )
xn1 xn
f ' ( xn )
xn e xn
xn1 xn
1 e xn
x1 0.5
0.5 e 0.56631
0.5
1 e 0.5
x2 0.56631
0.56631 e 0.56714
0.56631
1 e
0.56631
x3 0.56714
0.56714 e 0.56714
0.56714
1 e
0.56714
x4 0.56714
Example 2
Show that the equations 2 sin x x 0 has a root between x 1 (radian) and x 2 (radian).
Find the root of the equation by using Newton Raphson method. Giving your answer
correct to two decimal places.
Solution
f x 2sin x x f ’ x 2cos x –1
x0 = first approximation = 2
8
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
f ( xn )
xn1 xn
f ' ( xn )
2 sin xn xn
xn1 xn
2 cos xn 1
2 sin 2 2
x1 2 1.90
2 cos 2 1
x4 1.895
Example 3
Show that the equation x3 x 6 0 has a root between 1 and 2. Using the Newton-
Raphson method with the starting point 1.6 to determine an approximation to this root ,
giving your answer to three significant figures.
Solution
Let f x x3 x – 6
f (1) 13 1 6 4 0 (ve)
different signs
f (2) 2 2 6 4 0 (ve)
3
9
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
Let f x x3 x – 6
So f ' x 3x 2 1
x0 1.6
xn3 xn 6
xn1 xn
3xn2 1
x1 1.6
1.6 1.6 6
3
1.6350
31.6 1
2
x2 1.6350
1.6350 1.6350 6
3
1.6344
31.6350 1
2
x3 1.6344
Example 4
3
Use the Newton-Raphson Method to estimate 21 correct to four decimal places.
Solution :
10
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
Example 5
Solution :
Newton-Raphson method:
1
ex
2 x
1
2 x x
e
2 x ex
ex x 2 0
f ( x) e x x 2
f ' ( x) e x 1
e xn x 2
xn 1 xn
e xn 1
e0.4 2 0.4
x1 0.4 0.4434
e 1
0.4
11
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
e0.4434 2 0.4434
x2 0.4434 0.4429
e0.4434 1
x4 0.4429
x5 0.4429
Exercises:
Answer : 0.246
Answer: 1.91
3. Show that there is a real root for cos x x between x 0.5 radian and x 1 radian.
Hence, find the real root correct to four decimal places using Newton-Raphson
method.
Answer: 0.739
12
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
OBJECTIVES : The objectives of this lesson are to enable students to use the
b
trapezium rule to approximate f ( x)dx
a
for n 4.
CONTENT
Introduction
e
x2
What happens when a mathematical function cannot be integrated ?. Example dx ,
area between y = f (x) , the x-axis and the lines x = a and x = b . Therefore , even if
b b
a
f ( x)dx cannot be found, approximate value for f ( x)dx
a
can be found by evaluating the
appropriate area using another method. The two common methods are the trapezium rule
and Simpson’s rule. However, here we will discuss the trapezium rule as requested by our
syllabus.
13
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
Let y0 , y1 , y2 ,….,yn1,yn be the values of the function f (x) . These correspond to the
n 1 ordinates x0 , x1 , x2 ,...., xn respectively. Using
1
Area of trapezium = ( width sum of parallel sides )
2
y0 y1 y y2 y y3 y yn
h h 1 h 2 ......... h n1
2 2 2 2
1 1
h y0 y1 y2 .... yn1 yn
2 2
y0 yn 2 y1 y2 ....... yn1
h
2
ba
Where h , n number of strips (sub-interval) and y r f ( x r )
n
14
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
Example 1
5
Evaluate ln x dx using 4 strips by the trapezium rule.
1
Notation
Working must have 4 or more decimal places.
Solution
ba 4
So h= = =1
n 4
1, 2, 3, 4, 5
5
h
ln x dx
1
2
( y0 + y4) + 2 ( y1 +… + y3 )
1
= 1.6094 + 2 (3.178)
2
= 3.9828
15
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
*** Note : We can calculate the values of y 0 , y1 , y 2 , y3 and y 4 from the table above
using scientific calculator.
Example :
Key in :
MODE 1 (COMP)
ALPHA Y = ln X
CALC ( X = ?)
1=0
CALC ( X = ?)
2 = 0.69314…
CALC ( X = ?)
3 = 1.09861….
CONTINUE THE PROCESS.
Example 2
0.8
e
x2
Use the trapezium rule, with five ordinates, to evaluate dx .
0
Solution
ba 0.8
So, h = = = 0.2
n 4
16
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
0.8
h
e dx ( y0 + y4 ) + 2 ( y1 +… +y 3 )
x2
0
2
0 .2
= 2.8965 + 2 ( 3.6476 )
2
= 1.0192
Solution:
ba 2
The integration interval ( b - a ) = 5 – 3 = 2 units. So, h = 0.5 . Value of xi at
n 4
which yi is calculated are x0 = 3, x1 = 3.5, x2 = 4, x3 = 4.5, x4 = 5.
y 1 x
xi
First and last ordinates Remaining ordinates
x0 = 3 y0 1 x0 1 3 2
x1 = 3.5 y1 1 x1 1 3.5 2.12132
17
MR. SANJAY A/L PRADEEP KUMAR Mathematics QS 025
Topic 3: Numerical Method
x2 = 4 y2 1 x0 1 4 2.23607
x3 = 4.5 y3 1 x3 1 4.5 2.34521
x4 = 5 y4 1 x4 1 5 2.44949
Total 4.44949 6.70260
Trapezoidal Rule:
5 h
1 x dx ( y0 + y4) + 2 ( y1 + y2+y3 )
3 2
0 .5
= 4.44949 + 2 ( 6.70260 )
2
= 4.4637 (4 decimal places)
Exercises:
0 .4
(a) 0
( 1 - x 2 ) dx with 5 ordinates
Answer: 0.389
0 .6
xe
x
(b) dx with 7 ordinates
0
Answer: 0.273
2. correct your answer to three decimal places.
5
(c) x ln x
3
dx with 4 sub-intervals
Answer: 11.1742
π
3
(d) tan x
0
dx with 4 strips
Answer: 0.7098
π
2
(e)
0
sinh x dx with 4 strips
Answer: 1.3893
18