- #1
WraithM
- 32
- 0
So, I'm writing a program in matlab. I have a function of six variables, say f(x1,x2,x3,x4,x5,x6). I want to integrate over x4, x5, and x6 numerically. f is defined over a 10 sided 6-cube of points. I also want to integrate over the whole cube.
So I want,
[tex]F(x_1, x_2, x_3) = \int\int\int f(x_1, x_2, x_3, x_4, x_5, x_6) dx_4 dx_5 dx_6[/tex]
Does anybody have a hint to get me started down some path? I'm really stuck. It's sort of an insane problem.
The internet seems to point me toward monte carlo integration. These methods handle multidimensional integrals well apparently. Can monte carlo methods handle my problem of not integrating over all 6 dimensions? I don't know why I think monte carlo wouldn't, but if so, does anybody have an idea of how to do this? I'm not an expert in numerical integration at all. I'm also not opposed to turning this project into a C program or Mathematica or something. Anything that will solve the problem would be much appreciated!
So I want,
[tex]F(x_1, x_2, x_3) = \int\int\int f(x_1, x_2, x_3, x_4, x_5, x_6) dx_4 dx_5 dx_6[/tex]
Does anybody have a hint to get me started down some path? I'm really stuck. It's sort of an insane problem.
The internet seems to point me toward monte carlo integration. These methods handle multidimensional integrals well apparently. Can monte carlo methods handle my problem of not integrating over all 6 dimensions? I don't know why I think monte carlo wouldn't, but if so, does anybody have an idea of how to do this? I'm not an expert in numerical integration at all. I'm also not opposed to turning this project into a C program or Mathematica or something. Anything that will solve the problem would be much appreciated!