Why use lagrange multiplier




















The function to minimize is of course. Here, "sqrt" means "square root", of course; that's hard to draw in plain text. The teacher went through the problem on the board in the most direct way I'll explain it later , but it was taking him a while and I was a little bored, so I idly started working the problem myself while he talked. In my defense, I wasn't really focusing on what I was doing, since I was listening to lecture at the same time.

I felt a little silly, but I didn't think much more about it. Happily, we learned about Lagrange multipliers the very next week, and I immediately saw that my mistake had been a perfect introduction to the technique. So what did my teacher actually do? He used the equation of the line to substitute y for x in d P , Q , which left us with an "easy" single-variable function to deal with To solve the problem from this point, you take the derivative and set it equal to zero as usual.

That's exactly what we got earlier, so both methods seem to work. In this case, the second method may be a little faster though I didn't show all of the work , but in more complicated problems Lagrange multipliers are often much easier than the direct approach.

Finally, I've recorded a couple of video examples of solving problems using Lagrange multipliers. They're far from perfect, and they're aimed more at problem solving than explaining the concepts, but some folks may be interested. The first does try to explain the concepts a little in the context of finding the closest point to the origin on a parabola.

Another is purely problem solving, ostensibly about finding the nearest water to a house :. I've also recorded a video example involving a somewhat artificial commodities trading firm with five parameters and two constraints :. This section will be brief, in part because most readers have probably never heard of the calculus of variations.

Many people first see this idea in advanced physics classes that cover Lagrangian mechanics, and that will be the perspective taken here in particular, I will use variable names inspired by physics. If you don't already know the basics of this subject specifically, the Euler-Lagrange equations , you'll probably want to just skip this section.

The calculus of variations is essentially an extension of calculus to the case where the basic variables are not simple numbers x i which can be thought of as a position but functions x i t which in physics corresponds to a position that changes in time.

Rather than seeking the numbers x i that extremize a function f x i , we seek the functions x i t that extremize the integral dt of a function L[ x i t , x i ' t , t], where x i ' t are the time derivatives of x i t.

The reason we have to integrate first is to get an ordinary number out: we know what "maximum" and "minimum" mean for numbers, but there could be any number of definitions of those concepts for functions. In most cases, we integrate between fixed values t 0 and t 1 , and we hold the values x i t 0 and x i t 1 fixed. In physics, that means that the initial and final positions are held constant, and we're interested finding the "best" path to get between them; L defines what we mean by "best".

The solutions to this problem can be shown to satisfy the Euler-Lagrange equations I have suppressed the " t " in the functions x i t :. Imposing constraints on this process is often essential. In physics, it is common for an object to be constrained on some track or surface, or for various coordinates to be related like position and angle when a wheel rolls without slipping, as discussed below. To do this, we follow a simple generalization of the procedure we used in ordinary calculus.

Constraints that necessarily involve the derivatives of x i often cannot be solved. The Euler-Lagrange equations are then written as. There are further generalizations possible to cases where the constraint s are linear combinations of derivatives of the coordinates rather than the coordinates themselves , but I won't go into that much detail here.

As mentioned in the calculus section, the meaning of the Lagrange multiplier function in this case is surprisingly well-defined and can be quite useful.

Thus, for example, Lagrange multipliers can be used to calculate the force you would feel while riding a roller coaster. If you want this information, Lagrange multipliers are one of the best ways to get it. One of the simplest applications of Lagrange multipliers in the calculus of variations is a ball or other round object rolling down a slope without slipping in one dimension.

As usual, a problem this simple can probably be solved just as easier by other means, but it still illustrates the idea. As before, the prime ' denotes a time derivative, so this is a function of velocity and angular velocity. Thus, the Lagrangian for the system is. Respectively, the results are:. It is then straightforward to solve for the three "unknowns" in these equations:.

The first two equations give the constant acceleration and angular acceleration experienced as the ball rolls down the slope. Specifically, these are the force and torque due to friction felt by the ball:. But the torque is negative: it acts in the direction corresponding to rolling down the hill, which means that the speed of rotation increases as the ball rolls down. That is exactly what we would expect! Happily, that will not end up affecting the final answers at all. This page certainly isn't a complete explanation of Lagrange multipliers, but I hope that it has at least clarified the basic idea a little bit.

I'm always glad to hear constructive criticism and positive feedback, so feel free to write to me with your comments. My thanks to the many people whose comments have already helped me to improve this presentation.

I hope that I have helped to make this extremely useful technique make more sense. Best wishes using Lagrange multipliers in the future! Up to my tutorial page. Up to my teaching page. Up to my professional page. My personal site is also available. Any questions or comments? Note that we divided the constraint by 2 to simplify the equation a little. There are many ways to solve this system.

This gives,. Doing this gives,. This gave two possibilities. This leaves the second possibility. Therefore, the only solution that makes physical sense here is. We should be a little careful here. Anytime we get a single solution we really need to verify that it is a maximum or minimum if that is what we are looking for. This is actually pretty simple to do. If the volume of this new set of dimensions is smaller that the volume above then we know that our solution does give a maximum.

If, on the other hand, the new set of dimensions give a larger volume we have a problem. We only have a single solution and we know that a maximum exists and the method should generate that maximum. The only thing we need to worry about is that they will satisfy the constraint. So, we can freely pick two values and then use the constraint to determine the third value.

Plugging these into the constraint gives,. This is fairly standard for these kinds of problems. This one is going to be a little easier than the previous one since it only has two variables.

To determine if we have maximums or minimums we just need to plug these into the function. Also recall from the discussion at the start of this solution that we know these will be the minimum and maximums because the Extreme Value Theorem tells us that minimums and maximums will exist for this problem. Do not always expect this to happen. First note that our constraint is a sum of three positive or zero number and it must be 1.

In each case two of the variables must be zero. We also have two possible cases to look at here as well. However, this also means that,. So, we have four solutions that we need to check in the function to see whether we have minimums or maximums. We used it to make sure that we had a closed and bounded region to guarantee we would have absolute extrema.

For example. Before we proceed we need to address a quick issue that the last example illustrates about the method of Lagrange Multipliers. We found the absolute minimum and maximum to the function. However, what we did not find is all the locations for the absolute minimum. Every point in this set of points will satisfy the constraint from the problem and in every case the function will evaluate to zero and so also give the absolute minimum.

So, what is going on? Recall from the previous section that we had to check both the critical points and the boundaries to make sure we had the absolute extrema. The same was true in Calculus I.

Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. Upcoming Events. Featured on Meta. Now live: A fully responsive profile. The unofficial elections nomination post. Linked 0. Related 0. Hot Network Questions. Question feed.



0コメント

  • 1000 / 1000