Fixed point iteration problem

fixed-point-theoremsnumerical methods

So my $f(x)=0$ is:

$$x+e^x+e^{-3x}-4=0$$

Express $x$ as: $$x = 4-e^x-e^{-3x}$$

So my $g(x)$ is: $$4-e^x-e^{-3x}$$
$\varepsilon = 0.0001$

There is my graph, so my start point is $2$ for example ($x_0=2$)

enter image description here

Then I wrote a program which should find the root but I got $-\infty$.

enter image description here

Then I tried to use online programs to find root but they also returned $-\infty$.

I think that the problem is in my $\boldsymbol{g(x)}$

Can anybody help me?

Best Answer

Fixed-point iteration will not work if $|g'(x)|>1$ at the fixed-point, so a different $g$ must be chosen. You could consider instead the following functions for $g$:

$$\ln(4-x-e^{-3x}),~-\frac13\ln(4-x-e^x)$$

To find roots of $f$, other root-finding techniques, such as Newton's method or a bracketing method, could be tried instead. These are usually faster and have more guarantee of convergence.

Related Question