Topic 4: Differentiation

advertisement
Topic 5: Differentiation
Lecture Notes:
section 4
Jacques Text Book (edition 3):
Chapter4
1
Recall measuring change in the case
of a linear function:
y = a + bx
a = intercept
b = slope i.e. the impact of a unit change
in x on the level of y
y
y2  y1
b = x = x  x
2
1
 constant along a straight line
 y changes at a constant rate in
response to changes in x
2
If the function is non-linear: e.g. if y = x2
40
Total Cost Curve:
y=x2
y=x2
30
20
10
0
0
y
x
1
=
y2  y1
x2  x1
2
X3
4
5
6
gives slope of the line
connecting 2 points (x1, y1) and (x2,y2) on a
curve
 (2,4) to (4,16): slope = (16-4)/(4-2) = 6
 (2,4) to (6,36): slope = (36-4)/(6-2) = 8
3
The slope of a curve is equal to the slope of
the line (or tangent) that touches the curve
at that point
Total Cost Curve
40
35
30
y=x2
25
20
15
10
5
0
1
2
3
4
5
6
7
X
- which is different for different values
of x
4
y = x2
y+y = (x+x) 2
y+y =x2+2x.x+x2
y = x2+2x.x+x2 – y
since y = x2
y = 2x.x+x2
y
x
= 2x+x
The slope depends on x and x
Differentiation: finds the derived
function by letting change in x become
arbitrarily small, i.e. letting  x  0
y
x = 2x in the limit, as x 0
dy
y
f ' x  
 lim
 2x
dx x0 x
5
Rules for Differentiation (section 4.3)
1. The Constant Rule
If y = c where c is a constant,
dy
0
dx
dy
e.g. y = 10 then dx  0
2. The Linear Function Rule
If y = a + bx
dy
b
dx
dy
6
e.g. y = 10 + 6x then dx
6
3. The Power Function Rule
If y = axn,
a & n are constants
dy
 n.a.x n1
dx
dy
0

4
x
4
i) y = 4x => dx
ii) y = 4x
2
dy
=> dx  8 x
dy
2
3

12x
iii) y = 4x => dx
dy
3


8
x
iv) y = 4x => dx
-2
7
4. The Sum-Difference Rule
If y = f(x)  g(x)
dy d [ f ( x )] d [ g( x )]


dx
dx
dx
If y is the sum/difference of two or more
functions of x: differentiate the 2 (or more)
terms separately, then add/subtract
(i) y = 2x2 + 3x
then
dy
 4x  3
dx
(ii) y = 4x2 - x3 - 4x then
dy
 8 x  3x 2  4
dx
dy
(iii) y = 5x + 4 then dx  5
8
5. The Product Rule
If y = u.v where u and v are functions of x
dy
dv
du
Then dx  u dx  v dx
i) y = (x+2)(ax2+bx)
dy
 x  22ax  b   ax2  bx 
dx
ii)
y = (4x3-3x+2)(2x2+4x)



dy
 4 x 3  3 x  2 4 x  4  
dx
2 x 2  4 x 12 x 2  3


9
6. The Quotient Rule
If y = u/v where u and v are functions of x
du
dv
v
u
dy
dx
dx

Then dx
v2
i) y = (x+2)/(x+4)
dy 
dx



x  4   x  2



x4
2


2

 x  4 2




ii) y = (3x+2)/(x2+4)
dy

dx
 x2


 4 3  3x  22 x 

 x2


 4 

2
dy  3x 2  4 x  12

2
dx
 x2  4




10
7. The Chain Rule
If y is a function of v, and v is a function of
x, then y is a function of x and
dy
dy dv

.
dx
dv dx
i)
y = (ax2 + bx)½
let v = (ax2 + bx) , so y = v½

dy 1

ax 2  bx
dx 2
ii)
 .2ax  b

1
2
y = (4x3 + 3x – 7 )4
let v = (4x3 + 3x – 7 ), so y = v4



3
dy
3
 4 4 x  3x  7 . 12 x 2  3
dx
11
8. The Inverse Function Rule
dy
1
If x = f(y) then dx  dx
dy
The derivative of the inverse of the function
x = f(y), is the inverse of the derivative of
the function
(i) x = 3y2 then
dx
 6y
dy
dy
1
so dx  6 y
(ii) y = 4x3 then
dy
dx
1
2
 12x so

dy 12 x 2
dx
- Differentiating functions using Rules 1
 8,
See Section 4 of course manual,
questions 3, 4 and 10
12
Applications of the Basic Rules
Calculating Marginal Functions
d TR 
MR 
dQ
d TC 
MC 
dQ
Example 1
A firm faces the demand curve P=17-3Q
(i) Find an expression for TR in terms of Q
(ii) Find an expression for MR in terms of Q
Solution:
TR = P.Q = 17Q – 3Q2
d TR 
MR 
 17  6Q
dQ
13
Example 2:
If a firms Total Cost Curve is:
TC = Q3 – 4Q2 + 12Q
(i) Find an expression for AC in terms of Q
(ii) Find an expression for MC in terms of Q
(iii) When does AC=MC?
(iv) When does the slope of AC=0?
(v) Plot MC and AC curves and comment
on the economic significance of their
relationship
(vi) Suppose now TC=Q3- 4Q2+12Q +10.
Draw new curves and comment….
14
1) Find the Average Cost
AC = TC / Q = Q2 – 4Q + 12
2) Find the Marginal Cost
d TC 
2
dQ
 3Q  8Q  12
3) When does AC = MC?
Q2 – 4Q + 12 = 3Q2 – 8Q + 12
 2Q2 – 4Q = 0
 2Q = 4
Q =2
Thus, AC = MC curves when Q = 2
4) When does the slope of AC = 0?
Differentiate AC = Q2 – 4Q + 12 to find
slope……
d  AC 
dQ
 2Q  4
15
then set it equal to 0
2Q – 4 = 0
 Q = 2 when slope AC = 0
(v) Economic Significance?
MC curve cuts the AC curve at its
minimum point…….(draw both curves)
MC cuts AC curve at minimum point…
(vi) What happens if we introduce Fixed
costs to the TC function?
TC=Q3- 4Q2+12Q +10
 no impact on the MC function,
 shift up AC function by FC/q
16
Example 3: ELASTICITY
Price Elasticity of Demand:
ed =
proportional change in demand
proportional change in price
=
Q P
/
Q P
Q P
= P . Q
To calculate the point elasticity of demand
then,
ed =
dQ P
.
dP Q
e.g. Find ed of the function Q = aP-b
ed =
 baP b1 .
P
aP b
 baP b P
= P . aP b  b
17
 Inelastic demand: if ed < 1
 Unit elastic demand: if ed = 1
 Elastic demand: if ed > 1
18
9. Differentiating Exponential Functions
(Course Manual, parts of Topic 6.1)
Aside: The exponential function:
y = exp(x) = ex
Features of y = ex
 non-linear
 always positive
 as  x get  y and  slope of graph
 exponential function can be differentiated
Rule 9:
dy
x

e
If y = e then dx
where e = 2.71828….
x
More generally,
dy
rx
rx

rAe
 ry
If y = Ae then dx
19
Examples:
2x
1) y = e
dy
then dx = 2e2x using above
rule
2) y = e-7x
dy
then dx = -7e-7x
20
.Differentiating Natural Logs
(Course Manual, Topic 6.2)
Thus, if y = ex then x = loge y = ln y
Logs to the base e are natural logs
Differentiating Natural Logs
dy
 ex
dx

If y = e then

From The Inverse Function Rule
x
= y
dx 1
y = e  dy  y
x

Now, if y = ex this is equivalent to
writing x = loge y = ln y

dx 1
 dy  y
Thus, x = ln y
21
Rule 9: Differentiating Natural Logs
dy 1
if y = loge x = ln x  dx  x
NOTE: the derivative of a natural log
function does not depend on the co-efficient
of x
Thus, if y = ln mx 
dy 1

dx x
Proof
 if y = ln mx
m>0
 Rules of Logs  y = ln m+ ln x
 Differentiating (Sum-Difference rule)
dy
1 1
0 
dx
x x
22
Examples:
1) y = ln 5x (x>0) 
dy 1

dx x
2) y = ln(x2+2x+1)
let v = (x2+2x+1)
so y = ln v
dy dy dv
Chain Rule:  dx  dv . dx
dy
1
 2
.2 x  2
dx x  2 x  1

dy
2 x  2
 2
dx
x  2x  1


3) y = x4lnx
Product Rule: 
dy
4 1
x
 ln x.4 x3
dx
x
3
= x3  4 x3 ln x = x 1  4 ln x 
23
4) y = ln(x3(x+2)4)
Simplify first using rules of logs
 y = lnx3 + ln(x+2)4
 y = 3lnx + 4ln(x+2)
dy 3
4
 
dx x x  2
Note:
- Differentiating exponential and log
functions using Rules 9 and 10,
See Section 6 of course manual,
questions 3 and 4**
24
Example 1
If the Demand equation is given by
P = 200 – 40ln(Q+1)
Calculate the price elasticity of demand
when Q = 20
Solution
 Price elasticity of demand:
ed =
dQ P
.
dP Q
<0
dP
 P is expressed in terms of Q, so find dQ
dP
40

dQ
Q 1
 Inverse rule of differentiation 
dQ
1

dP dP dQ
25
Thus,
dQ
Q 1

dP
40
 Hence, ed =

Q 1 P
.
40 Q
<0
 The price elasticity of demand when Q is
20 is therefore computed as
21 78.22
 .
40 20 = -2.05
where P = 200 – 40ln(20+1) = 78.22
26
Natural Logs in Applied Examples
(see section 6.2 in Manual)
Useful in considering proportional changes
in variables….
The derivative of log(f(x))  f’(x) / f(x), or
the proportional change in the variable x
i.e. y = f(x), then the proportional  x
dy 1 d (ln y )
= dx . y =
dx
dy 1 
1) Show that if y = x, then dx . y  x
and this  derivative of ln(y) with respect to
x.
27
Solution:
dy 1
1
.  .x  1
dx y
y
1
x
 y . x

1
y
 y . . x  x
Now ln y = ln x
Re-writing  ln y = lnx
d (ln y )
1 
 . 

dx
x
x
Differentiating the ln y with respect to x
gives the proportional change in x.
28
Example :
If Price level at time t is P(t) = a+bt+ct2
The inflation rate at t is
1
dP( t )
b  2ct
.

P( t )
dt
a  bt  ct 2
This is equivalent to differentiating the log
of P(t) wrt t directly
lnP(t) = ln(a+bt+ct2)
where v = (a+bt+ct2) so lnP = ln v
Using chain rule,
dP dP dv

.
dt
dv dt
d ln P( t )
b  2ct

2
dt
a  bt  ct
29
Download