# Cobweb Diagrams

Iterations of the recursive equation

\left\{ \begin{align*} a_0 &= c \\ a_{n+1} &= 1+\frac{1}{a_n},n\geq0 \end{align*} \right.

can be illustrated by using a so called cobweb diagram.

## Slope of the Function

Any point that is "close enough" to an attracting fixpoint will end up at the fixpoint when iterated. The slope of the function at the fixpoint decides whether the fixpoint is repelling or attracting (or neither).

## Exercises

### Exercise 1 - Make a cobweb diagram using GeoGebra

• Input a function $$f(x) = 1+1/x$$, a line $$y = x$$ and a point $$A$$ on the $$x$$-axis.
• Use the tool Perpendicular line and intersection points to mark all points of the diagram. Zoom in when you get close to the fixpoint. Let the diagram start at the point $$A$$.
• Hide all lines and create segments between the points. Hide all points except for $$A$$.
• Choose the tool Input box. Enter f(x) = as caption and the function $$f(x)$$ as linked object.

### Exercise 2 - Make a cobweb diagram using the spreadsheet.

• Input a function $$f(x) = 1+1/x$$, a line $$y = x$$ and a point $$A$$ on the $$x$$-axis.
• Choose View -> Spreadsheet in the menu.
• Enter x(A) in cell A1
• Enter f(A1) in cell B1
• Enter (A1, B1) in cell C1
• Enter (B1, B1) in cell D1
• Enter x(D1) in cell A2
• To show the segments:
• Enter Segment[C1, D1] in cell E1
• Enter Segment[C2, D1] in cell F2
• Make relative copies.
• Choose the tool Input box. Enter f(x) = as caption and the function $$f(x)$$ as linked object.

### Exercise 3 - Repelling and attracting fixpoints

Use a GeoGebra-file showing a cobweb diagram. Create a slider m and check out the diagram using the function :

$f(x) = 1+m x$

For what slopes is the fixpoint attracting/repelling?

### Exercise 4 - Logistic map

Use a GeoGebra-file showing a cobweb diagram. Create a slider r and check out the diagram using the function

$f(x) = r x\cdot (1-x)$

where $$0\le r \le 4$$. Try to find values of r that illustrate:

• convergence towards $$0$$.
• convergence towards a fixpoint $$\ne 0$$.
• jumps between two values.
• jumps between four values.
• a seemingly chaotic behaviour.