I have a mesh with irregular hexaedra and I need a fast way to interpolate values at points inside these cells. I know that trilinear interpolation does not work well for large skews. Barycentric coordinates work for tetrahedrons. Is there any equivalent method for hexaedra, which is really efficient, possibly parallelization-friendly?

  • $\begingroup$ No. They can be random as well. $\endgroup$ Commented Sep 17, 2017 at 16:25
  • 2
    $\begingroup$ I don't know what rectangular prisms are (or 4-sided prisms as in the title). Are you talking about a hexahedron? $\endgroup$ Commented Sep 17, 2017 at 22:46
  • $\begingroup$ yes! I couldn't recall the name. $\endgroup$ Commented Sep 17, 2017 at 22:49
  • $\begingroup$ the google books preview of TJ Chung's CFD book looks useful: books.google.com/… $\endgroup$ Commented Sep 19, 2017 at 1:26

1 Answer 1


A hexahedron with straight edges is the image of the unit cube under a trilinear mapping. So, if you have values on the eight vertices of a hexahedron, and you are asking to interpolate between them to a point $x$ somewhere inside the hexahedron, then the correct approach is as follows:

  • Invert the trilinear mapping to find the corresponding point $\hat x = \Phi^{-1}(x)$ on the reference cell.
  • Use the trilinear shape functions on the reference cell to evaluate at $\hat x$ to obtain the interpolated value of your function based on the values at the vertices.

The second step is easy. The first requires inverting the mapping $\Phi$, which in general requires a nonlinear Newton iteration because it is a nonlinear, polynomial you are inverting.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.