Skip to article frontmatterSkip to article content
Site not loading correctly?

This may be due to an incorrect BASE_URL configuration. See the MyST Documentation for reference.

Practice implementing and analyzing root-finding algorithms.

Self-Assessment Questions

Test your understanding with these conceptual questions:

  1. IVT: If f(0)=2f(0) = -2 and f(1)=3f(1) = 3, what can you conclude about roots of ff in [0,1][0,1]?

  2. Bisection: How many bisection iterations are needed to reduce a starting interval of width 1 to width 10-6?

  3. Fixed Points: Given g(x)=cos(x)g(x) = \cos(x), does the iteration xn+1=cos(xn)x_{n+1} = \cos(x_n) converge? What is the fixed point?

  4. Convergence Rate: If a sequence converges linearly with rate C=0.5C = 0.5, approximately how many iterations to reduce error by a factor of 10-6?

  5. Newton’s Method: Why does Newton’s method fail or converge slowly for f(x)=x3f(x) = x^3 near x=0x = 0?


Bisection Method


Q3.1: Basic Bisection

Consider the function f(x)=x1.1f(x) = \sqrt{x} - 1.1 on the interval [0,2][0, 2].


Q3.2: Finding Roots with Bisection

Using bisection, determine the following roots to within atol=108\texttt{atol} = 10^{-8}. For each, report the solution (8 significant figures) and number of iterations.


Fixed Point Iteration


Q3.3: Cosine Fixed Point

Prove that for any x0Rx_0 \in \mathbb{R}, the iteration xn+1=cos(xn)x_{n+1} = \cos(x_n) converges to a unique fixed point cc. Find cc to at least 12 decimal places.

Hint

It may be helpful to consider h(x)=(gg)(x)=cos(cos(x))h(x) = (g \circ g)(x) = \cos(\cos(x)).


Q3.4: Sine Iteration

Consider the sequence xn+1=sin(xn)x_{n+1} = \sin(x_n) with x0=1x_0 = 1.


Q3.5: Convergence Analysis

For each iteration, determine if it converges to the indicated cc when x0x_0 is sufficiently close. If it converges, find the order of convergence using both graphical analysis and Taylor series expansion.


Newton’s Method


Q3.6: Newton’s Method Applications

Write programs to approximate the following values using Newton’s method with atol=1012\texttt{atol} = 10^{-12}. Use Taylor’s theorem to find a good initial guess.

Hint for (d)

You need an expansion that handles the singularity at π/2\pi/2.


Q3.7: Newton’s Method Basins of Attraction

Apply Newton’s method to f(x)=4x46x2114f(x) = 4x^4 - 6x^2 - \frac{11}{4}.


Q3.8: Multiple Roots

The function f(x)=(x1)2exf(x) = (x-1)^2 e^x has a double root at x=1x = 1.


Q3.9: Division Without Division

Suppose your calculator’s division button is broken (only +, −, × work).

Hint for (a)

To find 1/b1/b, solve f(x)=0f(x) = 0 where f(x)=1/xb=0f(x) = 1/x - b = 0, or equivalently f(x)=bx1=0f(x) = bx - 1 = 0... but that uses division. Try f(x)=1bxf(x) = 1 - bx.


Q3.10: Newton in 2D

Consider the system:

f(x,y)=2x22xy+2y2xy=0f(x,y) = 2x^2 - 2xy + 2y^2 - x - y = 0

g(x,y)=4xy+2=0g(x,y) = 4x - y + 2 = 0

Find an approximate solution by taking 2 steps of Newton’s method starting from (x0,y0)=(2,0)(x_0, y_0) = (2, 0). Compute (x1,y1)(x_1, y_1) and (x2,y2)(x_2, y_2).


Theory Questions


Q3.11: Newton for Multiple Roots

If cc is a root of multiplicity p2p \geq 2, then f(x)=(xc)ph(x)f(x) = (x-c)^p h(x) with h(c)0h(c) \neq 0.

Solution for (b)

Since g(c)=11/pg'(c) = 1 - 1/p is nonzero (for p2p \geq 2), the fixed point theorem gives only linear convergence with rate C=11/pC = |1 - 1/p|.

For a double root (p=2p = 2): C=1/2C = 1/2 For a triple root (p=3p = 3): C=2/3C = 2/3

The convergence slows as multiplicity increases.