# Doing a phase-space portrait in matlab

1. Sep 18, 2013

### bagram

So I have this system of equations:

$$\binom{x_{n+1}}{y_{n+1}}=\begin{pmatrix}e^{r} & 0 \\ 0 & e^{-r} \end{pmatrix}\begin{pmatrix}cos(\phi+I_{n}) & -sin(\phi+I_{n}) \\ sin(\phi+I_{n}) & cos(\phi+I_{n}) \end{pmatrix}\begin{pmatrix}x_{n}\\ y_{n} \end{pmatrix}$$

where
$$I_{n}=x_{n}^2+y_{n}^2$$

I have no idea how to plot that in matlab as a phase-space portrait...

Any help would be great

2. Sep 19, 2013

### kreil

What have you tried?

In general you would compute the derivatives at t=0 on a grid, then plot them as a vector field using the quiver() function.

3. Sep 19, 2013

### bagram

i've tried, generating a set and points and just sketching it and tried using the ezsurf/surf function to do it... but both ways failed. Does completing the derivative at t=0 the same as n=0?