I am trying to follow an example that does not show how a set of dynamics equations is converted to polar coordinates:
$\theta=\tan^{-1}\frac{x_2}{x_1}$
$\frac{d}{dt}\tan\theta=(\frac{1}{\cos\theta})^{2}\dot\theta$$=\frac{d}{dt}\frac{x_2}{x_1}=\frac{1}{x_1^2}$$(\dot{x_2}{x_1}$$-{x_2}$$\dot{x_1})$
After which point I insert my dynamics and cancel some terms to get...
$=\frac{1}{x_1^2}(-{x_1^2}-{x_2^2})$
$=\frac{1}{x_1^2}(-r^2)$
And now for the last part which I do not follow:
$\bbox[yellow]{=\frac{1}{x_1^2}(-r^2)=-(\frac{1}{\cos\theta})^2}$
So that, finally,
$\dot\theta=-1$
Can anyone please help me understand the part in yellow?
Edit: Any of these systems should produce clockwise limit cycles where $\dot\theta=-1$. See image for examples: Slotine's Applied Nonlinear Control
I still just don't get the part in yellow.
Figured out the step in yellow... Needed Wolfram Alpha for both of these steps lol
$=\frac{1}{x_1^2}(-{x_1^2}-{x_2^2})$
$=-\frac{x_2^2}{x_1^2}-1$
$=-(\tan\theta)^2-1$
$=-(\frac{1}{\cos\theta})^2$
$\dot\theta=-1$