Linear Algebra : Matrix Calculus

Study concepts, example questions & explanations for Linear Algebra

varsity tutors app store varsity tutors android store

Example Questions

Example Question #21 : The Hessian

\(\displaystyle f(x,y)= x^{2} - 3xy - y^{2}\)

Use the Hessian matrix \(\displaystyle H(f)\), if applicable, to answer this question:

Does the graph of \(\displaystyle f\) have a local maximum, a local minimum, or a saddle point at \(\displaystyle (0,0)\)?

Possible Answers:

The graph of \(\displaystyle f\) has a local minimum at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a local maximum at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\), but the Hessian matrix test is inconclusive. 

The graph of \(\displaystyle f\) does not have a critical point at \(\displaystyle (0,0)\)

The graph of \(\displaystyle f\) has a saddle point at \(\displaystyle (0,0)\).

Correct answer:

The graph of \(\displaystyle f\) has a saddle point at \(\displaystyle (0,0)\).

Explanation:

First, it must be established that the graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\); this holds if \(\displaystyle f_{x}(0,0) = f_{y}(0,0) = 0\), so the first partial derivatives of \(\displaystyle f\) must be evaluated at \(\displaystyle (0,0)\):

\(\displaystyle f(x,y)= x^{2} - 3xy - y^{2}\)

\(\displaystyle f_{x}(x,y)= 2x - 3y\)

\(\displaystyle f_{x}(0,0)= 2(0) - 3(0) = 0\)

\(\displaystyle f_{y}(x,y)= - 3x- 2y\)

\(\displaystyle f_{y}(0,0)= - 3(0) -2(0) = 0\)

 

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\), so the Hessian matrix test applies.

The Hessian matrix \(\displaystyle H(f)\) is the matrix of partial second derivatives

\(\displaystyle \begin{bmatrix} f_{xx} & f_{xy} \\ f_{yx} & f_{yy} \end{bmatrix}\),

the determinant of which can be used to determine whether a critical point of \(\displaystyle f\) is a local maximum, a local minimum, or a saddle point. Find the partial second derivatives of \(\displaystyle f\):

\(\displaystyle f_{x}(x,y)= 2x - 3y\)

\(\displaystyle f_{xx}(x,y)= 2\)

\(\displaystyle f_{xy}(x,y)= -3\)

 

\(\displaystyle f_{y}(x,y)= - 3x- 2y\)

\(\displaystyle f_{yx}(x,y)= - 3\)

\(\displaystyle f_{y}(x,y)= - 2\)

All four partial second derivatives are constant; the Hessian matrix at \(\displaystyle (0,0)\) is 

\(\displaystyle \begin{bmatrix} 2 & - 3 \\ -3 & -2 \end{bmatrix}\)

Its determinant is the upper-left to lower-right product minus the upper-right to lower-left product:

\(\displaystyle \begin{vmatrix} 2 & - 3 \\ -3 & -2 \end{vmatrix} = 2(-2) - (-3)(-3) = -13\)

The determinant of the Hessian is negative, so the graph of \(\displaystyle f\) has a saddle point at \(\displaystyle (0,0)\).

Example Question #21 : The Hessian

\(\displaystyle f(x,y)= e^{x} y^{2}\)

Use the Hessian matrix \(\displaystyle H(f)\), if applicable, to answer this question:

Does the graph of \(\displaystyle f\) have a local maximum, a local minimum, or a saddle point at \(\displaystyle (0,0)\)?

Possible Answers:

The graph of \(\displaystyle f\) has a local minimum at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a local maximum at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\), but the Hessian matrix test is inconclusive. 

The graph of \(\displaystyle f\) has a saddle point at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) does not have a critical point at \(\displaystyle (0,0)\)

Correct answer:

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\), but the Hessian matrix test is inconclusive. 

Explanation:

First, it must be established that the graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\); this holds if \(\displaystyle f_{x}(0,0) = f_{y}(0,0) = 0\), so the first partial derivatives of \(\displaystyle f\) must be evaluated at \(\displaystyle (0,0)\):

\(\displaystyle f(x,y)= e^{x} y^{2}\)

\(\displaystyle f_{x}(x,y)= e^{x} y^{2}\)

\(\displaystyle f_{x}(0,0)= e^{0}\cdot 0^{2} = 0\)

 

\(\displaystyle f_{y}(x,y)= 2e^{x} y\)

\(\displaystyle f_{y}(0,0) = 2e^{0} \cdot 0 = 0\)

 

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\), so the Hessian matrix test applies.

The Hessian matrix \(\displaystyle H(f)\) is the matrix of partial second derivatives

\(\displaystyle \begin{bmatrix} f_{xx} & f_{xy} \\ f_{yx} & f_{yy} \end{bmatrix}\),

the determinant of which can be used to determine whether a critical point of \(\displaystyle f\) is a local maximum, a local minimum, or a saddle point. Find the partial second derivatives of \(\displaystyle f\):

\(\displaystyle f_{xx}(x,y)= e^{x} y^{2}\)

\(\displaystyle f_{xx}(0,0)= e^{0} \cdot 0^{2} = 0\)

 

\(\displaystyle f_{xy}(x,y)= 2 e^{x} y\)

\(\displaystyle f_{xy}(0,0)= 2 e^{0} \cdot 0 = 0\)

 

\(\displaystyle f_{yx}(x,y)= 2e^{x} y\)

\(\displaystyle f_{yx}(0,0)= 2 e^{0} \cdot 0 = 0\)

 

\(\displaystyle f_{yy}(x,y)= 2e^{x}\)

\(\displaystyle f_{yy}(0,0)= 2 e^{0} = 2\)

 

The Hessian matrix at \(\displaystyle (0,0)\) is 

\(\displaystyle \begin{bmatrix}0 & 0 \\0 & 2 \end{bmatrix}\)

Its determinant is the upper-left to lower-right product minus the upper-right to lower-left product:

\(\displaystyle \begin{vmatrix}0 & 0 \\0 & 2 \end{vmatrix} = 0(2) - 0(0) = 0\)

Since the determinant of the Hessian is 0, the Hessian matrix test is inconclusive.

Example Question #21 : The Hessian

\(\displaystyle f(x,y) = \cos ^{2}x \cos y\)

Use the Hessian matrix \(\displaystyle H(f)\), if applicable, to answer this question:

Does the graph of \(\displaystyle f\) have a local maximum, a local minimum, or a saddle point at \(\displaystyle (0,0)\)?

Possible Answers:

The graph of \(\displaystyle f\) has a local minimum at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) does not have a critical point at \(\displaystyle (0,0)\)

The graph of \(\displaystyle f\) has a local maximum at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\), but the Hessian matrix test is inconclusive. 

The graph of \(\displaystyle f\) has a saddle point at \(\displaystyle (0,0)\).

Correct answer:

The graph of \(\displaystyle f\) has a local maximum at \(\displaystyle (0,0)\).

Explanation:

First, it must be established that the graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\); this holds if \(\displaystyle f_{x}(0,0) = f_{y}(0,0) = 0\), so the first partial derivatives of \(\displaystyle f\) must be evaluated at \(\displaystyle (0,0)\):

\(\displaystyle f(x,y) = \cos ^{2}x \cos y\)

\(\displaystyle f_{x}(x,y) =- 2 \sin x \cos x \cos y\)

\(\displaystyle f_{x}(0,0) =- 2 \sin 0 \cos 0 \cos 0 = -2(0)(1)(1)= 0\)

\(\displaystyle f_{y}(x,y) = - \cos ^{2}x \sin y\)

\(\displaystyle f_{y}(0,0) = - \cos ^{2}0 \sin 0 = -(1^{2}) (0)= 0\)

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\), so the Hessian matrix test applies.

The Hessian matrix \(\displaystyle H(f)\) is the matrix of partial second derivatives

\(\displaystyle \begin{bmatrix} f_{xx} & f_{xy} \\ f_{yx} & f_{yy} \end{bmatrix}\),

the determinant of which can be used to determine whether a critical point of \(\displaystyle f\) is a local maximum, a local minimum, or a saddle point. Find the partial second derivatives of \(\displaystyle f\):

\(\displaystyle f_{xx}(x,y) =- 2[ (\sin x) (-\sin x) +( \cos x )(\cos x) ] \cos y\)

\(\displaystyle =- 2 ( \cos ^{2}x- \sin ^{2}x )\cos y\)

\(\displaystyle f(0,0)=- 2 ( \cos ^{2}0- \sin ^{2}0 )\cos 0 = -2(1^{2}-0^{2}) (1) = -2\)

 

\(\displaystyle f_{xy}(x,y) = 2 \sin x \cos x \sin y\)

\(\displaystyle f_{xy}(0,0) = 2 \sin 0 \cos 0 \sin 0 = 2 (0)(1)(0 ) = 0\)

 

\(\displaystyle f_{yx}(x,y) = 2 \sin x \cos x \sin y\)

\(\displaystyle f_{yx}(0,0) = 2 \sin 0 \cos 0 \sin 0 = 2 (0)(1)(0 ) = 0\)

 

\(\displaystyle f_{yy}(x,y) = - \cos ^{2}x \cos y\)

\(\displaystyle f_{yy}(0,0) = - \cos ^{2}0 \cos 0 = -( 1^{2}) (1 ) = -1\)

 

The Hessian matrix at \(\displaystyle (0,0)\) is 

\(\displaystyle \begin{bmatrix} -2 & 0 \\ 0 & -1 \end{bmatrix}\)

Its determinant is the upper-left to lower-right product minus the upper-right to lower-left product:

\(\displaystyle \begin{vmatrix} -2 & 0 \\ 0 & -1 \end{vmatrix} = (-2)(-1) - (0)(0) = 2\)

The determinant is positive, making \(\displaystyle (0,0)\) a local extremum. Since \(\displaystyle f_{xx}(0,0)\) is negative, \(\displaystyle (0,0)\) is a local maximum. 

Example Question #21 : The Hessian

\(\displaystyle f(x,y) = (x-y+ 2)^{2}\)

Use the Hessian matrix \(\displaystyle H(f)\), if applicable, to answer this question:

Does the graph of \(\displaystyle f\) have a local maximum, a local minimum, or a saddle point at \(\displaystyle (-1,1)\)?

Possible Answers:

The graph of \(\displaystyle f\) has a local minimum at \(\displaystyle (-1,1)\).

The graph of \(\displaystyle f\) has a saddle point at \(\displaystyle (-1,1)\).

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (-1,1)\), but the Hessian matrix test is inconclusive. 

The graph of \(\displaystyle f\) has a local maximum at \(\displaystyle (-1,1)\).

The graph of \(\displaystyle f\) does not have a critical point at \(\displaystyle (-1,1)\)

Correct answer:

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (-1,1)\), but the Hessian matrix test is inconclusive. 

Explanation:

First, it must be established that the graph of \(\displaystyle f\) has a critical point at \(\displaystyle (-1,1)\); this holds if \(\displaystyle f_{x}(-1,1)= f_{y}(-1,1) = 0\), so the first partial derivatives of \(\displaystyle f\) must be evaluated at \(\displaystyle (-1,1)\):

\(\displaystyle f(x,y) = (x-y+ 2)^{2}\)

\(\displaystyle f_{x}(x,y) = 2 (x-y+ 2 ) = 2x-2y + 4\)

\(\displaystyle f_{x}(-1, 1) = 2(-1)-2(1) + 4= 0\)

 

\(\displaystyle f_{y}(x,y) = -2(x-y+ 2) = -2x+2y - 4\)

\(\displaystyle f_{y}(-1, 1) = -2(-1)+2(1) - 4= 0\)

 

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (-1,1)\), so the Hessian matrix test applies.

The Hessian matrix \(\displaystyle H(f)\) is the matrix of partial second derivatives

\(\displaystyle \begin{bmatrix} f_{xx} & f_{xy} \\ f_{yx} & f_{yy} \end{bmatrix}\),

the determinant of which can be used to determine whether a critical point of \(\displaystyle f\) is a local maximum, a local minimum, or a saddle point. Find the partial second derivatives of \(\displaystyle f\):

\(\displaystyle f_{x}(x,y) = 2x-2y + 4\)

\(\displaystyle f_{xx}(x,y) = 2\)

\(\displaystyle f_{xy}(x,y) =-2\)

 

\(\displaystyle f_{y}(x,y) = -2x+2y - 4\)

\(\displaystyle f_{yx}(x,y) =-2\)

\(\displaystyle f_{yy}(x,y) =2\)

 

All four partial second derivatives are constants. The Hessian matrix at any point, including \(\displaystyle (-1,1)\), is

\(\displaystyle \begin{bmatrix} 2 & -2 \\ -2 & 2 \end{bmatrix}\);

Its determinant is the upper-left to lower-right product minus the upper-right to lower-left product:

\(\displaystyle \begin{vmatrix} 2 & -2 \\ -2 & 2 \end{vmatrix} = 2(2)- (-2)(-2) = 0\)

Since the determinant of the Hessian is 0, the Hessian matrix test is inconclusive.

Example Question #22 : The Hessian

Consider the function \(\displaystyle f(x, y) = 2x \cos y -x^{2}\).

Determine whether the graph of the function has a critical point at \(\displaystyle (1,0)\); if so, use the Hessian matrix \(\displaystyle H(f)\) to identify \(\displaystyle (1,0)\) as a local maximum, a local minimum, or a saddle point.

Possible Answers:

The graph of \(\displaystyle f\) has a local minimum at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a local maximum at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) does not have a critical point at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a saddle point at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\), but the Hessian matrix test is inconclusive.

Correct answer:

The graph of \(\displaystyle f\) has a local maximum at \(\displaystyle (0,0)\).

Explanation:

First, it must be established that \(\displaystyle (1,0)\) is a critical point of the graph of \(\displaystyle f\); this holds if and only if both first partial derivatives are equal to 0 at this point. Find the partial derivatives and evaluate them at \(\displaystyle (1,0)\):

\(\displaystyle f(x, y) = 2x \cos y -x^{2}\)

 

\(\displaystyle f_{x}(x, y) = 2 \cos y -2x\)

\(\displaystyle f_{x}(1,0) = 2 \cos 0 -2(1)= 2(1)-2(1) = 0\)

 

\(\displaystyle f_{y}(x, y) =- 2x \sin y\)

\(\displaystyle f_{y}(1,0) =- 2(1) \sin 0 = -2(1)(0)= 0\)

 

Thus, the graph of \(\displaystyle f\) has a critical point at \(\displaystyle (1,0)\).

 

The Hessian matrix is the matrix of partial second derivatives

\(\displaystyle H(f)=\begin{bmatrix} f_{xx}(x,y) & f_{xy}(x,y) \\ f_{yx}(x,y) & f_{yy}(x,y) \end{bmatrix}\);

Find these derivatives and evaluate them at \(\displaystyle (1,0)\):

 

\(\displaystyle f_{x}(x, y) = 2 \cos y -2x\)

\(\displaystyle f_{xx}(x, y) = -2\)

\(\displaystyle f_{xx}(1,0) = -2\)

\(\displaystyle f_{xy}(x, y) =- 2 \sin y\)

\(\displaystyle f_{xy}(1,0 ) =- 2 \sin 0 = -2 (0) = 0\)

 

\(\displaystyle f_{y}(x, y) =- 2x \sin y\)

\(\displaystyle f_{yx}(x, y) =- 2 \sin y\)

\(\displaystyle f_{yx}(1,0 ) =- 2 \sin 0 = -2 (0) = 0\)

\(\displaystyle f_{yy}(x, y) =- 2x \cos y\)

\(\displaystyle f_{yy}(1,0) =- 2 (1) \cos 0 = -2 (1)(1) = -2\)

 

At \(\displaystyle (1,0)\), the Hessian matrix is

\(\displaystyle H(f)=\begin{bmatrix} -2 & 0 \\ 0 & -2 \end{bmatrix}\)

The determinant of this matrix is \(\displaystyle \det H(f) = -2(-2)- 0(0) = 4\)

Since the determinant of the Hessian matrix is positive, the graph of \(\displaystyle f\) has a local extremum at \(\displaystyle (1,0)\); since \(\displaystyle f_{xx}(1,0) = -2\), a negative value, it is a local maximum.

Example Question #21 : The Hessian

Consider the function \(\displaystyle f(x, y) = 2x \cos y - 2x\).

Determine whether the graph of the function has a critical point at \(\displaystyle (0,0)\); if so, use the Hessian matrix \(\displaystyle H(f)\) to identify \(\displaystyle (0,0)\) as a local maximum, a local minimum, or a saddle point.

Possible Answers:

The graph of \(\displaystyle f\) has a local maximum at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a local minimum at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a saddle point at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) does not have a critical point at \(\displaystyle (0,0)\).

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\), but the Hessian matrix test is inconclusive.

Correct answer:

The graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\), but the Hessian matrix test is inconclusive.

Explanation:

First, it must be established that \(\displaystyle (0,0)\) is a critical point of the graph of \(\displaystyle f\); this holds if and only if both first partial derivatives are equal to 0 at this point. Find the partial derivatives and evaluate them at \(\displaystyle (0,0)\):

\(\displaystyle f(x, y) = 2x \cos y - 2x\)

\(\displaystyle f_{x}(x,y) = 2 \cos y - 2\)

\(\displaystyle f_{x}(0,0) = 2 \cos 0 - 2 = 2(1)- 2 = 0\)

 

\(\displaystyle f_{y}(x, y) = -2x \sin y\)

\(\displaystyle f_{y}(0,0) = -2 (0) \sin 0=0\)

 

Thus, the graph of \(\displaystyle f\) has a critical point at \(\displaystyle (0,0)\).

 

The Hessian matrix is the matrix of partial second derivatives

\(\displaystyle H(f)=\begin{bmatrix} f_{xx}(x,y) & f_{xy}(x,y) \\ f_{yx}(x,y) & f_{yy}(x,y) \end{bmatrix}\);

Find these derivatives and evaluate them at \(\displaystyle (0,0)\):

 

\(\displaystyle f_{x}(x,y) = 2 \cos y - 2\)

\(\displaystyle f_{xx}(x,y) = 0\)

\(\displaystyle f_{xx}(0,0) = 0\)

\(\displaystyle f_{xy}(x,y) =- 2 \sin y\)

\(\displaystyle f_{xy}(0,0) =- 2 \sin 0 = -2(0)= 0\)

 

\(\displaystyle f_{y}(x, y) = -2x \sin y\)

\(\displaystyle f_{yx}(x, y) = -2 \sin y\)

\(\displaystyle f_{yx}(0,0) =- 2 \sin 0 = -2(0)= 0\)

\(\displaystyle f_{yy}(x, y) = -2x \cos y\)

\(\displaystyle f_{yy}(0,0) = -2 (0) \cos 0 = 0\)

 

The Hessian matrix, evaluated at \(\displaystyle (0,0)\), ends up being the matrix \(\displaystyle \begin{bmatrix} 0 & 0 \\ 0 & 0 \end{bmatrix}\). The determinant of the matrix is 0, which means that the Hessian matrix test is inconclusive.

Example Question #31 : The Hessian

Let \(\displaystyle f(x,y, z) = xy \cos z + xz \tan y\)

Which of the following does not appear in the Hessian matrix of \(\displaystyle f\)?

Possible Answers:

\(\displaystyle 2 xz \sec^{3} y\)

\(\displaystyle - x \sin z + x \sec^{2} y\)

\(\displaystyle \cos z + z \sec^{2} y\)

\(\displaystyle - xy \cos z\)

\(\displaystyle - y \sin z + \tan y\)

Correct answer:

\(\displaystyle 2 xz \sec^{3} y\)

Explanation:

The Hessian matrix of \(\displaystyle f\) is the matrix of partial second derivatives

\(\displaystyle H(f) = \begin{bmatrix} f_{xx} & f_{xy} & f_{xz} \\f_{yx} & f_{yy} & f_{yz} \\ f_{zx} & f_{zy} & f_{zz} \end{bmatrix}\)

To identify which choice does not give an entry of the matrix, we need to find all nine partial derivatives; however, since \(\displaystyle f_{yx}= f_{xy}\)\(\displaystyle f_{zx}= f_{xz}\), and \(\displaystyle f_{zy}= f_{yz}\), we need only find six such derivatives. They are as follows:

\(\displaystyle f(x,y, z) = xy \cos z + xz \tan y\)

\(\displaystyle f_{x}(x,y, z) = y \cos z + z \tan y\)

\(\displaystyle f_{xx}(x,y, z) =0\)

\(\displaystyle f_{xy}(x,y, z) = \cos z + z \sec^{2} y\)

\(\displaystyle f_{xz}(x,y, z) =- y \sin z + \tan y\)

 

\(\displaystyle f_{y}(x,y, z) = x \cos z + xz \sec^{2} y\)

\(\displaystyle f_{yy}(x,y, z) = 2 xz \tan y \sec^{2} y\)

\(\displaystyle f_{yz}(x,y, z) = - x \sin z + x \sec^{2} y\)

 

\(\displaystyle f_z(x,y, z) =- xy \sin z + x \tan y\)

\(\displaystyle f_{zz}(x,y, z) =- xy \cos z\)

 

Of the five given choices, only \(\displaystyle 2 xz \sec^{3} y\) is not one of the partial second derivatives. This is the correct choice.

Example Question #44 : Matrix Calculus

Let \(\displaystyle f(x, y) =2^{x}3^{y}\).

Find the Hessian matrix \(\displaystyle H(f)\).

Possible Answers:

\(\displaystyle 2^{x}3^{y} \begin{bmatrix} (\ln 2)^{2} &1 \\1& (\ln 3)^{2} \end{bmatrix}\)

\(\displaystyle 2^{x}3^{y} \begin{bmatrix} 1 & 0 \\ 0& 1 \end{bmatrix}\)

\(\displaystyle 2^{x}3^{y} \begin{bmatrix} 1& 1 \\ 1 & 1 \end{bmatrix}\)

\(\displaystyle 2^{x}3^{y} \begin{bmatrix} 1 &(\ln 2)(\ln 3) \\ (\ln 2)(\ln 3) & 1 \end{bmatrix}\)

\(\displaystyle 2^{x}3^{y} \begin{bmatrix} (\ln 2)^{2} &(\ln 2)(\ln 3) \\ (\ln 2)(\ln 3) & (\ln 3)^{2} \end{bmatrix}\)

Correct answer:

\(\displaystyle 2^{x}3^{y} \begin{bmatrix} (\ln 2)^{2} &(\ln 2)(\ln 3) \\ (\ln 2)(\ln 3) & (\ln 3)^{2} \end{bmatrix}\)

Explanation:

The Hessian matrix is the matrix of partial second derivatives

\(\displaystyle H(f)=\begin{bmatrix} f_{xx}(x,y) & f_{xy}(x,y) \\ f_{yx}(x,y) & f_{yy}(x,y) \end{bmatrix}\).

\(\displaystyle f(x, y) =2^{x}3^{y}\) can be rewritten as

\(\displaystyle f(x, y) =(e^{ \ln 2} )^{x}\cdot (e^{ \ln 3})^{y}\)

\(\displaystyle f(x, y) =e^{x \ln 2} \cdot e^{y \ln 3}\), then

\(\displaystyle f(x, y) =e^{x \ln 2+ y \ln 3}\)

This makes the partial second derivatives easier to find.

\(\displaystyle f_{x}(x, y) =(\ln 2) e^{x \ln 2+ y \ln 3}\)

\(\displaystyle f_{xx}(x, y) =(\ln 2) (\ln 2)e^{x \ln 2+ y \ln 3} = 2^{x}3^{y}(\ln 2)^{2}\)

\(\displaystyle f_{xy}(x, y) =(\ln 2) (\ln 3)e^{x \ln 2+ y \ln 3}= 2^{x}3^{y}(\ln 2)(\ln 3)\)

 

\(\displaystyle f_{y}(x, y) =(\ln 3) e^{x \ln 2+ y \ln 3}\)

\(\displaystyle f_{yx}(x, y) =(\ln 3) (\ln 2)e^{x \ln 2+ y \ln 3}= 2^{x}3^{y}(\ln 2)(\ln 3)\)

\(\displaystyle f_{yy}(x, y) =(\ln 3) (\ln 3)e^{x \ln 2+ y \ln 3}= 2^{x}3^{y}(\ln 3)^{2}\)

 

The Hessian matrix for \(\displaystyle f\) is

\(\displaystyle H(f)=\begin{bmatrix} 2^{x}3^{y}(\ln 2)^{2} & 2^{x}3^{y}(\ln 2)(\ln 3) \\ 2^{x}3^{y}(\ln 2)(\ln 3) & 2^{x}3^{y}(\ln 3)^{2} \end{bmatrix}\)

\(\displaystyle = 2^{x}3^{y} \begin{bmatrix} (\ln 2)^{2} &(\ln 2)(\ln 3) \\ (\ln 2)(\ln 3) & (\ln 3)^{2} \end{bmatrix}\)

Example Question #41 : Linear Algebra

Consider the function \(\displaystyle f(x, y, z ) = \cos x \sin y \tan z\).

Which of the following expressions does not appear twice in the Hessian matrix of \(\displaystyle f\)?

Possible Answers:

\(\displaystyle \cos x \cos y \sec^{2} z\)

\(\displaystyle 2 \cos x \sin y \tan z \sec^{2} z\)

\(\displaystyle - \cos x \sin y \tan z\)

\(\displaystyle - \sin x \sin y \sec^{2} z\)

\(\displaystyle - \sin x \cos y \tan z\)

Correct answer:

\(\displaystyle 2 \cos x \sin y \tan z \sec^{2} z\)

Explanation:

The Hessian matrix is the matrix of partial second derivatives

\(\displaystyle H(f)=\begin{bmatrix} f_{xx} & f_{xy} & f_{xz} \\ f_{yx} & f_{yy} & f_{yz} \\ f_{zx} & f_{zy} & f_{zz} \end{bmatrix}\).

Since \(\displaystyle f_{yx}= f_{xy} , f_{zx}= f_{xz} , f_{zy}= f_{yz}\), we only need to find six partial second derivatives and compare them to the five choices.

\(\displaystyle f = \cos x \sin y \tan z\)

\(\displaystyle f_{x} =- \sin x \sin y \tan z\)

\(\displaystyle f_{xx} =- \cos x \sin y \tan z\)

\(\displaystyle f_{xy} =- \sin x \cos y \tan z\)

\(\displaystyle f_{xz} =- \sin x \sin y \sec^{2} z\)

 

\(\displaystyle f_{y} = \cos x \cos y \tan z\)

\(\displaystyle f_{yy} = - \cos x \sin y \tan z\)

\(\displaystyle f_{yz} = \cos x \cos y \sec^{2} z\)

 

\(\displaystyle f_{z} = \cos x \sin y \sec^{2} z\)

\(\displaystyle f_{zz} =2 \cos x \sin y \tan z \sec^{2} z\)

As stated before,

\(\displaystyle f_{yx}= f_{xy} = - \sin x \cos y \tan z\)

\(\displaystyle f_{zx}= f_{xz} =- \sin x \sin y \sec^{2} z\)

\(\displaystyle f_{zy}= f_{yz} = \cos x \cos y \sec^{2} z\),

so all three expressions will appear twice in the Hessian matrix.

Also note that

\(\displaystyle f_{xx} = f_{yy} =- \cos x \sin y \tan z\),

so this expression appears twice as well.

\(\displaystyle f_{zz} =2 \cos x \sin y \tan z \sec^{2} z\),

however, only appears once. This is the correct choice.

Example Question #42 : Linear Algebra

\(\displaystyle \begin{align*}&\text{Find the matrix }Hf \text{ for }f(x,y,z)=13y^{2}tan(2x)tan(4z)\end{align*}\)

Possible Answers:

\(\displaystyle \begin{bmatrix}13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)&26ytan(2x)\cdot (4tan(4z)^{2} + 4)&104y^{2}tan(2x)tan(4z)\cdot (4tan(4z)^{2} + 4)\\26ytan(4z)\cdot (2tan(2x)^{2} + 2)&26tan(2x)tan(4z)&26ytan(2x)\cdot (4tan(4z)^{2} + 4)\\52y^{2}tan(2x)tan(4z)\cdot (2tan(2x)^{2} + 2)&26ytan(4z)\cdot (2tan(2x)^{2} + 2)&13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)\end{bmatrix}\)

\(\displaystyle \begin{bmatrix}52y^{2}tan(2x)tan(4z)\cdot (2tan(2x)^{2} + 2)&26ytan(4z)\cdot (2tan(2x)^{2} + 2)&13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)\\26ytan(4z)\cdot (2tan(2x)^{2} + 2)&26tan(2x)tan(4z)&26ytan(2x)\cdot (4tan(4z)^{2} + 4)\\13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)&26ytan(2x)\cdot (4tan(4z)^{2} + 4)&104y^{2}tan(2x)tan(4z)\cdot (4tan(4z)^{2} + 4)\end{bmatrix}\)

\(\displaystyle \begin{bmatrix}13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)&26ytan(4z)\cdot (2tan(2x)^{2} + 2)&52y^{2}tan(2x)tan(4z)\cdot (2tan(2x)^{2} + 2)\\26ytan(2x)\cdot (4tan(4z)^{2} + 4)&26tan(2x)tan(4z)&26ytan(4z)\cdot (2tan(2x)^{2} + 2)\\104y^{2}tan(2x)tan(4z)\cdot (4tan(4z)^{2} + 4)&26ytan(2x)\cdot (4tan(4z)^{2} + 4)&13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)\end{bmatrix}\)

\(\displaystyle \begin{bmatrix}26tan(2x)tan(4z)&26ytan(4z)\cdot (2tan(2x)^{2} + 2)&26ytan(2x)\cdot (4tan(4z)^{2} + 4)\\26ytan(4z)\cdot (2tan(2x)^{2} + 2)&52y^{2}tan(2x)tan(4z)\cdot (2tan(2x)^{2} + 2)&13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)\\26ytan(2x)\cdot (4tan(4z)^{2} + 4)&13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)&104y^{2}tan(2x)tan(4z)\cdot (4tan(4z)^{2} + 4)\end{bmatrix}\)

Correct answer:

\(\displaystyle \begin{bmatrix}52y^{2}tan(2x)tan(4z)\cdot (2tan(2x)^{2} + 2)&26ytan(4z)\cdot (2tan(2x)^{2} + 2)&13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)\\26ytan(4z)\cdot (2tan(2x)^{2} + 2)&26tan(2x)tan(4z)&26ytan(2x)\cdot (4tan(4z)^{2} + 4)\\13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)&26ytan(2x)\cdot (4tan(4z)^{2} + 4)&104y^{2}tan(2x)tan(4z)\cdot (4tan(4z)^{2} + 4)\end{bmatrix}\)

Explanation:

\(\displaystyle \begin{align*}&\text{In asking for H, the question asks for the Hessian.}\\&\text{The Hessian of a function is a matrix of second derivatives taken with}\\&\text{respect to its constituent variables. The form is as follows:}\\&\begin{bmatrix}\frac{d^2f}{d_{x_1}^2}&...&\frac{d^2f}{d_{x_1}d_{x_n}}\\...&...&...\\\frac{d^2f}{d_{x_n}d_{x_1}}&...&\frac{d^2f}{d_{x_n}^2}\end{bmatrix}\\&\text{Considering our function: }f(x,y,z)=13y^{2}tan(2x)tan(4z)\\&\text{And utilizing derivative rules:}\\&(f\circ g )'=(f'\circ g )\cdot g'\\&d[tan(u)]=\frac{du}{cos^2(u)}=(tan^2(u)+1)du\\&Hf=\begin{bmatrix}52y^{2}tan(2x)tan(4z)\cdot (2tan(2x)^{2} + 2)&26ytan(4z)\cdot (2tan(2x)^{2} + 2)&13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)\\26ytan(4z)\cdot (2tan(2x)^{2} + 2)&26tan(2x)tan(4z)&26ytan(2x)\cdot (4tan(4z)^{2} + 4)\\13y^{2}\cdot (2tan(2x)^{2} + 2)\cdot (4tan(4z)^{2} + 4)&26ytan(2x)\cdot (4tan(4z)^{2} + 4)&104y^{2}tan(2x)tan(4z)\cdot (4tan(4z)^{2} + 4)\end{bmatrix}\end{align*}\)

Learning Tools by Varsity Tutors