Knowing that $\tan\alpha$ , $\tan\beta$ are roots of the quadratic equation $x^2+px+q=0$ ;
Compute the expression $\sin^2(\alpha +\beta) +p\sin(\alpha +\beta) \cos(\alpha +\beta)+q\cos^2(\alpha +\beta$)
My Working :
Sum of the roots are : $\tan\alpha +\tan\beta = -p; $ product of the roots $\tan\alpha \tan\beta = q; $
After putting these values of roots in the given equation I got :
$x^2-(\tan\alpha + \tan\beta) x + ( \tan\alpha \tan\beta) =0$
Please suggest whether is it correct method of approaching this or some other better method. Thanks..