lecture 7: partial...

13
Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable functions Power series in two variables (Taylor series) Total differentiation vs partial differentiation Chain rules Extremum of multivariable functions and Hessian matrix Lagrange multiplier Maple commands MultivariateCalculus package diff TaylorApproximation LagrangeMultiplier plot3d 2. Partial Differentiation Example 2.1 = = = 2 = =

Upload: others

Post on 14-Aug-2020

9 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

Lecture 7: Partial Differentiation

1. Key pointsDifferentiation of multivariable functionsPower series in two variables (Taylor series)Total differentiation vs partial differentiationChain rulesExtremum of multivariable functions and Hessian matrixLagrange multiplier

Maple commandsMultivariateCalculus packagediffTaylorApproximationLagrangeMultiplierplot3d

2. Partial Differentiation

Example 2.1

=

=

= 2

=

=

Page 2: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(3)(3)

(4)(4)

(1)(1)

(2)(2)

Example 2.2 Ambiguity in expressionSuppose that a physical quantity is a function of coordinates. For example, using Cartesian coordinates in two-dimensional space

The same quantity can be expressed in polar coordinates:

We can also mix the Cartesian and polar coordinates like

or

All these expressions represent the same thing. Now, we want to calculate partial derivative .

Which expression should we use? That depends what quantity is fixed. If is fixed, we use Eq. (2).

Page 3: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

1. 1.

2. 2.

=

If is fixed, we use Eq. (3).

=

If is fixed, we use Eq. (4).

=

As you see, depends on what quantity is fixed. In order to avoid confusion, the fixed quantity

(second independent variable) is indicated by writing it as a subscript.

Exercises 1

For ,

(a) verify that

(b) verify that

If , , , find the following partial derivatives.

(a) (b) (c)

3. Taylor series in two variables

Page 4: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(5)(5)

where all the derivatives are evaluated at and .

Example 3.1Expand in Maclaurin series.

=

The same result can be obtained from the expansion of sin and cos

Exercise 3.1Expand in a two-variable Maclaurin series.

Answer

=

4. Total differential

For , total differential of z is given by

Suppose we know the value of at a point . Now, we move to a new point . How much does the value of change?The change is defined as

Page 5: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(7)(7)

(6)(6)

. Hence, we have

which is the meaning of (5).

Exercise 4.1Classical two-body problem can be mapped to an equivalent single-particle problem with an effective mass as a function of individual masses and . The reduced mass is

defined by . Find the change in when and are varied to and

, assuming and are small.

Answer

= = simplify

= = simplify

5. Chain rulesConsider a function of two variables . Now, if and are functions of , can be interpreted as a function as well: . Then, the regular derivative of with respect to can be obtained using the following chain rule:

Example 5.1

Consider a projectile motion and . The distance between

the initial position and the final position is given by Now, we calculate the time derivative of .

Page 6: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(10)(10)

(11)(11)

(8)(8)

(9)(9)

Important formulae

ProofThere are three quantities, , , and and they are not independent. If and are independent variables, then . On the other hand, if and are independent variables, .Taking the total differential of and ,

Substituting (9) into (8), we obtain

Comparing the left and right hand sides,

and

Page 7: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(13)(13)

(14)(14)

(15)(15)

(16)(16)

(17)(17)

(12)(12)

Multiplying to (12),

Here we used the reciprocal relation . Equations (11) and (13) are the

formulae.

Exercise 5.1

Show that for and ,

Answer

Substituting (15) to (14),

Compare it with

We find .

Exercise 5.2

Given , , , find

Page 8: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(24)(24)

(20)(20)

(21)(21)

(19)(19)

(22)(22)

(18)(18)

(12)(12)

.

Answer

6. Minimum and maximum of two variable functions

Consider a function . Its total differential is .

At maximum or minimum positions, . Hence, and . However, this is not

a sufficient condition. The point satisfying this condition corresponds maximum, minimum or saddle.

Consider a Hessian matrix where , , . The differentials

are evaluated at the point obtained from and .

Since the Hessian matrix is symmetric, all eigenvalues are real. If both eigenvalues are positive, the point is a minimum point. If both eigenvalues are negative, it is a maximum point. If two eigenvalues have opposite sign, then it is a saddle point. If one or both eigenvalues are zero, we obtain no conclusion.

Example 6.1

Find the maximum and minimum points.

Page 9: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(27)(27)

(28)(28)

(25)(25)

(26)(26)

(29)(29)

(12)(12)

(30)(30)

2

0

The Hessian matrix is . Its eigenvalues are 2 and -2. Hence, is a

saddle point.

Exercise 6.1

Find the maximum and mini points of .AnswerFirst, we find the candidates of the maximum and minimum points.

Page 10: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(32)(32)

(31)(31)

(25)(25)

(12)(12)

There is only one point. We now try to find it is maximum or minimum by computing Hessianmatrix

= 2 = 2 = 0

The eigenvalues of the Hessian are both positive. Hence, is the minimum point.

7. Lagrange multipliers

We want to find maximum or minimum points of a function under a constraint given in a form of . We already learned how to find maximum or minimum points if there is no sucha constraint. We extend the previous approach by adding a new independent variable called Lagrange multiplier.Consider a new function

Maximum or minimum points must satisfy the following conditions:

Note that the third condition is exactly the constraint. Therefore, solving these equation simultaneously for , , and we find the maximum or minimum points under the constraint. Since our objective is to find and , it is not necessary to find we find first and used it in finding and .

Example 7.1

Find a minimum point of under a constraint .Without the constraint is the minimum point.

Page 11: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(33)(33)

(25)(25)

(36)(36)

(34)(34)

(35)(35)

(12)(12)

x0 1 2

y 0

1

2

The blue line shows the constraint.

Equation (33) can be solved easily. The solution is either or .

For , we find from Eq. (35). This is the maximum point (as shown in the above plot). Note that we don't have to find in this case.

For , we find from Eq. (34) and from Eq. (35). This is the minimum

points.You can ask Maple to solve the simultaneous equation as follows:

Exercise 7.1Find the volume of the largest rectangular box, with edges parallel to the axes, inscribed on the

Page 12: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(39)(39)

(44)(44)

(41)(41)

(25)(25)

(43)(43)

(40)(40)

(42)(42)

(38)(38)

(12)(12)

(37)(37)

ellipsoid: .

AnswerLet , , and be the corners of the box. The volume of the box is . We want to maximize this function under the constraint

Using Lagrange's multiplier, we define a new function

We solve Eqs. (38) for , , , and .

Simplifying (43) using (41) we find (38) we obtain

Solving (44) for , we find

Page 13: Lecture 7: Partial Differentiationkawai.phy.uab.edu/courses/2011-Spring/ph432/partial_differential.pdf · Lecture 7: Partial Differentiation 1. Key points Differentiation of multivariable

(47)(47)

(45)(45)

(25)(25)

(46)(46)

(12)(12)

(39) and (40), we obtain and