roots_and_optimization
homework 3
i. Compare the number of iterations that each function needed to reach an accuracy of 0.00001%. Include a table in your README.md with:
| solver | initial guess(es) | ea | number of iterations|
| --- | --- | --- | --- |
|falsepos | 1,5 | 3.3027 | 1.1363 e-0.7 |
|incsearch | 1,5 | 66.2618 | 5.0248 e-0.7 |
|newtraph | 1 | 3.4172 e-07 | 802 |
|mod_secant | 1 | 0.0014 | 3 |
convergence of the four different methods falsepos, bisect, newtraph and mod_secant being used to solve for the angle of the projecitle function with an initial velocity of 15 m/s. the approximated error is being plotted against the number of iterations
divergence of Newton-Raphson method
iteration | x_i | approx error |
---|---|---|
0 | 2 | n/a |
1 | 2 | 12.5000 |
2 | 2 | 9.5703 |
3 | 2 | 7.8262 |
4 | 2 | 6.6491 |
5 | 2 | 5.7943 |
| - | -- | --- | | 0 | 0.2 | n/a | | 1 | 0.2 | 1.2500 e+0.3 | | 2 | 0.2 | 1.6531 e+0.5 | | 3 | 0.2 | 4.5122 e+11 | | 4 | 0.2 | 4.5122 e+11 | | 5 | 0.2 | 4.5122 e+11 |
Homework #4