Lagrange Multipliers; extrema, costs, profits

CHRISTIAN HEADS UP

1. All math hubs at my site have something about God in there last paragraph. In this hub the last paragraph addresses God's judgement on this Nation.

LAGRANGE MULTIPLIERS; WHAT CAN THEY DO?

2. God created Joseph-Louis Lagrange(1736--1813) to be a child prodigy, and when Professor Lagrange was only 19 years old, God revealed to him the method of Lagrange multipliers. It is, in my opinion, a brilliant way to find extrema( maximum and minimum) values of functions when there are one or more constraints and more than one variable. Your first meeting with LM( Lagrange multipliers) will probably be in calculus, but they are a valuable resource in other areas of math as linear programming. This concept of extrema, of which LM play an important role, has saved our nation much money by reducing costs; thereby providing all of us a higher standard of living. LM are also used in engineering to maximize safety and performance. If you are studying LM then you may do so proudly for the benefits they provide us and because they are really, really cool.

MINIMIZE HEATING COSTS:

3. This is hub is being written in January, 2012 in the Pacific Northwest so perhaps it is the cold weather that prompted me to use an example of minimizing heating costs. Also most of us can relate to this subject, but for those of us who don't can relate to minimizing air conditioning costs. I got this example from one of my textbooks( Calculus 2nd ed., by Dennis Berkey, a very good text). I wanted a real life practical example; however, I had to tweak it a bit to make the benefits of LM more conspicuous. I also had to switch from the preferred SI( metric) units to our archaic foot--pound system so the numbers would be more familiar. I checked the cost coefficients in the original problem, and I think they give a good representation of the true costs, but I adjusted them for inflation. These costs very widely depending on type of insulation, construction of building, location, etc. I also did some tweaking with the cost coefficients to correlate them with the roughly estimated wall, floor and ceiling heat losses of where I live now. However, in this problem I chose a volume constraint of 400,000 cubic fat footies(ft^3), and no one would build a building that big with such inefficient weatherization as my residence.


LET'S GET STARTED:

4. At L1 I subject you to my very talented artwork---yes, I know; it's a gift. Here at L1 we have a top view and side view of the building. You're laughing now, are'nt you? Well, I'm a firm believer in doing your best and being professional. Nothing but the best for my fellow hubbers.

COST FUNCTION; COSTS/FT^2:

5. At L2,3,4 and 5 we have the heating costs per square foot for the floor, ceiling and various walls. These are the costs averaged over an entire year. L6 is the cost function in which X represents the width, Y the length, and Z the height of the building. L7 is L6 simplified by collecting terms.

L8 IS A MNEMONIC:

6. L8 is a mnemonic( nee mawn' ik), which is an aid to remember something. By adding the volume constraint to the cost function, we only need to remember to take the partial derivatives in respect of each of the variables of this equation, L( the mnemonic). Notice the last term is zero, because at L9 we have X times Y times Z, which equals the volume; therefore, volume minus volume is zero. So all we are doing at L8 is adding zero to the cost function.

THE LAGRANGE MULTIPLIER, λ:

7. Also at L8 is the Greek letter λ(lambda), which is the Lagrange multiplier. As you go through this problem you may notice that, from a practical point of view, we did not actually need the LM. In this problem we were able to take the partial derivatives of the constraint function(g(X,Y,Z)→ XYZ -- 400,000 ft^3 = 0, and not loose it altogether or loose important components of it. However, in most LM problems it is of course mandatory to have λ at its proper place in the problem---you cannot solve the problem without it. In other words, you cannot solve a LM problem, in which the LM is necessary, without using the LM. WOW! You're not going to get any deeper philosophical thought than that right there.

THE GRADIENT---THE FOUNDATION OF LAGRANGE MULTIPLIERS:

8. This hub is an appetizer, not the actual meat and potatoes of the subject, but I want to mention the theory behind LM. Oh! I know. This hub is still yummy, but you just don't want to jump into the main meal right off the bat; I mean what with the cramps and the meal not agreeing with you--why risk it? LMs are taught in calculus but not until you have studied partial derivatives, gradients, and vector calculus, not to mention level curves. The reason for this is that those topics are all necessary in order to understand LMs. The gradient is taking the partial derivatives of a function and converting it into a vector. We can do this with both our cost function, C(X,Y,Z), and its constraint function, g(X,Y,Z). I think of the function of which we want to find the extreme values as the extrema function, f(X,Y,Z). In our problem the function C(X,Y,Z), or just C, is the extrema function, f. Incidentally, f can have only 2 variables, or more than 3( X1, X2, X3, . . . , Xn). There can also be more than one constraint function for each f. It can be shown that if f is parametrized with g making the composite function r , then the gradient of f and the gradient of g are both orthogonal( perpendicular) to the tangent of r , and the vectors grad f, and grad g , are parallel. Since they are parallel they have the same direction; therefore, all they need to be equal is a scalar factor, λ, to make them equal giving us grad f = λgrad g. With this apparently simple equation we can equate the various terms and solve for the variables simultaneously. We are doing a simplified version of that in this hub. I wrote this paragraph and read it back to myself, and said, WHAT? So I don't expect this to make much sense unless you have studied all these concepts. I just wanted to toss the foundation of LMs to you in case you were curious. To thoroughly develop the concepts in this paragraph will take another hub, or 2, or 3 . . . .

SET PARTIAL DERIVATIVES TO ZERO TO FIND EXTREMA:

9. At L10, L11 and L12 we are taking the partial derivatives of L at L8 in respect of each of the independent variables. They equal zero because we are looking for the extrema values( lowest cost for our problem), which is where the tangent to L is zero( horizontal). At L13 we then multiply L10 by X, L11 by Y, and L12 by Z so that the last terms of L10, L11 and L12 are all equal to λXYZ. We can then move these last terms over to the right as we did at L14, L15 and L16.

EQUATE THE THREE EQUATIONS AND SOLVE FOR X, Y AND Z:

10. Notice all the terms on the left of L14, L15 and L16 are all equal to --λXYZ; therefore, we can equate each of these to one another to solve for the variables. So at L17 we equated L14 with L15; subtracted out 0.51XY from both sides to get L18. Then divide out Z to get L19, and finally solve for Y in terms of X. The same sort of thing is done for Z at L20, 21, 22, and 23.


FINDING X, THE WIDTH OF THE BUILDING:

11. We have Y and Z in terms of X; therefore, we plug these into L24 at L25, and get L24 in terms of X at L26. We do the math and get X = 47.28 feet at L29. We take the value we found for Y at L19, and the value we found for Z at L23 and plug X into them at L30 and L31; thereby, finding the length, Y = 112.29 feet, and the height, Z = 75.35 feet.

FELT-PENS WRITING UNDER CONSTRAINT:

12. From L30 to the end of this hub my brand new felt pens were copping me an attitude by not writing properly. The black ran out of ink, and the never-used-before blue, red and green were being wimpy. I was getting so mad that I was thinking of doing a Lagrange multiplier calculation on these felt pens: What is the maximum writing ability of a wimpy felt pen under the constraint of being thrown into a barn fire?

RESULT OF OUR CALCULATION:

13. At L32 I rewrote the cost function for convenience, and plugged in our values of X,Y, and Z at L33, and determined an average cost of $677 per month for heat.

COST PROPORTIONAL TO SURFACE AREA:

14. At L34 we have all the dimensions equal, which means our building is a cube. We put these values into the cost function and at L36 we get an average cost of $719 per month for heat. At L37 we make our building just one floor high, which is this case is 7 feet; therefore, this gives us 239 feet to a side. Under this condition the heating cost is $2,580 per month on average. This makes sense. If you get a really hot bowl of oatmeal, you know it will take a decade to cool off; therefore, you transfer it to a plate, and spread it out, and it cools off in a minute. Although our answer in this problem does not give minimum surface area, it still gives the lowest heating cost with the dimensions we calculated.


OTHER CONSIDERATIONS:

15. Of course there are other things to consider besides heating costs. If you are going to build a higher building then you must consider the logistics and engineering of the project, not to mention the buildings vulnerability to horrific winds, violent earthquakes, and bird droppings on the roof.

GOD'S JUDGEMENT OF THIS NATION:

16. As I said at the beginning of this hub, and at the end of hub 12.2( inverse and determinant), God's revelation of innovative mathematical techniques, and His creating us with creative minds has given us a standard of living that exceeds the imagination of our forefathers. But how do we thank Him for all the blessings He has given to us? We expel Him out of our public schools, escort Him from our courtrooms, pass laws that violate His commandments concerning homosexuality, abortion, theft, idolatry, justice, and we have become self indulgent by being insouciant to serving and obeying Jesus Christ. After all of this we have the audacity and stupidity to backtalk God with statements as, "The world condition proves there is no God," or, "Evil in the world proves that God does not exist." I will acknowledge the fact that the evil in the world proves God does not exist in many of us, and it proves that our obedience to God, through Jesus Christ, is nonexistent. The one statement that beats them all in idiocy and illogic is "There is no evidence of God's existence." Well, brace yourself folks; God has a way of talking right back at us: Isaiah 30:1; Jeremiah 5:22--25; 18:5--17; 25:4--11.

More by this Author


Comments 7 comments

North Wind profile image

North Wind 4 years ago from The World (for now)

I am also reminded of the verse: Professing themselves to be wise they became as fools. Such an interesting hub, Caleb DRC and I love how you show that through God these calculations are possible. He created us and caused us to be intelligent and yet intelligence is the very thing sometimes that makes us foolish.


Caleb DRC profile image

Caleb DRC 4 years ago Author

You will not get an argument out of me on that point, North Wind. Intelligence is a wondrous gift from God, but if it is not based upon faith in Jesus Christ then it is nothing more than a fancy shovel that uses eloquent sophistry to justify sins thereby digging a wide expansive hole into the endless fires of hell. I might add that we do the digging, not God; therefore, we can't blame Him.

Incidentally, North Wind, what did you think of my very intricate and sophisticated computerized graphic at the beginning of this hub? Yap, I'm pretty proud. I think I can safely say that you will not find that kind of professionalism at any other site.


North Wind profile image

North Wind 4 years ago from The World (for now)

I was absotively posolutely amazed at the sophistication of your graphic, Caleb DRC! I agree that there is no graphic on any other site quite like it :)


John Smith 3 years ago

Why bring religion into math.......smh


Caleb DRC profile image

Caleb DRC 3 years ago Author

John, because no one can calculate their way out of a precipitous walk into eternal hell; the ascension away from hell can only be accomplished through obedience to Jesus Christ. As of this date( 10-26-13) I have had over 15,000 people come to my site; none of whom I have ever met, nor do I expect to meet. I have this rare opportunity to reach people all over the world with the most important information they will ever hear. Most people who read my math hubs( articles) would not choose to read an article exclusively written about God, or Christ, but right there after the math is information about the God who will judge their decisions and actions, and thereby decide their eternal destiny.


North Wind profile image

North Wind 3 years ago from The World (for now)

@John Smith - why bring up Edison when speaking about the light bulb?

Why talk about Steve Jobs when you explain how an iphone works? They are the ones behind it and God is the one behind Math. As His creations we understand a little bit - and I stress little - about Math. You think we know a lot? The Mathematics and Science known to man is just the tip of the iceberg.

That is why Caleb brings God into the equation. Without Him the equation would not exist.


Caleb DRC profile image

Caleb DRC 3 years ago Author

Hi North Wind,

Well, as usual, your comment hit the target dead center. I agree with you, also as usual, especially with the sentence, "The Mathematics and Science known to man is just the tip of the iceberg." Oh! and of course, "Without Him the equation would not exist."----ABSOLUTELY!

    Sign in or sign up and post using a HubPages Network account.

    0 of 8192 characters used
    Post Comment

    No HTML is allowed in comments, but URLs will be hyperlinked. Comments are not for promoting your articles or other sites.


    Click to Rate This Article
    working