Method of Lagrange Multipliers

Requires a Wolfram Notebook System
Interact on desktop, mobile and cloud with the free Wolfram Player or other Wolfram Language products.
The extrema of a function under a constraint
can be found using the method of Lagrange multipliers. A condition for an extremum can be expressed by
, which means that the level curve gradient
and the constraint gradient
are parallel. The scalar
is called a Lagrange multiplier.
Contributed by: Raymond Harpster (May 2019)
Based on an undergraduate research project at the Illinois Geometry Lab by Raymond Harpster, Tianli Li and Yikai Teng and directed by A. J. Hildebrand.
Open content licensed under CC BY-NC-SA
Snapshots
Details
Extrema are detected by computing the value of the dot product of the normalized level curve gradient and the normalized tangent of the constraint curve. The point changes from green to red as the absolute value of the dot product approaches zero. The dot product equals zero if and only if the level curve gradient is perpendicular to the tangent vector of the constraint curve, that is, parallel to the constraint gradient.
Extrema that occur on singular points of the surface or constraint may not be detected by the Lagrange multiplier method.
The constraint curve data used comes from the collection of curves available in the Wolfram Language.
Permanent Citation