18 2 Partial Derivs

Download as pdf or txt
Download as pdf or txt
You are on page 1of 9

 

Partial Derivatives 18.2 

Introduction
When a function of more than one independent input variable changes in one or more of the
input variables it is important to calculate the change in the function itself. If we hold all but
one of the variables constant and find the rate of change of the function with respect to the
remaining variable, then this process is called partial differentiation.
In this section we show how to carry out the process.

 

Prerequisites ① understand the principle of differentiating


a function of one variable
Before starting this Section you should . . .
 

✓ understand the concept of partial


Learning Outcomes differentiation
After completing this Section you should be ✓ differentiate a function partially with
able to . . . respect to each of its variables in turn

✓ evaluate first partial derivatives

✓ carry out two successive partial


differentiations

✓ formulate second partial derivatives


1. Partial differentiation

The x partial derivative


For a function of a single variable, y = f (x), changing the independent variable x leads to a
corresponding change in the dependent variable y. The rate of change of y with respect to x
is given by the derivative, written dfdx
. A similar situation occurs with functions of more than
one variable. For clarity we shall concentrate on functions of just two variables.
In the relation z = f (x, y) the independent variables are x and y and z is the dependent variable.
We have seen in section 1 that as x and y vary the z-value traces out a surface. Now both of
the variables x and y may change simultaneously inducing a change in z. However, rather than
consider this general situation, to begin with we shall, to begin with, hold one of the independent
variables fixed. This is equivalent to moving along a curve obtained by intersecting the surface
by one of the coordinate planes.
Consider f (x, y) = x3 + 2x2 y + y 2 + 2x + 1. Suppose we keep y constant and vary x; then what
is the rate of change of the function f ?
Suppose we hold y at the value 3 then

f (x, 3) = x3 + 6x2 + 9 + 2x + 1.

In effect, we now have a function of x only. If we differentiate it with respect to x we obtain the
expression:
3x2 + 12x + 0 + 2 + 0 ≡ 3x2 + 12x + 2.
We say that f has been differentiated partially with respect to x. We denote the partial derivative
of f with respect to x by ∂f
∂x
(to be read as ‘partial dee f by dee x’ ). In this particular example,
when y = 3:
∂f
= 3x2 + 12x + 2.
∂x
In the same way if y is held at the value 4 then f (x, 4) = x3 + 8x2 + 16 + 2x + 1 and so, for this
value of y
∂f
= 3x2 + 16x + 2.
∂x
If y = c, a general constant then

f (x, c) = x3 + 2x2 c + c2 + 2x + 1

and partial differentiation yields the expression


∂f
= 3x2 + 4cx + 2.
∂x
Now if we return to the original formulation

f (x, y) = x3 + 2x2 y + y 2 + 2x + 1

and treat y as a constant then the process of partial differentiation with respect to x gives
∂f
= 3x2 + 4xy + 0 + 2 = 3x2 + 4xy + 2.
∂x
HELM (VERSION 1: March 18, 2004): Workbook Level 1 2
18.2: Partial Derivatives
Key Point

The Partial Derivative of f with respect to x


For a function of two variables z = f (x, y) the partial derivative of f with respect to x is
denoted by:
∂f
∂x
and is obtained by differentiating f (x, y) with respect to x in the usual way but treating the
y-variable (temporarily) as if it were a constant.
∂z
Alternative notations are fx (x, y) and ∂x .

Example Find ∂f
∂x
for
(a) f (x, y) = x3 + x + y 2 + y, (b) f (x, y) = x2 y + xy 3 .

Solution
∂f ∂f
(a) ∂x
= 3x2 + 1 + 0 + 0 (b) ∂x
= 2x.y + 1.y 3

The y partial derivative


For functions of two variables f (x, y) the x and y variables are on the same footing, so what
we have done for the x-variable we can do for the y-variable. We can thus imagine keeping the
x-variable fixed and determining the rate of change of f as y changes. This rate of change is
denoted by ∂f
∂y
.

Key Point

The Partial Derivative of f with respect to y


For a function of two variables z = f (x, y) the partial derivative of f with respect to y is
denoted by:
∂f
∂y
and is obtained by differentiating f (x, y) with respect to y in the usual way but treating the
x-variable (temporarily) as if it were a constant.
∂z
Alternative notations are fy (x, y) and ∂y .

3 HELM (VERSION 1: March 18, 2004): Workbook Level 1


18.2: Partial Derivatives
Returning to f (x, y) = x3 + 2x2 y + y 2 + 2x + 1 we therefore obtain:
∂f
= 0 + 2x2 × 1 + 2y + 0 + 0 = 2x2 + 2y.
∂y

Example Find ∂f
∂y
for
(a) f (x, y) = x3 + x + y 2 + y
(b) f (x, y) = x2 y + xy 3

Solution
(a) ∂f
∂y
= 0 + 0 + 2y + 1 (b) ∂f
∂y
= x2 × 1 + x × 3y 2 = x2 + 3xy 2

Strictly speaking, we should talk about the partial derivative of f with respect to x and the
value of ∂f
∂x
at a specific point e.g. x = 1, y = −2.

Example Find fx (1, −2) and fy (−3, 2) for f (x, y) = x2 + y 3 + 2xy

Solution
fx (x, y) = 2x + 2y, so that fx (1, −2) = 2 − 4 = −2
fy (x, y) = 3y 2 + 2x, so that fy (−3, 2) = 12 − 6 = 6

Given f (x, y) = 3x2 + 2y 2 + xy 3 find fx (1, −2) and fy (−1, −1)


First find formulae for ∂f
∂x
and ∂f
∂y

Your solution
∂f ∂f
= =
∂x ∂y

∂y ∂x
= 4y + 3xy 2 ∂f
= 6x + y 3 , ∂f

Now find fx (1, −2) and fy (−1, −1)


Your solution
fx (1, −2) = fy (−1, −1) =

fy (−1, −1) = 4 × (−1) + 3(−1) × 1 = −7


fx (1, −2) = 6 × 1 + (−2)3 = −2

HELM (VERSION 1: March 18, 2004): Workbook Level 1 4


18.2: Partial Derivatives
Functions of several variables
As we have seen, a function of two variables f (x, y) has two partial derivatives, ∂f
∂x
and ∂f
∂y
. In an
exactly analagous way a function of three variables f (x, y, u) will have three partial derivatives
∂f ∂f
,
∂x ∂y
and ∂f
∂u
and so on for functions of more than three variables. Each partial derivative is
obtained in the same way:

Key Point

The Partial Derivatives of f (x, y, u, v, w, . . . )


For a function of several variables z = f (x, y, u, v, w, . . . ) the partial derivative of f with respect
to v (say) is denoted by:
∂f
∂v
and is obtained by differentiating f (x, y, u, v, w, . . . ) with respect to v in the usual way but
treating all the other variables (temporarily) as if they were constants.
∂z
Alternative notations are fv (x, y, u, v, w . . . ) and ∂v .

Find ∂f
∂x
and ∂f
∂u
for f (x, y, u, v) = x2 + xy 2 + y 2 u3 − 7uv 4

Your solution
∂f ∂f
= =
∂x ∂u
∂u ∂x
= 0 + 0 + y 2 × 3u2 − 7v 4 = 3y 2 u2 − 7v 4 . ∂f
= 2x + y 2 + 0 + 0; ∂f

2. Second partial derivatives


Just as for a function of one variable two successive differentiations (with respect to x) can be
2
carried out and written ddxf2 so two successive partial differentiations of f (x, y) with respect to
2
x (holding y constant) is denoted by ∂∂xf2 (or fxx (x, y)) and can be carried out using the same
principles as mentioned earlier. That is, we define
 
∂2f ∂ ∂f

∂x2 ∂x ∂x

5 HELM (VERSION 1: March 18, 2004): Workbook Level 1


18.2: Partial Derivatives
However, for functions of two or more variables other second-order partial derivatives can be
2
obtained. Most obvious is the second derivative of f (x, y) with respect to y is denoted by ∂∂yf2
(or fyy (x, y)) which is defined as:
 
∂2f ∂ ∂f

∂y 2 ∂y ∂y

∂2f ∂2f
Example Find ∂x2
and ∂y 2
for f (x, y) = x3 + x2 y 2 + 2y 3 + 2x + y

Solution
∂f
∂x
= 3x2 + 2xy 2 +0+2+0
∂2f
 ∂f 
≡ ∂
= 6x + 2y 2 + 0 + 0 + 0 = 6x + 2y 2 .
 
∂x 2 ∂x ∂x
∂2f ∂ ∂f
Similarly ∂y 2
= ∂y ∂y
.
∂2f
Now ∂f
∂y
= 0 + x2 × 2y + 6y 2 + 0 + 1 = 2x2 y + 6y 2 + 1 and ∂y 2
= 2x2 + 12y.

To evaluate these formulae we can make use of the alternative notation.

Example Find fxx (−1, 1) and fyy (2, −2) for the function of the last example.

Solution
fxx (−1, 1) = 6 × (−1) + 2 × (−1)2 = −4.
fyy (2, −2) = 2 × (2)2 + 12 × (−2) = −16

Mixed second derivatives


It is possible to carry out a partial differentiation of f with respect to x followed by a partial
differentiation with respect to y (or vice-versa). The results are examples of mixed derivatives.
We must be careful with the notation here, which is as follows:
∂2f
We use ∂x∂y to mean ‘differentiate first with respect to y and then with respect to x’ and we
∂2f
use ∂y∂x
to mean ‘differentiate first with respect to x and then with respect to y’
   
∂2f ∂ ∂f ∂2f ∂ ∂f
i.e. ≡ and ≡ .
∂x∂y ∂x ∂y ∂y∂x ∂y ∂x

HELM (VERSION 1: March 18, 2004): Workbook Level 1 6


18.2: Partial Derivatives
∂2f
Example For f (x, y) = x3 + 2x2 y 2 + y 3 find ∂x∂y

Solution
∂f ∂2f
∂y
= 4x2 y + 3y 2 ; ∂x∂y
= 8xy


 ∂f 
The final option is to differentiate first with respect to x and then with respect to y i.e. ∂y ∂x
.
For the given function
∂f
= 3x2 + 4xy 2
∂x
and
∂2f
= 8xy.
∂y∂x
Notice that for this function
∂2f ∂2f
≡ .
∂x∂y ∂y∂x
This equality of mixed derivatives is true for probably all functions which you are likely to meet
in your studies.
∂2f
To evaluate a mixed derivative we can use the alternative notation. To evaluate ∂x∂y we write
∂2f
fyx (x, y) to indicate that the first differentiation is with respect to y. Similarly, ∂y∂x
is denoted
by fxy (x, y).

Example Find fyx (1, 2) for the function f (x, y) = x3 + 2x2 y 2 + y 3

Solution

fyx = 8xy so fyx (1, 2) = 8 × 1 × 2 = 16.

Find fxx (1, 2), fyy (−2, −1), fxy (3, 3) for

f (x, y) ≡ x3 + 3x2 y 2 + y 2 .

Your solution

fxx (1, 2) = 6 + 24 = 30; fyy (−2, −1) = 26; fxy (3, 3) = 108
∂y∂x ∂x∂y ∂y 2 ∂x2
∂2f
= 12xy = ∂2f
= 6x2 + 2; ∂2f
= 6x + 6y 2 ; ∂2f
∂y ∂x
= 6x2 y + 2y ∂f
= 3x2 + 6xy 2 ; ∂f

7 HELM (VERSION 1: March 18, 2004): Workbook Level 1


18.2: Partial Derivatives
Exercises
∂f ∂f
1. For the following functions find ∂x
and ∂y

(a) f (x, y) = x + 2y + 3
(b) f (x, y) = x2 + y 2
(c) f (x, y) = x3 + xy + y 3
(d) f (x, y) = x4 + xy 3 + 2x3 y 2
(e) f (x, y, z) = xy + yz

2. For the functions of Q1 (a) to (d) find fx (1, 1), fx (−1, −1), fy (1, 2), fy (2, 1).

3. For the functions of Q1 find

∂2f ∂2f ∂2f ∂2f


, , , .
∂x2 ∂y 2 ∂x∂y ∂y∂x

4. For the functions of Q1 (a) to (d) find

fxx (1, −3), fyy (−2, −2), fxy (−1, 1).

∂f ∂2f
5. For the following functions find ∂x
and ∂x∂t

(a) f (x, t) = x sin(tx) + x2 t


(b) f (x, t, z) = zxt − ext
(c) f (x, t) = 3 cos(t + x2 )

HELM (VERSION 1: March 18, 2004): Workbook Level 1 8


18.2: Partial Derivatives
18.2: Partial Derivatives
HELM (VERSION 1: March 18, 2004): Workbook Level 1 9
Answers
∂f ∂f
1. (a) ∂x
= 1, ∂y
=2
∂f ∂f
(b) ∂x
= 2x, ∂y
= 2y
∂f ∂f
(c) ∂x
= 3x2 + y, ∂y
= x + 3y 2
∂f ∂f
(d) ∂x
= 4x3 + y 3 + 6x2 y 2 , ∂y
= 3xy 2 + 4x3 y
∂f ∂f
(e) ∂x
= y, ∂y
=x+z
x x y y
f (1, 1) f (−1, −1) f (1, 2) f (2, 1)
(a) 1 1 2 2
2. (b) 2 −2 4 2
(c) 4 2 13 5
(d) 11 1 20 38
∂2f ∂2f ∂2f ∂2f
3. (a) ∂x2
=0= ∂y 2
= ∂x∂y
= ∂y∂x
∂2f ∂2f ∂2f ∂2f
(b) ∂x2
=2= ∂y 2
; ∂x∂y
= ∂y∂x
=0
∂2f ∂2f ∂2f ∂2f
(c) ∂x2
= 6x, ∂y 2
= 6y; ∂x∂y
= ∂y∂x
= 1.
∂2f ∂2f ∂2f ∂2f
(d) ∂x2
= 12x2 + 12xy 2 , ∂y 2
= 6xy + 4x3 , ∂x∂y
= ∂y∂x
= 3y 2 + 12x2 y
∂2f ∂2f ∂2f ∂2f
(e) ∂x2
= ∂y 2
= 0; ∂x∂y
= ∂y∂x
=1
xx yy xy
f (1, −3) f (−2, −2) f (−1, 1)
(a) 0 0 0
4. (b) 2 2 0
(c) 6 −12 1
(d) 120 −8 15
∂f ∂2f ∂2f
5. (a) ∂x
= sin(tx) + xt cos(tx) + 2xt ∂t∂x
= ∂x∂t
= 2x cos(tx) − x2 t sin(tx) + 2x
∂f ∂2f ∂2f
(b) ∂x
= zt − text ∂t∂x
= ∂x∂t
= z − ext − txext
∂f ∂2f ∂2f
(c) ∂x
= −6x sin(t + x2 ) ∂t∂x
= ∂x∂t
= −6x cos(t + x2 )

You might also like