2
$\begingroup$

I'm trying to solve a nonlinear system of algebraic (not differential) equations which involves double integrals. I want to use Matlab. There seems to be two functions that can do double integration: dblquad and quad2d.

I noticed that the latter is much faster than the former (100+ times). But I don't know the accuracy. I used both functions to evaluate my integrals (which involves bivariate normal density) and got different answers. I chose a rectangular region around the mean in both cases, since Matlab (I think most numerical algorithms) seems to have difficulty finding the substantial values of the integrand if the region is too big and gives me 0.

My question is: does anyone know the difference of these two functions (in terms of integrating mechanism) as well as accuracy?

Thanks.

  • 0
    Ah, so my guess that `quad2d` didn't sufficiently sample your function was correct.2011-05-03

0 Answers 0