4
$\begingroup$

I need to calculate a quadrature rule with maximum degree of accuracy that looks like this:

$$ \int_0^\infty e^{-x}f(x)dx = \sum_{i=0}^n A_if(x_i) + R_n(f) $$

where $n=2$.

For $R_n(f)$ I have this formula:

$$ R_n(f) = \frac{f^{(2n)}(\xi)}{(2n)!} \, (\pi_n,\pi_n) $$

I've already calculated $A_n$ and $x_n$ and I already know that $\pi_n$ is a Laguerre polynomial.

As joriki pointed out, Laguerre polynomials are orthogonal so I'm left with this:

$$ R_2(f) = \frac{f^{(2n)}(\xi)}{24} $$

My question is: how do I choose $\xi$? Or do I just leave it like that?

  • 0
    How do you mean "choose $\xi$"? Presumably $\xi$ will depend on $f$? Do you mean "find $\xi$ given $f$"?2012-05-29
  • 0
    @joriki: I guess so. Presuming $f(x) = cos(x)$.2012-05-29
  • 0
    I don't understand -- if you're just looking for $\xi$ for $f(x)=\cos x$, you can just evaluate the integral (to $1/2$) and solve the resulting equation for $\xi$?2012-05-29
  • 0
    Also, what's $(\pi_n,\pi_n)$? If this is the scalar product with weight $\mathrm e^{-x}$, it's $1$ since the Laguerre polynomials are orthonormal; if not, what is it?2012-05-29
  • 0
    You're right, it's the scalar product. But I do not have an equation to solve. I have to approximate the integral on the left hand side. See updated question.2012-05-29

1 Answers 1

2

So, to answer my own question, you're not supposed to calculate $\xi$. The remainder term is just a way to gauge how big the approximation error is.

For example, if $f(x)=cos(x)$, the remainder is:

$$ R = \frac{cos(\xi)}{24} $$

which is not so bad, since $cos(x) \in [-1, 1]$.