The Contraction Cobweb

A cobweb spirals into a single point. That point is the fixed point.

Repeatedly apply a map that shrinks distances by a fixed ratio. The points crowd closer and closer together. In the end only one point can remain.

For example, nest a smaller πŸ“¦ box inside a box, then a smaller one inside that, and the boxes close in on a single point. Each step leaves less room than the last.

d(f(x),f(y))≀q d(x,y),β€…β€Šq<1β€…β€Šβ‡’β€…β€Šxn+1=f(xn)β†’xβˆ—d(f(x),f(y)) \le q\,d(x,y),\; q<1 \;\Rightarrow\; x_{n+1} = f(x_n) \to x^*

Part of these learning paths

Examples & Exercises

Show f(x)=x2+1f(x) = \frac{x}{2} + 1 is a contraction with q=12q = \frac12; find the fixed point and the error bound.

xβˆ—=2,∣xnβˆ’2βˆ£β‰€(12)n∣x0βˆ’2∣x^* = 2, \quad |x_n - 2| \le \left(\tfrac12\right)^n |x_0 - 2|
x0=0x_0 = 0, n=8n = 8: the error =0.0078= 0.0078 matches the bound exactly.
Show proof
  1. ∣f(x)βˆ’f(y)∣=∣xβˆ’y2∣=12∣xβˆ’y∣|f(x) - f(y)| = \left|\frac{x-y}{2}\right| = \frac12|x - y|, so ff is a contraction with q=12q = \frac12.

  2. Solving x=x2+1x = \frac{x}{2} + 1 gives xβˆ—=2x^* = 2.

  3. Since ∣xn+1βˆ’2∣=12∣xnβˆ’2∣|x_{n+1} - 2| = \frac12|x_n - 2|, induction gives ∣xnβˆ’2∣=(12)n∣x0βˆ’2∣|x_n - 2| = \left(\frac12\right)^n|x_0 - 2|. For x0=0x_0 = 0, n=8n = 8, the error is 2256=0.0078125\frac{2}{256} = 0.0078125.

Show cos⁑x\cos x is a contraction on [0,1][0,1]; explain the existence and uniqueness of the Dottie number xβˆ—β‰ˆ0.739x^* \approx 0.739.

∣cos⁑xβˆ’cos⁑yβˆ£β‰€sin⁑(1)β€‰βˆ£xβˆ’y∣,sin⁑(1)β‰ˆ0.8415<1|\cos x - \cos y| \le \sin(1)\,|x - y|, \quad \sin(1) \approx 0.8415 < 1
n=20n = 20: the iterates cling to the Dottie number 0.7390850.739085.
Show proof
  1. cos⁑\cos is continuous on [0,1][0,1] and differentiable on (0,1)(0,1), so the Mean Value Theorem applies: some ΞΎ\xi between xx and yy gives ∣cos⁑xβˆ’cos⁑y∣=βˆ£βˆ’sinβ‘ΞΎβˆ£β‹…βˆ£xβˆ’y∣|\cos x - \cos y| = |-\sin\xi|\cdot|x - y|.

    Since ξ∈[0,1]βŠ‚[0,Ο€2)\xi \in [0,1] \subset [0, \frac{\pi}{2}) and sin⁑\sin is increasing on [0,Ο€2)[0, \frac{\pi}{2}), ∣sinβ‘ΞΎβˆ£β‰€sin⁑(1)|\sin\xi| \le \sin(1), so ∣cos⁑xβˆ’cos⁑yβˆ£β‰€sin⁑(1)β€‰βˆ£xβˆ’y∣|\cos x - \cos y| \le \sin(1)\,|x - y|, and sin⁑(1)β‰ˆ0.8415<1\sin(1) \approx 0.8415 < 1, so cos⁑\cos is a contraction.

    Also cos⁑\cos is decreasing on [0,1][0,1] (since (cos⁑)β€²=βˆ’sin⁑<0(\cos)' = -\sin < 0), so cos⁑([0,1])=[cos⁑1,cos⁑0]=[cos⁑1,1]βŠ‚[0,1]\cos([0,1]) = [\cos 1, \cos 0] = [\cos 1, 1] \subset [0,1] (with cos⁑1β‰ˆ0.5403>0\cos 1 \approx 0.5403 > 0) β€” a contraction mapping [0,1][0,1] into itself.

  2. [0,1][0,1] is closed in R\mathbb{R}, hence complete β€” the completeness hypothesis of Banach's theorem holds. Banach's theorem then gives a unique fixed point in [0,1][0,1] β€” the Dottie number xβˆ—β‰ˆ0.739085x^* \approx 0.739085 (the value is from iteration).

Prove in three lines that there is at most one fixed point.

∣xβˆ—βˆ’yβˆ—βˆ£=∣f(xβˆ—)βˆ’f(yβˆ—)βˆ£β‰€q∣xβˆ—βˆ’yβˆ—βˆ£|x^* - y^*| = |f(x^*) - f(y^*)| \le q|x^* - y^*|
Every start gets sucked into the same point xβˆ—=2x^* = 2.
Show proof
  1. Suppose xβˆ—x^* and yβˆ—y^* are both fixed points.

  2. Then ∣xβˆ—βˆ’yβˆ—βˆ£=∣f(xβˆ—)βˆ’f(yβˆ—)βˆ£β‰€q∣xβˆ—βˆ’yβˆ—βˆ£|x^* - y^*| = |f(x^*) - f(y^*)| \le q|x^* - y^*|.

  3. Since q<1q < 1, this forces ∣xβˆ—βˆ’yβˆ—βˆ£=0|x^* - y^*| = 0, i.e. xβˆ—=yβˆ—x^* = y^*.

10. Differentiation