0
$\begingroup$

Why does the following approximation work very well for small theta's but not for large theta's?


$$ I = \int_0^\infty x (1 + \theta x)^{-2 \left(\frac{1}{\theta} + 1 \right)} \, \mathrm{d}x $$

Exact evaluation using integration by part

$$ I = \frac{1}{2(\theta + 2)} $$

Approximation using Gauss-Laguerre quadrature $$ I \approx \sum_{k=1}^N w_k \exp(x_k) \, x_k (1 + \theta x_k)^{-2 \left(\frac{1}{\theta} + 1 \right)} $$ where the $x_k$'s and the $w_k$'s can be found, e.g., here.

Comparison (N = 100)

  • theta = 0.5806:

    true = 0.1937534 and approx = 0.1937522

  • theta = 15:

    true = 0.02941176 and approx = 0.01662866


my R-code

#------ package ------
library(gaussquad)
#---------------------

#------ f(x) ------
f <- function(x, theta)
{
  x * (1 + theta * x)^(-2 * ((1 / theta) + 1))
}
#------------------

#------ xk and wk ------
laguerre <- glaguerre.quadrature.rules(n=100, alpha=0, normalized=FALSE)[[100]]
x <- laguerre[, 1]
w <- laguerre[, 2]
#-----------------------

#------ approx ------
approx <- function(theta, x, w)
{
  sum(w * exp(x) * f(x=x, theta=theta))
}
#--------------------

> approx(theta=0.5806, x=x, w=w)
[1] 0.1937522
> approx(theta=15, x=x, w=w)
[1] 0.01662866
$\endgroup$
  • $\begingroup$ Sorry, your integral is not showing up in the post. $\endgroup$ – Ron Gordon Apr 22 '13 at 10:35
  • $\begingroup$ @RonGordon: Should be fixed now. Thanks! $\endgroup$ – Marco Apr 22 '13 at 10:38
  • $\begingroup$ Sorry again, I still cannot see it. $\endgroup$ – Ron Gordon Apr 22 '13 at 10:40
  • $\begingroup$ @RonGordon: Sorry for the trouble! Hope it is ok now $\endgroup$ – Marco Apr 22 '13 at 11:14
  • 1
    $\begingroup$ In that case, maybe you should post your real problem, then. $\endgroup$ – J. M. is a poor mathematician Apr 22 '13 at 13:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.