Not at all. You need Wolfram Alpha to get an _approximation_ to the solution. The equation itself already was solved in the video before Wolfram Alpha was used. Why do sooooo many people think that an equation is only solved after one gets a numerical value and don't care at all that this numerical value usually is _not_ really the solution, but only an approximation to the solution? That is _not_ what "solution to an equation" actually means!
I should've tried this technique on tests where I couldn't figure things out. "The answer is B(5), where B is a function I'm defining right now that will solve this problem."
Once you have it in that form, you can calculate the answer numerically using newton approximation to any level of precision you want. It’s time consuming but you can do it.
Well it is exactly how this work and that B function might be numerically approximated easier than W. But of course standardized methods are preferred.
@@empathogen75 As I think you are saying it is much less work to just use newton's method on the original equation . I am not really impressed with this Lambert W jazz .
LambertW function is not a hack. It's a well-defined and researched function that can be numerically approximated. I understand why it may feel otherwise, particularly when you're seeing it for the first time. You may consider the situation as similar to how sqrt(-1) may have once felt to you before recognizing the vast world of complex numbers.
@@ir2001 yeah but it’s made up they just said this is now the inverse of that because I say so kind of like imaginary numbers they were just defined as the solution to negative square roots
@@luisfilipe2023 True, but I beg to disagree with the characterization. Keeping LambertW(x) aside for a moment so as to keep my explanation understandable by means of an analogy, how about ln(x)? You may call it merely an inverse of the exponential function, but on further analysis you would realise that it can be expressed as an integral, which can in turn be computed via numerical approximation methods. Therefore, you get an additional weapon for your Math arsenal. Essentially, resourceful abstractions help simplify our expressions without loss of precision.
All of mathematics is "just made up". The so-called elementary functions, such as exp, ln, sin, cos, tan, etc. were all made up at one time to solve problems, either purely mathematical or practical. Assigning a name to a particular function which is made up to solve some class of problems makes it easy to then study that function in detail. Such study can involve finding larger classes of problems which it solves, finding efficient numerical methods to find approximations, plotting graphs, studying its domain, range, etc., working out derivatives and integrals, finding a power series, etc., etc. Just look at the Wikipedia page for the Lambert W function to see how much it has been studied, for example.
Can you solve by hand sin(2.71828)? W is simply defined as the inverse function of z(e^z). Nothing more, nothing less. Just like (one) definition of sin(x) is to consider a unit-radius circle centered at the origin and looking at the relationship between an angle and the vertical coordinate of the point on the circle at that angle.
@@MadaraUchihaSecondRikudoIt’s actually surprisingly easy to calculate square roots (At least of whole numbers). If you convert the number to base 2, there’s a pretty simple pattern that can find the square root by hand. (There are technically patterns that work for higher bases to find square roots, but they’re fiendishly complicated. The base 2 pattern could be done by the average fifth grader)
@@Programmable_Rook Yeah, but this isn't the sqrt of a whole number, just like this isn't the W of a whole number. My point stands, it's a less well-known but no less well-defined function, whose values you generally need a calculator to find.
Ngl when I saw the question I start by guess it’s 2 and start using the calculator to make the number more specific by adding digits and actually got like 1.7158 sth lol within probably a minute
Cool. I learned it in 1999. But good to see that people are still discovering the program’s features. Let me give you something bigger. Goal Seek can accommodate only one variable, but you can project backward for more variables by using the Solver add-in. With Solver you can get a solution that works for multiple variables and you can even set constraints for them.
I think people are missing the fact that the Lambert W function is not just some arbitrary inverse, otherwise Presh could have just said P(2^x+x) = 5 and stopped there. The Lambert W function has been extensively researched, has a lot of properties, and identities, and is quite useful. This is why Presh went to the trouble to reformulate the problem into the product-log form.
@@Asafh2009 and you are rude. I will continue to get older and there is nothing I can do about that. You can choose whether you get ruder or decide instead to take an opposite path.
Yeah, it's a known function I think it would be more interesting to prove that there is a solution... it's not complicated, but it requires more formality than just "solving X"
In my head, I tried x=5/3 and realized it's a bit low. SO I went for 1.7. Then Newton's method: x_new= x- (x log(2)-log(5-x))/(log(2)+1/(5-x)) immediately gives 1.7156 (on a calculator that doesn't have a Lambert function).
using logarithmic naturally reduces exponents. but no way I'm doing that in my head without scientific calculator or log chart. In the past, majority of these exams were calculator free. So whenever these type of video mentions Harvard entrance exam or something, assume you can't use calculator. but in modern times they allow use of calculators with limited functionality. Even ACT (American College Testing) and other Professional College assessment exams such as MCAT (medical college assessment test) provided their own none scientific calculators in the past. This magical function lets you solve this without calculator. If you use windows, open up your calculator and set it to standard. that's basically what you were allowed to use IF they allowed calculators.
I remember something from school about Newton-Rapherson approximation of integrals from about 1980. I just did trial and error on a calculator and got 1.7156207 ish in no time. How do you suppose a calculator does logarithms?
@@angrytedtalks It sort of does the same thing. Look up CORDIC. It's an algorithm to find trig functions that they ended up expanding for other transcendental functions from logs to hyperbolics.
Yep newton raphson rocks Numerical estimation optimization methods are such a blessing to humanity Sad that i dun remember many of them now Only newton raphson and steepest hill descent
W(x)=Xe^X is it's definiton. Do you know precisely what log does? do you know what sine does? do you know what cosh does? At the end of the day, those functions are defined by what they do, and what they do is well known. W doesn't evaluate to a nice rational number, because it is based off the number "e", which is a mathematical constant. (like Pi) W(x) = x*e^X
@@Ninja20704 Lol. Verkuilb meant to follow up a video, not follow-up a video. Lol. Follow up is verb meaning sequential action. The act of following of a video by releasing another video. Follow-up is noun or adjective used when describing what you are referring to. A follow-up is a prompt and relevant response to a situation often in context of addressing a problem or providing additional information. So if you make up a follow-up appointment with a doctor, it means to check up on the same thing again to see how you're doing. But if you make a follow up appointment with a doctor, it just means your next visit.
And to those complaining, we got a near identical question in our Cambridge maths entrance exam, the very paper I sat had a question with the lambert-W function. Don’t believe me, look up STEP II 2021 Q4. Not something I had ever learnt in school or heard of at the time, but given its introduction I was still able to do the question. It’s not about solving the question for an exact answer using a calculator, but it’s about understanding and applying new techniques to gain an analytic closed form solution to an unseen problem. It actually tests your true mathematical ability.
@@Crand0m Yeah, if it's meant to test peoples ability to utilize unfamiliar functions, it should first introduce the function that's meant to be unfamiliar to you. This feels like Harvard punishing people for not knowing information that many haven't been taught.
@@dylanbowes427 it is indeed, for year 13s (17-18yos). That’s why it has a reputation for being the hardest maths exams in the UK at high school level. Most questions can be solved with basic high school knowledge, but you need to be an excellent problem solver and apply it in clever ways
I got a PhD in math without ever hearing about it It's not terribly important. But now that it's built-in to mathematical software a bunch of people think it's fair game for math puzzles. But really, there are countless functions that have inverses that we cannot put in closed form. How interesting is this particular one? I guess it depends on how often you want the inverse of a specific function. It's nice that Woflram-Alpha apparently has decided to hard-code this, but for the most part we don't want to work with functions that are not in a closed form of combinations of simple computations. Existential proofs that certain functions have inverses aren't very interesting, in general. There are infinitely many (uncountably many!) 1-1 functions and they're all invertible. I don't see what the appeal is here.
I got a PhD in physics without ever hearing about it. Only in the last about 5 years, I keep seeing TH-cam videos about it... :D But as others already have mentioned: It apparently has lots of applications in physics.
It is worth to mention that the Lambert-W function isn't exactly one function. To invert x * e^x in the real domain one needs two different branches of the Lambert-W functions, otherwise there would be two function values for x between -1/e and 0. Meaning that for x between -1/e and 0 only one of the two function branches might give you the desired solution, and in that case it's pretty tricky to know which one. Also, x < -1/e doesn't yield any real solution.
As I was fighting Comment Wars, I also researched that, most of it went above my head as only this semester I'm going to study Complex Analysis so. But it was interesting. I enjoyed it.
The equation we ended up with here, is u*(e^u) = 32*ln(2) where u = (5-x)*ln(2) . Since the righthandside , 32*ln(2) , is real and positive, this equation has only one real solution for u ; or in other words, only _one_ branch (of the infinitely many branches) of the Lambert W Function leads to a real solution, namely u = W₀( 32*ln(2) ) . In general, consider the equation u*(e^u) = y If y is real and positive, then only u = W₀(y) is real (and it's also positive); all other branches u = Wₖ(y) would be complex-valued. If y is real and between -1/e and 0, then both u = W₀(y) and u = W₋₁(y) are real (all other branches would be complex-valued), with W₀(y) being between -1 and 0 , and W₋₁(y) being less than -1 . If y is real and less than -1/e, then there are no real solutions; all branches u = Wₖ(y) would be complex-valued. In other words: there are two real branches for W(y) _only when_ y is real ánd between -1/e and 0 . (Please note: you seem to mix up x and y . If we think of x as the real variable of the real function f(x) = x*(e^x), as your comment seems to be suggesting, then it's y = f(x) that is between -1/e and 0 , for which there exist two real branches of inverses x = W(y) (namely one branch x < -1 , and one branch x between -1 and 0). And for real y > 0 , there is only one real branch x = W(y) , and it's also positive.)
For everyone complaining, consider ln(5) (natural log) If the answer was ln(5), would you say that it's an exact solution? If so, why would W(5) (lambert W) not also be an exact solution?
ln() is considered a function in closed form. W() is not. ln x has been computed with a hand-held calculator for a very long time. W() is not easily computable. The Taylor series for ln x is easily written with coefficients in a closed form. The same is not true for W().
@@rickdesper "ln() is considered a function in closed form" What is that supposed to mean? I never heard about a "function in closed form". "The Taylor series for ln x is easily written with coefficients in a closed form. The same is not true for W()." W has a rather simple Taylor series, what are you talking about?!?
@@rickdesper Lambert's W function can be computed with a hand-held calculator using Newton's Method, the same method you would use for calculating log(x) if your calculator doesn't have a log function. The W function also has a Taylor series with coefficients in a closed form. The coefficients for the Taylor series around 0 are (-n)^(n-1)/n!
"If so, why would W(5) (lambert W) not also be an exact solution?" Because the W function is not explained in any detail. Just watching the video, it looks like Presh has pulled a magic word from nowhere and defined it as the solution. This is leaving some of us (or maybe just me) mystified and confused. Now, given any complex equation, it looks like I can define the Mandolinic M function as the solution to that equation. Job done, move on.
I solved the problem in a slightly different way, and got x = log2( W(32 * ln(2)) / ln(2) ). When I plugged it into a calculator, I got the same result as Presh: 1.71562. I was a bit freaked out as to how two different-looking answers could give the same result without any obvious conversion between them, but then I noticed that both answers contain W(32 * ln(2)) / ln(2). If we call that quantity Y, then Presh's answer was x = 5 - Y, and mine was x = log2(Y). The only way these two answers could be the same is if Y = 5 - x = 2^x, which would imply that 2^x + x = 5, and oohhhh I get it now.
Wish harvard was this easy to get into for asians. Regarding the transcendental equation in this question, one ultimately needs a calculator. But using graphing calculators is not it, anyone can do it. Instead doing it with a normal scientific calculator will be the best thing to ask i believe.
I always forget about the Lambert function because W(x) doesnt mean anything to me. Plus, minus, square root, etc all have common sense meanings but it seems to me that W is an implied logic function as opposed to a mechanical function. If you say the solution is W(32ln2) its not clear what that is in real numbers or even a ballpark guess.
The Lambert W function is just a terrible function to work with. It's a mess to calculate, it has two separate branches on part of its domain (because x*e^x isn't one-to-one over its range), and it has sum and difference formulas that are a pain to remember. I can't believe a problem requiring its use appears on a college entrance exam.
It's not "clear" because you are not familiar with the function. How much is sin(2.71828)? Someone not familiar with trigonometric functions would have no clue; that does not make it poorly defined. I don't understand what you mean by "mechanical function" - W is neither more nor less mechanical than (say) sin.
Draw a graph of the relation/function y = f(x) = x*(e^x) . Since 32*ln(2) is real and positive, W( 32*ln(2) ) is the x-coordinate of the _only point_ on the graph for which the y-coordinate equals 32*ln(2) . In general, W(y) * e^W(y) = y .
@@ThreePointOneFou A simple approach to this problem would be to rewrite the equation as 2^x = 5 - x , then sketch the graphs of f(x) = 2^x and g(x) = (5 - x) into one diagram, and estimate the coordinates of the intersection point of f(x) and g(x) . No Lambert W Function needed. (This approach would also demonstrate clearly that there exists only one real solution.)
I actually think the lambert w function is a legitimate way to solve it, but if you just want a numerical answer, newton’s method would have been a lot faster.
Usually these are all approximated using series expansions for the functions. Which ones are used depends on the implementation; historically (40 years ago, when I had to write routines for those things as part of my education) it was a trade off between speed of convergence and amount of memory required to achieve the desired precision. Nowadays, I suspect people go for speed a lot more...
first try x=1 and x=2 to see that the solution must be closer to 2 than 1. now assume x = 2 - y and use 1st-order Taylor for exponential [note: 2^x = exp(x.ln2)]. then you get a linear equation in y with solution y = 1/(1+4.ln2) = 1/(1+4*0.69) = 0.265 (surely every one remembers ln(2)=0.69 ... think about half-life of exponential decays like in radioactivity). this then gives x = 2 - y = 1.735 without use of any special functions or a calculator ... all paper and pencil. and x = 1.735 is pretty close to the actual answer of 1.7156.
I like this one and this is also what I did. You can also do the next order Taylor expansion for 2^x and just get a quadratic equation to manage. You can get within 1% of the right answer that way...
It definitely should. The "problem" with it is that it requires complex analysis to understand it properly, but that was never an issue with roots, so I don't see why not!
@@DemoniqueLewis I suppose you don’t need CA to learn it in the same way sqrt(x) is taught as the inverse of x^2 on a cut domain, which is taught in schools. It would be really nice to learn the common real properties of it though as with any other elementary function like log (domain, range, sketch, derivatives and integrals etc…)
OTHER SOLUTION -> It would’ve also been possible to use Newton technique to solve the non-linear equation. The problem is equivalent of finding the root of f(x) = 2^x + x -5. You can then use the algorithm x_(n+1) = x_n + f(x)/f’(x) with a desired precision to solve. Finally for the initial approximation you could simply use something between 1 and 2 juste by looking at the equation. By doing multiple iteration, the algorithm would converge toward the numerical solution.
bro humiliated me (an indian 9th grader) in every single way by saying, "i wasn't able to go to harvard, that's why i went to stanford 0:23 ". btw: thanks for uploading such glorious content, your daily uploads makes my day, everyday.
@@KookyPiranha It's trivial, provided you know what W(x) is. Unless they introduced it before this question, this entrance exam seems more like a mathematics themed trivia quiz.
The W is quite a bit like normal logarithms, you usually "solve" them as well by means of the deux ex machina that we call a calculator (except no ordinary calculator has the W function). Side note: I'm 50 with an MSc in applied physics, and I heard of the W function only a few years ago. Definitely never learned about it in school...
in math, you often answer with functions. its same as answering with x = sin (x) or fun(x) = x^2 as long as its actual function that works in that specific general instance, its acceptable answer. since it saves time on writing out the entire page of equations. would you rather write X = 5 - w(32ln2)/ln2 or x = 5 - {ln(x/lnx) - {ln(x/lnx)/[1+ln(x/lnx)]} ln(1-lnlnx/lnx)}(32ln2)/ln2 i
@@Yiryujin the second One. I don't Need elegance if not explained. Moreover in the video Is talked like and operator like sin and cos (without demonstration ok) but you associate It like a substitution (nothing special if you think It would have been the third One in the example)
@@lucabastianello9830 Actually, the two expressions are NOT equivalent. The second one is an expression representing a lower bound for W in the original solution. It is an operator - or better, a multi-branched function. Neither more nor less so than the 'normal' logarithm.
I don't have an exact solution, but with just a basic calculator and guess and test methodology I got to the approximation of x=1.715 in about 2 minutes.
By using trial and error one can show the x lies between 2 and 1...and by choosing the mid section of this range, such that x=3/2....we find that the answer is much closer to 5....so the the range is between (3/2 , 2) By minimizing the range : (3/2 + 1/5 , 2 - 1/5)... ,one can get an approximate answer
Do you think that x in 5^x = 2 is better defined? (I think it's just that you are not familiar with W - in principle it's no different than any other function)
I am writing this comment before I watch the video, and will edit it after I watch it. My initial impression from just the thumbnail is... no way would a college entrance exam question involve the Lambert W function, right? Nobody would expect high school kids to know about the Lambert W function, right? EDIT: ...huh.
Possibly not - but if this were an interview question (rather than a written one), the interviewer could ask something like "imagine that you have a function that is the inverse of x(e^x) - could you solve it then?"
We literally got a question like this in our STEP exam for Cambridge maths, despite having never learnt it in school. It’s about how you well and quickly you are able to understand and apply totally new concepts
It's a fairly well-known tactic for top-level universities. That's why they sell their own math and physics textbooks to prepare students for entrance exams.
Typical problem in math exams. It’s not really a question where you use your insane abstract mind. It’s rather „ Do you know the pattern” type of question. Would never do it without lambert func
All of Higher Math's videos are about this base use of the Lambert function😂 What a joke,lol. I doubt it has anything to do with any entrance exam ever!
Lambert function is, imo, just a way to write x=something where you have an expression you can't analitically explicitate. It may be the way they wanted at that entrance exam. I would've just proceeded by writing it as 2^x = 5-x then plotting y=2x and y=5-x and figure out an approximate value by trials choosing the starting value of x by that graphic.
@Blackpenredpen does a lot of videos (think a whole playlist's worth) re: Lambert W function and explains it rather well... Bonus - he also uses "fish" to explain it! 😂
Alive without breath; As cold as death; Never thirsting, ever drinking; Clad in mail never clinking. Drowns on dry land, Thinks an island Is a mountain; Thinks a fountain Is a puff of air. So sleek, so fair! What a joy to meet! ***************** We only wish To catch a fish, So juicy-sweet!
I got a degree in Engineering and can say with confidence that 99.9% of the stuff I learned has never shown up in my life again. The stupidity of reality becomes the real problems you gotta deal with.
I believe my first comment "disappeared"... @Presh- Thanks very much. I'll look into Lambert W (I did attempt a guess at x=1.7; but it was a guess, and not a solution. Take good care, Presh. Thanks again !
2^x + x = 5, 2^x = 5-x = y = => x = 5 - y. 32*2^(-y) = y, y*2^y = 32. y*e^(ay) = 32, where a = log(2). (ay)e^(ay) = 32a > 0 = => ay = W0(32a) = => x = 5 - W0(32a)/a. There is a second branch of W-function, W(-1)(z), for z < 0. W function's branches cannot be expressed in terms of elementary functions.
Here is a quick way to approximate: It’s easy to argue that there is a single unique solution 1 < x < 2 because at x=1, 2^x + x = 3 and at x=2, it’s 6. Linear interpolation would give x=1.67, but we know the function 2^x + x is convex, so the solution should be a bit higher, so we will round it up and say roughly 1.7.
Once Presh went to an interview for the job at a Maths institute. The interviewer asked every candidate the same question - "Do you stand for humanity?" Many candidates replied yes and were rejected instantly. A candidate even replied no but was also rejected. When Presh was asked the same question, he said - "Your question has ambiguity. Does "U" mean the letter U or me as a person? Be clear cause the probability of my replies will change. Interviewer said - "Should we appoint you as the chairperson of this institute?"😂😂😂
If it was the letter "U" he would have used "Does" instead of "Do". Hence the interviewer definitely meant "you". (Considering he had the basic language knowledge)
i think we can use series expansion of 2^x and use as many terms as required to round up to correct answer (i.e first three terms give 1.75177), in the end it will be about solving a polynomial
i have an easier way to solve this (by approximation) (calculator not used) 2^x + x is an increasing function so we check by putting value the range of x b/w to natural numbers x equals 1 gives 3 x equals 2 gives 6 x equals 3 gives 11 and so on now we have got that 1
An economy university student once taught me to make a graphic instead of trying to solve it mathematical. And you can also try out numbers with decimals to get a good rounded result. It took me 4 attempts to get to 1.8. I tried 1 -> 3, 2 -> 6, 1.5 -> 3.75, 1.8 -> 5.04. 1 was too small and 2 too big. Looking at the results it must between 1.5 and 2, but closer to 2. Hence 1.8 was chosen as the next input. If I continue for more decimals then 1.79 -> 4.9941, 1.791 -> 4.998681, etc. The time to do this with a calculator beats the mathematical solve, which you also have to round up or down.
it has 2 complex and one real solutions. however, newtons procedure did not find a result: 10 print "mind your decisions-solving a harvard university entrance question" 20 z=5:sw=z/19:goto 40 30 a=ln(abs(sin(b)/b))/ln(2):dg=exp(a*ln(2))*cos(b):dg=(dg-a-z)/z:return 40 b=-5:gosub 50:goto 100 50 gosub 30 60 b1=b:dg1=dg:b=b+sw:if b>20*z then stop 70 b2=b:gosub 30:if dg1*dg>0 then 60 80 b=(b1+b2)/2:gosub 30:if dg1*dg>0 then b1=b else b2=b 90 if abs(dg)>1E-10 then 80 else return 100 gosub 110:goto 120 110 print "x=";a,"%",b;"*i":return 120 b=b+sw:gosub 50:gosub 110 130 x=-10:print "die reelle lösung ist x=";:goto 150 140 dg=(2^x+x-z)/z:return 150 gosub 140 160 x1=x:dg1=dg:x=x+sw:x=x+sw:x2=x:gosub 140:if dg1*dg>0 then 160 170 x=(x1+x2)/2:gosub 140:if dg1*dg>0 then x1=x else x2=x 180 if abs(dg)>1E-10 then 170 190 print x mind your decisions-solving a harvard university entrance question x=-5.0304466 % -3.24091965*i x=-5.03046368 % 3.04819125*i die reelle lösung ist x=1.71562073 > run in bbc basic sdl and hit ctrl tab to copy from the results window
Another simple but laborious method can be the so called "bifurcation" method. i x =2, 2^x+x=6 if x=1 then 2^x+x=3. Therefore, the value of x must be between 1 and 2. let's take a half of 1+2 which is 1.5. Then solve it and if we take enough iterations we reach the value of 1.76...
2^x + x - 5 = 0 Substitute -3,-2,-1, 0, 1, 2, 3 to see which values give a negative and positive answer and by how much. The answer will be a value between the two answers where the sign switches. In this case x =1 and x=2 Substitute fractions in between to find the answer.
I always like to solve these problems iteratively. In this case, start with a guess for x0 between 0 and 5. The next iteration x1 comes from setting 2^x1 +x0 = 5 or x1 = (ln(5-x0))/ln(2). The next iteration gives x2 = (ln(5-x1))/ln(2), and so on. This converges rapidly. If you try it the other way, ie, 2^x0 +x1 = 5 or x1 = 5 - 2^x0, it doesn't converge.
Presh, this was a really well-paced and thorough explanation of the Lambert W function. Great job! Would you do a sequel looking at the sort of calculus needed to derive the approximate value?
The W function is cool. And it lets you carry around an exact form, it’s still approximate when reduced to numbers. It would be nice to include it in BLAS software
if x = 1 then 3 = 5 if x = 2 then 6 = 5 1 < x < 2 5 - 3 = 2 6 - 3 = 3 2/3 = 0,6667 Meaning that x is approximately 1,6667 Then using calculator I refined it to 1.71562 My initial approximation was less than 3% off
why in the definition of 2^u = e^(u ln2) at 8:54 it didnt just simplified to 2^u = 2e^u? so when subtituted in the main equation, then it could turn into a way simpler form of 16 = ue^u, thus without the need of v definition and get rid off the ln2?
@@yurenchu ok, thats fair. but it doesnt algebraically explains why it cant be, since you could do e^(u ln2) = e^u • e^ln2 = e^u • 2. am i missing some important requirements to such simplification be valid? also, u already cant be 0 or 1 by definition (domain?) as a limitation from the equation, it would break if so at 32 = u2^u (this is also implied by x can't be 5 for the same reason)
thinking about it now, i guess that your contradiction isnt so valid since it may actually mean that, yes, u cant be 0 or 1, but as an incognito from the equation we are trying to find which value it may assume so the expression is valid, right?
@@eduardocortes6340 You're mixing up e^[u * ln(2)] with e^[u + ln(2)] . e^[u + ln(2)] = e^[u] * e^[ln(2)] = e^u * 2 = 2(e^u) vs. e^[u * ln(2)] = (e^u)^[ln(2)] = (e^[ln(2)])^u = 2^u Also note that 2^u = e^[u*ln(2)] is an _identity_ , not an equation. An identity is _always_ true, hence an identity holds for any value of u (such as, for example, for u = 0 and u = 1 ; inserting random values of u is a way to check if a statement is an identity). An equation isn't always true, it's only true as a condition for the problem under consideration, which means a particular value of u must be derived for which the equation holds true. Other examples: (cos(x))² + (sin(x))² = 1 is an identity, not an equation. If you try to solve for x, you'll find that any value of x will do; because the statement is true for any value of variable x . x² = 14x - 40 is an equation. It's not generally true (for example, if x = 3 then LHS = 9 and RHS = 2 , which isn't a match, so the statement is not true for x=3), but the assignment here is to solve for the particular values of x for which the statement becomes true. Those particular values are x = 4 and x = 10 , hence x=4 and x=10 are solutions to this problem. In the video, Presh wants to solve the equation 32 = u*(2^u) One step towards a solution is by rewriting (part of) the RHS by using the identity 2^u = e^[u*ln(2)] ; because that way, the equation becomes 32 = u*e^[u*ln(2)] (which is a statement that is _equivalent_ to the previous equation 32 = u*(2^u) ) and so he's a step closer to an equation of the form c = v*(e^v) , which he can eventually solve by using the Lambert W Function. I hope that helps.
@@eduardocortes6340 You're mixing up e^[u * ln(2)] with e^[u + ln(2)] . e^[u + ln(2)] = e^[u] * e^[ln(2)] = (e^u) * 2 = 2(e^u) vs. e^[u * ln(2)] = (e^u)^[ln(2)] = (e^[ln(2)])^u = 2^u Yes, we are trying to find the values of u for which the equation 32 = u * e^[u*ln(2)] [Equation 1] is valid. That means that we can't just substitute e^[u*ln(2)] in the righthandside with 2(e^u) , because the statement e^[u*ln(2)] = 2(e^u) is not generally true, it's only true for a particular value of u, and that particular value is probably _not_ the value(s) of u for which Equation 1 is true. Therefore, the substitution would be illegitimate. Likewise, you wouldn't solve the equation 13 = 3 + u + u by replacing u+u in the righthandside with (let's say) u^3 , right? No, you would replace u+u with 2u , because u+u = 2u is generally true (and hence useful here), while u+u = u^3 is not generally true (and hence illogical here).
Somehow I got into Harvard without having ever heard of the Lambert-W function. Go figure. Thanks, Presh, for the introduction. I'll do some more research into it. 🤓
9:09 at this step couldn’t we separate e^uln2 as e^u + e^ln2 . And e^ln2 is just 2 as we defined earlier right? So couldn’t we bring that over to the LHS and so it’s 16=ue^u?
Simply put value of x to make LHS equal to RHS. If we put 1 we got 3 which is less than 5 then for x=2 we got 6 which is greater than 5 so the answer is between 1 to 2 . If it is Mcqs so easily got it . For accurate answer we have to go for newton raphson method by which we will get the answer 1.71…
@dlevi67 So, it's a function whose calculation is very complicated and, therefore, is beyond the scope of this video? Looking at other comments and their replies, it seems that I should see it just like sin or log: a well-defined function that isn't really practical to calculate by hand.
@@TheJaguar1983 Yes, that's exactly what it is - more than complicated, I'd say awkward, though, at least for x>0. Unlike sin or log that have 'nice' series expansions, where a pattern is apparent (x/1 -x^2/2 + x^3/3 ...; x/1 -x^3/3! + x^5/5! ...), W's expansion is quite gnarly. The first 5 terms read: x - x² +3x³/2 - 8x⁴/3 + 125x⁵/24 - ... Then there is the "complication" that W (like the complex logarithm) is multi-branched, and the above expansion only holds for values near 0... so perhaps complicated _is_ the right term! 😁 EDIT - screwed up copying the expansion formula - sorry.
you can also arrive at an approximate value using the Taylor Series at a=1.5. This simplifies the equation to a polynomial and we all can solve polynomials :3
I used 1.5 as an estimate. Inserting x=1 is too small and x=2 is too large. So the actual answer might be around the middle. The higher order of derivatives you go, the more accurate answer you can get. But just the first derivative also approximates the answer quite well.
Ive lost my trust in youtubers. I’d love to say i learned something but now that u didn’t explain the inner workings of the W function I’m going to need to watch another video to learn about that. Thanks
There are no more "inner workings" to it than the definition, which Presh has spent the first half of the video in explaining. What "inner workings" are there to the square root of something?
I used Newton's method by hand one time and got 1.794 but there may have been arithmetic errors. No one said anything about an exact solution so I'm satisfied.
I'm glad I stopped trying to solve it after a while on my own. All I know are basic log rules. At some point you just realize there are only so many ways to rewrite the equation and you need some help :P. I have never heard of the Lambert W function before, but it sure was interesting to learn about it, especially with copilot's help. So I assume the lambert W function is in our calculators somewhere? It better be or I have no idea how the harvard students are doing this exam! I assume its all still paper and pencil
Oh! so the whole idea is to convert the equation from its implicit form to its explicit form in x and then use a so called function or simply a computer program to get it solved for us. Interesting. Btw Good job Presh to bring up this problem!
@dlevi67 I'm sorry dear.. By "so called", I didn't mean to detract such a useful function. With little knowledge about the function on my part ,I just said this...but l really like your sincere approbation towards Mathematics.😊
@@sumanjangid1250 No need to apologise - it was just meant as a clarification that Lambert's W isn't something made up by Presh on the hoof (which seems to be a rather pervasive idea in the comments). Sorry if it came across as too abrupt!
I was able to get an exact number by just plugging in values of x. No one does this and its probably just cheating but it works really well and no one uses it.
@@metalsplash310 Testing things "by inspection" is done by a lot of people in a lot of contexts. It's not 'cheating', but probably neither is it what the writers of the questions expected as an initial answer. BTW - you are _not_ getting an exact number. You are getting an approximation. The solution is an irrational (in fact, transcendental) number.
W is the inverse of x(e^x). There is no 'simple' expression of that inverse function in terms of elementary functions - unlike say cosh(x) = (e^x + e^-x)/2. You can approximate the value by using a series expansion, but unlike sin or log that have 'nice' series expansions, where a pattern is apparent (x/1 -x^2/2 + x^3/3 ...; x/1 -x^3/3! + x^5/5! ...), W's expansion is quite gnarly. The first 5 terms read: x - x² +3x³/2 - 8x⁴/3 + 125x⁵/24 - ...
It's called the W function because in the end you need to use Wolfram-Alpha to solve the equation.
Not at all. You need Wolfram Alpha to get an _approximation_ to the solution. The equation itself already was solved in the video before Wolfram Alpha was used.
Why do sooooo many people think that an equation is only solved after one gets a numerical value and don't care at all that this numerical value usually is _not_ really the solution, but only an approximation to the solution? That is _not_ what "solution to an equation" actually means!
@@bjornfeuerbacher5514
Does W have any standard numeric value like e or pi?
I know pi is irrational, still we use with approximated value..
@@arjunvarmamaths1349 Huh? W is a function, not a number.
@@bjornfeuerbacher5514
So the answer is with W??
I Mean in Harvard entrance exam , if I just put answer with W is that correct?😅
@@arjunvarmamaths1349 The answer is the one given at 10:50 in the video, which uses the function W, yes. Did you watch the video?
I should've tried this technique on tests where I couldn't figure things out. "The answer is B(5), where B is a function I'm defining right now that will solve this problem."
Once you have it in that form, you can calculate the answer numerically using newton approximation to any level of precision you want. It’s time consuming but you can do it.
@@empathogen75you can calculate the answer numerically to arbitrary precision without any knowledge of lambert W functions etc.
Well it is exactly how this work and that B function might be numerically approximated easier than W. But of course standardized methods are preferred.
"The exact form of B(x) is an exercise left to the grader."
@@empathogen75 As I think you are saying it is much less work to just use newton's method on the original equation . I am not really impressed with this Lambert W jazz .
I’ll never not be amazed by mathematicians ability to just make stuff up and call it the day
Exactly my thoughts, its fascinating and frustrating at the same time that i have no idea how it works.
LambertW function is not a hack. It's a well-defined and researched function that can be numerically approximated.
I understand why it may feel otherwise, particularly when you're seeing it for the first time. You may consider the situation as similar to how sqrt(-1) may have once felt to you before recognizing the vast world of complex numbers.
@@ir2001 yeah but it’s made up they just said this is now the inverse of that because I say so kind of like imaginary numbers they were just defined as the solution to negative square roots
@@luisfilipe2023 True, but I beg to disagree with the characterization.
Keeping LambertW(x) aside for a moment so as to keep my explanation understandable by means of an analogy, how about ln(x)? You may call it merely an inverse of the exponential function, but on further analysis you would realise that it can be expressed as an integral, which can in turn be computed via numerical approximation methods. Therefore, you get an additional weapon for your Math arsenal.
Essentially, resourceful abstractions help simplify our expressions without loss of precision.
All of mathematics is "just made up". The so-called elementary functions, such as exp, ln, sin, cos, tan, etc. were all made up at one time to solve problems, either purely mathematical or practical. Assigning a name to a particular function which is made up to solve some class of problems makes it easy to then study that function in detail. Such study can involve finding larger classes of problems which it solves, finding efficient numerical methods to find approximations, plotting graphs, studying its domain, range, etc., working out derivatives and integrals, finding a power series, etc., etc. Just look at the Wikipedia page for the Lambert W function to see how much it has been studied, for example.
So it still can't be solved by hand and needs a computer/calculator and I still don't know what a Lambert function is. I'll call it a day.
Can you solve by hand sin(2.71828)?
W is simply defined as the inverse function of z(e^z). Nothing more, nothing less. Just like (one) definition of sin(x) is to consider a unit-radius circle centered at the origin and looking at the relationship between an angle and the vertical coordinate of the point on the circle at that angle.
If we were to replace W with ln or with sqrt in the solution, do you think you'd have been able to get a number without a calculator then?
@@MadaraUchihaSecondRikudoIt’s actually surprisingly easy to calculate square roots (At least of whole numbers). If you convert the number to base 2, there’s a pretty simple pattern that can find the square root by hand.
(There are technically patterns that work for higher bases to find square roots, but they’re fiendishly complicated. The base 2 pattern could be done by the average fifth grader)
@@Programmable_Rook Yeah, but this isn't the sqrt of a whole number, just like this isn't the W of a whole number. My point stands, it's a less well-known but no less well-defined function, whose values you generally need a calculator to find.
Ngl when I saw the question I start by guess it’s 2 and start using the calculator to make the number more specific by adding digits and actually got like 1.7158 sth lol within probably a minute
Learning about the “Goal Seek” feature in Excel alone was worth the cost of admission. Thanks!
I'd never seen that function either.
Cool. I learned it in 1999. But good to see that people are still discovering the program’s features. Let me give you something bigger. Goal Seek can accommodate only one variable, but you can project backward for more variables by using the Solver add-in. With Solver you can get a solution that works for multiple variables and you can even set constraints for them.
@@michaelwisniewski6047 at which point I've gone and gotten my LP solving library ;) (which is probably what excel is doing anyway)
I thought the same!
yeah new thing to learn in excel
I think people are missing the fact that the Lambert W function is not just some arbitrary inverse, otherwise Presh could have just said P(2^x+x) = 5 and stopped there. The Lambert W function has been extensively researched, has a lot of properties, and identities, and is quite useful. This is why Presh went to the trouble to reformulate the problem into the product-log form.
Yeah, plus there are math programs (like Wolfram Alpha / Mathematica) that have a predefined W function for you to use.
You are old
@@Asafh2009 and you are rude.
I will continue to get older and there is nothing I can do about that.
You can choose whether you get ruder or decide instead to take an opposite path.
agreed! people are being a bit ignorant
im sure other inverse functions were once seen in this way as well, being considered "diselegant"
Yeah, it's a known function
I think it would be more interesting to prove that there is a solution... it's not complicated, but it requires more formality than just "solving X"
In my head, I tried x=5/3 and realized it's a bit low. SO I went for 1.7. Then Newton's method: x_new= x- (x log(2)-log(5-x))/(log(2)+1/(5-x)) immediately gives 1.7156 (on a calculator that doesn't have a Lambert function).
😮😮😮
using logarithmic naturally reduces exponents. but no way I'm doing that in my head without scientific calculator or log chart.
In the past, majority of these exams were calculator free. So whenever these type of video mentions Harvard entrance exam or something, assume you can't use calculator.
but in modern times they allow use of calculators with limited functionality.
Even ACT (American College Testing) and other Professional College assessment exams such as MCAT (medical college assessment test) provided their own none scientific calculators in the past.
This magical function lets you solve this without calculator. If you use windows, open up your calculator and set it to standard. that's basically what you were allowed to use IF they allowed calculators.
I remember something from school about Newton-Rapherson approximation of integrals from about 1980. I just did trial and error on a calculator and got 1.7156207 ish in no time. How do you suppose a calculator does logarithms?
@@angrytedtalks It sort of does the same thing. Look up CORDIC. It's an algorithm to find trig functions that they ended up expanding for other transcendental functions from logs to hyperbolics.
Yep newton raphson rocks
Numerical estimation optimization methods are such a blessing to humanity
Sad that i dun remember many of them now
Only newton raphson and steepest hill descent
What's the point of all this when there is no explanation of what the W function does??
W(x) is just a inverse of f(x) = x•e^x. As we don't know how to write it in the algebraic form so we just use symbols.
W(x)=Xe^X is it's definiton.
Do you know precisely what log does? do you know what sine does? do you know what cosh does?
At the end of the day, those functions are defined by what they do, and what they do is well known.
W doesn't evaluate to a nice rational number, because it is based off the number "e", which is a mathematical constant. (like Pi)
W(x) = x*e^X
All you have to do to solve the equation is set the calculator to Wumbo
@@meateaw Small correction - W(x) is the inverse of x(e^x)
how do we input W function on a scientific calculator?
Let me get this straight-you follow up a video about whether 3x5 is the same as 5x3…with this???
🤯
Hahahaha 😂😂
Well, you can't deny that he's got some range to his videos... 😊
ahahhhaaahahah. love it. wish this type of videos were around when I went to high school. then I may have actually grew to like and enjoy math.
Common Core...
It is not a follow up video, it is just two seperate/unrelated videos he is uploading
@@Ninja20704 Lol. Verkuilb meant to follow up a video, not follow-up a video. Lol.
Follow up is verb meaning sequential action. The act of following of a video by releasing another video.
Follow-up is noun or adjective used when describing what you are referring to. A follow-up is a prompt and relevant response to a situation often in context of addressing a problem or providing additional information.
So if you make up a follow-up appointment with a doctor, it means to check up on the same thing again to see how you're doing.
But if you make a follow up appointment with a doctor, it just means your next visit.
And to those complaining, we got a near identical question in our Cambridge maths entrance exam, the very paper I sat had a question with the lambert-W function. Don’t believe me, look up STEP II 2021 Q4. Not something I had ever learnt in school or heard of at the time, but given its introduction I was still able to do the question.
It’s not about solving the question for an exact answer using a calculator, but it’s about understanding and applying new techniques to gain an analytic closed form solution to an unseen problem. It actually tests your true mathematical ability.
This makes a lot of sense. Clever test design
That's fine if you're given the definition of the function. Just expecting people to know of it's existence is not a good question.
@@Crand0m Yeah, if it's meant to test peoples ability to utilize unfamiliar functions, it should first introduce the function that's meant to be unfamiliar to you. This feels like Harvard punishing people for not knowing information that many haven't been taught.
Apologizes for my ignorance, but Is this for undergrad? I find it hard to believe that they give that exam to 18 year olds
@@dylanbowes427 it is indeed, for year 13s (17-18yos). That’s why it has a reputation for being the hardest maths exams in the UK at high school level. Most questions can be solved with basic high school knowledge, but you need to be an excellent problem solver and apply it in clever ways
The Lambert W function was never mentioned in my High School or University maths subjects (in the 1970's !). Thanks for the info.
Hallelujah! Finally someone who has a sane reaction to learning something new. Thank _you!_
I got a PhD in math without ever hearing about it It's not terribly important. But now that it's built-in to mathematical software a bunch of people think it's fair game for math puzzles.
But really, there are countless functions that have inverses that we cannot put in closed form. How interesting is this particular one? I guess it depends on how often you want the inverse of a specific function.
It's nice that Woflram-Alpha apparently has decided to hard-code this, but for the most part we don't want to work with functions that are not in a closed form of combinations of simple computations. Existential proofs that certain functions have inverses aren't very interesting, in general. There are infinitely many (uncountably many!) 1-1 functions and they're all invertible.
I don't see what the appeal is here.
@@rickdesper It has significant amount of use in physics, chemistry and biosciences.
I got a PhD in physics without ever hearing about it. Only in the last about 5 years, I keep seeing TH-cam videos about it... :D But as others already have mentioned: It apparently has lots of applications in physics.
I lost my shoes once. Couldn't find them anywhere. Few weeks later, I'd forgotten that I lost them and went and got them.
It is worth to mention that the Lambert-W function isn't exactly one function. To invert x * e^x in the real domain one needs two different branches of the Lambert-W functions, otherwise there would be two function values for x between -1/e and 0. Meaning that for x between -1/e and 0 only one of the two function branches might give you the desired solution, and in that case it's pretty tricky to know which one. Also, x < -1/e doesn't yield any real solution.
As I was fighting Comment Wars, I also researched that, most of it went above my head as only this semester I'm going to study Complex Analysis so. But it was interesting. I enjoyed it.
The equation we ended up with here, is
u*(e^u) = 32*ln(2)
where u = (5-x)*ln(2) . Since the righthandside , 32*ln(2) , is real and positive, this equation has only one real solution for u ; or in other words, only _one_ branch (of the infinitely many branches) of the Lambert W Function leads to a real solution, namely u = W₀( 32*ln(2) ) .
In general, consider the equation
u*(e^u) = y
If y is real and positive, then only u = W₀(y) is real (and it's also positive); all other branches u = Wₖ(y) would be complex-valued.
If y is real and between -1/e and 0, then both u = W₀(y) and u = W₋₁(y) are real (all other branches would be complex-valued), with W₀(y) being between -1 and 0 , and W₋₁(y) being less than -1 .
If y is real and less than -1/e, then there are no real solutions; all branches u = Wₖ(y) would be complex-valued.
In other words: there are two real branches for W(y) _only when_ y is real ánd between -1/e and 0 .
(Please note: you seem to mix up x and y . If we think of x as the real variable of the real function f(x) = x*(e^x), as your comment seems to be suggesting, then it's y = f(x) that is between -1/e and 0 , for which there exist two real branches of inverses x = W(y) (namely one branch x < -1 , and one branch x between -1 and 0). And for real y > 0 , there is only one real branch x = W(y) , and it's also positive.)
For everyone complaining, consider ln(5) (natural log)
If the answer was ln(5), would you say that it's an exact solution?
If so, why would W(5) (lambert W) not also be an exact solution?
ln() is considered a function in closed form. W() is not. ln x has been computed with a hand-held calculator for a very long time. W() is not easily computable. The Taylor series for ln x is easily written with coefficients in a closed form. The same is not true for W().
@@rickdesper "ln() is considered a function in closed form"
What is that supposed to mean? I never heard about a "function in closed form".
"The Taylor series for ln x is easily written with coefficients in a closed form. The same is not true for W()."
W has a rather simple Taylor series, what are you talking about?!?
@@rickdesper Lambert's W function can be computed with a hand-held calculator using Newton's Method, the same method you would use for calculating log(x) if your calculator doesn't have a log function. The W function also has a Taylor series with coefficients in a closed form. The coefficients for the Taylor series around 0 are (-n)^(n-1)/n!
The issue is that most people would be unfamiliar with W(x), so it should be introduced in the question.
"If so, why would W(5) (lambert W) not also be an exact solution?"
Because the W function is not explained in any detail. Just watching the video, it looks like Presh has pulled a magic word from nowhere and defined it as the solution. This is leaving some of us (or maybe just me) mystified and confused. Now, given any complex equation, it looks like I can define the Mandolinic M function as the solution to that equation. Job done, move on.
ok, but could we just NOT do a Lambert W Function for a week or so? The videos on that topic are getting out of hand...
just.... watch a different video? lol
How did you create that link which leads to search results?
@@ShubhamKumar-re4zvI think TH-cam does that automatically sometimes.
I mean, he could have at least explained how the wolframalpha calculates LamW
@@SchildkroeteHundFisch Yes I also think so as the search link is not clickable now
*_U 2 to the Power of U_*
...sounds like a power ballad by Prince💜
Nothing Compares to U
@@otakurocklee ...apart from 5 - _x_ 😆
You are so right. That should be a song. Shades of "2 divided by zero" by the Pet Shop Boys.
Or "One and One is One" by Medicine Head: the greatest Boolean logic single of all time!
When Presh said "...and all that remains is to show that...", the auto-caption capitalized All That Remains, because it is a metalcore(?) band :D
I solved the problem in a slightly different way, and got x = log2( W(32 * ln(2)) / ln(2) ). When I plugged it into a calculator, I got the same result as Presh: 1.71562.
I was a bit freaked out as to how two different-looking answers could give the same result without any obvious conversion between them, but then I noticed that both answers contain W(32 * ln(2)) / ln(2). If we call that quantity Y, then Presh's answer was x = 5 - Y, and mine was x = log2(Y). The only way these two answers could be the same is if Y = 5 - x = 2^x, which would imply that 2^x + x = 5, and oohhhh I get it now.
@@danmerget EXCELLENT!! That is just 1 of the many reasons that I love math - that there's more than just 1 way!!
Play around on the calculator for a minute and x is something like 1.71562
No idea how you're supposed get that ..
High school maths to solve is assume f(x) = 2^x+ x-5 and use Newton raphson method.
xn1= xn0- f(xn0) /f'(xn0)
That does not give the actual solution, but only an approximation to the solution.
@@bjornfeuerbacher5514 So does the useless W function.
@@1yoan3 The video showed the solution, and the W function is anything but useless. You make no sense.
@@bjornfeuerbacher5514Depends on whether you can do long division by hand - most can
@@xzxz214 ??? Sorry, I don't understand at all what this has to do with long division.
Lambert “don’t know what to do” function
Wish harvard was this easy to get into for asians.
Regarding the transcendental equation in this question, one ultimately needs a calculator.
But using graphing calculators is not it, anyone can do it.
Instead doing it with a normal scientific calculator will be the best thing to ask i believe.
And God said: THERE IS ... a function that can do everything you can't do. Use it and pretend you have an understanding of why this is good.
I have gone 42 years since looking at that function, our HS physics 2 teacher taught it in the last few weeks of class. Haven't seen it since.
I’d have just started plugging in values between 1 and 2 until getting close enough 😂
I always forget about the Lambert function because W(x) doesnt mean anything to me. Plus, minus, square root, etc all have common sense meanings but it seems to me that W is an implied logic function as opposed to a mechanical function. If you say the solution is W(32ln2) its not clear what that is in real numbers or even a ballpark guess.
The Lambert W function is just a terrible function to work with. It's a mess to calculate, it has two separate branches on part of its domain (because x*e^x isn't one-to-one over its range), and it has sum and difference formulas that are a pain to remember. I can't believe a problem requiring its use appears on a college entrance exam.
It's not "clear" because you are not familiar with the function. How much is sin(2.71828)? Someone not familiar with trigonometric functions would have no clue; that does not make it poorly defined.
I don't understand what you mean by "mechanical function" - W is neither more nor less mechanical than (say) sin.
Draw a graph of the relation/function y = f(x) = x*(e^x) . Since 32*ln(2) is real and positive, W( 32*ln(2) ) is the x-coordinate of the _only point_ on the graph for which the y-coordinate equals 32*ln(2) .
In general,
W(y) * e^W(y) = y .
@@ThreePointOneFou A simple approach to this problem would be to rewrite the equation as 2^x = 5 - x , then sketch the graphs of f(x) = 2^x and g(x) = (5 - x) into one diagram, and estimate the coordinates of the intersection point of f(x) and g(x) . No Lambert W Function needed. (This approach would also demonstrate clearly that there exists only one real solution.)
I actually think the lambert w function is a legitimate way to solve it, but if you just want a numerical answer, newton’s method would have been a lot faster.
I wish all maths problems could be solved by making up a function that solves the problem and then using it to solve the problem.
Thanks. Very educational.
The next question is: How does a calculator calculate W(x)?
Similar to how is SQRT(x), SIN(x), LN(x), etc. calculated?
Usually these are all approximated using series expansions for the functions. Which ones are used depends on the implementation; historically (40 years ago, when I had to write routines for those things as part of my education) it was a trade off between speed of convergence and amount of memory required to achieve the desired precision. Nowadays, I suspect people go for speed a lot more...
First thing I noticed about the answer is that it is very nearly sqrt(3), which is probably just a coincidence.
Not very nearly actually only up to 1 decimal place.
√3 = 1.732050807568877...
I saw the same approximation, but with (e-1)=1.71828
Probably also a coincidence, but now with logarithms.
1/Sqrt(2)-1
seen too many bprp videos and i immediately knew that lambert w function would be the key to solving
Same lmao. Quite suprised he showed prime newtons videos instead of his, even tho both are very good
fish e to the fish
first try x=1 and x=2 to see that the solution must be closer to 2 than 1.
now assume x = 2 - y and use 1st-order Taylor for exponential [note: 2^x = exp(x.ln2)].
then you get a linear equation in y with solution y = 1/(1+4.ln2) = 1/(1+4*0.69) = 0.265 (surely every one remembers ln(2)=0.69 ... think about half-life of exponential decays like in radioactivity).
this then gives x = 2 - y = 1.735 without use of any special functions or a calculator ... all paper and pencil.
and x = 1.735 is pretty close to the actual answer of 1.7156.
I like this one and this is also what I did. You can also do the next order Taylor expansion for 2^x and just get a quadratic equation to manage. You can get within 1% of the right answer that way...
Never heard of Lambert W… should be added to the calculus class where logarithms and natural logs are covered.
It definitely should. The "problem" with it is that it requires complex analysis to understand it properly, but that was never an issue with roots, so I don't see why not!
Another name for it is the “Product Log function”
@@asparkdeity8717
Is that really a name for it?
@@feartheengage yes
@@DemoniqueLewis I suppose you don’t need CA to learn it in the same way sqrt(x) is taught as the inverse of x^2 on a cut domain, which is taught in schools. It would be really nice to learn the common real properties of it though as with any other elementary function like log (domain, range, sketch, derivatives and integrals etc…)
OTHER SOLUTION -> It would’ve also been possible to use Newton technique to solve the non-linear equation. The problem is equivalent of finding the root of f(x) = 2^x + x -5. You can then use the algorithm x_(n+1) = x_n + f(x)/f’(x) with a desired precision to solve. Finally for the initial approximation you could simply use something between 1 and 2 juste by looking at the equation. By doing multiple iteration, the algorithm would converge toward the numerical solution.
That depends on whether finding a numerical approximation counts as "solving."
bro humiliated me (an indian 9th grader) in every single way by saying, "i wasn't able to go to harvard, that's why i went to stanford 0:23 ". btw: thanks for uploading such glorious content, your daily uploads makes my day, everyday.
Tbh they gotta make math questions MORE tricky, not More harder if you know what I'm saying.
this problem isnt actually that hard
it's just a series of intuitive substitions
ive seen harder local math olympiad problems tbh
@@KookyPiranha It's trivial, provided you know what W(x) is. Unless they introduced it before this question, this entrance exam seems more like a mathematics themed trivia quiz.
@@psychopompous489 it's likely this is just a normal problem and they introduced the wx function in the description of the problem
Simply use Foggy’s F-function which outputs x whenever its argument is 2^x+x, yielding the straightforward solution x=F(5) in the problem above.
Ok, but the W remain and it solved like a deus ex machina...
The W is quite a bit like normal logarithms, you usually "solve" them as well by means of the deux ex machina that we call a calculator (except no ordinary calculator has the W function). Side note: I'm 50 with an MSc in applied physics, and I heard of the W function only a few years ago. Definitely never learned about it in school...
in math, you often answer with functions. its same as answering with x = sin (x) or fun(x) = x^2
as long as its actual function that works in that specific general instance, its acceptable answer. since it saves time on writing out the entire page of equations.
would you rather write
X = 5 - w(32ln2)/ln2
or
x = 5 - {ln(x/lnx) - {ln(x/lnx)/[1+ln(x/lnx)]} ln(1-lnlnx/lnx)}(32ln2)/ln2
i
@@Yiryujin the second One. I don't Need elegance if not explained. Moreover in the video Is talked like and operator like sin and cos (without demonstration ok) but you associate It like a substitution (nothing special if you think It would have been the third One in the example)
@@bjorneriksson2404 I never had problema using adanced physical or mathematicians feaurre, still my First time hearing about W -function
@@lucabastianello9830 Actually, the two expressions are NOT equivalent. The second one is an expression representing a lower bound for W in the original solution.
It is an operator - or better, a multi-branched function. Neither more nor less so than the 'normal' logarithm.
I don't have an exact solution, but with just a basic calculator and guess and test methodology I got to the approximation of x=1.715 in about 2 minutes.
By using trial and error one can show the x lies between 2 and 1...and by choosing the mid section of this range, such that x=3/2....we find that the answer is much closer to 5....so the the range is between (3/2 , 2)
By minimizing the range :
(3/2 + 1/5 , 2 - 1/5)...
,one can get an approximate answer
As he explained in the video (2:45 to 2:55), there are cases in which you want to have an exact solution, not only an approximate one.
I'd seen the function a lot before, but this really crystallised the solving algorithm for me. Thanks!
10:45 to me X really isn’t any clearer or better defined than it was at the beginning of this problem smh
Do you think that x in 5^x = 2 is better defined?
(I think it's just that you are not familiar with W - in principle it's no different than any other function)
@@dlevi67 well I liked it better that way…
Joking aside No I’m not familiar with W Lambert function haha
@@GY9944I strongly suggest you try it cuz it can be very fun
@@dlevi67i think you just aren’t familiar with 5^x=2
@@peterpumpkineater6928 Absolutely. One cannot be familiar with the transcendent except in its symbolic form.
I solved this using Newton Raphson method. I think that method is more intuitive than using an obscure function.
I am writing this comment before I watch the video, and will edit it after I watch it. My initial impression from just the thumbnail is... no way would a college entrance exam question involve the Lambert W function, right? Nobody would expect high school kids to know about the Lambert W function, right?
EDIT: ...huh.
Possibly not - but if this were an interview question (rather than a written one), the interviewer could ask something like "imagine that you have a function that is the inverse of x(e^x) - could you solve it then?"
We literally got a question like this in our STEP exam for Cambridge maths, despite having never learnt it in school. It’s about how you well and quickly you are able to understand and apply totally new concepts
It's a fairly well-known tactic for top-level universities. That's why they sell their own math and physics textbooks to prepare students for entrance exams.
@@CodecrafterArtemis You misspelled scam.
Is x just “-3” ?
but what does Lambert W function do?
It enables you to solve equations involving a mix of polynomials and exponentials.
Typical problem in math exams. It’s not really a question where you use your insane abstract mind. It’s rather „ Do you know the pattern” type of question. Would never do it without lambert func
All of Higher Math's videos are about this base use of the Lambert function😂 What a joke,lol. I doubt it has anything to do with any entrance exam ever!
Lambert function is, imo, just a way to write x=something where you have an expression you can't analitically explicitate.
It may be the way they wanted at that entrance exam. I would've just proceeded by writing it as 2^x = 5-x then plotting y=2x and y=5-x and figure out an approximate value by trials choosing the starting value of x by that graphic.
i doubt any of his videos are real entrance exams questions
The Qs and tasks are not the hardest ones, but I like the way you treat them when providing other related info, context, connections.
@Blackpenredpen does a lot of videos (think a whole playlist's worth) re: Lambert W function and explains it rather well... Bonus - he also uses "fish" to explain it! 😂
Alive without breath;
As cold as death;
Never thirsting, ever drinking;
Clad in mail never clinking.
Drowns on dry land,
Thinks an island
Is a mountain;
Thinks a fountain
Is a puff of air.
So sleek, so fair!
What a joy to meet!
*****************
We only wish
To catch a fish,
So juicy-sweet!
I got a degree in Engineering and can say with confidence that 99.9% of the stuff I learned has never shown up in my life again. The stupidity of reality becomes the real problems you gotta deal with.
I believe my first comment "disappeared"...
@Presh- Thanks very much.
I'll look into Lambert W
(I did attempt a guess at x=1.7; but it was a guess, and not a solution.
Take good care, Presh.
Thanks again !
2^x + x = 5, 2^x = 5-x = y = => x = 5 - y. 32*2^(-y) = y, y*2^y = 32. y*e^(ay) = 32, where a = log(2). (ay)e^(ay) = 32a > 0 = => ay = W0(32a) = => x = 5 - W0(32a)/a.
There is a second branch of W-function, W(-1)(z), for z < 0. W function's branches cannot be expressed in terms of elementary functions.
never thought that I would dislike a video from this channel, until I watched this one..
There is an imaginary function to un do that. 😊
Here is a quick way to approximate: It’s easy to argue that there is a single unique solution 1 < x < 2 because at x=1, 2^x + x = 3 and at x=2, it’s 6. Linear interpolation would give x=1.67, but we know the function 2^x + x is convex, so the solution should be a bit higher, so we will round it up and say roughly 1.7.
Once Presh went to an interview for the job at a Maths institute. The interviewer asked every candidate the same question - "Do you stand for humanity?" Many candidates replied yes and were rejected instantly. A candidate even replied no but was also rejected.
When Presh was asked the same question, he said - "Your question has ambiguity. Does "U" mean the letter U or me as a person? Be clear cause the probability of my replies will change.
Interviewer said - "Should we appoint you as the chairperson of this institute?"😂😂😂
If it was the letter "U" he would have used "Does" instead of "Do".
Hence the interviewer definitely meant "you". (Considering he had the basic language knowledge)
@@vinaykumaryadav7013😂😂
What about the interviewee who responded, “I’d rather sit for humanity. I already got my steps in for today.” ?
@@vinaykumaryadav7013 Actually the interviewer asked: Do "U"s stand for humanity? but in sloppy way of pronunciation. 🤠
@@verkuilb instantly rejected
i think we can use series expansion of 2^x and use as many terms as required to round up to correct answer (i.e first three terms give 1.75177), in the end it will be about solving a polynomial
Lambert was the kind of mathematician who was too embarrassed to admit he could not solve unsolvable equations. Hence he made up one to solve them 😂
To be fair, it has an infinite series approximation the same as sin and cos and nobody calls those fake
Well periodicity does help a lot ;)
@@GDyoutube2022 Log and exp also have infinite series approximations, and they are not periodic in R.
@@dlevi67 to that I'll say that it does help a lot to be single-valued ;)
i have an easier way to solve this (by approximation) (calculator not used)
2^x + x is an increasing function so we check by putting value the range of x b/w to natural numbers
x equals 1 gives 3
x equals 2 gives 6
x equals 3 gives 11 and so on
now we have got that 1
An economy university student once taught me to make a graphic instead of trying to solve it mathematical. And you can also try out numbers with decimals to get a good rounded result. It took me 4 attempts to get to 1.8. I tried 1 -> 3, 2 -> 6, 1.5 -> 3.75, 1.8 -> 5.04. 1 was too small and 2 too big. Looking at the results it must between 1.5 and 2, but closer to 2. Hence 1.8 was chosen as the next input. If I continue for more decimals then 1.79 -> 4.9941, 1.791 -> 4.998681, etc. The time to do this with a calculator beats the mathematical solve, which you also have to round up or down.
One thing I realized in math is that devision comes befoure multiplication and why is no one talking about it.
it has 2 complex and one real solutions. however, newtons procedure did not find
a result:
10 print "mind your decisions-solving a harvard university entrance question"
20 z=5:sw=z/19:goto 40
30 a=ln(abs(sin(b)/b))/ln(2):dg=exp(a*ln(2))*cos(b):dg=(dg-a-z)/z:return
40 b=-5:gosub 50:goto 100
50 gosub 30
60 b1=b:dg1=dg:b=b+sw:if b>20*z then stop
70 b2=b:gosub 30:if dg1*dg>0 then 60
80 b=(b1+b2)/2:gosub 30:if dg1*dg>0 then b1=b else b2=b
90 if abs(dg)>1E-10 then 80 else return
100 gosub 110:goto 120
110 print "x=";a,"%",b;"*i":return
120 b=b+sw:gosub 50:gosub 110
130 x=-10:print "die reelle lösung ist x=";:goto 150
140 dg=(2^x+x-z)/z:return
150 gosub 140
160 x1=x:dg1=dg:x=x+sw:x=x+sw:x2=x:gosub 140:if dg1*dg>0 then 160
170 x=(x1+x2)/2:gosub 140:if dg1*dg>0 then x1=x else x2=x
180 if abs(dg)>1E-10 then 170
190 print x
mind your decisions-solving a harvard university entrance question
x=-5.0304466 % -3.24091965*i
x=-5.03046368 % 3.04819125*i
die reelle lösung ist x=1.71562073
>
run in bbc basic sdl and hit ctrl tab to copy from the results window
Another simple but laborious method can be the so called "bifurcation" method. i x =2, 2^x+x=6 if x=1 then 2^x+x=3. Therefore, the value of x must be between 1 and 2. let's take a half of 1+2 which is 1.5. Then solve it and if we take enough iterations we reach the value of 1.76...
2^x + x - 5 = 0
Substitute -3,-2,-1, 0, 1, 2, 3
to see which values give a negative and positive answer and by how much.
The answer will be a value between the two answers where the sign switches.
In this case x =1 and x=2
Substitute fractions in between to find the answer.
I always like to solve these problems iteratively. In this case, start with a guess for x0 between 0 and 5. The next iteration x1 comes from setting 2^x1 +x0 = 5 or x1 = (ln(5-x0))/ln(2). The next iteration gives x2 = (ln(5-x1))/ln(2), and so on. This converges rapidly. If you try it the other way, ie, 2^x0 +x1 = 5 or x1 = 5 - 2^x0, it doesn't converge.
Presh, this was a really well-paced and thorough explanation of the Lambert W function. Great job! Would you do a sequel looking at the sort of calculus needed to derive the approximate value?
This equation was actually easier than people think, Most of it is just ln.
highly interesting. will now be reading about the definition of the W function.
thank you.
The W function is cool. And it lets you carry around an exact form, it’s still approximate when reduced to numbers. It would be nice to include it in BLAS software
if x = 1 then 3 = 5
if x = 2 then 6 = 5
1 < x < 2
5 - 3 = 2
6 - 3 = 3
2/3 = 0,6667
Meaning that x is approximately 1,6667
Then using calculator I refined it to 1.71562
My initial approximation was less than 3% off
So why is the w function gives just x? What does it do to xe^x?
I love your videos. You do an excellent job of explaining everything!
why in the definition of 2^u = e^(u ln2) at 8:54 it didnt just simplified to 2^u = 2e^u?
so when subtituted in the main equation, then it could turn into a way simpler form of 16 = ue^u, thus without the need of v definition and get rid off the ln2?
Because 2^u = e^(u*ln(2)) doesn't simplify to 2e^u .
Just try random values for u , such as u = 0 or u = 1 . Clearly, 2^u does _not_ equal 2e^u .
@@yurenchu ok, thats fair. but it doesnt algebraically explains why it cant be, since you could do e^(u ln2) = e^u • e^ln2 = e^u • 2.
am i missing some important requirements to such simplification be valid?
also, u already cant be 0 or 1 by definition (domain?) as a limitation from the equation, it would break if so at 32 = u2^u
(this is also implied by x can't be 5 for the same reason)
thinking about it now, i guess that your contradiction isnt so valid since it may actually mean that, yes, u cant be 0 or 1, but as an incognito from the equation we are trying to find which value it may assume so the expression is valid, right?
@@eduardocortes6340 You're mixing up e^[u * ln(2)] with e^[u + ln(2)] .
e^[u + ln(2)] = e^[u] * e^[ln(2)] = e^u * 2 = 2(e^u)
vs.
e^[u * ln(2)] = (e^u)^[ln(2)] = (e^[ln(2)])^u = 2^u
Also note that 2^u = e^[u*ln(2)] is an _identity_ , not an equation. An identity is _always_ true, hence an identity holds for any value of u (such as, for example, for u = 0 and u = 1 ; inserting random values of u is a way to check if a statement is an identity). An equation isn't always true, it's only true as a condition for the problem under consideration, which means a particular value of u must be derived for which the equation holds true.
Other examples:
(cos(x))² + (sin(x))² = 1 is an identity, not an equation. If you try to solve for x, you'll find that any value of x will do; because the statement is true for any value of variable x .
x² = 14x - 40 is an equation. It's not generally true (for example, if x = 3 then LHS = 9 and RHS = 2 , which isn't a match, so the statement is not true for x=3), but the assignment here is to solve for the particular values of x for which the statement becomes true. Those particular values are x = 4 and x = 10 , hence x=4 and x=10 are solutions to this problem.
In the video, Presh wants to solve the equation
32 = u*(2^u)
One step towards a solution is by rewriting (part of) the RHS by using the identity 2^u = e^[u*ln(2)] ; because that way, the equation becomes
32 = u*e^[u*ln(2)]
(which is a statement that is _equivalent_ to the previous equation 32 = u*(2^u) )
and so he's a step closer to an equation of the form c = v*(e^v) , which he can eventually solve by using the Lambert W Function.
I hope that helps.
@@eduardocortes6340 You're mixing up e^[u * ln(2)] with e^[u + ln(2)] .
e^[u + ln(2)] = e^[u] * e^[ln(2)] = (e^u) * 2 = 2(e^u)
vs.
e^[u * ln(2)] = (e^u)^[ln(2)] = (e^[ln(2)])^u = 2^u
Yes, we are trying to find the values of u for which the equation
32 = u * e^[u*ln(2)] [Equation 1]
is valid. That means that we can't just substitute e^[u*ln(2)] in the righthandside with 2(e^u) , because the statement e^[u*ln(2)] = 2(e^u) is not generally true, it's only true for a particular value of u, and that particular value is probably _not_ the value(s) of u for which Equation 1 is true. Therefore, the substitution would be illegitimate.
Likewise, you wouldn't solve the equation
13 = 3 + u + u
by replacing u+u in the righthandside with (let's say) u^3 , right? No, you would replace u+u with 2u , because u+u = 2u is generally true (and hence useful here), while u+u = u^3 is not generally true (and hence illogical here).
Luckily for me as a terrible math student AI solved it for me in 1.25 seconds.
Somehow I got into Harvard without having ever heard of the Lambert-W function. Go figure. Thanks, Presh, for the introduction. I'll do some more research into it. 🤓
I am ecstatic that I even remembered there WAS a Lambert W function
9:09 at this step couldn’t we separate e^uln2 as e^u + e^ln2 . And e^ln2 is just 2 as we defined earlier right? So couldn’t we bring that over to the LHS and so it’s 16=ue^u?
First 2 methods gave me enough precision.
One of the best ads for excel of all time
Euler would weep if he saw this
You’re not gonna believe this.. but Euler is the one who actually described the function back in 1783 😂
Euler was just derived this function using the Lagrange Inversion Formula.
Simply put value of x to make LHS equal to RHS. If we put 1 we got 3 which is less than 5 then for x=2 we got 6 which is greater than 5 so the answer is between 1 to 2 . If it is Mcqs so easily got it . For accurate answer we have to go for newton raphson method by which we will get the answer 1.71…
Interesting, but this begs the obvious question: how do we calculate W(32 ln(2))?
How do you calculate ln(32 + 2^π)?
There are series expansion formulae for both...
@dlevi67 So, it's a function whose calculation is very complicated and, therefore, is beyond the scope of this video? Looking at other comments and their replies, it seems that I should see it just like sin or log: a well-defined function that isn't really practical to calculate by hand.
@@TheJaguar1983 Yes, that's exactly what it is - more than complicated, I'd say awkward, though, at least for x>0.
Unlike sin or log that have 'nice' series expansions, where a pattern is apparent (x/1 -x^2/2 + x^3/3 ...; x/1 -x^3/3! + x^5/5! ...), W's expansion is quite gnarly. The first 5 terms read: x - x² +3x³/2 - 8x⁴/3 + 125x⁵/24 - ...
Then there is the "complication" that W (like the complex logarithm) is multi-branched, and the above expansion only holds for values near 0... so perhaps complicated _is_ the right term! 😁
EDIT - screwed up copying the expansion formula - sorry.
Some people are taking the Lambert W function for granted, as if they don't calculate log, sin, cos, tan using a calculator.
you can also arrive at an approximate value using the Taylor Series at a=1.5. This simplifies the equation to a polynomial and we all can solve polynomials :3
I used 1.5 as an estimate. Inserting x=1 is too small and x=2 is too large. So the actual answer might be around the middle. The higher order of derivatives you go, the more accurate answer you can get. But just the first derivative also approximates the answer quite well.
Ive lost my trust in youtubers. I’d love to say i learned something but now that u didn’t explain the inner workings of the W function I’m going to need to watch another video to learn about that. Thanks
There are no more "inner workings" to it than the definition, which Presh has spent the first half of the video in explaining. What "inner workings" are there to the square root of something?
I used Newton's method by hand one time and got 1.794 but there may have been arithmetic errors. No one said anything about an exact solution so I'm satisfied.
I'm glad I stopped trying to solve it after a while on my own. All I know are basic log rules. At some point you just realize there are only so many ways to rewrite the equation and you need some help :P. I have never heard of the Lambert W function before, but it sure was interesting to learn about it, especially with copilot's help. So I assume the lambert W function is in our calculators somewhere? It better be or I have no idea how the harvard students are doing this exam! I assume its all still paper and pencil
If you're going to magically introduce things like Lambert W-functions, then you might as well just say "x = f^(-1)(5), where f(x) = 2^(x) + x".
Thankyou Presh for explaining it so nicely.
I like how every single video with a bs thumbnail has a bs answer or missing conditions
I left the video disappointed that W wasn't really explained. How does a computer evaluate it?
My wife saw the thumbnail and said negative 3 I'm gonna watch your video to see if she's right.
It's easier to just do it graphically, no need for fancy functions. I just input y=2^x and y=5-x into a graphing calculator and found that x=1.71562.
Oh! so the whole idea is to convert the equation from its implicit form to its explicit form in x and then use a so called function or simply a computer program to get it solved for us. Interesting. Btw Good job Presh to bring up this problem!
It's a standard non-elementary function with 250+ years of study behind it. Not a "so called function" that someone has made up just now.
@dlevi67 I'm sorry dear..
By "so called", I didn't mean to detract such a useful function.
With little knowledge about the function on my part ,I just said this...but l really like your sincere approbation towards Mathematics.😊
@@sumanjangid1250 No need to apologise - it was just meant as a clarification that Lambert's W isn't something made up by Presh on the hoof (which seems to be a rather pervasive idea in the comments). Sorry if it came across as too abrupt!
Researched too much about tetration and already knew the answer would involve Lambert W function
Binary search in to get approximated answer as answer lies between 1 and 2 and function is increasing.
I don’t know why I’m watching the video
Perhaps a more neat form of the solution: log2(W(32*ln(2))/ln(2))
Now I just need to find an algorithm for calculating W.
I estimated "about 1.7" in 10 seconds without a calculator by plugging in 2 and immediately roughly estimating that it was about 1.7.
I also immediately thought of using a graphing calculator, but I thought that would be cehating
I was able to get an exact number by just plugging in values of x. No one does this and its probably just cheating but it works really well and no one uses it.
@@metalsplash310 Testing things "by inspection" is done by a lot of people in a lot of contexts. It's not 'cheating', but probably neither is it what the writers of the questions expected as an initial answer.
BTW - you are _not_ getting an exact number. You are getting an approximation. The solution is an irrational (in fact, transcendental) number.
Yeah but you don’t get a calculator in your Harvard Interview
But what is the lambert W function as in what is the calculator doing to figure out that decimal approximation.
W is the inverse of x(e^x). There is no 'simple' expression of that inverse function in terms of elementary functions - unlike say cosh(x) = (e^x + e^-x)/2. You can approximate the value by using a series expansion, but unlike sin or log that have 'nice' series expansions, where a pattern is apparent (x/1 -x^2/2 + x^3/3 ...; x/1 -x^3/3! + x^5/5! ...), W's expansion is quite gnarly. The first 5 terms read: x - x² +3x³/2 - 8x⁴/3 + 125x⁵/24 - ...
The best I could aproximately think is that: easilly we see that 1.5
Rabbit-out-of-the-hat function and hey-presto!! How is that working with Taylor Series etc, to get a better feeling for the approximative answer?