Вы находитесь на странице: 1из 10

Two Variable Optimization Using Calculus For Maximization Problems

One Variable Case


If we have the following function y = 10x x2 we have an example of a dome shaped function. To nd the maximum of the dome, we simply need to nd the point where the slope of the dome is zero, or
dy dx

OPMT 5701

= 10 2x = 0 10 = 2x x=5 and y = 25

Two Variable Case


Suppose we want to maximize the following function z = f (x, y ) = 10x + 10y + xy x2 y 2 Note that there are two unknowns that must be solved for: x and y . This function is an example of a three-dimensional dome. (i.e. the roof of BC Place ) To solve this maximization problem we use partial derivatives. We take a partial derivative for each of the unknown choice variables and set them equal to zero
z x z y

= fx = 10 + y 2x = 0 The slope in the x direction = 0 = fy = 10 + x 2y = 0 The slope in the y direction = 0

This gives us a set of equations, one equation for each of the unknown variables. When you have the same number of independent equations as unknowns, you can solve for each of the unknowns. rewrite each equation as y = 2x 10 x = 2y 10 substitute one into the other x = 2(2x 10) 10 x = 4x 30 3x = 30 1

x = 10 similarly, y = 10

REMEMBER: To maximize (minimize) a function of many variables you use the


technique of partial dierentiation. This produces a set of equations, one equation for each of the unknowns. You then solve the set of equations simulaneously to derive solutions for each of the unknowns. Second order Conditions (second derivative Test) To test for a maximum or minimum we need to check the second partial derivatives. Since we have two rst partial derivative equations (fx ,fy ) and two variable in each equation, we will get four second partials ( fxx , fyy , fxy , fyx ) Using our original rst order equations and taking the partial derivatives for each of them (a second time) yields: fx = 10 + y 2x = 0 fy = 10 + x 2y = 0 fxx = 2 fxy = 1 fyy = 2 fyx = 1

The two partials,fxx , and fyy are the direct eects of of a small change in x and y on the respective slopes in in the x and y direction. The partials, fxy and fyx are the indirect eects, or the cross eects of one variable on the slope in the other variables direction. For both Maximums and Minimums, the direct eects must outweigh the cross eects

Rules for two variable Maximums and Minimums


1. Maximum fxx < 0 fyy < 0 fyy fxx fxy fyx > 0 2. Minimum fxx > 0 fyy > 0 fyy fxx fxy fyx > 0 3. Otherwise, we have a Saddle Point From our second order conditions, above, fxx = 2 < 0 fyy = 2 < 0 fxy = 1 fyx = 1 and therefore we have a maximum. fyy fxx fxy fyx = (2)(2) (1)(1) = 3 > 0 2

Hessian Matrix of Second Partials:


Sometimes the Second Order Conditions are checked in matrix form, using a Hession Matrix. The Hessian is written as fxx fxy H= fyx fyy = fyy fxx fxy fyx

where the determinant of the Hessian is fxx fxy |H | = fyx fyy

which is the measure of the direct versus indirect strengths of the second partials. This is a common setup for checking maximums and minimums, but it is not necessary to use the Hessian.

Example: Prot Maximization


A monopolist oers two dierent products, each having the following market demand functions q1 = 14 1 p 4 1 1 q2 = 24 2 p2 The monopolists joint cost function is
2 2 C (q1 , q2 ) = q1 + 5q1 q2 + q2

The monopolists prot function can be written as


2 2 = p1 q1 + p2 q2 C (q1 , q2 ) = p1 q1 + p2 q2 q1 5q1 q2 q2

which is the function of four variables: p1 , p2 , q1 ,and q2 . Using the market demand functions, we can eliminate p1 and p2 leaving us with a two variable maximization problem. First, rewrite the demand functions to get the inverse functions p1 = 56 4q1 p2 = 48 2q2 Substitute the inverse functions into the prot function
2 2 = (56 4q1 )q1 + (48 2q2 )q2 q1 5q1 q2 q2

The rst order conditions for prot maximization are


q1 q2

= 56 10q1 5q2 = 0 = 48 6q2 5q1 = 0

Solve the rst order conditions using Cramers rule. First, rewrite in matrix form 10 5 q1 56 = 5 6 48 q2 3

where |A| = 35

56 5 48 6 = 2.75 q1 = 35 10 56 5 48 = q2 = 5.7 35 Using the inverse demand functions to nd the respective prices, we get p 1 = 56 4(2.75) = 45 p 2 = 48 2(5.7) = 36.6 From the prot function, the maximum prot is = 213.94

Next, check the second order conditions to verify that the prot is at a maximum. The various second derivatives can be set up in a matrix called a Hessian The Hessian for this problem is 10 5 11 12 = H= 5 6 21 22 The sucient conditions are |H1 | = 11 = 10 < 0 (First Principle Minor of Hessian) |H2 | = 11 22 12 21 = (10)(6) (5)2 = 35 > 0 (determinant) Therefore the function is at a maximum. Further, since the signs of |H1 | and |H2 | are invariant to the values of q1 and q2 , we know that the prot function is strictly concave.

Example: Prot Max Capital and Labour


Suppose we have the following production function q = f (K, L) = L + K
1 2 1 2

q = Output L = Labour K = Capital

Then the prot function for a competitive rm is = P q wL rK or 1 1 = P L 2 + P K 2 wL rK First order conditions 4 P = Market Price w = Wage Rate r = Rental Rate

1. 2.

L k

= =

1 P L 2 w 2 1 P K 2 r 2

=0 =0

General Form P fL w = 0 P fK r = 0

Solving (1) and (2), we get


w 2 ) L = ( 2P r 2 K = ( 2 ) P

Second order conditions (Hessian) LL = P fLL = 4P L 2 < 0 3 KK = P fKK = 4P K 2 < 0 LK = KL = P fLK = P fKL = 0 or, in matrix form P 3 LL LK 0 4 L2 H = 3 P KL KK = K 2 0 4 P 3 L2 4 P 3 K 2 4
3

Dierentiate rst order of conditions with respect to capital (K) and labour (L) =Therefore prot maximization Example: If P = 1000, w = 20, and r = 10 1. Find the optimal K , L, and 2. Check second order conditions

P fLL fKK (fLK )2 =

0>0

Example: Cobb-Douglas production function and a competitive rm


Consider a competitive rm with the following prot function = T R T C = P Q wL rK where P is price, Q is output, L is labour and K is capital, and w and r are the input prices for L and K respectively. Since the rm operates in a competitive market, the exogenous variables are P,w and r. There are three endogenous variables, K, L and Q. However output, Q, is in turn a function of K and L via the production function Q = f (K, L)

which in this case, is the Cobb-Douglas function Q = La K b where a and b are positive parameters. If we further assume decreasing returns to scale, then a + b < 1. For simplicity, lets consider the symmetric case where a = b = 1 4 Q = L4 K 4 Substituting Equation 3 into Equation 1 gives us (K, L) = P L 4 K 4 wL rK The rst order conditions are
L K
1 1 1 1

The sucient conditions for a maximum are that |H1 | < 0 and |H | > 0. Therefore, the second order conditions are satised. We can now return to the rst order conditions to solve for the optimal K and L. Rewriting the rst equation in Equation 5 to isolate K 3 1 P 1 L 4K4 = w 4 w 3 K = ( 4p L 4 )4 Substituting into the second equation of Equation 5
3 P 1 L 4 K 4 4

This system of equations dene the optimal L and K for prot maximization. But rst, we need to check the second order conditions to verify that we have a maximum. The Hessian for this problem is 2 3 3 # " 7 1 3 LL LK )L 4 K 4 P 1 L 4K 4 P ( 16 1 2 3 3 4 3 1 7 H= = KL KK P 4 L 4 K 4 P 16 L 4 K 4

3 1 L 4K4 w = 0 =P 1 41 1 3 = P 4 L4 K 4 r = 0

= P4

Re-arranging to get L by itself gives us


3 1 P L = ( w 4 r 4 )2 4

1 4
4

w3 L2 = r

P
4

1 4

4w 3 L4 p

4 3 4

=r

Taking advantage of the symmetry of the model, we can quickly nd the optimal K
1 P 3 K = ( r 4 w 4 )2 4

L and K are the rms factor demand equations. 6

Cournot Doupoly (Game Theory)


. Assumption: Each rm takes the other rms output as exogenous and chooses output to maximize its own prots. Market Demand: P = a bq or P = a b(q1 + q2 ) (q1 + q2 = q ) Where qi is rm is output i = 1, 2 Each rm faces the same cost function T C = K + cqi (i = 1, 2) Each rms prot function is i = P qi cqi K 1 = P q1 cq1 K 1 = (a bq1 bq2 )q1 cq1 K Max 1, treating q2 as constant = a bq2 2bq1 c = 0 2bq1 = a c bq2 c q1 = a2 q22 Best Response Function b Best Response Function tells Firm 1 the prot maximizing q1 for any level of q2 . For Firm 2 2 = (a bq1 bq2 )q2 cq2 K Treating q1 as constant Max 2 q1 c q2 = a2 Firm 2s Best Response Function b 2 The two Best Response Functions Firm 1 q1 = Firm 2 q2 =
ac 2b ac 2b q1

Firm 1

q2 2 q1 2

gives us two equations and two unknowns. The solution to this system of equations is the equilibrium to the Cournot Duopoly Game. Using Cramers Rule
c 1. q1 = a3 b c 2. q2 = a3 b Market Output q1 + q2 =

2(ac) 3b

Review of Some Derivative Rules


1. Partial Derivative Rules: U U U U U = xy = xa y b a = xa y b = x yb = ax + by = ax1/2 + by 1/2 U/ x = y U/ x = axa1 y b U/ x = axa1 y b U/ x = a U/ x = a 1 x1/2 2 U/ y U/ y U/ y U/ y U/ y =x = bxa y b1 = bxa y b1 = b =b 1 y 1/2 2

2. Logarithm (Natural log) ln x (a) Rules of natural log

If y = AB y = A/B y = Ab

T hen ln y = ln(AB ) = ln A + ln B ln y = ln A ln B ln y = ln(Ab ) = b ln A

NOTE: ln(A + B ) 6= ln A + ln B (b) derivatives IF y = ln x y = ln (f (x)) (c) Examples If y = ln(x2 2x) ln x y = ln(x1/2 ) = 1 2 3. The Number e if y = ex then if y = ef (x) (a) Examples y = e3x 3 y = e7x y = ert
dy dx dy dx dy dt

T HEN dy 1 =x dx dy = f (1x) f 0 (x) dx T hen 1 dy/dx = (x2 (2x 2) 2x) 1 1 dy/dx = 2 x = 21x

dy = ex dx dy = ef (x) f 0 (x) then dx

= e3x (3) 3 = e7x (21x2 ) = rert

Finding the MRS from Utility functions


EXAMPLE: Find the total dierential for the following utility functions

1. U (x1 , x2 ) = ax1 + bx2 where (a, b > 0)


3 2. U (x1 , x2 ) = x2 1 + x2 + x1 x2 b 3. U (x1 , x2 ) = xa 1 x2 where (a, b > 0)

4. U (x1 , x2 ) = ln c1 + ln c2 where (, > 0) Answers: U = U1 = a 1. x1 and

U x2

= U2 = b dU = U1 dx1 + U2 dx2 = adx1 + bdx2 = 0

If we rearrange to get dx2 /dx1 dx2 U1 a x1 = = = U dx1 U2 b x2 The MRS is the Absolute value of
dx2 dx1 U

: MRS = a b

U U = U1 = 2x1 + x2 = U2 = 3x2 2. 2 + x1 x1 x2 and dU = U1 dx1 + U2 dx2 = (2x1 + x2 )dx1 + (3x2 2 + x1 )dx2 = 0

Find dx2 /dx1 dx2 U1 (2x1 + x2 ) = = dx1 U2 (3x2 2 + x1 ) The MRS is the Absolute value of
dx2 dx1

: (2x1 + x2 ) (3x2 2 + x1 )

MRS =

1 b b1 U U = U1 = axa = U2 = bxa iii) 1 x2 1 x2 x1 x2 and 1 b a b1 dU = axa x + bx1 x2 dx dx2 = 0 1 1 2

Rearrange to get

1 b dx2 U1 axa ax2 1 x2 = = a = b1 dx1 U2 bx1 bx1 x2 dx2 dx1

The MRS is the Absolute value of

: MRS = ax2 bx1

iv) and

U c1

= U1 =


1 c1

dc1 =


c1

dc1 c1 dc1 +

U x2

= U2 =

dU = Rearrange to get

c2


1 c2

dc2 =


c2

dc2

dc2 = 0

The MRS is the Absolute value of

c1 c2 dc2 U1 = = = dc1 U2 c1 c2 dc2 dc1

MRS =

c2 c1

10

Оценить