Univariate Calculus
Professor Peter Cramton
Economics 300
Outline
• Rules of differentiation
– Sum rule
– Scale rule
– Product rule
– Power rule
– Exponential rule
– Chain rule
– Quotient rule
– Logarithmic rule
Outline
• Second derivatives and convexity
• Economic applications
– Risk aversion and utility functions
– Elasticities
– Total revenue
– Average, marginal, and total cost
Rules of differentiation
• Used to evaluate derivative of any function
• Much easier than working with basic definition dy dx
lim
0
( x ) f x
x
Sum rule y
( )
( )
( ) dy dx
( )
( )
( )
Scale rule y
( )
( ) dy dx
( )
( )
Product rule y
( )
( ) ( ) dy dx
( )
( ) ( )
Power rule y
( )
kx n dy dx
( )
nkx n
1
Exponential rule y
( )
e kx dy dx
( )
ke kx
Chain rule y
( )
( ( )) dy dx
( )
( ( ))
( ) y
( ) u
( ) dy
dy du dx du dx
Quotient rule y
( )
dy dx
( )
( ) ( )
2
Logarithmic rule y
( )
ln x dy
1 dx x y
( )
log b x dy dx
1 1 x ln b
y
x
3 y
25 y
7
4 x
4 y
8 x
2
3 x
14
1 y x
3
2
2 x
Exercise dy dx
3
2 x dy dx
7 x
5 dy dx dy dx
16
3 x x
2
1/ 2
2
3 x
3
2
y
20 x
4 x
2 y
e
2 x y
3ln x y
2( x
1)
2
Exercise dy
20 8 x dx dy
2 e
2 x dx dy
3 dx x dy dx
4( x
1)
f x
( x
1)
3
( x
2 x
2
5 f x
3( x
1)
2
2( x
2 x x
2)
( )
(2 x
4)
99 f x
x
98
( ) 99(2 4) 2 f x
e x ab
( )
x ab
1 x
( ) e
abe abx
( )
( e x a b
)
( )
( x a b
1 x
) a e ax a
1 ab e x a b a
( ) x
1
( )
( e
2
)
10
( ) 10( e
2
10
) ( b
2 )
y
log (2
2 x
3) y
x
2 log (8 )
4 y
x
3 log
2 x
Exercise y
2 1
2 x
3 ln 2 y
16 x 1
2 1
8 x
2 ln 4 x ln 4 y
x
2
3 log
2 x
x
3
1 1 x ln 2 y
log
3 x
2 x y
1
2 x
2 log
3 x
1 1 1
2 x x ln 3
Second derivative
• First derivative
– Rate of change
– Slope of the function
– Velocity dy dx
( )
• Second derivative
– Rate of change of the rate of change
– Rate of change of the slope of the function
– Acceleration
2 d dy d y
dx dx dx
2 f
( )
Example: square-root utility
( )
ac
1
2 dU
dc
2 d U dc
2
( )
1
2 ac
1
2
( )
1
4 ac
3
2
Square-root utility function
( )
c
1
2 dU
dc
( )
1
2 c
1
2
2 d U dc
2
( )
1
4 c
3
2
Example: logarithmic utility
( )
ln x dU
dx
2 d U dx
2
( )
x
( )
x
2
Logarithmic utility function
Second derivative and convexity
• Strictly convex
– Slope strictly increasing
– Second derivative positive: f”(x) > 0
• Strictly concave
– Slope strictly decreasing
– Second derivative negative: f”(x) < 0
Second derivative and convexity
• Convex
– Slope increasing
– Second derivative f”(x)
0
• Concave
– Slope decreasing
– Second derivative f”(x)
0
Concave and convex functions
Strictly concave
Strictly convex
Which do you prefer?
• $12 for sure
• 50-50 chance of $6 or $18
• Expected value of both is $12
.5($6) + .5($18) = $12
• Risk averse
– Prefer sure thing
– U(12) > .5U(6) + .5U(18)
– Concave utility
• Risk seeking
– Prefer gamble
– U(12) < .5U(6) + .5U(18)
– Convex utility
Risk-averse and risk-loving utility
y
Exercise: Concave or convex?
x
6 x
2 x
3 y
x
3 x
2 y x
30
25
20
Concave y”<0 Convex y”>0
1 2 3 4
Elasticities
• How sensitive is demand to a change in price?
• Does revenue increase or decrease when price is raised?
• Depends on price elasticity of demand
• % change in quantity / % change in price
Elasticities
0, percentage change in Q is dQ
Q
0, percentage change in P is dP
P
Price elasticity of demand
/
dQ P
/ dP Q
Elasticities
•
< -1 demand is price elastic
– quantity falls by more than 1% if price increases by 1%
•
> -1 demand is price inelastic
– quantity falls by less than 1% if price increases by 1%
• Elasticities in different markets are comparable, since based on % change
P
Elastic
P
Inelastic
D
Q
D
Q
Elasticities with linear demand
Elastic
Inelastic q p
dq p
p
p
2
, q
2 p p dp q q
p
Arc elasticity for discrete changes
arc
(
(
Q
P
Q
Q
A
A
P
B
B
Q
P
B
B
P
A
A
) / 2
) / 2
Alternative form for elasticity
Price elasticity of demand
/
dQ P
/ dP Q d ln Q
1
dQ Q d ln Q
dQ
Q d ln P
1
dP P d ln P
dP
P
dQ P
d ln Q dP Q d ln P
Log-linear demand
Infant mortality and income/capita
Elasticity and other economic concepts
• Substitutes
– Products with good substitutes are more elastic
• Complements
– Products with many complements are less elastic
• Luxury goods tend to be more elastic
• Necessities tend to be less elastic
Do consumers or producers bear a tax?
• Depends on elasticity of demand and supply
– Party least able to substitute away pays more of tax
P
C
P
P
T
Q ( P
D C
)
Q P
S P
)
dP
C
dP
P
dT dQ
D dP
C dQ P
D
dQ
S
P dP Q dP Q
C P dP
P dT
D
S D
dP
P
and
dP
C dT dP
C
S
S
dQ
S dP
P dQ P
D dP Q
C dT
D dP
P
Impact of quantity change on revenue
• Depends on elasticity of demand
– Producer wants to reduce quantity if it faces inelastic demand
R
PQ dR dP
dQ dQ
Q P P
1
dP Q dQ P
P
1
1
•
> -1 then revenue declines when produce more
•
< -1 then revenue increases when produce more
• Monopolist allows produces in elastic portion of demand (
< -1)
2500
2000
1500
1000
500
P = 100 – Q; R = (100 – Q)Q
< -1
> -1
20 40 60 80 100
y
Exercise: Find elasticity
4
dy x dx y
2
4
92
8 / 92 y
16 8 x
2
,
1.5
ln y
x x
3
.5
x y
2 x
4
x
3 / 2.5
y
50 x
2
, x
2
2
50
3 x x
50 x
2
2
Total, average, and marginal
• Total product
• Average product
• Marginal product
800
Q
Q
/
100
L
1/2
100
L
1/2
1/2
/ 50 L
Total product
600
Average product > marginal product since concave
400
200
60
L
10 20 30 40 50
Total, average, and marginal
• Total cost
C
Q
3
15 Q
2
93 Q
100
• Average cost
• Marginal cost
$ dC dQ
3 Q
2
30 Q
93
Total cost
700
600
500
400
300
200
Average cost = marginal cost at minimum average cost
12
Q
2 4 6 8 10
300
250
200
150
100
50
Average cost = marginal cost at min
Competitive firm size
Marginal cost
Average cost
5 10 15