yego.me
💡 Stop wasting time. Read Youtube instead of watch. Download Chrome Extension

Lagrange multiplier example, part 2


4m read
·Nov 11, 2024

So where we left off, we have these two different equations that we want to solve. Um, and there's three unknowns: there's S, the tons of steel that you're using; H, the hours of labor; and then Lambda, this Lagrange multiplier we introduced that's basically a proportionality constant between the gradient vectors of the revenue function and the constraint function.

And always the third equation that we're dealing with here to solve this is the constraint itself that gives us another equation that'll help solve for H and S, and ultimately Lambda if that's something you want as well.

So as kind of a first pass here, I'm going to do a little more simplifying, but I'm going to make a substitution that'll make this easier for us. So I see S over H here, and they're both to the same power, so I feel it might be a little bit easier if I just substitute U in for S / H. What that'll let me do is rewrite this first equation here as 3/23 * U^(1/3), and that's equal to 20 * Lambda.

Then likewise, what that means for this guy is, well, this is H over S, not S over H, so that one's going to be 1003, not times U^(2/3), but times U^(-2/3) because we swapped the H and S here. So that's U^(-2/3), and this is just to make it a little bit cleaner; I think we kind of want to treat H and S in the same package.

Now let me go ahead and put all the constants together, and I'm going to take this guy and multiply it by 3, divide by 200, and multiply both sides of that just to cancel out what's on the left side here. What that's going to give me, and I'll go ahead and write it over here, kind of all over the place, U^(1/3) is equal to, let's see, 3/200. So that 20 almost cancels out with the 200; it just leaves a 10, so that's going to give me 3/10 * Lambda.

Then similarly over here, I'm going to take this whole equation and multiply it by 3 over 100, and what that's going to leave me with is that U^(-2/3) is equal to, let's see, this 2,000 when we divide by 100 becomes 20, and that 20 * 3 is 60. So that'll be 60 * Lambda.

Alright, so now I want a way to simplify each of these, and what I notice is they look pretty similar on each side. You know that it's something related to U equal to Lambda. So if I can get this in a form where I'm really isolating U, that would be great. The way I'm going to do this is I'm going to multiply each one of them by U^(2/3).

I'm going to multiply it into this guy, and I'm going to multiply it into that guy because on the top it's going to turn this into just U, which will be nice, and on the bottom, it'll cancel out that U entirely. So it feels like it'll make both of these nicer, even though it might make the right side a little uglier. Those right sides will still kind of be the same, and we'll take advantage of that.

So when I do that to the top part, like I said, that U^(1/3) * U^(2/3) ends up being U, and then on the right side we have our 3/10 * Lambda but now U^(2/3). Then on the bottom here, when I multiply it by U^(2/3), the right side becomes one because it cancels out with U^(-2/3), and the right side is 60 * Lambda * U^(2/3).

Now these right sides look very similar, and the left sides are quite simple, so I'm going to multiply this top one by whatever it takes to make it look exactly like that right side. So in this case, I'm going to multiply that top by 10, which will get it to 30, and then by another 20 to make that constant 60.

So I'm going to multiply this entire top equation by 200, and what that gives me is that 200 * U is equal to 60 * Lambda * U^(2/3). Now these two equations have the same right side, so this is the same as saying 200 * U is equal to, well, one, because each one of those expressions equals the same complicated thing.

And now, 200 * U, well that's S / H, so this is the same thing as saying 200 * (S / H) = 1, which we can write more succinctly as H is equal to 200 * S. Great! So I'm going to go ahead and circle that: H is equal to 200 * S.

Now what we apply that to is the constraint: 200 * H + 2,000 * S equals our budget. I'll go ahead and kind of write that down again: that our 20 * H, I think 20 * the hours of labor plus $2,000 per ton of steel is equal to our budget of $20,000.

Now we can just substitute in. Instead of H, I'm going to write 200S. So that's 200; sorry, 20 * 200S plus 2,000 * S is equal to 20,000. Now this right side, 20 * 200 is equal to 4,000, and I'm just going to go ahead and kind of write, so this here is 4,000S.

So the entire right side of the equation simplifies to 6,000S is equal to 20,000, and when those cancel out, what that gives us is S is equal to 20 / 6, which is the same as 10 divided by 3.

So that's how many tons of steel we should get. S is 10 over 3. Then when we apply that to the fact that H is 200 * S, that's going to mean that H is equal to 200 times that value, 10 over 3, which is equal to 2,000 over 3. That's how many hours of labor we want.

So evidently, in our original problem where we have this model for our revenue function for our widgets, with $20 per hour of labor and $2,000 per ton of steel, with a budget of $20,000, the allocation that you should make is to buy 10/3 of a ton of steel and 2,000/3 hours of labor.

More Articles

View All
Solving equations by graphing: word problems | Algebra 2 | Khan Academy
We’re told to study the growth of bacteria. A scientist measures the area in square millimeters occupied by a sample population. The growth of the population can be modeled by ( f(t) = 24 \times e^{0.4t} ) where ( t ) is the number of hours since the expe…
Why geniuses hunt demons for sport | Jimena Canales
I started more than a decade ago tracking the references to the word demon. These are creatures that are thought up by scientists in order to push the boundaries of the research, to think beyond what is known. Computers are a great example where I could s…
Why Do We Play Games?
Hey, Vsauce. Michael here. Why do humans play games? Whether it’s a video game or a board game or a physical game, like soccer - or football. I don’t have to put the ball in the net to survive, and, even if I did, why would I invite a goalie and another …
Rothbard on Animal Rights
This video addresses an essay written by Murray Rothbard, which was published on mises.org. The link is in the sidebar. Rothbard talks about—he’s making a case for human rights and against animal rights, or non-human animal rights. So, Rothbard talks abou…
Is It Okay to Touch Mars?
[Music] Hey, Vauce! Michael here. No rocks from Mars have ever been brought back to Earth, and no human has ever touched anything on Mars. But that’s about to change. National Geographic has asked me, and Jake, and Kevin to talk about Mars because they ha…
The 3 ways I LOST over $250,000 as a Real Estate Agent
What’s up you guys? It’s Graham here. So if you want to learn from my mistakes, it’s really easy; all you have to do is not click out of this video. Mind blown! So these are the top three mistakes I made as a real estate agent that have easily cost me ov…