Gaussian quadratures: Adaptive method

125 Views Asked by At

In my book I was asked to find the gaussian quadrature on the form $$ \int_0^1 f(x)\mathrm{d}x \approx W_0 f(x_0) + W_1 f(x_1) $$ With weight $w(x)=1$ and where $x_0$ and $x_1$ are the zeros of the quadratic polynomial orthogonal on $(0,1)$. Eg $$\phi_2(x) = x^2 - x + 1/6$$ The weights $W$ are given as $$ W_0 = \int_0^1 w(x)\left(\frac{x - x_1}{x_0 - x_1}\right) \mathrm{d}x \quad \text{and} \quad W_1 = \int_0^1 w(x)\left(\frac{x - x_0}{x_1 - x_0}\right) \mathrm{d}x $$ So summarizing I get that $$ \int_0^1 f(x)\mathrm{d}x \approx \frac12f\left(\frac{3-\sqrt3}{6}\right) +\frac12f\left(\frac{3+\sqrt3}{6}\right) $$ Which seems correct. The question is now to find an adaptive rule based on $$ \int_a^b f(t)\mathrm{d}t = \sum_{j=0}^{n-1} \int_{t_j}^{t_j+h} f(t)\,\mathrm{d}t\,,\quad t_j = a + jh\,,\quad h = \frac{b-a}{n} $$ For the integral $$ \int_0^1 \frac{1}{1+t} \mathrm{d}t $$ By using the substitution $t = t_j + h(1+x)/2$ I can rewrite the integral into $$ \sum_{j=0}^{n-1} \int_{t_j}^{t_j+h} f(t)\,\mathrm{d}t = \sum_{j=0}^{n-1} \int_{-1}^{1} f\left( t_j + h \frac{1+x}{2}\right)\,\mathrm{d}x $$ My question is, is it possible to use the quadrature form I found in b) to evaluate the integral? Or do I need to find new orthogonal polynomials and new weights? I know that the polynomials on (-1,1) are the well known langrange polynomials, but finding the weights is still somewhat tedious, so It would be very nice to be able to use the form from (0,1).