Pendulum question- Angular momentum-impulse The pendulum of mass m and length l is released from rest at $\theta=0$. Using only the
principle of angular impulse and momentum, determine the expression for
$\ddot \theta $ in terms of $\theta$, and find the velocity v, of the pendulum at
$\theta=90\unicode{xb0}$
. Compare this approach with
a solution by the work-energy principle.  
I can easily solve using the work- energy principle. But the other approach wasn't clearly explained in the answers:
$\sum M=\dot H : mg\ell cos(\theta)=\frac{d(m\ell^2 \dot\theta)}{dt}\Rightarrow\ddot \theta=\frac{gcos(\theta)}{\ell}$.
What I don't get is this :$\int \dot \theta d\dot \theta=\int \ddot \theta d \theta$  
Note that $\theta$ starts from the horizontal.  
Please explain how they got this. Thanks!

 A: The torque derivation is as follows:
$$ \sum \vec \tau = \frac{\mathrm{d}L}{\mathrm{d}t} $$
The magnitude of the torque (measuring $\theta$ with respect to the horizontal) is:
$$ |\vec{\tau}| = mgl\cos\theta $$
The angular momentum $L$ is given by:
$$ L = mr^2\omega = ml^2\frac{\mathrm{d}\theta}{\mathrm{d}t} $$
So the rate of change of angular momentum is:
$$ \frac{\mathrm{d}L}{\mathrm{d}t} = ml^2\frac{\mathrm{d}^2\theta}{\mathrm{d}t^2}$$
Which gives the differential equation:
$$ mgl\cos\theta = ml^2\frac{\mathrm{d}^2\theta}{\mathrm{d}t^2} $$
$$ \frac{\mathrm{d}^2\theta}{\mathrm{d}t^2} - \frac{g}{l}\cos\theta = 0 $$
Without going into elliptic integrals, the most you can find out of this differential equation is the velocity:
Multiply the differential equation by $ 2\frac{d\theta}{dt} $ and inspect:
$$ 2\frac{\mathrm{d}\theta}{\mathrm{d}t}\cdot\frac{\mathrm{d}^2\theta}{\mathrm{d}t^2} - \frac{2g}{l}\cos\theta\cdot\frac{\mathrm{d}\theta}{\mathrm{d}t} = 0 $$
$$ \left(\frac{\mathrm{d}\theta}{\mathrm{d}t}\right)^2 - \frac{2g}{l}\sin\theta = 0$$
Note that this is pretty much a trick, so it's fair to use. Now you can find the velocity and compare!
EDIT: For clarity, you can use the chain rule to find the angular velocity by using information from the angular displacement:
$$ \dot{\theta} = \frac{\mathrm{d}\theta}{\mathrm{d}t} = \frac{\mathrm{d}\theta}{\mathrm{d}\dot{\theta}}\frac{\mathrm{d}\dot{\theta}}{\mathrm{d}t} = \frac{\mathrm{d}\theta}{\mathrm{d}\dot{\theta}}\ddot{\theta}$$
Which gives the expression you're looking for by rearranging the differentials and integrating:
$$ \int\dot{\theta}\,\mathrm{d}\dot{\theta} = \int \ddot{\theta}\,\mathrm{d}\theta $$
