1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Newton's method

  1. May 22, 2010 #1
    1. The problem statement, all variables and given/known data

    Use Newton's method to find the coordinates of the inflection point of the curve y = e^cosx, 0 <= x <= pi, correct to six decimal places.

    2. Relevant equations

    None.

    3. The attempt at a solution

    I calculated y'' (as f(x) in newton formula) and y''' (as f'(x) in newton formula), as they wanted to find the coordinates of the inflection point (when y'' = 0).

    y' = -e^(cosx) * sinx

    y'' = e^(cosx) * ( sinx^(2) - cosx )

    y''' = e^(cosx) * sinx( cosx^2 + 3cosx )

    I then subbed in y'' and y''' into the newton equation and this is where I am having trouble, since when ever I try to use an initial approximation e.g. x1 = 0 or x1 = pi, f'(x1) = 0 which is undefined (from x1 = x2 + f(x1) / f'(x1)
     
  2. jcsd
  3. May 22, 2010 #2

    Mark44

    Staff: Mentor

    Newton's method can be used to find a zero (x-intercept) for a function f(x). For the inflection point, you want to find out where y'' = 0. You have formulas for y'' and y'''. Use them in Newton's method.
     
  4. May 22, 2010 #3
    Yeah I tried that, but when I sub in the beginning (0) and end point of the interval (pi), I get an f'(1) (in the denominator of newtons method) to be 0 which is undefined. Unless I am choosing a wrong initial approximation? Or can you choose any initial approximation?
     
  5. May 22, 2010 #4

    Mark44

    Staff: Mentor

    Start at a different number. You don't have to start at 0.
     
  6. May 22, 2010 #5
    What if when guessing an initial approximation, you guess one which is to the left of the root, and then you keep on taking further approximations from the initial one, wouldnt the tangent lines move to the left, completely missing the root? (refer to diagram)
     

    Attached Files:

  7. May 22, 2010 #6

    vela

    User Avatar
    Staff Emeritus
    Science Advisor
    Homework Helper
    Education Advisor

    Not if you don't make a guess that's too far away. In your picture, for instance, you'd have f(x0)<0 and f'(x0)>0, so x1=x0-f(x0)/f'(x0) will be greater than x0, i.e. you move to the right.

    If you go too far away so that you pass that minimum, then yes, Newton's method will shoot you off in the wrong direction.
     
  8. May 22, 2010 #7
    Then how do you 'guess' without missing the root?
     
  9. May 22, 2010 #8

    vela

    User Avatar
    Staff Emeritus
    Science Advisor
    Homework Helper
    Education Advisor

    You can use your knowledge of the function to make an educated guess; maybe plot it to see what the roots approximately are; if you get a root, make sure it's the one you were looking for; etc.
     
  10. May 22, 2010 #9
    I cant check it by plotting it, as we not allowed calculators in our exam. I read somewhere that choosing the mid-point of the interval (0 <= x <= pi) is a good initial approximation, but for this example, obviously pi/2 doesnt work as f'(x) = 0 which is undefined in the formula (as is 0 and pi)
     
  11. May 22, 2010 #10

    vela

    User Avatar
    Staff Emeritus
    Science Advisor
    Homework Helper
    Education Advisor

    You don't need an exact plot. You're just trying to make a decent guess. There's a reason why you learned how to analyze functions and sketch their graphs.

    For your particular function, you don't even need to plot it. If you look at your expression for y'''(x), you can easily see it's zero when sin x=0 or cos x=0, so avoid those points. If you write y''(x) in terms of only cos x, you see it vanishes when cos2 x+cos x-1=0. You can use the quadratic equation to solve for cos x. Estimate what cos x equals (about 0.6) and then what x equals (around pi/3) and use that as your initial guess.
     
  12. May 23, 2010 #11
    I see. Someone also told me that you could find an initial approximation, by finding where the tangent line crosses the y-axis
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook




Similar Discussions: Newton's method
  1. Newton's method (Replies: 6)

  2. Newtons method? (Replies: 2)

  3. Newton's method (Replies: 3)

  4. Newton's Method (Replies: 3)

  5. Newton method (Replies: 3)

Loading...