Back to index

salome-med  6.5.0
Barycentric coordinates algorithm

Computation of barycentric coordinates is used to fill interpolation matrix in case of P1 an P1d types of interpolation.

Computation of barycentric coordinates consists in finding weights of vertices bearing values within the cell. The cell is triangle in 2D space and tetrahedron in 3D space.

Input of the algorithm includes

Purpose is to find coefficients so that

Combining the last two expressions we get an equation in matrix form a * T = ( b - pn ) where

In 2D case solution is found by inversing T which is trivial: a = T^(-1) * ( b - pn )

In 3D case we use Gaussian elimination algorithm. First we use elementary row operations to transform T into upper triangular form and then perform back substitution to find coeficients a.