FixedPointList
[f, expr]FixedPointList
[f, expr, n]FixedPointList[Cos, 1.0, 4]
Observe the convergence of Newton's method for approximating square roots:
newton[n_] := FixedPointList[.5(# + n/#) &, 1.];
newton[9]
Compute the Hailstone Number: for 14:
collatz[1] := 1;
collatz[x_ ? EvenQ] := x / 2;
collatz[x_] := 3 x + 1;
list = FixedPointList[collatz, 14]
Plot this:
ListLinePlot[list]