Lagrange Multipliers Calculator

Apply the method of Lagrange multipliers step by step

The calculator will try to find the maxima and minima of the two- or three-variable function, subject to the given constraints, using the method of Lagrange multipliers, with steps shown.

Related calculator: Critical Points, Extrema, and Saddle Points Calculator

Optional.

If the calculator did not compute something or you have identified an error, or you have a suggestion/feedback, please contact us.

Your Input

Find the maximum and minimum values of f(x,y)=3x+4yf{\left(x,y \right)} = 3 x + 4 y subject to the constraint x2+y2=25x^{2} + y^{2} = 25.

Solution

Attention! This calculator doesn't check the conditions for applying the method of Lagrange multipliers. Use it at your own risk: the answer may be incorrect.

Rewrite the constraint x2+y2=25x^{2} + y^{2} = 25 as x2+y225=0x^{2} + y^{2} - 25 = 0.

Form the Lagrangian: L(x,y,λ)=(3x+4y)+λ(x2+y225)L{\left(x,y,\lambda \right)} = \left(3 x + 4 y\right) + \lambda \left(x^{2} + y^{2} - 25\right).

Find all the first-order partial derivatives:

x((3x+4y)+λ(x2+y225))=2λx+3\frac{\partial}{\partial x} \left(\left(3 x + 4 y\right) + \lambda \left(x^{2} + y^{2} - 25\right)\right) = 2 \lambda x + 3 (for steps, see partial derivative calculator).

y((3x+4y)+λ(x2+y225))=2λy+4\frac{\partial}{\partial y} \left(\left(3 x + 4 y\right) + \lambda \left(x^{2} + y^{2} - 25\right)\right) = 2 \lambda y + 4 (for steps, see partial derivative calculator).

λ((3x+4y)+λ(x2+y225))=x2+y225\frac{\partial}{\partial \lambda} \left(\left(3 x + 4 y\right) + \lambda \left(x^{2} + y^{2} - 25\right)\right) = x^{2} + y^{2} - 25 (for steps, see partial derivative calculator).

Next, solve the system {Lx=0Ly=0Lλ=0\begin{cases} \frac{\partial L}{\partial x} = 0 \\ \frac{\partial L}{\partial y} = 0 \\ \frac{\partial L}{\partial \lambda} = 0 \end{cases}, or {2λx+3=02λy+4=0x2+y225=0\begin{cases} 2 \lambda x + 3 = 0 \\ 2 \lambda y + 4 = 0 \\ x^{2} + y^{2} - 25 = 0 \end{cases}.

The system has the following real solutions: (x,y)=(3,4)\left(x, y\right) = \left(-3, -4\right), (x,y)=(3,4)\left(x, y\right) = \left(3, 4\right).

f(3,4)=25f{\left(-3,-4 \right)} = -25

f(3,4)=25f{\left(3,4 \right)} = 25

Thus, the minimum value is 25-25, and the maximum value is 2525.

Answer

Maximum

2525A at (x,y)=(3,4)\left(x, y\right) = \left(3, 4\right)A.

Minimum

25-25A at (x,y)=(3,4)\left(x, y\right) = \left(-3, -4\right)A.