Calculus Slides
Calculus Slides
Calculus
1
Function
• A function must produce one and only one output value for
every possible input value
• Please refer to the lecture video Introduction for details.
𝑥 𝑓 𝑓(𝑥)
Domain Range
2
Polynomial Function
A polynomial function 𝑓 is given by
𝑓 𝑥 = 𝑎𝑛 𝑥 𝑛 + 𝑎𝑛−1 𝑥 𝑛−1 + ⋯ + 𝑎1 𝑥 + 𝑎0
where
𝑛 is a non-negative integer, called the degree of the polynomial;
𝑎𝑛 , 𝑎𝑛−1 , … , 𝑎1 are real numbers, called the coefficients of the
polynomial;
𝑎0 is usually called the constant term of the polynomial.
3
Polynomial Function: Example
Malaria is an infectious disease transmitted by mosquitoes. The
daily survival probability of adult mosquitoes 𝑝 can be related to
the temperature 𝑇 by the following quadratic function:
(a) When is 𝑝 𝑇 ≥ 0 ?
(b) When is malaria transmission most efficient ?
4
Exponential Function
An exponential function 𝑃 is a function in which the
independent variable 𝑥 appears in the exponent, e.g., 𝑃 𝑥 = 2𝑥
Or, in a more general form,
𝑃 𝑥 = 𝑃0 𝑎𝑘𝑥
where 𝑎 is a positive real number, 𝑃0 and 𝑘 are real numbers.
5
Natural Exponential Function
From the general form of exponential function, we can see that
the number 𝑎 can be chosen without any loss of generality.
It is usually convenient to choose 𝑎 = 𝑒 ≈ 2.7182818284590,
where 𝑒 is the Euler number. Taking exponents of 𝑒 gives the
natural exponential function, i.e.,
𝑃 𝑥 = 𝑃0 𝑒 𝑘𝑥
6
Logarithmic Function
An logarithmic function 𝑓 is an inverse function of exponential
function, i.e.,
𝑓 𝑥 = log 𝑎 𝑥
where 𝑎 is a positive real number, called the base.
7
Natural Logarithmic Function
A natural logarithmic function 𝑓 is an inverse function of natural
exponential function, i.e.,
𝑓 𝑥 = log 𝑒 𝑥 = ln 𝑥
with 𝑒 as the base.
Examples:
1. Simplify ln 3𝑥 − ln 3 .
2. Simplify ln 𝑥 7 − ln(𝑥 3 ).
3. Evaluate ln 𝑒 2 without using a calculator.
8
Exp/Log Functions: Example 1
Let 𝐶(𝑡) be the amount of caffeine in the body , where 𝑡 is the
amount of hours since Mary drank coffee. Suppose 𝐶(𝑡) follows
the relation
𝐶 𝑡 = 0.88 𝐶(𝑡 − 1)
(a) Express 𝐶(𝑡) as a function of 𝐶(0).
(b) Mary had 80 mg of caffeine at 6 pm. If she is finally able to
sleep at 1 am, find the amount of caffeine in Mary’s body at
that time.
(c) If Mary wants to sleep at 10 pm, what is the latest time that
she should consume a cup of coffee containing 60 mg of
caffeine ?
Please refer to the lecture video exp/log functions example:
caffeine elimination for solutions.
9
Exp/Log Functions: Example 2
Example 2: Radiometric dating
10
Introduction to differentiation
𝑑𝑓
• Differentiation of a function (represented by 𝑓′(𝑥) or )gives
𝑑𝑥
us the slope of tangent to the graph at a certain point
(so-called the instantaneous rate)
• For example, the slope of the brown line (tangent to 𝑦 = 𝑓(𝑥)
𝑑𝑓
at 𝑥 = 4) can be found by 𝑓 ′ 4 or ȁ𝑥=4 .
𝑑𝑥
11
Differentiation rules
• How can we obtain the derivative of a given function, let’s say
𝑓(𝑥) ?
12
Power rule
For any non-zero real number 𝑛, the derivative of 𝑦 = 𝑥 𝑛 can be
obtained by
𝑑 𝑛
𝑥 = 𝑛𝑥 𝑛−1
𝑑𝑥
Examples:
1. Find the derivative of 𝑦 = 𝑥 2 .
2. Find the derivative of 𝑦 = 𝑥.
1
−2
3. Find the derivative of 𝑦 = 𝑥 .
13
Constant multiple rule
For any constant 𝑘 and function 𝑓(𝑥), the derivative of 𝑦 =
𝑘𝑓(𝑥) can be obtained by
𝑑
𝑘𝑓(𝑥) = 𝑘𝑓′(𝑥)
𝑑𝑥
In other words, ‘𝑘’ can be ‘pulled’ out of the differentiation.
Examples:
4
1. Find the derivative of 𝑉 = 𝜋𝑟 3 .
3
2. Find the derivative of 𝑠 = 5𝑡.
3 −1
3. Find the derivative of 𝑥 = 𝑦 2.
2
4. Find the derivative of 𝑦 = 𝑘.
Please refer to the lecture video Constant multiple rule for
solutions.
14
Sum rule
For functions 𝑓(𝑥) and 𝑔(𝑥), the derivative of 𝑦 = 𝑓 𝑥 ± 𝑔(𝑥)
can be obtained by
𝑑
𝑓 𝑥 ± 𝑔 𝑥 = 𝑓 ′ 𝑥 ± 𝑔′(𝑥)
𝑑𝑥
In other words, each function is differentiated separately.
Examples:
1 3
1. Find the derivative of 𝑦 = 𝑥2 + 𝑥 − .
4 2
2. Find the derivative of 𝑠 = 6.933𝑡 − 4.905𝑡 2 .
7𝜋 𝑟 3 +5𝑟+25
3. Find the derivative of 𝐶 = .
3
Please refer to the lecture video Sum rule for solutions.
15
Rules for special functions
Rule Function Derivative Example
Exponential
𝑒𝑥 𝑒𝑥 𝑒𝑥 ′ = 𝑒𝑥
function
Logarithmic 1 ′
1
ln 𝑥 ln 𝑥 =
function 𝑥 𝑥
1
Product rule 𝑓 𝑥 𝑔(𝑥) 𝑓𝑔′ + 𝑔𝑓′ 𝑥 ln 𝑥 ′
=𝑥⋅ + 1 ln 𝑥
𝑥
Examples:
1. Find the derivative of 𝑦 = (𝑥 + 2)(3𝑥 − 4).
2. Find the derivative of 𝑃 = 𝑒 𝑡 ln 𝑡 − 2𝑡 log 2 𝑡.
Please refer to the lecture video Rules for special functions for
solutions.
16
Quotient rule
𝑓 𝑥
For functions 𝑓(𝑥) and 𝑔(𝑥), the derivative of 𝑦 = can be
𝑔 𝑥
obtained by
𝑑 𝑓 𝑥 𝑓 ′ 𝑥 𝑔 𝑥 − 𝑓 𝑥 𝑔′ 𝑥
=
𝑑𝑥 𝑔 𝑥 𝑔 𝑥 2
Examples:
𝑒 𝑥 −1
1. Find the derivative of 𝑦 = .
𝑥
𝑥+15 𝑥+1
2. Find the derivative of 𝑦 = .
𝑥−6
17
Chain rule
If 𝑓 is a function of 𝑢 and 𝑢 is a function of 𝑥, the derivative of
𝑦 = 𝑓[𝑢(𝑥)] can be obtained by
𝑑 𝑑𝑓 𝑢 𝑥 𝑑𝑢 𝑥
𝑓𝑢 𝑥 = ⋅
𝑑𝑥 𝑑𝑢 𝑥 𝑑𝑥
= 𝑓 ′ (𝑢) ⋅ 𝑢′(𝑥)
18
Chain rule: Examples
1. Find the derivative of 𝑦 = 𝑥 2 − 16.
2. Find the derivative of 𝑦 = 8500𝑒 −9.6×10−5 .
𝑥−1 2
1
3. Find the derivative of 𝑦 = 𝑒− 2 .
2𝜋
𝑥2
𝑥 −2
4. Find the derivative of 𝑦 = 𝑒 .
2𝜋
5. Find the derivative of 𝑦 = 2 ln 1 − 0.5𝑥 .
𝑥2
6. Find the derivative of 𝑦 = 4.74 − log10 .
0.1−𝑥
𝑥 2 −16
7. Find the derivative of 𝑦 = .
𝑥
𝑥 2 −16
8. Find the derivative of 𝑦 = 5 sin2 .
𝑥
19
Summary
Rule Function First derivative Example
21
Application of Differentiation
Recall:
• 𝑦 = 𝑓′(𝑥) gives the rate of change of 𝑓(𝑥) with respect to 𝑥.
• In graphical representation, it gives the slope of tangent at a
particular point.
22
Application of Differentiation
How is this useful ?
• In chemistry, if one knows the concentration of a product in a
certain reaction as a function of time 𝑡, i.e., [A](𝑡), the rate of
reaction (rate of change of concentration) is represented by
𝑑𝐴
.
𝑑𝑡
23
Application of Differentiation: Example
1. DNA hybridization (a reaction with second-order kinetics)
Please refer to the lecture video Rate of change motivating
example – second order reaction for question setting and
solutions.
2. Koala population
Please refer to the lecture video Rate of change motivating
example – koala population for question setting and solutions.
24
Related rates
Sometimes we are interested to find the relations between the
rate of change of various quantities.
25
Related rates (Cont.)
𝑑𝑉
We aim to find out .
𝑑𝑡
Differentiating both sides with respect to 𝑡,
𝑑𝑉 4 𝑑 𝑟 3
= 𝜋
𝑑𝑡 3 𝑑𝑡
𝑑 𝑟3 𝑑 𝑟3 𝑑𝑟 2 𝑑𝑟
Using chain rule = ⋅
= 3𝑟 ⋅ , we obtain
𝑑𝑡 𝑑𝑟 𝑑𝑡 𝑑𝑡
𝑑𝑉 2
𝑑𝑟
= 4𝜋𝑟
𝑑𝑡 𝑑𝑡
𝑑𝑟
These rates are hence related. We know that = 1 cm/s.
𝑑𝑡
𝑑𝑉
Substituting 𝑟 = 2 cm, we find ȁ = 16𝜋 cm3/s.
𝑑𝑡 𝑟=2
Please refer to the lecture video Related rates introduction for
one more example regarding bacterial growth.
26
Graphical Representation of First Derivative
Recall that 𝑓′(𝑥) represents the slope of tangent to the graph
𝑦 = 𝑓(𝑥) at a certain point. What does its sign mean?
• 𝑓′ 𝑥 > 0: 𝑓(𝑥) increasing, positive slope of tangent
• 𝑓′ 𝑥 < 0: 𝑓(𝑥) decreasing, negative slope of tangent
• 𝑓′ 𝑥 = 0: 𝑥 is a critical point, slope of tangent = 0
27
First derivative test
Critical points
To determine whether they are maximum and minimum points,
one way is to look for the sign of 𝑓′(𝑥) around the critical points.
29
Graphical Representation of Second Derivative
𝑑2 𝑦
• Second derivative, 𝑓′′(𝑥) or , gives the rate of change of
𝑑𝑥 2
slope of tangent
• 𝑓 ′′ 𝑥 > 0: • 𝑓 ′′ 𝑥 < 0:
• 𝑓′(𝑥) is increasing • 𝑓′(𝑥) is decreasing
• 𝑓(𝑥) concave upward • 𝑓(𝑥) concave downward
30
Second derivative test
An alternative to locate maximum and minimum.
𝑑
1. Find critical points by setting and solving 𝑑𝑥 𝑓 𝑥 = 0.
2. Compute the second derivatives of the critical points
• If 𝑓 ′′ (𝑥) is positive, then 𝑥 is a minimum point.
• Slope of tangent is increasing
• If 𝑓 ′′ 𝑥 is negative, then 𝑥 is a maximum point.
• Slope of tangent is decreasing
31
Optimization
• To maximize or minimize a certain quantity, e.g., reaction rate,
population …
Examples:
1. Range of kicking a football
2. Building design
33
Inflection points: Examples
1. Titration curve
2. Logistic model
34
Integration
• The reverse process of differentiation
35
Antiderivatives
• The inverse product of differentiating a function
36
Antiderivatives
An antiderivative of 𝑓 is any function 𝐹 such that
𝐹 ′ 𝑥 = 𝑓(𝑥)
න 𝑓 𝑥 𝑑𝑥 = 𝐹 𝑥 + 𝐶
37
Antiderivatives
Many ‘integration rules’ can be derived from the respective
differentiation rules, for example, sum rule and constant
multiple rule. For details, please refer to the lecture video
Antiderivatives.
38
Integration by Substitution
It is usually the case that the integrand is a composite function of
the integration variable, where we cannot integrate directly.
Hence we have to use the chain rule, or more conveniently,
integration by substitution (𝑢-substitution in the video).
1. Let 𝑢(𝑥) be a function of the integration variable 𝑥. The
function is of your choice to simplify the integral. You will
learn how to choose one by working on examples.
𝑑𝑢
2. Change the integration variable from 𝑥 to 𝑢 by finding ,
or
𝑑𝑥
a relation between 𝑑𝑢 and 𝑑𝑥.
3. Replace all variables 𝑥 in the integral by the new variable 𝑢.
4. Calculate the integral, or proceed with another substitution.
39
Integration by Substitution: Examples
1. Find 𝑥 + 4 5 𝑑𝑥 .
𝑥 2
2. Find 𝑥𝑑 𝑒𝑥 .
3. Evaluate 𝑔 𝑥 𝑔 𝑓 ′ 𝑥 𝑑𝑥.
40
Definite Integral
Definite integration computes the area under the curve within
an interval; it represents the sum of the dependent variable.
For example, the region bounded by the curve 𝑦 = 𝑓(𝑥), the
vertical lines 𝑥 = 𝑎 and 𝑥 = 𝑏, and the horizontal 𝑥-axis can be
represented by
𝑏
න 𝑓(𝑥) 𝑑𝑥
𝑎
where 𝑎 and 𝑏 are respectively called
the lower limit and the upper limit
of the integration.
41
Definite Integral
• The area is positive if it is
above the 𝑥-axis while it is
negative if it is below the 𝑥-
axis.
• Hence we may interpret
𝑏
𝑥𝑑 )𝑥(𝑓 𝑎as (the area of
the portion above the 𝑥-
axis) – (the area of the
portion below the 𝑥-axis)
42
Definite Integral
Many rules in handling indefinite integrals also apply to definite
integrals. There is a particularly interesting property of definite
integral:
𝑏 𝑐 𝑏
න 𝑓 𝑥 𝑑𝑥 = න 𝑓 𝑥 𝑑𝑥 + න 𝑓 𝑥 𝑑𝑥
𝑎 𝑎 𝑐
i.e., the area over the interval [𝑎, 𝑏] is the sum of area over the
intervals [𝑎, 𝑐] and [𝑐, 𝑏].
Please refer to the lecture video Definite integral (II) for question
and solutions.
43
Fundamental Theorem of Calculus
The theorem consists of two parts:
1. If 𝐹(𝑥) is a function which is differentiable over the interval
[𝑎, 𝑏], and 𝑓 𝑥 = 𝐹′(𝑥) (i.e., 𝐹 is an anti-derivative of 𝑓),
then
𝑏
න 𝑓 𝑥 𝑑𝑥 = 𝐹 𝑏 − 𝐹(𝑎)
𝑎
2. If 𝑓(𝑥) is a “well-behaved” function defined over the interval
[𝑎, 𝑏], then
𝑥
𝑑
න 𝑓 𝑡 𝑑𝑡 = 𝑓(𝑥)
𝑑𝑥 𝑎
44
Fundamental Theorem of Calculus: Examples
1. Find the area under the graph 𝑓 𝑥 = 𝑒 2𝑥 from 𝑥 = −1 to
𝑥 = 1.
2. Find the area between 𝑓 𝑥 = 𝑥 2 − 2𝑥 + 3 and 𝑔 𝑥 = 2𝑥.
3. Suppose the population density of a city is modelled by
−0.01𝑟 2
𝜌 𝑟 = 5000𝑒 persons per km2, where 𝑟 is the
distance from the city centre. Calculate the population within
a 10 km radius of the city centre.
45
A Tip to Learn Calculus Well
Keep practising!
There are more than 100 questions
available for you on Moodle!
46