Anda di halaman 1dari 22

Multivariable Functions

The Three­Dimensional Coordinate System 
Functions of Several Variables 
Partial Derivatives 
Finding Extrema (Max/Min of multivariable 
functions)

Session 9 : 9/25  1
Multivariable Functions
p  So far, we have been working with functions of two dimensions (one 
dependent variable, one independent variable) 

Examples:  y = 2 x + 1 

f ( x ) = x 2 - 7 x - 2 

But, in reality, most independent variables are dependent on more than one 
dependent variable.  For example: 

Plant growth (P) is dependent on time (t), temperature (T), and water content (w). 

Then we can see that P is a function of t, T, and w.  This is written 
mathematically as: 
P ( t , T , w ) 

Session 9 : 9/25  2
Examples:

D( r , t ) = r × t 

Ideal Gas Law : 
n = moles 
T = temperature 
nRT  p = pressure 
V ( n , T , p ) = R = gas constant 


Notice that V is not a function of R, because R is a constant.

Session 9 : 9/25  3
Understanding Multivariable Functions Graphically:
The 3-D Coordinate System

Now, we have to define 
points in 3­dimensions. 

e  xy­plane 
a n
l
z ­p
y

xz­plane 

Session 9 : 9/25  4
Points in 3 Dimensions


(1,3,3) 2 
­4 
1  ­3  (4,0,­3) 
­2 

­3  ­2  1  2  3  4 


2  ­1
(0,0,4)  3 
4  ­2
z  ­3 

Session 9 : 9/25  5
Distance and Midpoint Formulas

The distance between points (x 1 , y 1 , z 1 ) and (x 2 , y 2 , z 2 ) 
2  2  2 
d =  ( x 2  - x 1 )  + ( y 2  - y 1 )  + ( z 2  - z 1 ) 

The midpoint between points (x 1 , y 1 , z 1 ) and (x 2 , y 2 , z 2 ) 
æ x 1  + x 2  y 1  + y 2  z 1  + z 2  ö
M  = ç ,  ,  ÷
è 2  2  2  ø
Session 9 : 9/25  6
Equation of a Sphere
p  For a sphere centered at (h,k,l) with radius r, the 
equation of the sphere is: 
( x - h ) 2  + ( y - k ) 2  + ( z - l ) 2  = r 2 
Example: What is the equation of a sphere centered at (1,3,3) 
with radius 2?  y 

( x - 1 ) 2  + ( y - 3 ) 2  + ( z - 3 ) 2  = 2 2 

Session 9 : 9/25  7
Functions of Several Variables
p  Multivariable functions are evaluated by the same process 
as single variable function 
p  Example: 
f ( x , y ) = 3 x 2 + 2 y , evaluated at ( 2,­1) 

f ( 2 , -1 ) = 3 ( 2 ) 2  + 2 ( -1 ) 


80 
60 
f ( 2 , -1 ) = 12 - 2 = 10  f(x)40  4 
20 



­2  x 
­2 

Session 9 : 9/25  y  ­4  8


Examples: 


f ( x , y , z ) = - x + 3 y  + 2 z  evaluated at (1,­1,4) 

2  3 
G ( a , T ) = a  - evaluated at (3,1) 

Session 9 : 9/25  9
Monthly Payments 
Monthly payment M for an installment loan P (in dollars) taken 
out over t years at annual interest rate of r is given by: 
P × r 
M  = f ( P , r , t ) = 12 
12 t 
é 1  ù
1 - ê ú
ê1 + ( r  ) ú
ë 12  û
What would your monthly payment have to be for a car loan of 
$15,000 over 6 years at an annual interest rate of 3.9% 
Plug in t = 6, P = 15000, and r = 0.039 

15000 × 0 . 039 
M =  f ( 15000 , 0 . 039 , 6 ) = 12  = $ 233 . 99 
12 ( 6 ) 
é 1  ù
1 - ê ú
ê1 + ( 0 . 039  ) ú
ë 12  û
Session 9 : 9/25  10
Partial Derivatives: Derivatives when you
have more than one dependent variable 

Partial differential of z with respect to x 

¶z  f ( x + Dx ) - f ( x , y )  Treat y as a constant, 


= lim  differentiate with 
¶x  D x ®0  Dx  respect to x 

Partial differential of z with respect to y

¶z  f ( x , y + Dy ) - f ( x , y )  Treat x as a constant, 


= lim  only differentiate with 
¶y  Dy ®0  Dy  respect to y 

Session 9 : 9/25  11
Notation:
p  For f(x,y), the partial derivative with respect to 
x can be written as:
¶f  ¶
= f x ( x , y ) = f x  = [ f ( x , y ) ] 
¶x  ¶x 
p  For f(x,y), the partial derivative with respect to 
y can be written as:

¶f  ¶
= f y ( x , y ) = f y  = [ f ( x , y ) ] 
¶y  ¶y 

Session 9 : 9/25  12
What does a partial differential mean graphically?

p  If we take the partial with respect to x, then we 
can find the slope in the x­direction at that point. 

p  If we take the partial with respect to y, we can 
find the slope in the x­direction at that point.

Session 9 : 9/25  13
Examples
¶ z ¶z 
and 
p  Find                  of: 
¶x  ¶y 

2 2 
A)  z = 2 x  - xy + 3 y  + 1 


B) z = 2 - 3 y + x + 4 x 

Session 9 : 9/25  14
What does the partial derivative mean
graphically? 
¶ Evaluated at a point in a 3­D coordinate system gives 
you the slope in the x­direction at that point 
¶x

¶ Evaluated at a point in a 3­D coordinate system gives 
you the slope in the y­direction at that point
¶y

Session 9 : 9/25  15
Graphically:

Slope in y­direction

Slope in x­direction 

Session 9 : 9/25  16
Extrema of multivariable functions
Recall that we could find extrema (minimum/maximum) of a 
function in two dimensions by finding where the derivative with 
respect to x is 0. 

For multivariable functions (i.e. f(x,y)), the maxima and minima 
occur when the slope in both x­ and y­directions are 0. 

Mathematically, the point (x o ,y 0 ) is a minimum or maximum of f(x,y) if 
¶ f  ¶f 
=0 and  = 0 
¶x  ¶y 
when evaluated at (x 0 ,y 0 )
Session 9 : 9/25  17
Example:
p  Find the relative extrema (critical point) of: 

2 2 
f ( x , y ) = 2 x  + y  + 8 x - 6 y + 20 

600 
400 
200  10 


­10  0 
­5 

Session 9 : 9/25 
­10  18

5
10 
How do we know if maximum or minimum?
“Second Partials Test for Relative Extrema” 
If you have determined an extrema at (a,b,f(a,b)), then find d by: 

[
d  = f xx ( a , b ) f yy ( a , b ) - f xy ( a , b )  ]  2 

Then, use the following principles to determine if 
f(a,b) is at a minimum, maximum or neither 

1.  f ( a , b )  is a relative minimum if  d  > 0 and  f xx ( a , b ) > 0 


2 .  f ( a , b )  is a relative maximum if  d  > 0 and  f xx ( a , b ) < 0 
3 .  ( a , b ,  f ( a , b )) is a saddle point if  d  < 0 
4 .  If  d  = 0  you can' t determine 

Session 9 : 9/25  19
Using Mathematica: Quick Tutorial

Questions: 

1.  How can I solve for the zeroes of 2x 2  +5x +2? 


2.  How can I find the derivative of f(x)=3x 2 (x 4 ­2)(x+1) 
3.  How can I plot the graph of f(x,y)=3x 2 ­2y? 
4.  How can I find the integral of f(x)=2x/(x 2 +4)

Session 9 : 9/25  20
In MatLab:
p  Solving Solutions: 
n  Solve[f(x)==a] 

p  Finding Derivatives: 
n  f[x_]:=Your function of x 
p  f’[z]  evaluates the derivative of f[x] at z 

p  Plotting in three dimensions: 
n  Plot3D[f(x),{x,a,b},{y,a,b}] 

p  Integration: 
n  Integrate[f(x),{x,xmin,xmax}]

Session 9 : 9/25  21
Tomorrow:

p  Trigonometric Functions, their derivatives 
and integrals

Session 9 : 9/25  22

Anda mungkin juga menyukai