We want the x where the curve y = cos x meets the line y = x.Pick a starting value x₀.Go up to the curve: that height is cos x₀.Go across to the line y = x: this turns the height into the next x.Up (or down) to the curve again …… and across to the line again.The path winds inwards like a spiral.Every loop lands closer.Up to the curve …… across to the line.It settles at 0.739: the fixed point, where x = cos x.
In plain words
Rewrite the equation as x = g(x)
Put a guess into g; the result is the next guess
If g is "flat enough" near the answer, the guesses settle down
New words today
fixed point
a value that g leaves unchanged: r = g(r)
iterate
one of the successive guesses x₀, x₁, x₂, …
cobweb diagram
the up-and-across picture on the left
converges if
|g′(x)| < 1 near the root
contraction
a g that pulls any two points closer together
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
4 / 21
The idea: a fixed point of g
Rewritef(x)=0⟺x=g(x)
Iteratexn+1=g(xn),n=0,1,2,…
A fixed pointr satisfies r=g(r): g leaves it unchanged
Geometrically: where y=g(x) meets the line y=x
If the iterates converge to some r and g is continuous, then r=g(r), so f(r)=0
Example: x=cosx is already in this form; g(x)=cosx
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
5 / 21
One equation, many rearrangements: x2−4x−10=0
Rearrangement x=g(x)
how
g′(x)
∣g′(r)∣ at r=5.7417
verdict
x=4x+10
move x2, take root
4x+102
0.348
converges
x=4x2−10
solve for the 4x term
2x
2.871
diverges
x=x−410
factor x(x−4)=10
(x−4)2−10
3.297
diverges (goes to the other root)
x=4+x10
divide by x
x2−10
0.303
converges (spirals)
Roots: x=2±14, i.e. 5.741657 and −1.741657. Every rearrangement has the same fixed points, but only some lead there.
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
6 / 21
When does it converge?
Error recursion (mean value theorem)xn+1−r=g(xn)−g(r)=g′(ξn)(xn−r)
Convergence condition∣g′(x)∣≤L<1 near r⟹∣xn−r∣≤Ln∣x0−r∣→0
Each step multiplies the error by about g′(r): linear convergence, rate ∣g′(r)∣
∣g′(r)∣>1: errors grow, the iteration moves away from r
Smaller ∣g′(r)∣ = faster; g′(r)=0 is very fast (that is Newton, next lecture)
Steps for tolerance ε: n≈lnLln(ε/e0); here ln0.348ln(0.00005/0.742)≈9.1 → 10 ✓
Compare: x=cosx has L=sin(0.739)=0.674: 36 iterations for 6 decimals
L close to 1 means painfully slow; L>1 means divergence
Rule of thumb
Digits per iteration
Each iteration gains about −log10L correct decimal digits. L=0.348: 0.46 digits per step. L=0.1: one digit per step. Bisection (L=21): 0.3 digits per step.
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
12 / 21
Fixed-point iteration in Python and C
A guard on ∣x∣ stops runaway (divergent) iterations
Change g to the other three rearrangements
Print the ratio of successive differences: it approaches g′(r)
Try g(x)=cosx and g(x)=e−x
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
13 / 21
Choosing g for x3+x−1=0 (root 0.6823)
g(x)
∣g′(r)∣
result from x0=0.5
1−x3
1.397
diverges (oscillates and grows)
1+x21
0.635
converges: 21 iterations to 4 dp
(1−x)1/3
0.716
converges, slower
Newton: x−3x2+1x3+x−1
0
converges fast: 4 iterations
The last row is a sneak preview: choosing g cleverly makes g′(r)=0. That choice is Newton's method (Lecture 9).
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
14 / 21
When to use it
Fixed-point iteration: method profile
Best case
∣g′(r)∣ small: Kepler's equation E=1+0.1sinE converges in 5 steps
g′(r)=0: much faster than linear (this is Newton's method, L9)
The problem is already in the form x=g(x): no derivative, one line of code
Worst case
∣g′(r)∣ close to 1: x=cosx needs 36 steps; Kepler with e=0.9 needs 11
∣g′(r)∣>1: diverges, e.g. x=(x2−10)/4 for the root 5.7417
The choice of g is guesswork without the ∣g′∣<1 test
Best suited for
Equilibrium problems: PageRank, Bellman value iteration, EM, Kepler's equation
Large linear systems (Jacobi, Gauss–Seidel are fixed-point iterations, L14)
Quick prototypes where a contraction g is obvious
Avoid when
No rearrangement with ∣g′∣<1 is known
High accuracy is needed quickly (linear convergence)
You need a guarantee from any start (use bracketing)
Rule of thumb: check ∣g′∣ before iterating; the smaller it is, the fewer steps you need (about −1/log10∣g′∣ steps per digit).
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
15 / 21
Comparison
Comparative analysis so far: x2−4x−10=0 (root 5.741657)
Method
Start
Iterations for 10−6
Needs
Guaranteed?
Bisection
[5,6]
20
sign change
yes
False position
[5,6]
5
sign change
yes
Fixed point, g=4x+10
x0=5
14
a good g
only if ∣g′∣<1
Fixed point, g=(x2−10)/4
x0=5
diverges from 5.74
a good g
no
Fixed-point iteration is not faster here than false position, and it can fail. Its value is the idea: Lecture 9 builds the best possible g, with g′(r)=0.
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
16 / 21
Roadmap
Limitations, and where we fix them
Fixed-point iteration introduced open methods and the convergence rate ∣g′(r)∣. Its weaknesses point to the next lectures:
Click a card: each one is literally x←g(x) repeated until it stops changing.
🌐 PageRank
Where exactly: the core of Google's original ranking. The rank vector is the fixed point of r←dMr+N1−d, with damping d=0.85 acting as the contraction factor.
Three pages: A links to B and C; B links to C; C links to A
Start with r=(1/3,1/3,1/3) and apply the update repeatedly
Each page gives its rank, times 0.85, equally to the pages it links to; everyone gets 0.05
Page
A
B
C
rank after convergence
0.3878
0.2148
0.3974
28 iterations to 10⁻⁶. C ranks highest: two pages link to it. Google ran the same iteration on billions of pages.
🛰️ Kepler's equation: satellite positions
Where exactly: every GPS receiver computes satellite positions from broadcast orbit data. The key step solves Kepler's equation for the eccentric anomaly E, given the mean anomaly M and eccentricity e.
E=M+esinE(g(E)=M+esinE,∣g′(E)∣≤e<1)
iteration
1
2
3
4
5
E (M=1, e=0.1)
1.084147
1.088390
1.088588
1.088597
1.088598
Since |g′| ≤ e, the iteration always converges for an orbit (e < 1); GPS orbits have e < 0.02, so a few iterations suffice. For very elliptical orbits (e = 0.9) it needs 11 steps; Newton needs 6 (Lecture 9).
🎮 Reinforcement learning: value iteration
Where exactly: planning in Markov decision processes. The value function is the fixed point of the Bellman operator.
V(s)←amax[R(s,a)+γs′∑P(s′∣s,a)V(s′)]
The Bellman operator is a contraction with factor γ (the discount): exactly our ∣g′∣≤L<1
So the error shrinks like γn: with γ=0.9, each digit costs about 22 iterations
This is why RL becomes slow as γ→1
Same theorem as today, applied to a vector of state values instead of a single number.
🧮 Jacobi iteration for big linear systems
Where exactly: solving Ax=b with millions of unknowns (heat flow, circuits, PageRank). Rewrite each equation for its own unknown and iterate.
xi←aii1(bi−j=i∑aijxj)
It converges when the matrix version of |g′| < 1 holds: the spectral radius of the iteration matrix is below 1 (for example when A is diagonally dominant).
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
18 / 21
Practice
Practice problem
Problem 2"State the condition of convergence of the iteration method xn+1=g(xn) and explain why the choice of g matters. Illustrate with x2−4x−10=0."
How to write a complete answer
Condition: ∣g′(x)∣<1 in an interval around the root containing all iterates (sufficient)
Reason in one line: en+1=g′(ξ)en (mean value theorem)
Illustrate: 4x+10 (∣g′∣=0.35, converges) vs (x2−10)/4 (∣g′∣=2.87, diverges)
Mention: convergence is linear; the smaller ∣g′(r)∣, the faster
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
19 / 21
Checkpoint
Checkpoint · think, then discuss with your neighbourFor x=g(x) with g(x)=3x2+2, does iteration converge to the root r=1?
AYes, ∣g′(1)∣=2/3<1
BNo, ∣g′(1)∣=2/3
CYes, g(1)=1
DNo, ∣g′(1)∣>1
A. g′(x)=2x/3, so ∣g′(1)∣=2/3<1: converges (staircase, since g′>0). The other root r=2 has g′(2)=4/3>1: iteration moves away from it.
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
20 / 21
Summary
Key points
Rewrite f(x)=0 as x=g(x) and iterate xn+1=g(xn)
Converges if ∣g′(x)∣<1 near the root; diverges if ∣g′(r)∣>1
Linear convergence: error × ∣g′(r)∣ per step; steps ≈ ln(ε/e0)/lnL
The rearrangement decides everything; always check ∣g′∣ before iterating
Choosing g with g′(r)=0 gives fast convergence: Newton's method
Opening problem: solved
cos settles because near 0.739 its slope is ∣−sinx∣=0.674<1 (a contraction); tan never settles because its slope sec2x≥1 everywhere.
Homework
Solve x=e−x by iteration from x0=0.5 to 4 decimal places. How many iterations?
Find two rearrangements of x3−2x−5=0: one that converges near x=2.09 and one that does not. Justify with g′.
Write a C program that reads x0 and prints the iterates of g(x)=cosx until 6 decimals agree.
Lab: in the cobweb tab, find a g whose iterates oscillate between two values forever.
Next lecture
Newton–Raphson. Use the tangent line: the fastest of the classical methods, with digits doubling each step, and some spectacular failures.
Md Mahbub E Noor
Lecture 8: Fixed-Point Iteration
University of Barishal
21 / 21
Keys →Space next step · ← back A reveal the whole slide number + Enter jump to slide S slide list · F full screen · N notes [] previous / next lecture · L lab In a code box: Ctrl+Enter runs the code