Skip to main content
\(\renewcommand{\chaptername}{Unit} \newcommand{\derivativehomeworklink}[1]{\href{http://db.tt/cSeKG8XO}{#1}} \newcommand{\chpname}{unit} \newcommand{\sageurlforcurvature}{http://bmw.byuimath.com/dokuwiki/doku.php?id=curvature_calculator} \newcommand{\uday}{ \LARGE Day \theunitday \normalsize \flushleft \stepcounter{unitday} } \newcommand{\sageworkurl}{http://bmw.byuimath.com/dokuwiki/doku.php?id=work_calculator} \newcommand{\sagefluxurl}{http://bmw.byuimath.com/dokuwiki/doku.php?id=flux_calculator} \newcommand{\sageworkfluxurl}{http://bmw.byuimath.com/dokuwiki/doku.php?id=both_flux_and_work} \newcommand{\sagelineintegral}{http://bmw.byuimath.com/dokuwiki/doku.php?id=line_integral_calculator} \newcommand{\sagephysicalpropertiestwod}{http://bmw.byuimath.com/dokuwiki/doku.php?id=physical_properties_in_2d} \newcommand{\sagephysicalpropertiesthreed}{http://bmw.byuimath.com/dokuwiki/doku.php?id=physical_properties_in_3d} \newcommand{\sageDoubleIntegralCheckerURL}{http://bmw.byuimath.com/dokuwiki/doku.php?id=double_integral_calculator} \newcommand{\myscale}{1} \newcommand{\ds}{\displaystyle} \newcommand{\dfdx}[1]{\frac{d#1}{dx}} \newcommand{\ddx}{\frac{d}{dx}} \newcommand{\ii}{\vec \imath} \newcommand{\jj}{\vec \jmath} \newcommand{\kk}{\vec k} \newcommand{\vv}{\mathbf{v}} \newcommand{\RR}{\mathbb{R}} \newcommand{\R}{ \mathbb{R}} \newcommand{\inv}{^{-1}} \newcommand{\im}{\text{im }} \newcommand{\colvec}[1]{\begin{bmatrix}#1\end{bmatrix} } \newcommand{\cl}[1]{ \begin{matrix} #1 \end{matrix} } \newcommand{\bm}[1]{ \begin{bmatrix} #1 \end{bmatrix} } \DeclareMathOperator{\rank}{rank} \DeclareMathOperator{\rref}{rref} \DeclareMathOperator{\vspan}{span} \DeclareMathOperator{\trace}{tr} \DeclareMathOperator{\proj}{proj} \DeclareMathOperator{\curl}{curl} \newcommand{\blank}[1]{[14pt]{\rule{#1}{1pt}}} \newcommand{\vp}{^{\,\prime}} \newcommand{\lt}{<} \newcommand{\gt}{>} \newcommand{\amp}{&} \)

Section10.3Lagrange Multipliers

Objectives

In this section you will learn how to...

  • Use Lagrange multipliers to find solutions to constrained optimization problems

The cake exercise was an example of an optimization problem where we wish to optimize a function (the volume of a box) subject to a constraint (the box has to fit inside a cake). If you are an economics student, this section may be the key reason why you were asked to take multivariate calculus. In the business world, we often want to optimize something (profit, revenue, cost, utility, etc.) subject to some constraint (a limited budget, a demand curve, warehouse space, employee hours, etc.). An aerospace engineer will build the best wing that can withstand given forces. Everywhere in the engineering world, we often seek to create the “best” thing possible, subject to some outside constraints. Lagrange discovered an extremely useful method for answering this question, and today we call it “Lagrange Multipliers.”

Rather than introduce Cobb-Douglass production functions (from economics) or sheer-stress calculations (from engineering), we'll work with simple examples that illustrate the key points. Sometimes silly examples carry the message across just as well.

Exercise10.3.1

Suppose an ant walks around the circle \(g(x,y)=x^2+y^2=1\text{.}\) As the ant walks around the circle, the temperature is \(f(x,y) = x^2+y+4\text{.}\) Our goal is to find the maximum and minimum temperatures reached by the ant as it walks around the circle. We want to optimize \(f(x,y)\) subject to the constraint \(g(x,y)=1\text{.}\)

(a)

Draw the circle \(g(x,y)=1\text{.}\) Then, on the same set of axes, draw several level curves of \(f\text{.}\) The level curves \(f=3, 4, 5, 6\) are a good start. Then add more (maybe at each 1/4th). If you make a careful, accurate graph, it will help a lot below.

(b)

Based solely on your graph, where does the minimum temperature occur? What is the minimum temperature?

(c)

If the ant is at the point \((0,1)\text{,}\) and it moves left, will the temperature rise or fall? What if the ant moves right?

(d)

On your graph, place a dot(s) where you believe the ant reaches a maximum temperature (it may occur at more than one spot).

(e)

Explain why you believe this is the spot where the maximum temperature occurs. What about the level curves tells you that these spots should be a maximum?

(f)

Draw the gradient of \(f\) at the places where the minimum and maximum temperatures occur. Also draw the gradient of \(g\) at these spots.

(g)

Explain how are gradients of \(f\) and \(g\) related at these spots.

Subsection10.3.1Practicing with Langrange Multipliers

Exercise10.3.2

Suppose an ant walks around the circle \(x^2+y^2=1\text{.}\) As the ant walks around the circle, the temperature is \(T(x,y) = x^2+y+4\text{.}\) Our goal is to find the maximum and minimum temperatures \(T\) reached by the ant as it walks around the circle.

(a)

What function \(f(x,y)\) do we wish to optimize? What is the constraint \(g(x,y)=c\text{?}\)

(b)

The most common error on this exercise is to divide both sides of an equation by \(x\text{,}\) which could be zero. If you do this, you'll only get 2 ordered pairs.

Find the gradient of \(f\) and the gradient of \(g\text{.}\) Then solve the system of equations that you get from the equations

\begin{equation*} \vec \nabla f = \lambda \vec \nabla g, x^2+y^2=1. \end{equation*}

You should obtain 4 ordered pairs \((x,y)\text{.}\)

(c)

At each ordered pair, find the temperature.

(d)

What is the maximum temperature obtained? What is the minimum temperature obtained? Do your results match the previous exercise?

Exercise10.3.3

Consider the curve \(xy^2=54\) (draw it). The distance from each point on this curve to the origin is a function that must have a minimum value. Find a point \((a,b)\) on the curve that is closest to the origin.

Hint

The distance to the origin is \(d(x,y)=\sqrt{x^2+y^2}.\) This distance is minimized when \(f(x,y) = x^2+y^2\) is minimized. So use \(f(x,y)=x^2+y^2\) as the function you wish to minimize. What's the constraint \(g(x,y)=c\text{?}\)

Exercise10.3.4

Find the dimensions of the rectangular box with maximum volume that can be inscribed inside the ellipsoid

\begin{equation*} \frac{x^2}{2^2}+\frac{y^2}{3^2}+\frac{z^2}{5^2}=1. \end{equation*}
Hint

What is the function \(f\) you wish to optimize? What is the constraint \(g=c\text{?}\) Try solving each equation for \(\lambda\) so you can eliminate it from the exercise.

Exercise10.3.5

Repeat Exercise 10.2.5, but this time use Lagrange multipliers. Find the dimensions of the rectangular box of maximum volume that fits underneath the surface \(z=f(x,y)=9-x^2-y^2\) for \(z\geq 0\text{.}\)

Hint

Let \(f(x,y,z) = (2x)(2x)(z)\) and \(g(x,y,z)=z+x^2+y^2=9\text{.}\) You'll get a system of 4 equations with 4 unknowns (\(x,y,z,\lambda\)). Try solving each equation for lambda. You know \(x,y,z\) can't be zero or negative, so ignore those possible cases.

Subsection10.3.2Computational Practice

These are provided to help you achieve better skills in basic computational answers.

1
2
3