= Solution
For distinct <Gaussian quadrature> nodes, let $\ell_i$ be the <Lagrange interpolation polynomial> with $\ell_i(x_j)=\delta_{ij}$. Since $\ell_i^2$ has degree $2n-2$, exactness gives
$$
\boxed{b_i=\sum_jb_j\ell_i(x_j)^2=\int_a^bw(x)\ell_i(x)^2\,dx>0.}
$$
The last inequality follows from $w>0$ on the interval and the nonzero polynomial $\ell_i$ being nonzero on a subinterval. It does not require prior knowledge of the signs of the weights.
For $n=2$, the nodes are the roots of the supplied <orthogonal polynomial> $p_2$:
$$
\boxed{x_1=-\sqrt{2/5},\qquad x_2=\sqrt{2/5},\qquad b_1=b_2=\frac43.}
$$
Indeed exactness for $1$ gives $b_1+b_2=\int_{-1}^1(1+x^2)\,dx=8/3$, and exactness for $x$ gives equality of the weights.
Back to article page