Triple integral of a function with spatially-dependent coefficients

157 Views Asked by At

I would like to compute the following integral:

$$\int_\Omega f(x, y, z)d\Omega$$

where $\Omega$ is an arbitrary linear tetrahedron and $f$ is a trilinear interpolation. As suggested by Wikipedia, $f$ can be written as

$$f(x,y,z)\approx a_{0}+a_{1}x+a_{2}y+a_{3}z+a_{4}xy+a_{5}xz+a_{6}yz+a_{7}xyz$$

where the coefficients $a_i$ depend on the coordinates and scalar values associated to the eight grid points surrounding the generic point $p(x, y, z)$.

If the vertices of the tetrahedron lie inside a cell, then the coefficient $a_i$ are determined and the computation of the integral can be performed quite easily (map the generic tetrahedron to the reference tetrahedron, compute the determinant of the Jacobian, etc.).

With the term $\textit{cell}$ I mean the eight grid points surrounding the generic point $p(x, y, z)$.

If the vertices of the tetrahedon are distrubuted across more than one cell, then the coefficients $a_i$ vary from cell to cell. So I could split the integral into the sum of the contribution on every cell. However, the domains inside the cells are not necessarily tetrahedra, so it would be necessary to subdivide the polyhedra into tetrahedra. I think that this approach is correct, however is too complicated.

Do you think a simpler approach exists to solve this integral? I would like to exclude the Monte Carlo integration because this integral has to be computed several times.