Beruflich Dokumente
Kultur Dokumente
Motivations
The aim of studying the functions depending on several variables is to understand the
functions which has several input variables and one or more output variables. For example,
the following are Real valued functions of two variables x, y:
(1) f (x, y) = x2 + y 2 is a real valued function dened over IR2 .
(2) f (x, y) =
xy
x2 +y 2
The real world problems like temperature distribution in a medium is a real valued function
with more than 2 variables. The temperature function at time t and at point (x, y) has
3 variables. For example, the temperature distribution in a plate, (unit square) with zero
temperature at the edges and initial temperature (at time t = 0)T0 (x, y) = sin x sin y, is
2
T (t, x, y) = e kt sin x sin y.
Another important problem of physics is Sound waves and water waves. The function
u(x, t) = A sin(kx t) represents the traveling wave of the initial wave front sin kx.
The Optimal cost functions, for example a manufacturing company wants to optimize the
resources, for their produce, like man power, capital expenditure, raw materials etc. The
cost function depends on these variables. Earning per share for Apple company (20052010) has been modeled by z = 0.379x 0.135y 3.45 where x is the sales and y is the
share holders equity.
Limits
Let IR2 denote the set of all points (x, y) : x, y IR. The open ball of radius r with center
(x0 , y0 ) is denoted by
Br ((x0 , y0 )) = {(x, y) :
(x x0 )2 + (y y0 )2 < r}.
Denition: A point (a, b) is said to be interior point of a subset A of IR2 if there exists r
such that Br ((a, b)) A. A subset is called open if each point of is an interior point
of . A subset is said to be closed in its compliment is an open subset of IR2 . For example
(1). The open ball of radius : B ((0, 0)) = {(x, y) IR2 : x2 + y 2 < 1} is an open set
1
A sequence {(xn , yn )} is said to converge to a point (x, y) in IR2 if for > 0, there exists
N IN such that
|xn x|2 + |yn y|2 < , for all n N.
Denition: Let be a open set in IR2 , (a, b) and let f be a real valued function
dened on except possibly at (a, b). Then the limit lim f (x, y) = L if for any > 0
(x,y)(a,b)
Using the triangle inequality (as in one variable limit), one can show that if limit exists,
then it is unique. That is, the limit is independent of choice path (xn , yn ) (a, b).
1. Examples
4xy 2
. This function is dened in
x2 + y 2
IR2 \{(0, 0)}. Let > 0. Then 4|xy 2 | 2(x2 + y 2 )( x2 + y 2 ). Therefore =
For such , |f (x, y) 0| < .
2r cos2 sin
.
r2 cos4 + sin2
2
For any r > 0, the denominator is > 0. Since | cos2 sin | 1, we tend to think for a
while that this limit goes to zero as r 0. So if we take the path r sin = r2 cos2 ,
sin
(i.e., r = cos
2 ), we get
2 sin2
f (r, ) =
= 1.
2 sin2
Let f be a real valued function dened in a ball around (a, b). Then
Denition: f is said to be continuous at (a, b) if
lim
(x,y)(a,b)
f (x, y) = f (a, b)
f (x, y) =
xy
x2 + y 2 = 0
x=y=0
x +y 2
x2 +y 2
f (x, y) =
xy
x2 +y 2
(x, y) (0, 0)
(x, y) (0, 0)
fx (0, 0) = lim
1
i + 12 j.
2
f (1 +
s0
1
= lim
s0 s
s , 2
2
s )
2
f (1, 2)
s
1
1
2
s + s(2 2 + ) = 2 2 +
2
2
The existence of partial derivatives does not guarantee the existence of directional
derivatives in all directions. For example take
xy
x2 + y 2 = 0
2
2
f (x, y) = x +y
.
0
x=y=0
Let
p = (p1 , p2 ) such that p21 + p22 = 1. Then the directional derivative along p is
f (hp1 , hp2 ) f (0, 0)
p 1 p2
= lim
2
h0
h0 h(p2
h
1 + p2 )
x2 y
(x, y) (0, 0)
4
2
.
f (x, y) = x +y
0
x=y=0
Let
p = (p1 , p2 ) such that p21 + p22 = 1. Then the directional derivative along p is
f (sp1 , sp2 ) f (0, 0)
s
s3 p21 p2
= lim
2 2
s0 s(s4 p4
1 + s p2 )
p2 p2
= 1 2 if p2 = 0
p2
s0
In case of p2 = 0, we can compute the partial derivative w.r.t y to be 0. Therefore all the
directional derivatives exist. But this function is not continuous (y = mx2 and x 0).
Dierentiability
x sin 1 + y sin 1 , xy = 0
x
y
f (x, y) =
0
xy = 0
Solution: |f (x, y)| |x| + |y| 2
x2 + y 2 implies that f is continuous at (0, 0). Also
f (h, 0) f (0, 0)
= 0.
h0
h
fx (0, 0) = lim
f (0, k) f (0, 0)
= 0.
k0
k
If f is dierentiable, then there exists 1 , 2 such that
fy (0, k) = lim
f (h, k) f (0, 0) = 1 h + 2 k
where 1 , 2 0 as h, k 0. Now taking h = k, we get
f (h, h) = (1 + 2 )h = 2h sin
1
= h(1 + 2 ).
h
h0
00
= 0, and similar calculation shows fy (0.0) = 0
h
3. = h2 + k 2
Equivalent condition for dierentiability:
Theorem: f is dierentiable at (a, b) lim
f df
= 0.
f df
f df
= 0.
= 0, then
f = df + , 0 as h, k 0.
|h| +
|k|
|h| + |k|
|h| + |k|
sgn(h)
sgn(k)
=
h+
k
|h| + |k|
|h| + |k|
=
sgn(h)
|h|+|k|
and 2 =
sgn(k)
.
|h|+|k|
x2 y 2
x2 +y 2
(x, y) (0, 0)
.
x=y=0
Partial derivatives exist at (0, 0) and fx (0, 0) = 0, fy (0, 0) = 0. By taking h = cos , k =
sin , we get
f df
h2 k 2
4 cos2 sin
= 3 =
= cos2 sin .
3
Therefore, fdf 0 as 0. Therefore f is dierentiable at (0, 0).
x2 y
(x, y) 0
2
2
.
Example: Consider f (x, y) = x +y
0
x=y=0
Example: Consider the function f (x, y) =
3
The limit does not exist. Therefore f is NOT dierentiable at (0, 0).
The following theorem is on Sucient condition for dierentiability:
Theorem: Suppose fx (x, y) and fy (x, y) exist in an open neighborhood containing (a, b)
and both functions are continuous at (a, b). Then f is dierentiable at (a, b).
is continuous at (a, b), there exists a neighborhood N (say) of (a, b) at
Proof. Since f
y
every point of which fy exists. We take (a + h, b + k), a point of this neighborhood so that
(a + h, b), (a, b + k) also belongs to N .
We write
f (a + h, b + k) f (a, b) = {f (a + h, b + k) f (a + h, b)} + {f (a + h, b) f (a, b)}.
Consider a function of one variable (y) = f (a + h, y).
Since fy exists in N, (y) is dierentiable with respect to y in the closed interval [b, b + k]
and as such we can apply Lagranges Mean Value Theorem, for function of one variable y
x3 sin 1 + y 3 sin 1 xy = 0
x2
y2
f (x, y) =
0
xy = 0.
Then
fx (x, y) =
Also fx (0, 0) = limh0
f (h,0)f (0,0)
h
3x2 sin
1
x2
2 cos x12
xy = 0
xy = 0
1
1
+ (y)3 sin
2
(x)
(y)2
= 0 + 0 + 1 x + 2 y
1
1
2
where 1 = (x)2 sin (x)
2 and 2 = (y) sin (y)2 . It is easy to check that 1 , 2 0. So
f is dierentiable at (0, 0).
There are functions for which directional derivatives exist in any direction, but the
function is not dierentiable.
Example: Consider the function
y x2 + y 2 y = 0
f (x, y) = |y|
0
y=0
(Exercise problem)
Chain rule:
Partial derivatives of composite functions: Let z = F (u, v) and u = (x, y), v = (x, y).
Then z = F ((x, y), (x, y)) as a function of x, y. Suppose F, , have continuous partial
derivatives, then we can nd the partial derivatives of z w.r.t x, y as follows: Let x be
increased by x, keeping y constant. Then the increment in u is x u = u(x + x, y)
u(x, y) and similarly for v. Then the increment in z is (as z is dierentiable as a function
of u, v )
x z := z(x + x, y + y) z(x, y) =
F
F
x u +
x v + 1 x u + 2 x v
u
v
Now dividing by x
x u
x v
x z
F x u F x v
=
+
+ 1
+ 2
x
u x
v x
x
x
10
Taking x 0, we get
z F u F v
u
v
=
+
+ ( lim 1 )
+ ( lim 2 )
x0
x0
x u x
v x
x
x
F u F v
=
+
u x
v x
similarly, one can show
z
F u F v
=
+
.
y
u y
v y
2
2u x+y2
2x
e
+ 2
u2 + v
u +v
dy
dx
= FFxy .
11
Using the directional derivatives, we can also nd the Direction of maximum rate of change.
Properties of directional derivative for dierentiable function
Dpf = f p = |f | cos . So the function f increases most rapidly when cos = 1 or
f
is equal to |f |.
when p is the direction of f . The derivative in the direction |f
|
Similarly, f decreases most rapidly in the direction of f . The derivative in this direction
is Dpf = |f |. Finally, the direction of no change is when = 2 . i.,e., p f .
Problem: Find the direction in which f = x2 /2 + y 2 /2 increases and decreases most
rapidly at the point (1, 1). Also nd the direction of zero change at (1, 1).
Example Functions for which all directional derivatives exist but not dierentiable.
Consider the function
y x2 + y 2 , y = 0
f (x, y) = |y|
0
y=0
f (sp1 , sp2 ) f (0, 0)
p2
=
.
s0
s
|p2 |
k
k2
00
|k|
fx (0, 0) = lim
= 0, fy (0, 0) = lim
= 1.
h0
k0
h
k
Dpf (a, b) = lim
In this case, both Dpf (a, b) and f (a, b) p exists but not equal.
Tangents and Normal to Level curves
Let f (x, y) be dierentiable and consider the level curve f (x, y) = c. Let
r (t) = g(t)i +
h(t)j be its parametrization. for example f (x, y) = x2 + y 2 has x(t) = a cos t, y(t) = a sin t
as level curve x2 + y 2 = a2 , which is a circle of radius a. Now dierentiating the equation
f (x(t), y(t)) = a2 with respect to t, we get
fx
dx
dy
+ fy
= 0.
dt
dt
Now since
r (t) = x (t)i + y (t)j is the tangent to the curve, we can infer from the above
equation that f is the direction of Normal. Hence we have
Equation of Normal at (a, b) is x = a + fx (a, b)t, y = b + fy (a, b)t, t IR
Equation of Tangent is (x a)fx (a, b) + (y b)fy (a, b) = 0.
12
Let
r (t) = g(t)i + h(t)j + k(t)k is a smooth level curve(space curve) of the level surface
f (x, y, z) = c. Then dierentiating f (x(t), y(t), z(t)) = c with respect to t and applying
chain rule, we get
f (a, b, c) (x (t), y (t), z (t)) = 0
Now as in the above, we infer the following:
Normal line at (a, b, c) is x = a + fx t, y = b + fy t, z = c + fz t.
Tangent plane: (x a)fx + (y b)fy + (z c)fz = 0.
Example: Find the tangent plane and normal line of f (x, y, z) = x2 + y 2 + z 9 = 0 at
(1, 2, 4).
f +2xi+2yj+ k at (1,2,4) is = 2i+4j+ k and tangent plane is 2(x1)+4(y2)(z4) = 0.
Then normal line is x = 1 + 2t, y = 2 + 4t, z = 4 + t.
Problem: Find the tangent line to the curve of intersection of two surfaces f (x, y, z) =
x2 + y 2 2 = 0, z R, g(x, y, z) = x + z 4 = 0.
Solution: The intersection of these two surfaces is an an ellipse on the plane g = 0. The
direction of normal to g(x, y, z) = 0 at (1, 1, 3) is i + k and normal to f (x, y, z) = 0 is
2i + 2j. The required tangent line is orthogonal to both these normals. So the direction of
tangent is
v = f g = 2i 2j 2k.
Tangent through (1, 1, 3) is x = 1 + 2t, y = 1 2t, z = 3 2t.
Linearization: Let f be a dierentiable function in a rectangle containing (a, b). The
linearization of a function f (x, y) at a point (a, b) where f is dierentiable is the function
L(x, y) = f (a, b) + fx (a, b)(x a) + fy (a, b)(y b).
The approximation f (x, y) L(x, y) is the standard linear approximation of f (x, y) at
(a, b). Since the function is dierentiable,
E(x, y) = f (x, y) L(x, y) = 1 (x a) + 2 (y b)
13
M
(|x a| + |y b|)2 .
2
Taylors theorem
Now
f (h, k) f (0, k)
1 hk(h2 k 2 )
= lim
= k
h0
h0 h
h
h2 + k 2
fx (0, k) = lim
14
f
( )
y x
and
fx (0, k) fx (0, 0)
= 1.
h0
k
///
The following theorem is on the sucient condition for equality of mixed derivatives. We
omit the proof.
Theorem: If f, fx , fy , fxy , fyx are continuous in a neighbourhood of (a, b). Then fxy (a, b) =
fyx (a, b). But this is not a necessary condition as can be seen from the following example
Example: fxy , fyx not continuous
but mixed derivatives are equal.
x2 y2 x = 0, y = 0
2
2
.
Consider the function f (x, y) = x +y
0
x=y=0
Here fxy (0, 0) = fyx (0, 0) but they are not continuous at (0, 0) (Try!).
Taylors Theorem:
Theorem: Suppose f (x, y) and its partial derivatives through order n + 1 are continuous
throughout an open rectangular region R centered at a point (a, b). Then, throughout R,
f (a + h, b + k) =f (a, b) + (hfx + kfy ) (a,b) +
1 2
(h fxx + 2hkfxy + k 2 fyy ) (a,b)
2!
1 3
(h fxxx + 3h2 kfxxy + 3hk 2 fxyy + k 3 fyyy ) (a,b)
3!
1
1
+ ... + (h
+ k )n f (a,b) +
(h
+ k )n+1 f (a+ch,b+ck)
n! x
y
(n + 1)! x
y
+
where (a + ch, b + ck) is a point on the line segment joining (a, b) and (a + h, b + k).
Proof. Proof follows by applying the Taylors theorem, Chain rule on the one dimensional
function (t) = f (x + ht, y + kt) at t = 0.
The function f (x, y) = |xy| does not satisfy the hypothesis of Taylors theorem around
(0, 0). Indeed, the rst order partial derivatives are not continuous at (0, 0).
Error estimation:
problem: The function f (x, y) = x2 xy + y 2 is approximated by a rst degree Taylors
polynomial about (2, 3). Find a square |x 2| < , |y3 | < such that the error of approximation is less than or equal to 0.1.
Solution: We have fx = 2x y, fy = 2y x, fxx = 1, fxy = 1, fyy = 2. The maximum
15
B
(|x 2| + |y 3|)2
2
2
|R| ( + )2 < 0.1 or 4 2 < 0.1, or < 0.025
2
Derivative test:
From our discussion on one variable calculus, it is enough to determine the sign of f =
f (a + x, b + y) f (a, b). Now by Taylors theorem,
f =
where =
1
fxx (a, b)(x)2 + 2fxy (a, b)xy + fyy (a, b)(y)2 + ()3
2
(x)2 + (y)2 . We use the notation
A = fxx , B = fxy , C = fyy
In polar form,
x = cos , y = sin
Then we have
1
f = ()2 A cos2 + 2B cos sin + C sin2 + 2 .
2
Suppose A = 0, then
1
f = ()2
2
1
f = ()2 m2 + 2
2
16
AC B 2
sin2 0 + 2
A
<0
for small. so we dont have constant sign along all directions. Hence (a, b) is
neither a point of maximum nor a point of minimum. Such point (a, b) is called
Saddle point.
2. Let AC B 2 < 0, A < 0.
Similar as above the sign along path = 0 is < 0 and tan 0 = A/B is > 0.
3. Let AC B 2 < 0, A = 0.
In this case B = 0 and
1
f = ()2 (sin (2B cos + C sin ) + 2)
2
for small , 2B cos + C sin is close to 2B, but sin changes sign for > 0 or
< 0. Again here (a, b) is a saddle point.
Case 4: Let AC B 2 = 0.
Again in this case it is dicult to decide the sign of f . For instance, if A = 0,
1
f = ()2
2
(A cos + B sin )2
+ 2
A
Condition
Nature
2
AC B > 0, A > 0 local minimum
AC B 2 > 0, A < 0 local maximum
AC B 2 < 0
Saddle point
2
AC B = 0
No conclusion
Find critical points and their nature of f (x, y) = xy x2 y 2 2x 2y + 4
fx = y 2x 2 = 0, fy = x 2y 2 = 0
Constrained minimization
First, we describe the substitution method. Consider the problem of nding the shortest
distance from origin to the plane z = 2x + y 5.
Here we minimize the function f (x, y, z) = x2 + y 2 + z 2 subject to the constraint 2x + y
z 5 = 0. Substituting the constraint in the function, we get
h(x, y) = f (x, y, 2x + y 5) = x2 + y 2 + (2x + y 5)2 .
The critical points of this function are
hx = 2x + 2(2x + y 5)(2) = 0, hy = 2y + 2(2x + y 5) = 0.
This leads to x = 5/3, y = 5/6. Then z = 2x + y 5 implies z = 5/6. We can check that
AC B 2 > 0 and A > 0. So the point (5/3, 5/6, 5/6) is a point of minimum.
Does this substitution method always work? The answer is NO. The following
example explains
Example: The shortest distance from origin to x2 z 2 = 1.
This is minimizing f (x, y, z) = x2 + y 2 + z 2 subject to the constraint x2 z 2 = 1. Then
19
substituting z 2 = x2 1 in f , we get
h(x, y) = f (x, y, x2 1) = 2x2 + y 2 1
The critical points of the function are hx = 4x = 0, hy = 2y = 0. That is, x = 0, y =
0, z 2 = 1. But this point is not on the hyperbolic cylinder. To overcome this diculty,
we can substitute x2 = z 2 + 1 in f and nd that z = y = 0 and x = 1. These points are
on the hyperbolic cylinder and we can check that AC B 2 > 0, A > 0. This implies the
points are of local minimum nature.
In the substitution method, once we substitute the constraint in the minimizing function, then the the domain of the function will be the domain of the minimizing function.
Then the critical points can belong to this domain which may not be the domain of constraints. This is overcome by the following:
Lagrange Multiplier Method:
Imagine a small sphere centered at the origin. Keep increasing the radius of the sphere
untill the sphere touches the hyperbolic cylinder. The required smallest distance is the
radius of that sphere which touches the cylinder. When the sphere touches the cylinder,
both these surfaces has common tangent plane. So at the point of touching, both surfaces
has normal proportional.
That is f = g for some . Now solving this equations along with g = 0 gives the
points of extrema. In the above example, taking f = x2 + y 2 + z 2 and g = x2 z 2 1 = 0,
we get
2xi + 2y
j + 2z
k = (2xi 2z
k)
This implies, 2x = 2x, 2y = 0 2z = 2z. x = 0 does not satisfy g = 0. So from rst
equation we get = 1. Then 2z = 2z. That is z = 0, and y = 0. Therefore, the critical
points are (x, 0, 0). Substituting this in the constraint equation, we get x = 1. Hence the
points of extrema are (, 0, 0).
Caution: The Method of Lagrange multiplies gives only the points of extremum. To nd
the maxima or minima one has to compare the function values at these extremum points.
Method of Lagrange multipliers with many constraints in n variables
1. Number of constraints m should be less than the number of independent variables n
say g1 = 0, g2 = 0, ....gm = 0.
20
Figure 1:
i gi .
i=1
i gi ,
gi = 0, i = 1, 2, ...m
i=1
4. Once we have extremum points, compare the values of f at these points to determine
the maxima and minima.
Refereces:
1. Thomas Calculus Chapter 14
2. N. Piskunov, Dierential and Integral calculus
21