Skip to main content
Mathematics LibreTexts

5.6: Critical Points and Extrema

  • Page ID
    108825
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    With functions of one variable we were interested in places where the derivative is zero, since they made candidate points for the maximum or minimum of a function. If the derivative is not zero, we have a direction that is downhill and moving a little in that direction gives a lower value of the function. Similarly, with functions of two variables we can only find a minimum or maximum for a function if both partial derivatives are 0 at the same time. Such points are called critical points.

    The point \((a,b)\) is a critical point for the multivariable function \(f(x,y)\text{,}\) if both partial derivatives are 0 at the same time.

    In other words

    \[ \frac{\partial }{\partial x} f(x,y)|_{x=a,y=b}=0 \nonumber \]

    and

    \[ \frac{\partial }{\partial y} f(x,y)|_{x=a,y=b}=0 \nonumber \]

    Example 6.3.1: Finding a Local Minimum of a Function.

    Use the partial derivatives of \(f(x,y)=x^2+ 2xy+3y^2-4x-3y\) to find the minimum of the graph.

    Solution

    Critical Point by Algebra: In the previous section, we already computed

    \[ \frac{\partial }{\partial x} f(x,y)=2x+2y-4 \nonumber \]

    \[ \frac{\partial }{\partial y} f(x,y)=2x+6y-3. \nonumber \]

    We need to find the places where both partial derivatives are 0. With this simple system, I can solve this system algebraically and find the only critical point is \((9/4, -1/4)\text{.}\)

    \[ 0=2x+2y-4 \nonumber \]

    \[ 0=2x+6y-3 \nonumber \]

    Subtract the equations to eliminate \(x\text{.}\)

    \[ 0=0-4y-1 \nonumber \]

    Solve for \(y\text{.}\)

    \[ 4y=-1 \nonumber \]

    \[ y=-1/4 \nonumber \]

    Substitute back and solve for \(x\text{.}\)

    \[ 0=2x+2(-1/4)-4 \nonumber \]

    \[ 2x=9/2 \nonumber \]

    \[ x=9/4 \nonumber \]

    Critical Point by Solver: However, if the partials are more complicated, I will want to find the critical points another way. I can find the point with Solver.

    clipboard_eef39c3e17edd87adc72c477add4846e7.png

    To get solver to set both partials to 0 at the same time, I ask it to solve for \(f_y=0\text{,}\) while setting \(f_x=0\) as a constraint. Make sure to uncheck the box that makes unconstrained variables non-negative.

    clipboard_eee5d53d5b6340f23c4d0ee34afc0f860.png

    This finds our critical point within our error tolerance.

    clipboard_e870fa1768dfaf7b728de7cda8c926346.png

    Critical Point by CAS: We can also use Wolfram|Alpha to find the solution to our system of equations.

    clipboard_eb648730950d18518b54db62eb3e07dbe.png

    Determining the Critical Point is a Minimum We thus get a critical point at (9/4,-1/4) with any of the three methods of solving for both partial derivatives being zero at the same time. Once we have a critical point we want to determine if it is a maximum, minimum, or something else. The easiest way is to look at the graph near the critical point.

    clipboard_e57a8e37c6f1674eaf9a6ff1ea174dfb9.png

    It is clear from the graph that this critical point is a local minimum.

    It is easy to see that \(f(x,y)=x^2+y^2\) has a critical point at \((0,0)\) and that that point is a minimum for the function. Similarly, \(f(x,y)=-x^2-y^2\) has a critical point at \((0,0)\) and that that point is a maximum for the function. For some functions, like \(f(x,y)=x^2-y^2\text{,}\) which has a critical point at \((0,0)\text{,}\) we can have a maximum in one direction and a minimum in another direction. Such a point is called a saddle point. We note that we can have a saddle point even if the \(x\) and \(y\) slice curves both indicate a minimum.

    Example 6.3.2: A Saddle Point at a Minimum on Both Axes.

    Show that \(f(x,y)=x^2-3xy+y^2\) has a critical point at \((0,0)\text{,}\) which is a minimum of both slice curves, but is not a local minimum.

    Solution

    We look at the two partial derivatives, and notice they are both zero at the origin.

    \[ \frac{\partial }{\partial x} f(x,y)=2x-3y \nonumber \]

    \[ \frac{\partial }{\partial x} f(x,y)=-3x+2y. \nonumber \]

    We then see that both slice curves are parabolas that bend up, with a minimum at 0.

    \[ f(x,0)=x^2 \nonumber \]

    \[ f(0,y)=y^2. \nonumber \]

    However if we take the slice with \(x=y\text{,}\) we get a parabola bending down, so we don’t have a minimum.

    \[ f(x,-x)=x^2-3x x+x^2=-x^2. \nonumber \]

    Looking at the graph, we see that this graph does not have a minimum.

    clipboard_e4342b44733b3fb32ebf27d16ab657ba7.png

    With only first derivatives, we can just find the critical points. To check if a critical point is maximum, a minimum, or a saddle point, using only the first derivative, the best method is to look at a graph to determine the kind of critical point. For some applications we want to categorize the critical points symbolically.

    Second Partial Derivatives

    With functions of one variable we used the second derivative to test if a critical point was a maximum or minimum. In the two variable case we need to define the second derivatives and use them to define the discriminant of a function to test if a critical point is a minimum, maximum, or saddle point. We first need to define second partial derivatives.

    Second partials:

    \[ f_{ab}=(f_a )_b=\frac{\partial}{\partial b}(\frac{\partial}{\partial a} f). \nonumber \]

    Note that \(f_{xx}\) is simply the old second derivative of the curve \(f(x,y_0)\) and \(f_{yy}\) is simply the old second derivative of the curve \(f(x_0,y)\text{.}\) For curves with continuous second partial derivatives, the mixed partials, \(f_{yx}\) and \(f_{xy}\) are the same.

    Example 6.3.3: Finding Second Partial Derivatives.

    Find the second partial derivatives of

    \[ f(x,y)=x^2+ 3xy+5y^3-7x-11y. \nonumber \]

    Solution

    We start by computing the first partial derivatives.

    \[ f_x=\frac{\partial}{\partial x} f(x,y)=2x+3y-7 \nonumber \]

    \[ f_y=\frac{\partial}{\partial y} f(x,y)=3x+15y^2-11. \nonumber \]

    Then we compute the second partial derivatives.

    \[ f_{xx}=\frac{\partial}{\partial x} f_x=2 \nonumber \]

    \[ f_{xy}=\frac{\partial}{\partial y} f_x=3 \nonumber \]

    \[ f_{yx}=\frac{\partial}{\partial x} f_y=3 \nonumber \]

    \[ f_{yy}=\frac{\partial}{\partial y} f_y=30y \nonumber \]

    As expected, the mixed partials are the same.

    Using the Discriminant to Test Critical Points

    To test if a critical point is a maximum, minimum, or saddle point we compute the discriminant of the function.

    Discriminant:

    \[ D(f(x,y))=f_{xx} f_{yy}-f_{xy}^2. \nonumber \]

    Example 6.3.4: Finidng the Discriminant of a Function.

    Find the discriminant of

    \[ f(x,y)=x^2+ 3xy+5y^3-7x-11y. \nonumber \]

    Solution

    We have already computed the second partial derivatives.

    \[ f_xx=2,\quad f_xy=3,\quad f_yy=30y. \nonumber \]

    Substituting into the formula

    \[ D=(2)(30y)-3^2=60y-9. \nonumber \]

    Discriminant test: Let \((a,b)\) be a critical point of \(f(x,y)\text{.}\)

    If \(D(a,b)>0\) and \(f_{xx} (a,b)>0\) then \((a,b)\) is a local minimum of \(f(x,y)\text{.}\)

    If \(D(a,b)>0 \) and \(f_{xx} (a,b)\lt 0\) then \((a,b)\) is a local maximum of \(f(x,y)\text{.}\)

    If \(D(a,b)\lt 0\) then \((a,b)\) is a saddle point of \(f(x,y)\text{.}\)

    If \(D(a,b)=0\) we do not have enough information to classify the point.

    Example 6.3.5: Using the Discriminant to Classify Critical Points.

    Based on the information given, classify each of the following points as a local maximum, local minimum, saddle point, not a critical point, or not enough information to classify.

    p \({f_x}\) \({f_y}\) \(f_{xx}\) \(f_{xy}\) \(f_{yy}\)
    A 0 0 0 0 1
    B 0 1 3 2 4
    C 1 0 0 2 3
    D 0 0 1 2 0
    E 0 0 -1 2 3
    F 0 0 -3 1 -2
    G 0 0 3 3 3

    Solution

    We need to compute the discriminant and apply the test.

    p \(f_x\) \(f_y\) \(f_{xx}\) \(f_{xy}\) \(f_{yy}\) Discriminant Classification
    A 0 0 0 0 1 0 Not enough information
    B 0 1 3 2 4 8 Not a critical point
    C 1 0 0 2 3 -4 Not a critical point
    D 0 0 1 2 0 -4 Saddle point
    E 0 0 -1 2 3 -7 Saddle point
    F 0 0 -3 1 -2 5 Maximum
    G 0 0 3 3 3 0 Not enough information
    Example 6.3.6: Finding and Classifying Critical Points.

    Let \(f(x,y)=x^3-3x+y^3-3y^2\text{.}\) Find the critical points and classify them using the discriminant.

    Solution

    We start by computing the first partial derivatives.

    \[ f_x=3x^2-3=3(x-1)(x+1) \nonumber \]

    \[ f_y=3y^2-6y=3(y-2)(y). \nonumber \]

    Then we compute the second partial derivatives and the discriminant.

    \[ f_{xx}=6x,\quad f_{xy}=0,\quad f_{yy}=6y-6,\quad D=(6x)(6y-6)-0^2=36xy-36x. \nonumber \]

    We have critical points when both first partials are 0, so at \((1,2)\text{,}\) \((-1,2)\text{,}\) \((1,0)\text{,}\) and \((-1,0)\text{.}\)

    At \((1,2)\text{,}\) both \(D\) and \(f_{xx}\) are positive, so we have a local minimum.

    At \((-1,2)\) and \((1,0)\text{,}\) \(D\) is negative, so we have a saddle point.

    At (\((-1,0)\text{,}\) \(D\) is positive and \(f_{xx}\) is negative, so we have a local maximum.

    Exercises: Critical Points and Extrema Problems

    class="

    For exercises 1-6, for the given functions and region:

    • Find the partial derivatives of the original function.
    • Find any critical points in the region.
    • Produce a small graph around any critical point.
    • Determine if the critical points are maxima, minima, or saddle points.
    Exercise 1:

    The function is \(f(x,y)=x^2+2xy+4y^2+5x-6y\text{,}\) for the region \(-10\le x\le 10\text{,}\) and \(-10\le y\le 10\text{.}\)

    Answer
    • \[ f_x (x,y)=2x+2y+5 \nonumber \]

    This page titled 5.6: Critical Points and Extrema is shared under a CC BY-NC-SA 4.0 license and was authored, remixed, and/or curated by Mike May, S.J. & Anneke Bart via source content that was edited to the style and standards of the LibreTexts platform; a detailed edit history is available upon request.