Equating Coefficients of Cos and Sin

ordinary differential equationspolar coordinates

I've got a nonlinear system
\begin{align}
x'&=\frac{1}{2}x-y-\frac{1}{2}(x^3+y^2x)\\
y'&=x+\frac{1}{2}y-\frac{1}{2}(y^3+x^2y)
\end{align}

I am to analyse the system when the system is changed to polar coordinates. The writer of the book states that he computes the following
\begin{align}
r'\cos\theta-r(\sin\theta)\theta'&=x'=\frac{1}{2}(r-r^3)\cos\theta-r\sin\theta\\
r'\sin\theta+r(\cos\theta)\theta'&=y'=\frac{1}{2}(r-r^3)\sin\theta+r\cos\theta
\end{align}

And by equating the coefficients of $\cos\theta,\sin\theta$ he gets the following system
\begin{align}
r'&=r(1-r^2)/2\\
\theta'&=1
\end{align}

My issues is then:

I'm not sure where he gets the following identities
\begin{align}
r'\cos\theta-r(\sin\theta)\theta'&=x'\\
r'\sin\theta+r(\cos\theta)\theta'&=y'
\end{align}

And I'm not that familiar with the equating coefficients method, so I've read a bit about it, and I can't seem to compute the presented system.

If I were to make a phase portrait of the system, would the axis be $r'$ and $\theta'$?

Source: [c. 8, p. 162], Differential Equations, Dynamical Systems & An Introduction to Chaos (2nd Ed) by Morris W. Hirsch, Stephen Smale and Robert L. Devaney.

Best Answer

$$\begin{cases} x=r\cos(\theta) \\ y=r\sin(\theta) \end{cases}\qquad \begin{cases} x'=r'\cos(\theta)-r\sin(\theta)\theta' \\ y'=r'\sin(\theta)+r\cos(\theta)\theta' \end{cases} $$ $$\begin{cases} x'=r'\cos(\theta)-r\sin(\theta)\theta'=\frac12r\cos(\theta)-r\sin(\theta)-\frac12r^3\cos(\theta) \\ y'=r'\sin(\theta)+r\cos(\theta)\theta'=r\cos(\theta)+\frac12 r\sin(\theta)-\frac12r^3\sin(\theta) \end{cases} $$

$x'\cos(\theta)+y'\sin(\theta)=r'=\left(\frac12r\cos(\theta)-r\sin(\theta)-\frac12r^3\cos(\theta) \right)\cos(\theta)+\left(r\cos(\theta)+\frac12 r\sin(\theta)-\frac12r^3\sin(\theta) \right)\sin(\theta)$

and after simplification : $$r'=\frac12r-\frac12r^3$$

$-x'\sin(\theta)+y'\cos(\theta)=r\theta' =-\left(\frac12r\cos(\theta)-r\sin(\theta)-\frac12r^3\cos(\theta) \right)\sin(\theta)+\left(r\cos(\theta)+\frac12 r\sin(\theta)-\frac12r^3\sin(\theta) \right)\cos(\theta)$

and after simplification :

$$r\theta'=r\qquad;\qquad \theta'=1$$

The equations in the book are correct.

Related Question