First change your $\cos^2 \theta$ to $\sin^2 \theta$ using the identity $\sin^2 \theta + \cos^2 \theta = 1$