Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Impossible solving for a variable?

  1. Feb 15, 2007 #1
    I have the equation that's in the attachment. Sorry I don't know how to write the equation here directly. My trouble is more or less like the one in the following example:

    xln(x) + x^2 = 10

    How do I solve for x??

    In the equation that's in the file I'm solving for r3 btw.

    Attached Files:

    • ec..doc
      File size:
      17 KB
    Last edited: Feb 16, 2007
  2. jcsd
  3. Feb 16, 2007 #2


    User Avatar
    Science Advisor
    Homework Helper
    Gold Member
    Dearly Missed

    Forget it, if what you are after is some exact solution.
  4. Feb 16, 2007 #3


    User Avatar
    Science Advisor
    Homework Helper

    Graph intersection is a nice method to find an approximate solution.
  5. Feb 16, 2007 #4
    yeah, graphing is one of the first things I thought of.
    But hell, there has to be a logical solution, I mean, after all, a calculator does a mathematical procedure when it gives you the solution.
    It has to be possible!
  6. Feb 16, 2007 #5

    D H

    User Avatar
    Staff Emeritus
    Science Advisor

    Why would you think that? Your calculator gives an approximate answer when you make it calculate something as simple as 1.0/3.0. You get an approximate answer almost every time you invoke your calculator's trig functions, exponential function, or log function.
  7. Feb 17, 2007 #6


    User Avatar
    Science Advisor
    Homework Helper
    Gold Member
    Dearly Missed

    Why do you think it is illogical that there exists no algorithm that in a finite number of steps gives you the exact solution of some problem?

    After all, even though we know that the number [itex]\sqrt{2}[/itex] HAS a decimal representation it does not at all follow we also have an algorithm that provides us with that representation in a finite number of steps.

    Do you find that illogical as well?
  8. Feb 17, 2007 #7
    So there is no way of manually solving for x then?
    I'll have to do trial and error then...
  9. Feb 18, 2007 #8


    User Avatar
    Science Advisor
    Homework Helper
    Gold Member
    Dearly Missed

    Why trial&error?

    You can perfectly well use any one of a number of numerical techniques available that will give you as good an approximation as your perseverance allows you to get.
  10. Feb 19, 2007 #9
    hmmm i don't get you.
    But please someone tell me yes or no...is there a way to get an exact value for x manually??
    And arildno, what are those techniques, can you please share them with me?
  11. Feb 19, 2007 #10
    An exact value, no. An approximate value, yes.
  12. Feb 19, 2007 #11


    User Avatar
    Science Advisor

    No one can answer your first question until you tell what you mean by "manually"! (Counting on your fingers?:rofl: ) I would interpret "manually" as meaning "without a calculator" but then how are you going to find the logarithm itself?

    A very simple numerical method (a little more sophisticated than "trial and error") is "bisection". First find an interval having a positive value for the function at one end and negative at the other (so you know that, for any continuous function, there is a zero in the interval). Here it is easy to see (using a calculator), with f(x)= xln(x)+ x2- 10, that f(2) is negative but f(3) is positive so there exist a solution between 2 and 3. Try half way between: calculate f(2.5) and see whether it is positive or negative. If it is positive, then there must be a solution between 2 and 2.5. If it is negative, then there must be a solution between 2.5 and 3.0. In either case, try half way between again. Keep doing that until you have enough accuracy.

    "Newton's method" is more sophisticated and more accurate but more difficult to explain- you use the derivative to replace the function, at some starting x, with its tangent line- solve that linear equation for a new "trial" x, and repeat.

    By the way, "trial and error", while not very sophisticated, is a well respected mathematical technique!
  13. Feb 19, 2007 #12
    newton's method works well here

    you'll need the function:

    f (x) = xln(x) + x^2 - 10 = 0

    its first derivative:

    f'(x) = ln(x) + 1 + 2x

    and an initial guess:

    x0 = 1

    x1 = x0 - f(x0)/f'(x0) = 4

    x2 = x1 - f(x1)/f'(x1) = 2.8884219891

    x3 = 2.708932239

    x4 = 2.703818875

    x5 = 2.703814691

    x6 = x5 according to my calculator, we can stop here, it's good enough

    try it out

    (there was a similar post with a similar reply, i'm spreading the newton's method love today :-))
  14. Feb 20, 2007 #13
    wow, thanks a lot to the last two posters, great help at last =)
Share this great discussion with others via Reddit, Google+, Twitter, or Facebook