Secant method used on x^3-2x+2 w/ x0=0, x1=1; what is x2,x3?

calchere

Junior Member
Joined
Sep 13, 2006
Messages
50
1) If we use the secant method on f(x) = x^3-2x+2 starting with x0 = 0 and x1=1, what is x2, and x3.
2) If the secant method is used on f(x) = x^5 + x^3 + 3 and if xn-2 = 0 and xn-1 = 1, what is xn, xn+1, and xn+2.

The equation i'm using for the secant method:

\(\displaystyle x_{n + 1} = x_n - (\frac{{x_n - x_{n - 1} }}{{f(x_n ) - f(x_{n - 1} )}})f(x_n ) \\\)

For number 1 i get:

\(\displaystyle x_2 = x_1 - (\frac{{x_1 - x_0 }}{{f(x_1 ) - f(x_0 )}})f(x_1 ) \\\)

\(\displaystyle x_2 = 1 - (\frac{{1 - 0}}{{1 - 2}})(1) = 2 \\\)

\(\displaystyle x_3 = 2 - (\frac{{2 - 1}}{{6 - 1}})(6) = 10.8 \\\)

I don't think this is right. I thought that x should be closing in on 1.769..., but i can't see what i'm doing wrong.

For number 2, i get:

\(\displaystyle x_n = 1 - (\frac{{1 - 0}}{{5 - 3}})(5) = 2.5\)

i didn't go any further because xn should equal -2/3.

Not sure what i'm doing wrong. Any help would be appreciated.
Thanks.
 
calchere said:
1) If we use the secant method on f(x) = x^3-2x+2 starting with x0 = 0 and x1=1, what is x2, and x3.
The Secant Method is used to find the roots of a function numerically. For (1), your calculations appear to be correct for x[sub:dwsuppe1]2[/sub:dwsuppe1], but you might want to check your work for x[sub:dwsuppe1]3[/sub:dwsuppe1]:

. . . . .\(\displaystyle x_3\, =\, 2\, -\, \left(\frac{2\, -\, 1}{6\, -\, 1}\right)\, (6)\, =\, 2\, -\, \left(\frac{1}{5}\right)\, (6)\, =\, 2\, -\, \frac{6}{5}\, =\, \frac{4}{5}\)

Since the actual root is around x = -2, it may take a while for this process to converge, given the inital starting values.

calchere said:
2) If the secant method is used on f(x) = x^5 + x^3 + 3 and if xn-2 = 0 and xn-1 = 1, what is xn, xn+1, and xn+2.
For the second exercise, you have f(0) = 3 and f(1) = 5, so:

. . . . .\(\displaystyle x_n\, =\, 1\, -\, \left(\frac{1\, -\, 0}{5\, -\, 3}\right)\, (5)\, =\, 1\, -\, \left(\frac{1}{2}\right)\, (5)\, =\, 1\, -\, \frac{5}{2}\, =\, -\frac{3}{2}\)

I don't see how you arrived at a value of +2.5...? But I would guess that the "-2/3" in the solutions is a typo. :wink:

Eliz.
 
Thanks. It looks like i was subtracting before i was multiplying. I don't know why i was doing this.

Thanks again.
 
Top