Multivariable numerical integration with changing limits

Hi!

I am not very proficient in Julia (or in numerical methods, for that matter), so please be forgiving with my ignorance…

I am trying to numerically integrate a function of the form:

\int_a^b \int_{\underline x(w)}^{\overline x(w)} f(w,x) dx dw

I see that there are several packages (HCubature, Nintegration) that integrate over more than one dimension, but they seem to do it for a fixed hypercube. So that the limits of integration on x are fixed, and do not depend on the value of w.

is there any way to do this? … I am sure I am not the first person with this problem!!!

Thanks a lot!!

1 Like

Transform the problem to a hypercube, eg by mapping [\underline{x}(w), \bar{x}(w)] to [0, 1] using an affine transform that depends on w. Don’t forget to adjust by the Jacobian.

2 Likes

I’ll try!!! :slight_smile: Thanks so much!!!

1 Like

On an unrelated note good to see you diving into Julia, hope my thesis was an inspiration :wink:

:slight_smile: