Docsity
Docsity

Prepara tus exámenes
Prepara tus exámenes

Prepara tus exámenes y mejora tus resultados gracias a la gran cantidad de recursos disponibles en Docsity


Consigue puntos base para descargar
Consigue puntos base para descargar

Gana puntos ayudando a otros estudiantes o consíguelos activando un Plan Premium


Orientación Universidad
Orientación Universidad


soluciones problemas tema 4, Ejercicios de Matemáticas

soluciones de los problemas tema 4

Tipo: Ejercicios

2022/2023

Subido el 18/05/2023

Laiacastel
Laiacastel 🇪🇸

2 documentos

1 / 14

Toggle sidebar

Esta página no es visible en la vista previa

¡No te pierdas las partes importantes!

bg1
Mathematics II
Bachelor in Economics
Bachelor in Business Administration
Problem Set 4: Partial derivatives
Solutions.
Departament d’Economia i d’Hist`
oria Econ`
omica
1
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe

Vista previa parcial del texto

¡Descarga soluciones problemas tema 4 y más Ejercicios en PDF de Matemáticas solo en Docsity!

Mathematics II

Bachelor in Economics

Bachelor in Business Administration

Problem Set 4: Partial derivatives

Solutions.

Departament d’Economia i d’Historia Economica

  1. Compute the partial derivatives with respect to x and y for the following functions, and evaluate the partial derivatives at the indicated points:

(a) f (x, y) = x^2 + y^2 , p = (1. 5 , 0 .5) ∂f (x, y)/∂x = 2x ∂f (x, y)/∂x|p = 2 · 1 .5 = 3 ∂f (x, y)/∂y = 2y ∂f (x, y)/∂y|p = 2 · 0 .5 = 1

(b) f (x, y) = ln x − y^2 , p = (3, 1 .1) ∂f (x, y)/∂x = 1/x ∂f (x, y)/∂x|p = 1/ 3 ∂f (x, y)/∂y = − 2 y ∂f (x, y)/∂y|p = − 2 · 1 .1 = − 2. 2

(c) f (x, y) = exp x/y, p = (6, 4) For this one, we need to use the chain rule. ∂f (x, y)/∂x = exp(x/y)(1/y) ∂f (x, y)/∂x|p = exp(6/4)(1/4) = 14 exp(^32 ) ∂f (x, y)/∂y = exp(x/y)(− (^) yx 2 ) ∂f (x, y)/∂y|p = exp^64 (− 166 ) = −^38 exp(^32 )

  1. Compute the gradient vectors and Hessian matrix for the following functions.

(a) f (x, y, z, t) = xyz^2 + t^2

∇f (x, y, z, t) =

yz^2 xz^2 2 xyz 2 t

,^ H(x, y, z, t) =

0 z^2 2 yz 0 z^2 0 2 xz 0 2 yz 2 xz 2 xy 0 0 0 0 2

(b) f (x, y) = x^2 + 10y ∇f (x, y) =

[

2 x 10

]

, H(x, y) =

[

]

(c) f (x, y, z) = y + ln(xyz)

∇f (x, y, z, t) =

1 x 1 + (^1) y 1 z

, H(x, y, z, t) =

− 1 x^2 0 0 − y 21 0 0 0 − z 21

(d) f (x, y) = x^2 + y^2 ∇f (x, y) =

[

2 x 2 y

]

, H(x, y) =

[

]

The green circle is the level set for f (x, y) = 20, and the blue circle is the level set for f (x, y) = 10. So, point A is on the green level set, and point B is on the blue level set. The gradient vectors ∇f (A) = (4, 8) and ∇f (B) = (6, 2) at the two points are also plotted. The gradients point in the direction of increase of the function. We see that if we are at point B, the gradient points in the direction of the higher level set. If we are at point A, the gradient points away from the lower level set. To answer part b): Given the two level sets, then we know that the gradient vectors point in the direction of most rapid increases, and are orthogonal to the tangent to the level set. So, at point A,we know that both partial derivatives must be positive.

  1. Repeat problem 4 for the function g(x, y) = x + y.

Two level sets are shown, with the blue corresponding to a higher value of the function. The gradient vector is ∇f (x, y) = (1, 1) at both points. If we’re at point B,the gradient points toward the higher level set. If we’re at point A,the gradient points away from the lower level set. Note that the level sets can be written as k = y + x, so y = k − x. Thus, a level set can be represented as the collection of points (x, y) such that

[

x y

]

[

k

]

  • t

[

]

. The vector

v =

[

]

is the direction vector of the line that is the level set. Note that v is orthogonal to ∇f (x, y) : (1, 1) · (1, −1) = 0. So, we confirm that the gradient vector is orthogonal to the direction vector of the tangent line to the level set (which in this case coincides with the level set, because the level sets are straight lines).

  1. Compute the directional derivatives of the functions at the points p in the direction of the vectors v:

(a) f (x, y) = x^2 − y^2 , p = (1, 1), v = (1, −1) (b) f (x, y, z) = xyz, p = (1, 1 , 0), v = (1, − 1 , 0) Solution

Denote by f (^) u′(x 0 ) the directional derivative of f at the point x 0 ∈

  1. Consider the function f (x, y) = xy. Calculate the gradient vector at the points (1, 1) and (− 1 , −1). Show graphically that they have that property of being perpendicular at the tangent lines of the function at the corresponding point and they point in the direction of maximum increase of the function.

Solution Geogebra code for this problem is at https://www.geogebra.org/graphing/pwnn4ttw

Consider the point (1, 1)

  • Gradient vector of f at point (1, 1):

[∇f (1, 1)]T^ =

∂f (1, 1) ∂x

∂f (1, 1) ∂y

= (y, x)(1,1) = (1, 1)

In the graph this is the black vector from the origin to point A.

  • The equation of the tangent line to the level curve passing through the point (1, 1) is:

y − 1 =

∂f (1, 1) ∂x ∂f (1, 1) ∂y

 (x^ −^ 1)^ ⇔^ y^ −^ 1 = (−1) (x^ −^ 1)^ ⇔^ x^ +^ y^ −^ 2 = 0

In the graph this is the blue line in the first quadrant.

  • Directing vector of the previous tangent line is (1, −1) [ax + by + c = 0 has as a directing vector (b, −a)]
  • Since the scalar product

[∇f (1, 1)]T^ · (1, −1) = (1, 1) · (1, −1) = 0

it follows that they are orthogonal. Therefore, the gradient is perpendicular to the line tangent to the level curve of the function f at the point (1, 1)

  • The level curve passing by (1, 1) is xy = 1 because f (1, 1) = 1. This is the green line in quadrant 1.

Now, consider the point (− 1 , −1)

  • Gradient vector of f at the point (− 1 , −1):

[∇f (− 1 , −1)]T^ =

∂f (− 1 , −1) ∂x

∂f (− 1 , −1) ∂y

= (y, x)(− 1 ,−1) = (− 1 , −1)

In the graph this is the vector from the origin to point

  • The equation of the tangent line to the level curve passing through the point (− 1 , −1) is

y + 1 =

∂f (− 1 , −1) ∂x ∂f (− 1 , −1) ∂y

 (x^ + 1)^ ⇔^ y^ + 1 = (−1) (x^ + 1)^ ⇔^ x^ +^ y^ + 2 = 0

In the graph this is the black vector from the origin to point B.

  • Directing vector of the previous tangent line is (1, −1) [ax + by + c = 0 has as a directing vector (b, −a)]
  • Since the scalar product

[∇f (− 1 , −1)]T^ · (1, −1) = (− 1 , −1) · (1, −1) = 0

it follows that they are orthogonal. Therefore, the gradient is perpendicular to the line tangent to the level curve of the function f at the point (− 1 , −1)

  • Level curve passing by (− 1 , −1) is xy = 1 because f (1, 1) = 1. This is the green line in quadrant 3.

In general, graphically (with computers!) we are able to see that the gradient vector ∇f (x, y) is perpendicular to the tangent line of the level curve f (x, y) = k.

(a) The direction of the gradient ∇f tells us the direction of greatest increase:

∇f (2, 3) =

( (^) y

1 + xy

x 1 + xy

To obtain the direction of steepest descent we need to find the direction of −∇f :

−∇f (2, 3) =

This vector has length

‖ − ∇f (2, 3)‖ =

To obtain the unit vector, we divide the gradient by its length, so that

u =

is the unit vector in the direction of steepest descent. (b) The direction of no change is a unit vector orthogonal to u. Note that the unit vectors orthogonal to a generic unit vector (a, b) are (−b, a) and (b. − a). Hence, in our case, the direction of no change at the point (2, 3) is

v =

  1. Calculate the tangent planes of the following functions at the indicated points

(a) f (x, y) = x^2 + y^2 , p = (1, 1) (b) f (x, y) = ln x − y^2 , p = (e, 1) (c) f (x, y) = x + y, p = (0, 0) Solution

The equation of the tangent to z = f (x, y) at the point p = (x 0 , y 0 ,z 0 ) where z 0 = f (x 0 , y 0 ) is given by: z − z 0 =

[

∂f ∂x

(x 0 , y 0 )

]

(x − x 0 ) +

[

∂f ∂y

(x 0 , y 0 )

]

(y − y 0 )

(a) f (x, y) = x^2 + y^2 , p = (1, 1) z = x^2 + y^2 , P = (1, 1 , f (1, 1)) = (1, 1 , 2)

z − 2 =

[

∂f ∂x

]

(x − 1) +

[

∂f ∂y

]

(y − 1)

z − 2 = 2x (x − 1) + 2y (y − 1) z − 2 = 2 (x − 1) + 2(y − 1) z = 2x + 2y − 2 See the geogebra code https://www.geogebra.org/3d/exrfkn9d. This gives us the following plot, where we see that the blue plane is tangent to the function f (x, y) (in red) at the point P = (1, 1 , 2).

(b) f (x, y) = ln x − y^2 , p = (e, 1)

z = ln x − y^2 , P = (e, 1 , f (e, 1)) = (e, 1 , 0)

z − 0 =

[

∂f ∂x

(e, 1)

]

(x − e) +

[

∂f ∂y

(e, 1)

]

(y − 1)

z =

[

x

]

(e,1)

(x − e) + − 2 y (y − 1)

z =

e

(x − 1) − 2(y − 1)

z =

e

x − 2 y + 1

If you like, use geogebra to make a plot similar to that of part a).

  1. Let f (x) = ex^ and g(x) = 3x^2 + 2. Define h(x) = f (g(x)). Compute h′(x) using the Chain rule.

Solution Recall the chain rule: h′(x) = f ′(g(x))g′(x). Start by computing the derivatives of f and g:

f ′(x) = ex, g′(x) = 6x

so that h′(x) = f ′(3x^2 + 2)(6x) = 6xe^3 x (^2) +

  1. Compute the derivatives of the following functions

(a) f (x) = 6ex (^4) +x 2

(b) f (x) = ln(x^2 + 1)

Solution

(a) The function f is the composition of two functions:

g(x) = 6ez^ , and h(x) = x^4 + x^2

so that we can write f (x) = g(h(x)). The derivatives of functions g and h are

g′(z) = 6ez^ , h′(x) = 4x^3 + 2x

so that applying the chain rule,

f ′(x) = g′(h(x))h′(x) = g′(x^4 + x^2 )(4x^3 + 2x) = 6ex (^4) +x 2 (4x^3 + 2x) = 12(2x^3 + x)ex (^4) +x 2

(b) Define p(z) = ln(z) and q(x) = x^2 + 1. Then,

p′(z) =

z

and q′(x) = 2x

so that g′(x) = p′(q(x))q′(x) =

x^2 + 1

(2x) =

2 x x^2 + 1

  1. Consider a factory that produces chairs using a technology described by the following produc- tion function f (x, y) = 200

6 x^2 + y^2 where x denotes units of labor and y units of capital. Presently, the factory is using 10 units of labor and 5 units of capital. Estimate the change in production associated to increasing capital in one unit and decreasing labor in half a unit by using a linear approximation.

Solution Let z ≡ f (x, y). The impact on the production level can be computed using the linear approxi- mation to the function f (x, y) around the point (10, 5). In general, the linear approximation to a function f (x, y) around a point (a, b) is given by

f (x, y) ' f (x, y)

(a,b)

  • ∂f /∂x

(a,b)

(x − a) + ∂f /∂y

∣(y − b)

Using the chain rule,

∂f /∂x = 200

12 x √ 6 x^2 + y^2

1200 x √ 6 x^2 + y^2

∂f /∂y = 200

2 y √ 6 x^2 + y^2

200 y √ 6 x^2 + y^2

and evaluating these expressions at the point (a, b) = (10, 5), we have

∂f /∂x = 480, and ∂f /∂y = 40

Therefore, the approximate value of the production at the point (x, y) = (9. 5 , 6) is

f (9. 5 , 6) ' f (x, y)|(10,5) + ∂f /∂x|(10,5)(9. 5 − 10) + ∂f /∂x|(10,5)(6 − 5) = = f (x, y)|(10,5) + 480(− 0 .5) + 40(1) = f (x, y)|(10,5) − 200

so that production would decrease by 200 units.