Two-node Gaussian quadrature with sine weight (source code)

= Two-node Gaussian quadrature with sine weight
{title2=$c_{1,2}=\pi/2\mp\sqrt{\pi^2/4-2},\quad b_1=b_2=1$}

For integration against $\sin x$ on $[0,\pi]$, the monic quadratic <orthogonal polynomial> is $x^2-\pi x+2$. Its two roots are the <Gaussian quadrature> nodes $c_{1,2}=\pi/2\mp\sqrt{\pi^2/4-2}$, with weights one. The rule integrates every cubic exactly: divide it by the orthogonal quadratic and integrate the degree-one remainder.