I'll take the picture.
[tex]\frac{1+cos\theta}{sin\theta}+\frac{sin\theta}{cos\theta}=\frac{cos\theta+1}{sin\theta{cos\theta}}[/tex]
Multiply by [tex]sin\theta{cos\theta}[/tex] to get:
[tex](1+cos\theta)sin\theta=cos\theta+1[/tex], which means that [tex]sin\theta=1[/tex], like wtf?
I guess you got to this result.
Btw, if it's an equation you get that [tex]\theta=k\pi[/tex], for k integer.