# Getting different results when doing the Lagrangian of a simple pendulum with different coordinates

I was just testing out the Lagrangian on the simple pendulum and noticed that I got different results based on how I defined theta.

When defining $$\theta$$ from the vertical, we have $$x=r\sin\theta$$ and $$y=-r\cos\theta$$. Then, \begin{align} L&=T-U \\ &=\frac{1}{2}mr^2\dot\theta^2-mgr\cos\theta \end{align} Then the Euler-Lagrange equations give, $$\frac{g}{r}\sin\theta+\ddot\theta=0\tag{1}$$

But when defining $$\theta$$ from the horizontal, we end up with $$\frac{g}{r}\cos\theta+\ddot\theta=0\tag{2}$$

Since (1) and (2) are not the same when considering the small angle approximation, what am I missing here?

The reason for the difference is because of the two different coordinate systems. When defining $$\theta$$ from the vertical axis, the stable stationary point is when $$\theta=0$$ which enables the small angle approximation. However, when defining $$\theta$$ from the horizontal axis, the stable stationary point is at $$\theta=90^\circ$$ and we cannot use the small angle approximation. Instead, we would have to do a slightly different small angle approximation: $$\cos\left(\pi/2\pm\theta\right)\approx\cos(\pi/2)\mp\theta\sin(\pi/2)\simeq\mp\theta$$ which seems to give you the same solution as when considering $$\theta$$ from vertical axis.